54.7.8 problem 9

Internal problem ID [8656]
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 : 9
Date solved : Wednesday, March 05, 2025 at 06:11:40 AM
CAS classification : [_Jacobi]

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

Using series method with expansion around

\begin{align*} 1 \end{align*}

Maple. Time used: 0.021 (sec). Leaf size: 50
Order:=8; 
ode:=x*(1-x)*diff(diff(y(x),x),x)+2*(1-x)*diff(y(x),x)+2*y(x) = 0; 
dsolve(ode,y(x),type='series',x=1);
 
\[ y = \left (1-2 \left (x -1\right )-3 \left (x -1\right )^{2}+2 \left (x -1\right )^{3}-\frac {5}{3} \left (x -1\right )^{4}+\frac {3}{2} \left (x -1\right )^{5}-\frac {7}{5} \left (x -1\right )^{6}+\frac {4}{3} \left (x -1\right )^{7}+\operatorname {O}\left (\left (x -1\right )^{8}\right )\right ) c_{2} +c_{1} \left (x -1\right ) \left (1+\operatorname {O}\left (\left (x -1\right )^{8}\right )\right )+\ln \left (x -1\right ) \left (2 \left (x -1\right )+\operatorname {O}\left (\left (x -1\right )^{8}\right )\right ) c_{2} \]
Mathematica. Time used: 0.383 (sec). Leaf size: 69
ode=x*(1-x)*D[y[x],{x,2}]+2*(1-x)*D[y[x],x]+2*y[x]==0; 
ic={}; 
AsymptoticDSolveValue[{ode,ic},y[x],{x,1,7}]
 
\[ y(x)\to c_2 (x-1)+c_1 \left (\frac {1}{30} \left (-42 (x-1)^6+45 (x-1)^5-50 (x-1)^4+60 (x-1)^3-90 (x-1)^2-90 (x-1)+30\right )+2 (x-1) \log (x-1)\right ) \]
Sympy. Time used: 0.889 (sec). Leaf size: 12
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x*(1 - x)*Derivative(y(x), (x, 2)) + (2 - 2*x)*Derivative(y(x), x) + 2*y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics,hint="2nd_power_series_regular",x0=1,n=8)
 
\[ y{\left (x \right )} = C_{2} \left (x - 1\right ) + C_{1} + O\left (x^{8}\right ) \]