4.12.20 \(x (1-x y(x)) y'(x)+y(x) (x y(x)+1)=0\)

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

[[_homogeneous, `class G`], _rational, [_Abel, `2nd type`, `class B`]]

Book solution method
Exact equation, integrating factor

Mathematica
cpu = 1.0209 (sec), leaf count = 30

\[\left \{\left \{y(x)\to -\frac {1}{x W\left (\frac {e^{-1+\frac {9 c_1}{2^{2/3}}}}{x^2}\right )}\right \}\right \}\]

Maple
cpu = 0.173 (sec), leaf count = 18

\[\left [y \left (x \right ) = -\frac {1}{\LambertW \left (-\frac {\textit {\_C1}}{x^{2}}\right ) x}\right ]\] Mathematica raw input

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

Mathematica raw output

{{y[x] -> -(1/(x*ProductLog[E^(-1 + (9*C[1])/2^(2/3))/x^2]))}}

Maple raw input

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

Maple raw output

[y(x) = -1/LambertW(-_C1/x^2)/x]