54.7.10 problem 10 (as series)

Internal problem ID [8658]
Book : Elementary differential equations. Rainville, Bedient, Bedient. Prentice Hall. NJ. 8th edition. 1997.
Section : CHAPTER 18. Power series solutions. 18.9 Indicial Equation with Difference of Roots a Positive Integer: Logarithmic Case. Exercises page 384
Problem number : 10 (as series)
Date solved : Wednesday, March 05, 2025 at 06:11:43 AM
CAS classification : [_Bessel]

\begin{align*} x^{2} y^{\prime \prime }+x y^{\prime }+\left (x^{2}-1\right ) y&=0 \end{align*}

Using series method with expansion around

\begin{align*} 0 \end{align*}

Maple. Time used: 0.020 (sec). Leaf size: 52
Order:=8; 
ode:=x^2*diff(diff(y(x),x),x)+x*diff(y(x),x)+(x^2-1)*y(x) = 0; 
dsolve(ode,y(x),type='series',x=0);
 
\[ y = \frac {c_{1} x^{2} \left (1-\frac {1}{8} x^{2}+\frac {1}{192} x^{4}-\frac {1}{9216} x^{6}+\operatorname {O}\left (x^{8}\right )\right )+c_{2} \left (\ln \left (x \right ) \left (x^{2}-\frac {1}{8} x^{4}+\frac {1}{192} x^{6}+\operatorname {O}\left (x^{8}\right )\right )+\left (-2+\frac {3}{32} x^{4}-\frac {7}{1152} x^{6}+\operatorname {O}\left (x^{8}\right )\right )\right )}{x} \]
Mathematica. Time used: 0.016 (sec). Leaf size: 75
ode=x^2*D[y[x],{x,2}]+x*D[y[x],x]+(x^2-1)*y[x]==0; 
ic={}; 
AsymptoticDSolveValue[{ode,ic},y[x],{x,0,7}]
 
\[ y(x)\to c_2 \left (-\frac {x^7}{9216}+\frac {x^5}{192}-\frac {x^3}{8}+x\right )+c_1 \left (\frac {5 x^6-90 x^4+288 x^2+1152}{1152 x}-\frac {1}{384} x \left (x^4-24 x^2+192\right ) \log (x)\right ) \]
Sympy. Time used: 0.768 (sec). Leaf size: 26
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x**2*Derivative(y(x), (x, 2)) + x*Derivative(y(x), x) + (x**2 - 1)*y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics,hint="2nd_power_series_regular",x0=0,n=8)
 
\[ y{\left (x \right )} = C_{1} x \left (- \frac {x^{6}}{9216} + \frac {x^{4}}{192} - \frac {x^{2}}{8} + 1\right ) + O\left (x^{8}\right ) \]