2.31.32 Problem 180

2.31.32.1 Maple
2.31.32.2 Mathematica
2.31.32.3 Sympy

Internal problem ID [13841]
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-5
Problem number : 180
Date solved : Friday, December 19, 2025 at 03:06:33 PM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

\begin{align*} \left (a \,x^{2}+b x +c \right ) y^{\prime \prime }-\left (-k^{2}+x^{2}\right ) y^{\prime }+\left (k +x \right ) y&=0 \\ \end{align*}
2.31.32.1 Maple. Time used: 0.052 (sec). Leaf size: 1482
ode:=(a*x^2+b*x+c)*diff(diff(y(x),x),x)-(-k^2+x^2)*diff(y(x),x)+(k+x)*y(x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ \text {Expression too large to display} \]

Maple trace

Methods for second order ODEs: 
--- Trying classification methods --- 
trying a quadrature 
checking if the LODE has constant coefficients 
checking if the LODE is of Euler type 
trying a symmetry of the form [xi=0, eta=F(x)] 
checking if the LODE is missing y 
-> Trying a Liouvillian solution using Kovacics algorithm 
   A Liouvillian solution exists 
   Reducible group (found an exponential solution) 
   Group is reducible, not completely reducible 
   Solution has integrals. Trying a special function solution free of integrals\ 
... 
   -> Trying a solution in terms of special functions: 
      -> Bessel 
      -> elliptic 
      -> Legendre 
      -> Kummer 
         -> hyper3: Equivalence to 1F1 under a power @ Moebius 
      -> hypergeometric 
         -> heuristic approach 
         -> hyper3: Equivalence to 2F1, 1F1 or 0F1 under a power @ Moebius 
      -> Mathieu 
         -> Equivalence to the rational form of Mathieu ODE under a power @ Mo\ 
ebius 
      -> Heun: Equivalence to the GHE or one of its 4 confluent cases under a \ 
power @ Moebius 
      <- Heun successful: received ODE is equivalent to the  HeunC  ODE, case  \ 
a <> 0, e <> 0, c = 0 
   <- Kovacics algorithm successful
 
2.31.32.2 Mathematica. Time used: 1.753 (sec). Leaf size: 119
ode=(a*x^2+b*x+c)*D[y[x],{x,2}]-(x^2-k^2)*D[y[x],x]+(x+k)*y[x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \frac {(k-x) \left (c_2 \int _1^x\frac {\exp \left (\frac {\frac {\left (b^2-2 a \left (a k^2+c\right )\right ) \arctan \left (\frac {b+2 a K[1]}{\sqrt {4 a c-b^2}}\right )}{\sqrt {4 a c-b^2}}+a K[1]}{a^2}\right ) (c+K[1] (b+a K[1]))^{-\frac {b}{2 a^2}}}{(k-K[1])^2}dK[1]+c_1\right )}{k} \end{align*}
2.31.32.3 Sympy
from sympy import * 
x = symbols("x") 
a = symbols("a") 
b = symbols("b") 
c = symbols("c") 
k = symbols("k") 
y = Function("y") 
ode = Eq((k + x)*y(x) - (-k**2 + x**2)*Derivative(y(x), x) + (a*x**2 + b*x + c)*Derivative(y(x), (x, 2)),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
False