61.29.27 problem 136

Internal problem ID [12557]
Book : Handbook of exact solutions for ordinary differential equations. By Polyanin and Zaitsev. Second edition
Section : Chapter 2, Second-Order Differential Equations. section 2.1.2-4
Problem number : 136
Date solved : Monday, March 31, 2025 at 05:38:56 AM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

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

Maple. Time used: 0.178 (sec). Leaf size: 243
ode:=x^2*diff(diff(y(x),x),x)+(a*x^2+b)*diff(y(x),x)+c*((a-c)*x^2+b)*y(x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \sqrt {x}\, \left (\operatorname {HeunD}\left (4 \sqrt {-b \left (-2 c +a \right )}, -4 \sqrt {-b \left (-2 c +a \right )}-1+\left (-4 a +8 c \right ) b , 8 \sqrt {-b \left (-2 c +a \right )}, -4 \sqrt {-b \left (-2 c +a \right )}+1+\left (-8 c +4 a \right ) b , \frac {\sqrt {-b \left (-2 c +a \right )}\, x -b}{\sqrt {-b \left (-2 c +a \right )}\, x +b}\right ) {\mathrm e}^{\frac {-x^{2} c +b}{x}} c_1 +\operatorname {HeunD}\left (-4 \sqrt {-b \left (-2 c +a \right )}, -4 \sqrt {-b \left (-2 c +a \right )}-1+\left (-4 a +8 c \right ) b , 8 \sqrt {-b \left (-2 c +a \right )}, -4 \sqrt {-b \left (-2 c +a \right )}+1+\left (-8 c +4 a \right ) b , \frac {\sqrt {-b \left (-2 c +a \right )}\, x -b}{\sqrt {-b \left (-2 c +a \right )}\, x +b}\right ) {\mathrm e}^{-x \left (a -c \right )} c_2 \right ) \]
Mathematica. Time used: 0.692 (sec). Leaf size: 44
ode=x^2*D[y[x],{x,2}]+(a*x^2+b)*D[y[x],x]+c*((a-c)*x^2+b)*y[x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to e^{-c x} \left (c_2 \int _1^xe^{\frac {b}{K[1]}-a K[1]+2 c K[1]}dK[1]+c_1\right ) \]
Sympy
from sympy import * 
x = symbols("x") 
a = symbols("a") 
b = symbols("b") 
c = symbols("c") 
y = Function("y") 
ode = Eq(c*(b + x**2*(a - c))*y(x) + x**2*Derivative(y(x), (x, 2)) + (a*x**2 + b)*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
NotImplementedError : The given ODE Derivative(y(x), x) - (-a*c*x**2*y(x) - b*c*y(x) + c**2*x**2*y(x) - x**2*Derivative(y(x), (x, 2)))/(a*x**2 + b) cannot be solved by the factorable group method