# Commuting diagonalisable matrices are simultaneously diagonalizable [duplicate]

Possible Duplicate:
Simultaneous diagonalization

If $A$ and $B$ are diagonalisable matrices such that $AB=BA$, prove that there exists an invertible matrix $P$ such that $P^{-1}AP$ and $P^{-1}BP$ are diagonal matrices.

If such $P$ exists, the columns of $P$ must be eigenvectors of $A$ and $B$, right? So we need to prove that $A$ and $B$ have exactly the same eigenvectors. If $x$ is an eigenvector of $A$ associated to an eigenvalue $\lambda$, then $ABx=BAx=B\lambda x=\lambda Bx$. So $Bx$ is also an eigenvector of $A$. I'm not sure how to continue from here.

• We don't need to prove that $A$ and $B$ have exactly the same eigenvectors. We need to prove that there's a basis consisting of eigenvectors of both. Your version is not true: for example, if $A$ is the identity, then it commutes with everything and has everything as an eigenvector, but $B$ need not have everything as an eigenvector. – Chris Eagle Nov 23 '11 at 11:24
• See this, for instance. – J. M. is a poor mathematician Nov 23 '11 at 11:28
• I don't understand why $B$ takes the form of 4.53. – kdewrwe Nov 23 '11 at 12:48
• I'm sorry if it is, but I don't even know what "invariant" means. – kdewrwe Nov 23 '11 at 13:06
• @kdewrwe: A subspace $W$ is $A$-invariant if for every $w\in W$, $Aw \in W$. That is, the restriction of $A$ to $W$ is a linear map from $A$ to itself. – Arturo Magidin Nov 23 '11 at 16:31