TITLE: How to find the minimal polynomial of a matrix
QUESTION [5 upvotes]: Let $A=\begin{pmatrix}
1 &2  & 1 &0\\ 
-2 & 1 & 0 &1 \\ 
0 &0  &1  &2 \\ 
0 &0  & -2 & 1
\end{pmatrix}$. Then the characteristic polynomial of $A$ is $\chi (x)=(x^2-2x+5)^2$.
I want to find the minimal polynomial of $A$. How can I find this? Are there some formulaic algorithm?(That is, if some algorithm for this question exists, this algorithm can be applied to other matrices?)

REPLY [3 votes]: The minimal polynomial must be a divisor of the characteristic polynomial. 
You've already found a factorization of the characteristic polynomial into quadratics, and it's clear that $A$ doesn't have a minimal polynomial of degree $1$, so the only thing that remains is to check whether or not $x^2-2x+5$ is actually the minimal polynomial or not.