How can I factor the polynomial $x^4-2x^3+x^2-1$?
This is an exercise in algebra. I have the solution showing that $$ x^4-2x^3+x^2-1=(x^2-x-1)(x^2-x+1). $$
But the solution does not show any details. Using the distributive property I can check that this is indeed true: $$ \begin{align} &(x^2-x-1)(x^2-x+1)\\ &=x^2(x^2-x+1)-x(x^2-x+1)-(x^2-x+1)\\ &=x^4-x^3+x^2-x^3+x^2-x-x^2+x-1\\ &=x^4-2x^3+x^2-1, \end{align} $$
but I can't figure out the steps to get there. Can anyone help?
Let’s examine the first three terms of your quartic$$y=x^4-2x^3+x^2-1$$The coefficients are in the order of $1,-2,1$. Thus$$\begin{align*}x^4-2x^3+x^2-1 & =x^2(x^2-2x+1)-1\\ & =x^2(x-1)^2-1\\ & =\left[x(x-1)-1\right]\left[x(x-1)+1\right]\\ & =(x^2-x-1)(x^2-x+1)\end{align*}$$where the second to last step is obtained with the difference of squares factorization.