15.2.12 problem 12

Internal problem ID [2882]
Book : Differential Equations by Alfred L. Nelson, Karl W. Folley, Max Coral. 3rd ed. DC heath. Boston. 1964
Section : Exercise 6, page 25
Problem number : 12
Date solved : Sunday, March 30, 2025 at 12:40:04 AM
CAS classification : [[_homogeneous, `class A`], _rational, _dAlembert]

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

Maple. Time used: 0.007 (sec). Leaf size: 20
ode:=y(x)*(x^2-x*y(x)+y(x)^2)+x*diff(y(x),x)*(x^2+x*y(x)+y(x)^2) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \tan \left (\operatorname {RootOf}\left (\textit {\_Z} +\ln \left (\tan \left (\textit {\_Z} \right )\right )+2 \ln \left (x \right )+2 c_1 \right )\right ) x \]
Mathematica. Time used: 0.122 (sec). Leaf size: 26
ode=y[x]*(x^2-x*y[x]+y[x]^2)+x*D[y[x],x]*(x^2+x*y[x]+y[x]^2)==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ \text {Solve}\left [\arctan \left (\frac {y(x)}{x}\right )+\log \left (\frac {y(x)}{x}\right )=-2 \log (x)+c_1,y(x)\right ] \]
Sympy. Time used: 0.940 (sec). Leaf size: 22
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x*(x**2 + x*y(x) + y(x)**2)*Derivative(y(x), x) + (x**2 - x*y(x) + y(x)**2)*y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \log {\left (x \right )} = C_{1} - \log {\left (\sqrt {\frac {y{\left (x \right )}}{x}} \right )} - \frac {\operatorname {atan}{\left (\frac {y{\left (x \right )}}{x} \right )}}{2} \]