82.18.3 problem Ex. 3

Internal problem ID [18746]
Book : Introductory Course On Differential Equations by Daniel A Murray. Longmans Green and Co. NY. 1924
Section : Chapter III. Equations of the first order but not of the first degree. Examples on chapter III. page 38
Problem number : Ex. 3
Date solved : Thursday, March 13, 2025 at 12:45:09 PM
CAS classification : [_separable]

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

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