# Find an invertible matrix $P$ and a diagonal matrix $D$ such that $D=P^{−1}AP$?

I have a matrix $A=\begin{bmatrix} -5 & -1 & 2\\ 2 & 0 & -2\\ -6 & -1 & 3\end{bmatrix}$, and I need to find an invertible matrix P and a diagonal matrix D such that $D = P^{-1}AP$. I've found the eigenvalues for the matrix and they are $-3, 1, 0$, so I know the D matrix, but I can't seem to figure out the eigenvectors for the P matrix.

• What is your problem with calculating the eigenvectors? – user127.0.0.1 Feb 19 '14 at 22:25
• @user127.0.0.1 I honestly don't know I'm just not getting the right answer, the eigenvectors form the columns of Matrix P right? I'm just not getting it – Johnathon Pomenrantz Feb 19 '14 at 22:33

The $P$ matrix is just the matrix of eigenvectors of A. You find the eigenvectors by solving the equation $$(\lambda I-A)\mathbf{x}=\mathbf{0}$$ For eigenvalue $\lambda=0$, you get the associated eigenvector $\begin{bmatrix}1\\-3\\1\end{bmatrix}$
For eigenvalue $\lambda=-3,$ you get the associated eigenvector $\begin{bmatrix}1\\0\\1\end{bmatrix}$
Fr eigenvalue $\lambda=1,$ you get the associated eigenvector $\begin{bmatrix}.5\\-1\\1\end{bmatrix}$
Thus your matrix $P=\begin{bmatrix}1&1&.5\\-3&0&-1\\1&1&1\end{bmatrix}$