# Find the polynomials which are solution for a differential equation

Find all the polynomials grade $\leqslant 2$ which are solution for:

$x^{2}y^{'}+(x+1)y=x^{3}$

I'm lost here, I don't understand what is being asked for exactly. So my attempt to do it is to find the general solution of the differential equation.

I have now the homogeneous part:

$y(x)= c \frac{e^{\frac{1}{x}}}{x}$

I'm trying now to find the solution for the inhomogeneous part with the variation of constants method, but I couldn't do it.

I want to know if I'm on the right path, and if that is the case I need some help for the inhomogeneous part.

You're looking for solutions of very particular form, which greatly simplifies the problem. Write the general solution as $y=ax^2+bx+c$, find the derivative: $y'=2ax+b$ and insert it into the original equation: $$2ax^3+(x+1)(ax^2+bx+c)=x^3$$
Now all you have to do is find for what values of $a,b$ and $c$ the last equality holds for every $x$.