# Diagonalisation of Square Matrices

When does a matrix ${\bf A}$ have a similar diagonal matrix and when does it not? I have a matrix ${\bf A}$:

\begin{pmatrix} 4 & 1\\ 3 & 2 \end{pmatrix}

and I am trying to find a matrix ${\bf P}$ such that ${\bf A = P^{-1}\Lambda P}$ where ${\bf \Lambda}$ is the diagonal matrix of the eigenvalues of A. I was told that ${\bf P}$ is a matrix with the eigenvectors of A in each column.

So I have ${\bf \Lambda}$ as:

\begin{pmatrix} 1 & 0\\ 0 & 5 \end{pmatrix}

and hence ${\bf P}$:

\begin{pmatrix} 1 & 1\\ -3 & 1 \end{pmatrix}

and hence ${\bf P^{-1}}$:

\begin{pmatrix} 1/4 & -1/4\\ 3/4 & 1/4 \end{pmatrix}

However this does not satisfy the equality ${\bf A = P^{-1}\Lambda P}$. Why?

-

You have your matrices switched a little bit. It's $\mathbf A = \mathbf P\mathbf \Lambda\mathbf P^{-1}$ or $\mathbf \Lambda = \mathbf P^{-1}\mathbf A\mathbf P,$ not $$\mathbf \Lambda = \mathbf P\mathbf A\mathbf P^{-1},$$ as you have it.
In your setup it is true that $A = P\Lambda P^{-1}$. If you want the $P^{-1}$ to be on the left then $P^{-1}$ will have to be the matrix with eigenvectors of $A$ as its columns.
An $n \times n$ matrix is similar to a diagonal matrix if and only if it has $n$ linearly independent eigenvectors. In particular, this is true if there are $n$ distinct eigenvalues.