I have a question about solving polynomial equations modulo some number.
Say we were to solve the following quadratic congruence equation: $$x^2+x + 2 = 0 \quad mod \quad 4$$ We could of course just try the values $0, 1, 2, 3$ and check wheater or not they solve the equation. But what is the proper procedure for something to the likes of: $$x^4+x^3+7x^2+x+3=0 \quad mod \quad 45$$ Do we keep using a brute force method or is there a more simple way of thinking about this that I don't know of.
I have seen that for instance, quadratic congruence equations, can be solved using the quadratic formula given that you can find values to satisfiy the root and division parts. However, according to a teacher this does not work in every case. An example is the aforementioned quadratic equation.
Using the quadratic formula we would arrive at $$x=\frac{-b\pm\sqrt{b^2-4c}}{2}$$ Firstly to find the multiplicative inverse of $2$ would require solving $2y = 1 \quad mod \quad 4$ which has no solutions. This in the face of the fact that the original quadratic congruence equation does have solutions.
To clarify my question, what is the best way to go about solving these kinds of equations when we cannot simply relay on checking every single case? Is there anyway to reduce these equations? Also, does it matter if we use modulo a prime or a composite number in these equations?