23.2.95 problem 97

Internal problem ID [5450]
Book : Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
Section : Part II. Chapter 2. THE DIFFERENTIAL EQUATION IS OF FIRST ORDER AND OF SECOND OR HIGHER DEGREE, page 278
Problem number : 97
Date solved : Tuesday, September 30, 2025 at 12:43:31 PM
CAS classification : [_quadrature]

\begin{align*} x {y^{\prime }}^{2}&=\left (a -x \right )^{2} \end{align*}
Maple. Time used: 0.011 (sec). Leaf size: 35
ode:=x*diff(y(x),x)^2 = (a-x)^2; 
dsolve(ode,y(x), singsol=all);
 
\begin{align*} y &= \frac {2 \sqrt {x}\, \left (-x +3 a \right )}{3}+c_1 \\ y &= -\frac {2 \sqrt {x}\, \left (-x +3 a \right )}{3}+c_1 \\ \end{align*}
Mathematica. Time used: 0.013 (sec). Leaf size: 43
ode=x*(D[y[x],x])^2==(a-x)^2; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to -\frac {2}{3} \sqrt {x} (x-3 a)+c_1\\ y(x)&\to \frac {2}{3} \sqrt {x} (x-3 a)+c_1 \end{align*}
Sympy. Time used: 0.325 (sec). Leaf size: 41
from sympy import * 
x = symbols("x") 
a = symbols("a") 
y = Function("y") 
ode = Eq(x*Derivative(y(x), x)**2 - (a - x)**2,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = C_{1} - 2 a \sqrt {x} + \frac {2 x^{\frac {3}{2}}}{3}, \ y{\left (x \right )} = C_{1} + 2 a \sqrt {x} - \frac {2 x^{\frac {3}{2}}}{3}\right ] \]