61.3.9 problem 9

Internal problem ID [12014]
Book : Handbook of exact solutions for ordinary differential equations. By Polyanin and Zaitsev. Second edition
Section : Chapter 1, section 1.2. Riccati Equation. subsection 1.2.3. Equations Containing Exponential Functions
Problem number : 9
Date solved : Sunday, March 30, 2025 at 10:16:31 PM
CAS classification : [_Riccati]

\begin{align*} y^{\prime }&=a \,{\mathrm e}^{k x} y^{2}+b \,{\mathrm e}^{s x} \end{align*}

Maple. Time used: 0.016 (sec). Leaf size: 228
ode:=diff(y(x),x) = a*exp(k*x)*y(x)^2+b*exp(s*x); 
dsolve(ode,y(x), singsol=all);
 
\[ y = -\frac {b \,{\mathrm e}^{s x} \left (\operatorname {BesselY}\left (\frac {s}{k +s}, \frac {2 \sqrt {b}\, \sqrt {a}\, {\mathrm e}^{\frac {x \left (k +s \right )}{2}}}{k +s}\right ) c_1 +\operatorname {BesselJ}\left (\frac {s}{k +s}, \frac {2 \sqrt {b}\, \sqrt {a}\, {\mathrm e}^{\frac {x \left (k +s \right )}{2}}}{k +s}\right )\right )}{\operatorname {BesselJ}\left (\frac {k +2 s}{k +s}, \frac {2 \sqrt {b}\, \sqrt {a}\, {\mathrm e}^{\frac {x \left (k +s \right )}{2}}}{k +s}\right ) \sqrt {b}\, \sqrt {a}\, {\mathrm e}^{\frac {x \left (k +s \right )}{2}}+\operatorname {BesselY}\left (\frac {k +2 s}{k +s}, \frac {2 \sqrt {b}\, \sqrt {a}\, {\mathrm e}^{\frac {x \left (k +s \right )}{2}}}{k +s}\right ) {\mathrm e}^{\frac {x \left (k +s \right )}{2}} \sqrt {b}\, \sqrt {a}\, c_1 -s \left (\operatorname {BesselY}\left (\frac {s}{k +s}, \frac {2 \sqrt {b}\, \sqrt {a}\, {\mathrm e}^{\frac {x \left (k +s \right )}{2}}}{k +s}\right ) c_1 +\operatorname {BesselJ}\left (\frac {s}{k +s}, \frac {2 \sqrt {b}\, \sqrt {a}\, {\mathrm e}^{\frac {x \left (k +s \right )}{2}}}{k +s}\right )\right )} \]
Mathematica. Time used: 2.631 (sec). Leaf size: 859
ode=D[y[x],x]==a*Exp[k*x]*y[x]^2+b*Exp[s*x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} \text {Solution too large to show}\end{align*}

Sympy
from sympy import * 
x = symbols("x") 
a = symbols("a") 
b = symbols("b") 
k = symbols("k") 
s = symbols("s") 
y = Function("y") 
ode = Eq(-a*y(x)**2*exp(k*x) - b*exp(s*x) + Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
NotImplementedError : The given ODE -a*y(x)**2*exp(k*x) - b*exp(s*x) + Derivative(y(x), x) cannot be solved by the lie group method