64.6.19 problem 19

Internal problem ID [13290]
Book : Differential Equations by Shepley L. Ross. Third edition. John Willey. New Delhi. 2004.
Section : Chapter 2, Miscellaneous Review. Exercises page 60
Problem number : 19
Date solved : Wednesday, March 05, 2025 at 09:34:43 PM
CAS classification : [_separable]

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

With initial conditions

\begin{align*} y \left (2\right )&=1 \end{align*}

Maple. Time used: 0.107 (sec). Leaf size: 15
ode:=4*x*y(x)*diff(y(x),x) = 1+y(x)^2; 
ic:=y(2) = 1; 
dsolve([ode,ic],y(x), singsol=all);
 
\[ y = \sqrt {\sqrt {x}\, \sqrt {2}-1} \]
Mathematica. Time used: 3.545 (sec). Leaf size: 22
ode=4*x*y[x]*D[y[x],x]==y[x]^2+1; 
ic={y[2]==1}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to \sqrt {\sqrt {2} \sqrt {x}-1} \]
Sympy. Time used: 0.512 (sec). Leaf size: 17
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(4*x*y(x)*Derivative(y(x), x) - y(x)**2 - 1,0) 
ics = {y(2): 1} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \sqrt {\sqrt {2} \sqrt {x} - 1} \]