Problem:

Solve the following differential equation.

$$ x^2 , dy + (y^2 -xy) , dx = 0 $$

Answer:

$$ left( dfrac{x^2}{y^2} right) , dy

+ left( dfrac{y^2}{x^2} – dfrac{y}{x} right) , dx = 0 $$

Hence we have a homogeneous differential equation. Let $y = vx$.

begin{align*}

dfrac{dy}{dx} &= v + xdfrac{dv}{dx} \

v^2 left( v + xdfrac{dv}{dx} right) &= v^2 – v \

v^3 + v^2 x dfrac{dv}{dx} &= v^2 – v \

v^2 x dfrac{dv}{dx} &= -v^3 + v^2 – v \

x dfrac{dv}{dx} &= -v + 1 – v^{-1} \

dfrac{dv}{-v + 1 – v^{-1}} &= dfrac{dx}{x}

end{align*}

Using an online integral calculator, we find:

$$ int dfrac{1}{-v + 1 – v^{-1}} , dv =

-dfrac{lnleft(v^2-v+1right)}{2}

– dfrac{arctanleft(frac{2v-1}{sqrt{3}}right)}{sqrt{3}} $$

begin{align*}

-dfrac{lnleft(v^2-v+1right)}{2}

– dfrac{arctanleft(frac{2v-1}{sqrt{3}}right)}{sqrt{3}}

&= ln{|x|} + C

end{align*}

However, the book gets:

$$ y = dfrac{x}{ln{|x|}+C} $$

My answer is not going to match the book’s answer. Where did I go wrong?