61.31.8 problem 189

Internal problem ID [12610]
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-6
Problem number : 189
Date solved : Monday, March 31, 2025 at 05:53:54 AM
CAS classification : [[_2nd_order, _exact, _linear, _homogeneous]]

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

Maple. Time used: 0.005 (sec). Leaf size: 46
ode:=x*(a*x^2+b)*diff(diff(y(x),x),x)+2*(a*x^2+b)*diff(y(x),x)-2*a*x*y(x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {\left (a \,x^{2}+b \right ) c_2 \arctan \left (\frac {\sqrt {a b}\, x}{b}\right )+\sqrt {a b}\, c_2 x +c_1 \left (a \,x^{2}+b \right )}{x} \]
Mathematica. Time used: 0.189 (sec). Leaf size: 39
ode=x*(a*x^2+b)*D[y[x],{x,2}]+2*(a*x^2+b)*D[y[x],x]-2*a*x*y[x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to \frac {\left (a x^2+b\right ) \left (c_2 \int _1^x\frac {1}{\left (a K[1]^2+b\right )^2}dK[1]+c_1\right )}{x} \]
Sympy
from sympy import * 
x = symbols("x") 
a = symbols("a") 
b = symbols("b") 
y = Function("y") 
ode = Eq(-2*a*x*y(x) + x*(a*x**2 + b)*Derivative(y(x), (x, 2)) + (2*a*x**2 + 2*b)*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
False