12.12.18 problem 20

Internal problem ID [1872]
Book : Elementary differential equations with boundary value problems. William F. Trench. Brooks/Cole 2001
Section : Chapter 7 Series Solutions of Linear Second Equations. 7.2 SERIES SOLUTIONS NEAR AN ORDINARY POINT I. Exercises 7.2. Page 329
Problem number : 20
Date solved : Tuesday, March 04, 2025 at 01:45:27 PM
CAS classification : [[_2nd_order, _exact, _linear, _homogeneous]]

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

Using series method with expansion around

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

Maple. Time used: 0.003 (sec). Leaf size: 48
Order:=6; 
ode:=(3*x^2+6*x+5)*diff(diff(y(x),x),x)+9*(1+x)*diff(y(x),x)+3*y(x) = 0; 
dsolve(ode,y(x),type='series',x=-1);
 
\[ y = \left (1-\frac {3 \left (x +1\right )^{2}}{4}+\frac {27 \left (x +1\right )^{4}}{32}\right ) y \left (-1\right )+\left (x +1-\left (x +1\right )^{3}+\frac {6 \left (x +1\right )^{5}}{5}\right ) y^{\prime }\left (-1\right )+O\left (x^{6}\right ) \]
Mathematica. Time used: 0.001 (sec). Leaf size: 70
ode=(5+6*x+2*x^2)*D[y[x],{x,2}]+9*(x+1)*D[y[x],x]+3*y[x]==0; 
ic={}; 
AsymptoticDSolveValue[{ode,ic},y[x],{x,-1,5}]
 
\[ y(x)\to c_1 \left (-\frac {93}{20} (x+1)^5+\frac {17}{8} (x+1)^4+(x+1)^3-\frac {3}{2} (x+1)^2+1\right )+c_2 \left (\frac {9}{5} (x+1)^5+2 (x+1)^4-2 (x+1)^3+x+1\right ) \]
Sympy. Time used: 0.791 (sec). Leaf size: 36
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((9*x + 9)*Derivative(y(x), x) + (3*x**2 + 6*x + 5)*Derivative(y(x), (x, 2)) + 3*y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics,hint="2nd_power_series_ordinary",x0=-1,n=6)
 
\[ y{\left (x \right )} = C_{2} \left (\frac {27 \left (x + 1\right )^{4}}{32} - \frac {3 \left (x + 1\right )^{2}}{4} + 1\right ) + C_{1} \left (x - \left (x + 1\right )^{3} + 1\right ) + O\left (x^{6}\right ) \]