I need to find the prime factorization of $f = x^3-5x^2+6x+7$ in $Z/11Z$
I tried the following but not sure if it is correct and if there is a better and faster way to do it.
first i tried one by one each of $x \in (1,2,..10)$ and found that 9 is a root.
then divided f by $x-9$ and got $ f = (x-9)(x^2+4x+9)$
then again trying all $x \in (1,2,...,10)$ in $x^2 +4x + 9 $ and found that it does not have any prime factorization.
so my question is - is $(x-9)(x^2+4x+9)$ the prime factorization of f?
and if so , is there a simpler way to find it?
There are some tricks (like the quadratic residue mentioned in the comment), but your method is the most straightforward when dealing with small degree polynomials (degree $\leq 3$) in a finite field. Keep in mind that a degree four or higher polynomial might factor into irreducible non-linear polynomials, and not have any roots.