60.1.136 problem 139

Internal problem ID [10150]
Book : Differential Gleichungen, E. Kamke, 3rd ed. Chelsea Pub. NY, 1948
Section : Chapter 1, linear first order
Problem number : 139
Date solved : Sunday, March 30, 2025 at 03:20:08 PM
CAS classification : [_rational, _Riccati]

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

Maple. Time used: 0.005 (sec). Leaf size: 229
ode:=x^2*(diff(y(x),x)+y(x)^2)+a*x^k-b*(b-1) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {-\left (\operatorname {BesselY}\left (\frac {\operatorname {csgn}\left (2 b -1\right ) \left (2 b -1\right )+k}{k}, \frac {2 \sqrt {a}\, x^{\frac {k}{2}}}{k}\right ) c_1 +\operatorname {BesselJ}\left (\frac {\operatorname {csgn}\left (2 b -1\right ) \left (2 b -1\right )+k}{k}, \frac {2 \sqrt {a}\, x^{\frac {k}{2}}}{k}\right )\right ) x^{\frac {k}{2}} \sqrt {a}+\left (\operatorname {BesselY}\left (\frac {\operatorname {csgn}\left (2 b -1\right ) \left (2 b -1\right )}{k}, \frac {2 \sqrt {a}\, x^{\frac {k}{2}}}{k}\right ) c_1 +\operatorname {BesselJ}\left (\frac {\operatorname {csgn}\left (2 b -1\right ) \left (2 b -1\right )}{k}, \frac {2 \sqrt {a}\, x^{\frac {k}{2}}}{k}\right )\right ) \left (\frac {1}{2}+\operatorname {csgn}\left (2 b -1\right ) b -\frac {\operatorname {csgn}\left (2 b -1\right )}{2}\right )}{x \left (\operatorname {BesselY}\left (\frac {\operatorname {csgn}\left (2 b -1\right ) \left (2 b -1\right )}{k}, \frac {2 \sqrt {a}\, x^{\frac {k}{2}}}{k}\right ) c_1 +\operatorname {BesselJ}\left (\frac {\operatorname {csgn}\left (2 b -1\right ) \left (2 b -1\right )}{k}, \frac {2 \sqrt {a}\, x^{\frac {k}{2}}}{k}\right )\right )} \]
Mathematica. Time used: 0.469 (sec). Leaf size: 627
ode=x^2*(D[y[x],x]+y[x]^2) + a*x^k - b*(b-1)==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to \frac {\sqrt {a} x^k \operatorname {Gamma}\left (\frac {2 b+k-1}{k}\right ) \operatorname {BesselJ}\left (-\frac {-2 b+k+1}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )-\sqrt {a} x^k \operatorname {Gamma}\left (\frac {2 b+k-1}{k}\right ) \operatorname {BesselJ}\left (\frac {2 b+k-1}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )+\sqrt {x^k} \operatorname {Gamma}\left (\frac {2 b+k-1}{k}\right ) \operatorname {BesselJ}\left (\frac {2 b-1}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )-\sqrt {a} c_1 x^k \operatorname {Gamma}\left (\frac {-2 b+k+1}{k}\right ) \operatorname {BesselJ}\left (\frac {-2 b+k+1}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )+\sqrt {a} c_1 x^k \operatorname {Gamma}\left (\frac {-2 b+k+1}{k}\right ) \operatorname {BesselJ}\left (-\frac {2 b+k-1}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )+c_1 \sqrt {x^k} \operatorname {Gamma}\left (\frac {-2 b+k+1}{k}\right ) \operatorname {BesselJ}\left (\frac {1-2 b}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )}{2 x \sqrt {x^k} \left (\operatorname {Gamma}\left (\frac {2 b+k-1}{k}\right ) \operatorname {BesselJ}\left (\frac {2 b-1}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )+c_1 \operatorname {Gamma}\left (\frac {-2 b+k+1}{k}\right ) \operatorname {BesselJ}\left (\frac {1-2 b}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )\right )} \\ y(x)\to \frac {\frac {\sqrt {a} \sqrt {x^k} \left (\operatorname {BesselJ}\left (-\frac {2 b+k-1}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )-\operatorname {BesselJ}\left (\frac {-2 b+k+1}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )\right )}{\operatorname {BesselJ}\left (\frac {1-2 b}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )}+1}{2 x} \\ y(x)\to \frac {\frac {\sqrt {a} \sqrt {x^k} \left (\operatorname {BesselJ}\left (-\frac {2 b+k-1}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )-\operatorname {BesselJ}\left (\frac {-2 b+k+1}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )\right )}{\operatorname {BesselJ}\left (\frac {1-2 b}{k},\frac {2 \sqrt {a} \sqrt {x^k}}{k}\right )}+1}{2 x} \\ \end{align*}
Sympy
from sympy import * 
x = symbols("x") 
a = symbols("a") 
b = symbols("b") 
k = symbols("k") 
y = Function("y") 
ode = Eq(a*x**k - b*(b - 1) + x**2*(y(x)**2 + Derivative(y(x), x)),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
NotImplementedError : The given ODE Derivative(y(x), x) - (-a*x**k + b**2 - b - x**2*y(x)**2)/x**2 cannot be solved by the factorable group method