20.1.1 problem 1.a

Internal problem ID [4241]
Book : Differential equations with applications and historial notes, George F. Simmons. Second edition. 1971
Section : Chapter 2, section 7, page 37
Problem number : 1.a
Date solved : Tuesday, September 30, 2025 at 07:08:20 AM
CAS classification : [[_homogeneous, `class A`], _rational, _Bernoulli]

\begin{align*} x^{2}-y^{2}+x y y^{\prime }&=0 \end{align*}
Maple. Time used: 0.004 (sec). Leaf size: 28
ode:=x^2-y(x)^2+x*y(x)*diff(y(x),x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\begin{align*} y &= \sqrt {-2 \ln \left (x \right )+c_1}\, x \\ y &= -\sqrt {-2 \ln \left (x \right )+c_1}\, x \\ \end{align*}
Mathematica. Time used: 0.112 (sec). Leaf size: 36
ode=(x^2-y[x]^2)+x*y[x]*D[y[x],x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to -x \sqrt {-2 \log (x)+c_1}\\ y(x)&\to x \sqrt {-2 \log (x)+c_1} \end{align*}
Sympy. Time used: 0.223 (sec). Leaf size: 29
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x**2 + x*y(x)*Derivative(y(x), x) - y(x)**2,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = - x \sqrt {C_{1} - 2 \log {\left (x \right )}}, \ y{\left (x \right )} = x \sqrt {C_{1} - 2 \log {\left (x \right )}}\right ] \]