TITLE: Polynomials Shouldn't Have factors using Rational Root Theorem but it does!
QUESTION [4 upvotes]: I came across this polynomial 

$X^4 + X^3 + 2X^2 + X + 1$

I tried to factor it using Rational root theorem, but it seems there are no roots possible. 1 or -1 don't work.
But I know for a fact that its composed of $(X^2 + X + 1) * (X^2 + 1)$ Wolfram Alpha factored it properly but can't seem to generate a step by step solution so I can understand what method was used?
I need 2 things:

A test that can tell me if this is factorizable.
A method to factor it.

REPLY [0 votes]: Apart from just "seeing" the factorization as in the answer of amWhy, one can also use the fact that the polynomial is symmetric to reduce the degree of the problem. After dividing by $X^2$ one obtains a symmetric Laurent-polynomial
\begin{align}
X^2+X+2+X^{-1}+X^{-2}=(X+X^{-1})^2+(X+X^{-1})=Z^2+Z=Z\,(Z+1)
\end{align}
Here the resulting quadratic polynomial in $Z=X+X^{-1}$ has a trivial factorization, but any symmetric polynomial of degree 4 reduces in this way to a quadratic polynomial that can then be factorized into linear factors. Each linear factor $Z-a$ then gives a quadratic factor $X^2-aX+1$ of the original polynomial.
{"set_name": "stack_exchange", "score": 4, "question_id": 857149}