4.13.19 $$\left (x^2+2 x y(x)-y(x)^2\right ) y'(x)+x^2-2 x y(x)+y(x)^2=0$$

ODE
$\left (x^2+2 x y(x)-y(x)^2\right ) y'(x)+x^2-2 x y(x)+y(x)^2=0$ ODE Classiﬁcation

[[_homogeneous, class A], _rational, _dAlembert]

Book solution method
Homogeneous equation

Mathematica
cpu = 0.405919 (sec), leaf count = 89

$\text {Solve}\left [c_1=\text {RootSum}\left [\text {\#1}^3-3 \text {\#1}^2+\text {\#1}-1\& ,\frac {\text {\#1}^2 \log \left (\frac {y(x)}{x}-\text {\#1}\right )-2 \text {\#1} \log \left (\frac {y(x)}{x}-\text {\#1}\right )-\log \left (\frac {y(x)}{x}-\text {\#1}\right )}{3 \text {\#1}^2-6 \text {\#1}+1}\& \right ]+\log (x),y(x)\right ]$

Maple
cpu = 0.026 (sec), leaf count = 37

$\left [y \left (x \right ) = \RootOf \left (\int _{}^{\textit {\_Z}}\frac {\textit {\_a}^{2}-2 \textit {\_a} -1}{\textit {\_a}^{3}-3 \textit {\_a}^{2}+\textit {\_a} -1}d \textit {\_a} +\ln \left (x \right )+\textit {\_C1} \right ) x\right ]$ Mathematica raw input

DSolve[x^2 - 2*x*y[x] + y[x]^2 + (x^2 + 2*x*y[x] - y[x]^2)*y'[x] == 0,y[x],x]

Mathematica raw output

Solve[C[1] == Log[x] + RootSum[-1 + #1 - 3*#1^2 + #1^3 & , (-Log[-#1 + y[x]/x] -
 2*Log[-#1 + y[x]/x]*#1 + Log[-#1 + y[x]/x]*#1^2)/(1 - 6*#1 + 3*#1^2) & ], y[x]]

Maple raw input

dsolve((x^2+2*x*y(x)-y(x)^2)*diff(y(x),x)+x^2-2*x*y(x)+y(x)^2 = 0, y(x))

Maple raw output

[y(x) = RootOf(Intat(1/(_a^3-3*_a^2+_a-1)*(_a^2-2*_a-1),_a = _Z)+ln(x)+_C1)*x]