23.3.320 problem 322

Internal problem ID [6034]
Book : Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
Section : Part II. Chapter 3. THE DIFFERENTIAL EQUATION IS LINEAR AND OF SECOND ORDER, page 311
Problem number : 322
Date solved : Tuesday, September 30, 2025 at 02:20:15 PM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

\begin{align*} \left (b x +a \right ) y+2 a x y^{\prime }+x^{2} y^{\prime \prime }&=0 \end{align*}
Maple. Time used: 0.002 (sec). Leaf size: 59
ode:=(b*x+a)*y(x)+2*a*x*diff(y(x),x)+x^2*diff(diff(y(x),x),x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = x^{\frac {1}{2}-a} \left (\operatorname {BesselY}\left (\sqrt {4 a^{2}-8 a +1}, 2 \sqrt {b}\, \sqrt {x}\right ) c_2 +\operatorname {BesselJ}\left (\sqrt {4 a^{2}-8 a +1}, 2 \sqrt {b}\, \sqrt {x}\right ) c_1 \right ) \]
Mathematica. Time used: 0.064 (sec). Leaf size: 123
ode=(a + b*x)*y[x] + 2*a*x*D[y[x],x] + x^2*D[y[x],{x,2}] == 0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to b^{\frac {1}{2}-a} x^{\frac {1}{2}-a} \left (c_1 \operatorname {Gamma}\left (1-\sqrt {4 a^2-8 a+1}\right ) \operatorname {BesselJ}\left (-\sqrt {4 a^2-8 a+1},2 \sqrt {b} \sqrt {x}\right )+c_2 \operatorname {Gamma}\left (\sqrt {4 a^2-8 a+1}+1\right ) \operatorname {BesselJ}\left (\sqrt {4 a^2-8 a+1},2 \sqrt {b} \sqrt {x}\right )\right ) \end{align*}
Sympy
from sympy import * 
x = symbols("x") 
a = symbols("a") 
b = symbols("b") 
y = Function("y") 
ode = Eq(2*a*x*Derivative(y(x), x) + x**2*Derivative(y(x), (x, 2)) + (a + b*x)*y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
TypeError : invalid input: 1 - 2*a