29.16.15 problem 458

Internal problem ID [5056]
Book : Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
Section : Various 16
Problem number : 458
Date solved : Tuesday, March 04, 2025 at 07:48:48 PM
CAS classification : [[_homogeneous, `class G`], _rational, [_Abel, `2nd type`, `class A`]]

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

Maple. Time used: 0.108 (sec). Leaf size: 57
ode:=(x^2-y(x))*diff(y(x),x) = 4*x*y(x); 
dsolve(ode,y(x), singsol=all);
 
\begin{align*} y \left (x \right ) &= -\frac {c_{1} \sqrt {c_{1}^{2}-4 x^{2}}}{2}+\frac {c_{1}^{2}}{2}-x^{2} \\ y \left (x \right ) &= \frac {c_{1} \sqrt {c_{1}^{2}-4 x^{2}}}{2}+\frac {c_{1}^{2}}{2}-x^{2} \\ \end{align*}
Mathematica. Time used: 2.44 (sec). Leaf size: 246
ode=(x^2-y[x])D[y[x],x]==4 x y[x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to x^2 \left (1+\frac {2-2 i}{\frac {i \sqrt {2}}{\sqrt {x^2 \cosh \left (\frac {2 c_1}{9}\right )+x^2 \sinh \left (\frac {2 c_1}{9}\right )-i}}-(1-i)}\right ) \\ y(x)\to x^2 \left (1+\frac {2-2 i}{(-1+i)-\frac {i \sqrt {2}}{\sqrt {x^2 \cosh \left (\frac {2 c_1}{9}\right )+x^2 \sinh \left (\frac {2 c_1}{9}\right )-i}}}\right ) \\ y(x)\to x^2 \left (1+\frac {2-2 i}{(-1+i)-\frac {\sqrt {2}}{\sqrt {x^2 \cosh \left (\frac {2 c_1}{9}\right )+x^2 \sinh \left (\frac {2 c_1}{9}\right )+i}}}\right ) \\ y(x)\to x^2 \left (1+\frac {2-2 i}{\frac {\sqrt {2}}{\sqrt {x^2 \cosh \left (\frac {2 c_1}{9}\right )+x^2 \sinh \left (\frac {2 c_1}{9}\right )+i}}-(1-i)}\right ) \\ y(x)\to 0 \\ y(x)\to -x^2 \\ \end{align*}
Sympy. Time used: 1.023 (sec). Leaf size: 48
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-4*x*y(x) + (x**2 - y(x))*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = 2 C_{1}^{2} - 2 C_{1} \sqrt {\left (C_{1} - x\right ) \left (C_{1} + x\right )} - x^{2}, \ y{\left (x \right )} = 2 C_{1}^{2} + 2 C_{1} \sqrt {\left (C_{1} - x\right ) \left (C_{1} + x\right )} - x^{2}\right ] \]