82.12.22 problem Ex. 24

Internal problem ID [18708]
Book : Introductory Course On Differential Equations by Daniel A Murray. Longmans Green and Co. NY. 1924
Section : Chapter II. Equations of the first order and of the first degree. Examples on chapter II at page 29
Problem number : Ex. 24
Date solved : Thursday, March 13, 2025 at 12:39:51 PM
CAS classification : [_exact, _rational]

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

Maple. Time used: 0.011 (sec). Leaf size: 129
ode:=y(x)*(x^2+y(x)^2+a^2)*diff(y(x),x)+x*(x^2+y(x)^2-a^2) = 0; 
dsolve(ode,y(x), singsol=all);
 
\begin{align*} y \left (x \right ) &= \sqrt {-a^{2}-x^{2}-2 \sqrt {a^{2} x^{2}-c_{1}}} \\ y \left (x \right ) &= \sqrt {-a^{2}-x^{2}+2 \sqrt {a^{2} x^{2}-c_{1}}} \\ y \left (x \right ) &= -\sqrt {-a^{2}-x^{2}-2 \sqrt {a^{2} x^{2}-c_{1}}} \\ y \left (x \right ) &= -\sqrt {-a^{2}-x^{2}+2 \sqrt {a^{2} x^{2}-c_{1}}} \\ \end{align*}
Mathematica. Time used: 2.407 (sec). Leaf size: 165
ode=y[x]*(x^2+y[x]^2+a^2)*D[y[x],x]+x*(x^2+y[x]^2-a^2)==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to -\sqrt {-a^2-\sqrt {a^4+4 a^2 x^2+4 c_1}-x^2} \\ y(x)\to \sqrt {-a^2-\sqrt {a^4+4 a^2 x^2+4 c_1}-x^2} \\ y(x)\to -\sqrt {-a^2+\sqrt {a^4+4 a^2 x^2+4 c_1}-x^2} \\ y(x)\to \sqrt {-a^2+\sqrt {a^4+4 a^2 x^2+4 c_1}-x^2} \\ \end{align*}
Sympy
from sympy import * 
x = symbols("x") 
a = symbols("a") 
y = Function("y") 
ode = Eq(x*(-a**2 + x**2 + y(x)**2) + (a**2 + x**2 + y(x)**2)*y(x)*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
Timed Out