71.6.12 problem 12

Internal problem ID [14418]
Book : Ordinary Differential Equations by Charles E. Roberts, Jr. CRC Press. 2010
Section : Chapter 2. The Initial Value Problem. Exercises 2.3.2, page 63
Problem number : 12
Date solved : Tuesday, January 28, 2025 at 06:30:21 AM
CAS classification : [_separable]

\begin{align*} 2 x y y^{\prime }+y^{2}&=-1 \end{align*}

Solution by Maple

Time used: 0.005 (sec). Leaf size: 34

dsolve(2*x*y(x)*diff(y(x),x)+y(x)^2=-1,y(x), singsol=all)
 
\begin{align*} y &= \frac {\sqrt {\left (-x +c_{1} \right ) x}}{x} \\ y &= -\frac {\sqrt {\left (-x +c_{1} \right ) x}}{x} \\ \end{align*}

Solution by Mathematica

Time used: 0.297 (sec). Leaf size: 98

DSolve[2*x*y[x]*D[y[x],x]+y[x]^2==-1,y[x],x,IncludeSingularSolutions -> True]
 
\begin{align*} y(x)\to -\frac {\sqrt {-x+e^{2 c_1}}}{\sqrt {x}} \\ y(x)\to \frac {\sqrt {-x+e^{2 c_1}}}{\sqrt {x}} \\ y(x)\to -i \\ y(x)\to i \\ y(x)\to \frac {\sqrt {-x}}{\sqrt {x}} \\ y(x)\to \frac {\sqrt {x}}{\sqrt {-x}} \\ \end{align*}