29.25.27 problem 724

Internal problem ID [5314]
Book : Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
Section : Various 25
Problem number : 724
Date solved : Sunday, March 30, 2025 at 07:53:48 AM
CAS classification : [[_homogeneous, `class C`], _dAlembert]

\begin{align*} \left (1+\sqrt {x +y}\right ) y^{\prime }+1&=0 \end{align*}

Maple. Time used: 0.009 (sec). Leaf size: 19
ode:=(1+(x+y(x))^(1/2))*diff(y(x),x)+1 = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ -y-2 \sqrt {x +y}-c_1 = 0 \]
Mathematica. Time used: 0.085 (sec). Leaf size: 39
ode=(1+Sqrt[x+y[x]])*D[y[x],x]+1==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to -2 \sqrt {x+1+c_1}+2+c_1 \\ y(x)\to 2 \sqrt {x+1+c_1}+2+c_1 \\ \end{align*}
Sympy. Time used: 1.174 (sec). Leaf size: 31
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((sqrt(x + y(x)) + 1)*Derivative(y(x), x) + 1,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = C_{1} - 2 \sqrt {C_{1} + x + 1} + 2, \ y{\left (x \right )} = C_{1} + 2 \sqrt {C_{1} + x + 1} + 2\right ] \]