58.6.24 problem 24

Internal problem ID [14655]
Book : Differential Equations by Shepley L. Ross. Third edition. John Willey. New Delhi. 2004.
Section : Chapter 2, Miscellaneous Review. Exercises page 60
Problem number : 24
Date solved : Thursday, October 02, 2025 at 09:46:17 AM
CAS classification : [[_homogeneous, `class A`], _rational, _Bernoulli]

\begin{align*} y x +x^{2} y^{\prime }&=\frac {y^{3}}{x} \end{align*}

With initial conditions

\begin{align*} y \left (1\right )&=1 \\ \end{align*}
Maple. Time used: 0.033 (sec). Leaf size: 16
ode:=x^2*diff(y(x),x)+x*y(x) = y(x)^3/x; 
ic:=[y(1) = 1]; 
dsolve([ode,op(ic)],y(x), singsol=all);
 
\[ y = \frac {2 x}{\sqrt {2 x^{4}+2}} \]
Mathematica. Time used: 0.356 (sec). Leaf size: 21
ode=x^2*D[y[x],x]+x*y[x]==y[x]^3/x; 
ic={y[1]==1}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \frac {\sqrt {2} x}{\sqrt {x^4+1}} \end{align*}
Sympy. Time used: 0.612 (sec). Leaf size: 19
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x**2*Derivative(y(x), x) + x*y(x) - y(x)**3/x,0) 
ics = {y(1): 1} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \sqrt {2} x \sqrt {\frac {1}{x^{4} + 1}} \]