<s>[INST] If $p, q, r$ are the roots of $x^3 -x+1=0$, what is $p^5 + q^5 + r^5$? Can someone please help us solve this equation. It was on our college entry exam, but no one managed to solve it. The problem is:

Let $p,q,r$ be the roots of $x^3 -x+1=0$.  Then $p^5+q^5+r^5 = ?$

Correct answer was $-5$, but no one managed to solve this problem. We tried different methods, but none came up with a solution. Any help is appreciated. 
 [/INST] Alternative approach: the characteristic polynomial of
$$ M = \begin{pmatrix}0 & 0 & -1 \\ 1 & 0 & 1 \\ 0 & 1 & 0 \end{pmatrix}$$
is exactly $p(x)=x^3-x+1$, since $M$ is the companion matrix of $p(x)$.  It follows that the wanted sum is
$$ p^5+q^5+r^5=\text{Tr }\begin{pmatrix}0 & 0 & -1 \\ 1 & 0 & 1 \\ 0 & 1 & 0 \end{pmatrix}^5 = \text{Tr }\begin{pmatrix}-1 & 1 & -1 \\ 1 & -2 & 2 \\ -1 & 1 & -2 \end{pmatrix}=\color{red}{-5}. $$
</s>