I need to find the general solution of this DE: $x^2(xy'+y)=2x^4+y^2$
I've changed it into this form: $y'=\frac{y^2}{x^3}-\frac{y}{x}+2x$, but I do not know how to proceed from here.
I'd appreciate general instructions on how to solve any Riccati DE.
There is no general solution to the Riccati equation. There are two main methods for solving the special forms of the Riccati equation. The first method and more powerful/complicated is to use Lie symmetries. The second method but less powerful/complicated method is the following.
Guess a solution of the type $y_1(x) = ax^n$. It is pretty easy to see that $n=2$, the factor $a$ can then be quickly determined by plugging $y_1(x)=ax^2$ into the ordinary differential equation (ODE).
Then use the substitution
$$y(x) = \dfrac{1}{u(x)} + y_1(x)$$ to reduce the ODE.
You can also go back to the beginning of your calculations.
$$x^2(xy'+y)=2x^4+y^2$$ $$x^2(xy)'=2x^4+y^2$$ $$(xy)'=2x^2+(y/x)^2$$
Now substitute $y=z(x)/x$:
$$z' =2x^2+z^2/x^4.$$
Maybe now guessing the solution to this ODE is a little bit simpler.