My first question is that is a basis for each eigenspace the same thing as a corresponding eigenvector for an eigenspace?
Could someone tell me if im doing this correctly?
I have the matrix $A=\begin{bmatrix} 4 & 3 & 3\\ -9 & -8 & -9\\ 3 & 3 & 4\\ \end{bmatrix}$
I found out that the characteristic polynomial is $-(\lambda-1)^2(\lambda+2)$
So the eigenvalues are -2 and 1.
I solved for the the eigenvector for $\lambda=-2$ and I got the eigenvector to be $\begin{bmatrix} 1 \\ -3 \\ 1\\ \end{bmatrix}$
When I solve for $\lambda=1$, I get $\begin{bmatrix} -1 \\ 1 \\ 0\\ \end{bmatrix}$ and $\begin{bmatrix} -1 \\ 0 \\ 1\\ \end{bmatrix}$ as my basis.
So from this is my $P=\begin{bmatrix} 1 & -1 & -1\\ -3 & 1 & 0\\ 1 & 0 & 1\\ \end{bmatrix}$ and my $D=\begin{bmatrix} -2 & 0 & 0\\ 0 & 1 & 0\\ 0 & 0 & 1\\ \end{bmatrix}$?
And lastly,how does the negative sign in my characteristic polynomial affect my answer?
Could you please check my work, I feel like I am doing something wrong.
The negative sign as no bearing on your answer because you're interested in the roots of the polynomial and $-(\lambda-1)^2(\lambda+2)=0\iff (\lambda-1)^2(\lambda+2)=0$.
You can check what you did yourself by computing $P^{-1}AP$.
In fact $$\begin{align}P^{-1}AP &=\begin{bmatrix} -1& -1 &-1\\ -3 & -2 & -3\\ 1 & 1 & 2\end{bmatrix}\begin{bmatrix} 4 & 3 & 3\\ -9 & -8 & -9\\ 3 & 3 & 4\end{bmatrix}P\\ &=\begin{bmatrix} 2& 2 & 2\\ -3 & -2 & -3\\ 1 & 1 & 2\end{bmatrix}\begin{bmatrix} 1 & -1 & -1\\ -3 & 1 & 0\\ 1 & 0 & 1\end{bmatrix}=D.\end{align}$$