<s>[INST] What is the tip for this exact differential equation? $$ xdx + ydy = \frac{xdy - ydx}{x^2 + y^2} $$
I have multiplied the left part $x^2+y^2$ for $x dx + y dy$ getting 
$$(x^3+xy^2+y)dx+(x^2y+y^3-x)dy=0$$ 
And the derivative test give me: 
$\frac{dM}{dy}= 0+2xy+1$ and $\frac{dN}{dx} = 2xy+0-1$. 
Where´s my mistake?
 [/INST] your differential equation $$Mdx + Ndy = (x^3 + xy^2 + y)\, dx +(y^3 + yx^2 - x)\, dy  = 0.$$ then we have $$M_y = 2xy + 1, N_x = 2xy - 1 $$ therefore is not exact. we can make it exact by multiplying by $a$ and demanding that $$(aM)_y = (aN)_x \to a_y M + aM_y = a_x N + aN_x \to a_xN- a_y M = a(M_y - N_x) = 2a $$  that is $$a_x(y^3 + yx^2 -x) -a_y(x^3 + xy^2 +y) = 2a\tag 1$$ now choose $$a = a(r), r^2 = x^2 + y^2$$  so that $$ a_x = \frac x r a', a_y = \frac x y a'$$ subbing this in $(1),$  we get $$\frac x r a'\left(yr^2 - x\right) - \frac y r a'\left(xr^2+y\right)  = 2a \to -r\frac{da}{dr} = 2a \to a = \frac1{r^2} = \frac1{x^2 + y^2} $$
now that we have an integration factor, we get $$ \frac1{x^2 + y^2}(x^3 + xy^2 + y)\, dx +\frac 1{x^2 + y^2}(y^3 + yx^2 - x)\, dy  = 0 \to x\,dx + y\, dy +\frac{ydx - xdy}{x^2 + y^2} = 0 .$$  we have  $$ F_x = M  = x + \frac y{x^2 + y^2}, F_y = N = y -\frac x{x^2 + y^2} \to \\
 F_{xy} = \frac1{x^2+y^2} - \frac{2y^2}{(x^2+y^2)^2} = \frac{x^2 - y^2}{(x^2 + y^2)^2},\\ F_{yx} = -\frac 1{x^2 + y^2} + \frac{2x^2}{(x(2 + y^2)^2} =  \frac{x^2 - y^2}{(x^2 + y^2)^2}$$
integrating $F_x$ i get $$F = \frac 12 x^2 + \tan^{-1}\left(\frac x y\right) + C(y) \to F_y = \frac 1{1 + (x/y)^2}( -\frac x{y^2}) + \frac{dC}{dy} \to F_y = -\frac x{x^2 + y^2} +\frac{dC}{dy}   $$
 this gives $$ \frac{dC}{dy} = y \to C = \frac 1{2}y^2 + const$$
this has the integral $$\frac 12(x^2 + y^2) + \tan^{-1}\left(\frac xy\right) = const. $$
</s>