61.29.10 problem 119

Internal problem ID [12540]
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 : 119
Date solved : Thursday, March 13, 2025 at 11:43:28 PM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

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

Maple. Time used: 0.329 (sec). Leaf size: 134
ode:=x^2*diff(diff(y(x),x),x)-(a^2*x^(2*n)+a*(2*b+n-1)*x^n+b*(b-1))*y(x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = 2 x^{-\frac {3 n}{2}+\frac {1}{2}} c_{2} \left (b -\frac {1}{2}-\frac {n}{2}\right )^{2} \operatorname {WhittakerM}\left (\frac {n -2 b +1}{2 n}, -\frac {2 b -2 n -1}{2 n}, \frac {2 a \,x^{n}}{n}\right )+n \left (\left (-b +\frac {1}{2}+\frac {n}{2}\right ) x^{-\frac {3 n}{2}+\frac {1}{2}}+a \,x^{-\frac {n}{2}+\frac {1}{2}}\right ) c_{2} \operatorname {WhittakerM}\left (-\frac {2 b +n -1}{2 n}, -\frac {2 b -2 n -1}{2 n}, \frac {2 a \,x^{n}}{n}\right )+c_{1} x^{b} {\mathrm e}^{\frac {a \,x^{n}}{n}} \]
Mathematica
ode=x^2*D[y[x],{x,2}]-(a^2*x^(2*n)+a*(2*b+n-1)*x^n+b*(b-1))*y[x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 

Not solved

Sympy
from sympy import * 
x = symbols("x") 
a = symbols("a") 
b = symbols("b") 
n = symbols("n") 
y = Function("y") 
ode = Eq(x**2*Derivative(y(x), (x, 2)) - (a**2*x**(2*n) + a*x**n*(2*b + n - 1) + b*(b - 1))*y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
ValueError : Expected Expr or iterable but got None