36.5.9 problem 9

Internal problem ID [6353]
Book : Fundamentals of Differential Equations. By Nagle, Saff and Snider. 9th edition. Boston. Pearson 2018.
Section : Chapter 8, Series solutions of differential equations. Section 8.3. page 443
Problem number : 9
Date solved : Sunday, March 30, 2025 at 10:53:14 AM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

\begin{align*} \sin \left (x \right ) y^{\prime \prime }-\ln \left (x \right ) y&=0 \end{align*}

Using series method with expansion around

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

Maple. Time used: 0.012 (sec). Leaf size: 90
Order:=6; 
ode:=sin(x)*diff(diff(y(x),x),x)-y(x)*ln(x) = 0; 
dsolve(ode,y(x),type='series',x=1);
 
\[ y = \left (1+\frac {\csc \left (1\right ) \left (x -1\right )^{3}}{6}-\frac {\csc \left (1\right ) \left (2 \cot \left (1\right )+1\right ) \left (x -1\right )^{4}}{24}+\frac {\left (11+\cos \left (2\right )+3 \sin \left (2\right )\right ) \csc \left (1\right )^{3} \left (x -1\right )^{5}}{240}\right ) y \left (1\right )+\left (x -1+\frac {\csc \left (1\right ) \left (x -1\right )^{4}}{12}-\frac {\left (\sin \left (1\right )^{2}+\sin \left (2\right )\right ) \csc \left (1\right )^{3} \left (x -1\right )^{5}}{40}\right ) y^{\prime }\left (1\right )+O\left (x^{6}\right ) \]
Mathematica. Time used: 0.003 (sec). Leaf size: 107
ode=Sin[x]*D[y[x],{x,2}]-Log[x]*y[x]==0; 
ic={}; 
AsymptoticDSolveValue[{ode,ic},y[x],{x,1,5}]
 
\[ y(x)\to c_1 \left (\frac {1}{6} (x-1)^3 \csc (1)-\frac {1}{120} (x-1)^5 \left (-5 \csc (1)-6 \cot ^2(1) \csc (1)-3 \cot (1) \csc (1)\right )-\frac {1}{12} (x-1)^4 \left (\frac {\csc (1)}{2}+\cot (1) \csc (1)\right )+1\right )+c_2 \left (x+\frac {1}{12} (x-1)^4 \csc (1)-\frac {1}{20} (x-1)^5 \left (\frac {\csc (1)}{2}+\cot (1) \csc (1)\right )-1\right ) \]
Sympy. Time used: 1.722 (sec). Leaf size: 68
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-y(x)*log(x) + sin(x)*Derivative(y(x), (x, 2)),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 {\left (x - 1\right )^{4} \log {\left (x + 1 \right )}^{2}}{24 \sin ^{2}{\left (x + 1 \right )}} + \frac {\left (x - 1\right )^{2} \log {\left (x + 1 \right )}}{2 \sin {\left (x + 1 \right )}} + 1\right ) + C_{1} \left (x + \frac {\left (x - 1\right )^{3} \log {\left (x + 1 \right )}}{6 \sin {\left (x + 1 \right )}} - 1\right ) + O\left (x^{6}\right ) \]