TITLE: Condition for commuting matrices
QUESTION [5 upvotes]: Let $A,B$ be $n \times n$ matrices over the complex numbers. If $B=p(A)$ where $p(x) \in \mathbb{C}[x]$ then certainly $A,B$ commute. Under which conditions the converse is  true?
Thanks :-)

REPLY [4 votes]: THEOREM: The following are equivalent conditions about a matrix $A$ with entries in $\mathbb C$:
(I) $A$ commutes only with matrices $B = p(A)$ for some $p(x) \in \mathbb C[x]$ 
(II) The minimal polynomial and characteristic polynomial of $A$ coincide
(III) $A$ is similar to a companion matrix. 
(IV) Each characteristic value of $A$ occurs in only one Jordan block. This includes the possibility that all eigenvalues are distinct, but allows for repetition if they all occur in one Jordan block.