69.1.48 problem 67

Internal problem ID [14122]
Book : DIFFERENTIAL and INTEGRAL CALCULUS. VOL I. by N. PISKUNOV. MIR PUBLISHERS, Moscow 1969.
Section : Chapter 8. Differential equations. Exercises page 595
Problem number : 67
Date solved : Wednesday, March 05, 2025 at 10:35:43 PM
CAS classification : [_separable]

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

Maple. Time used: 0.003 (sec). Leaf size: 20
ode:=(-x^2+1)*diff(y(x),x)-x*y(x)+a*x*y(x)^2 = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {1}{\sqrt {x -1}\, \sqrt {x +1}\, c_{1} +a} \]
Mathematica. Time used: 0.395 (sec). Leaf size: 53
ode=(1-x^2)*D[y[x],x]-x*y[x]+a*x*y[x]^2==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to \text {InverseFunction}\left [\int _1^{\text {$\#$1}}\frac {1}{K[1] (a K[1]-1)}dK[1]\&\right ]\left [\frac {1}{2} \log \left (x^2-1\right )+c_1\right ] \\ y(x)\to 0 \\ y(x)\to \frac {1}{a} \\ \end{align*}
Sympy. Time used: 1.528 (sec). Leaf size: 48
from sympy import * 
x = symbols("x") 
a = symbols("a") 
y = Function("y") 
ode = Eq(a*x*y(x)**2 - x*y(x) + (1 - x**2)*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = \frac {1 - \sqrt {C_{1} \left (x^{2} - 1\right )}}{a \left (- C_{1} x^{2} + C_{1} + 1\right )}, \ y{\left (x \right )} = \frac {\sqrt {C_{1} \left (x^{2} - 1\right )} + 1}{a \left (- C_{1} x^{2} + C_{1} + 1\right )}\right ] \]