Solve a non-exact ODE by a different method The following equation
$$(x^3+2xy)dx-x^2dy=0$$
is not exact, since
$$\frac{\partial M}{\partial y}=2x\ne\frac{\partial N}{\partial x}=-2x$$
I wanted to try the following then,
$$-x^2dy=-(x^3+2xy)dx$$
$$\frac{dy}{dx}=\frac{x^3+2xy}{x^2}$$
$$dy=\frac{x^3+2xy}{x^2}dx$$
$$\int dy=\int xdx+ \int \frac{2y}{x}dx$$
But the last integral, according to what I suspect does not make any sense for finding a solution to the original problem. That would mean that the answer by this approach is:
$$y=\frac{x^2}{2}+2y\ln x$$
However, this is not correct.
Any ideas how to solve this?
Thanks

First, compute $\frac{M_y-N_x}{N}$ and we will get $\frac{M_y-N_x}{N}$=-$\frac{4}{x}$
So set the integrating factor Ψ as $e^{-\int\frac{4}{x}dx}$ and we will have
Ψ =$x^{-4}$.
Multiply Ψ =$x^{-4}$ to both sides and you can check that the differential equation after multiplying the integrating factor will be exact.
