60.1.104 problem 106

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

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

Maple. Time used: 0.006 (sec). Leaf size: 39
ode:=x*diff(y(x),x)+x^a*y(x)^2+1/2*(a-b)*y(x)+x^b = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = -\tan \left (\frac {2 x^{\frac {a}{2}+\frac {b}{2}}+c_1 \left (a +b \right )}{a +b}\right ) x^{-\frac {a}{2}+\frac {b}{2}} \]
Mathematica. Time used: 0.649 (sec). Leaf size: 40
ode=x*D[y[x],x] + x^a*y[x]^2 + (a-b)*y[x]/2 + x^b==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to -x^{\frac {b-a}{2}} \tan \left (\frac {2 x^{\frac {a+b}{2}}}{a+b}-c_1\right ) \]
Sympy
from sympy import * 
x = symbols("x") 
a = symbols("a") 
b = symbols("b") 
y = Function("y") 
ode = Eq(x*Derivative(y(x), x) + x**a*y(x)**2 + x**b + (a - b)*y(x)/2,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
NotImplementedError : The given ODE Derivative(y(x), x) - (-a*y(x)/2 + b*y(x)/2 - x**a*y(x)**2 - x**b)/x cannot be solved by the factorable group method