4.19.2 \(x^2 y'(x)^2-2 x y(x) y'(x)+y(x) (y(x)+1)-x=0\)

ODE
\[ x^2 y'(x)^2-2 x y(x) y'(x)+y(x) (y(x)+1)-x=0 \] ODE Classification

[[_1st_order, _with_linear_symmetries], _rational]

Book solution method
Change of variable

Mathematica
cpu = 0.0332616 (sec), leaf count = 55

\[\left \{\left \{y(x)\to \frac {c_1^2 x}{4}-i c_1 \sqrt {x}+x-1\right \},\left \{y(x)\to \frac {c_1^2 x}{4}+i c_1 \sqrt {x}+x-1\right \}\right \}\]

Maple
cpu = 0.244 (sec), leaf count = 22

\[ \left \{ y \left ( x \right ) =x,y \left ( x \right ) =\sqrt {x}{\it \_C1}-{\frac {x{{\it \_C1}}^{2}}{4}}+x-1 \right \} \] Mathematica raw input

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

Mathematica raw output

{{y[x] -> -1 + x - I*Sqrt[x]*C[1] + (x*C[1]^2)/4}, {y[x] -> -1 + x + I*Sqrt[x]*C
[1] + (x*C[1]^2)/4}}

Maple raw input

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

Maple raw output

y(x) = x, y(x) = x^(1/2)*_C1-1/4*x*_C1^2+x-1