How to find $P$ such that $D=P^{-1}AP$ if $A$ has multiple parameters? 
It is given that matrix $A$: $$
A=\begin{pmatrix} 1&0&1\\0&1&b\\0&0&c\end{pmatrix}  
$$
  is diagonizable if $c \neq 1$. There're two eigenvalues are $t_1=1$ and $t_2=c\neq 1$. Find the matrix $P$ such that $D=P^{-1}AP$.

As far as I understand I need to find the general solution to the following system:
$$
tI-A=\begin{pmatrix} t-1&0&-1\\0&t-1&-b\\0&0&t-c\end{pmatrix}  
$$
If $t_1=1$ then we get:
$$
I-A=\begin{pmatrix} 0&0&-1\\0&0&-b\\0&0&1-c\end{pmatrix}  
$$
After row reduction I'd get only one row which means that the eigenspace $V_{t_1}=span\{(0,0,1)\}$.
Also if $t_2=c$ then we get:
$$
cI-A=\begin{pmatrix} c-1&0&-1\\0&c-1&-b\\0&0&0\end{pmatrix}  
$$
So $b=c-1$ then:
$$
cI-A=\begin{pmatrix} b&0&-1\\0&b&-b\\0&0&0\end{pmatrix}  
$$
which would mean that the eigenspace $V_{t_2}=span\{(1,1,1)\}$
What am I doing wrong? Please provide feedback on the method I'm using to find $P$ (though solving the corresponding homogeneous system of linear equations).
 A: Just rewrite this as a matrix equation $PD=AP$ with $D=diag(1,1,c)$, $A$ as given, and an invertible matrix $P=(p_{ij})$. This gives linear equations in the unknowns $p_{ij}$ which can be solved by Gauss elimination as usual. The matrix $P$ need not be unique in general. Also, one has to check $\det(P)\neq 0$, of course.
From the $9$ linear equations I obtain that
$$
P=\begin{pmatrix} p_{11} & p_{12} & p_{13} \cr p_{21} & p_{22} & bp_{13} \cr
0 & 0 & (c-1)p_{13} \end{pmatrix}
$$
Now I can choose an invertible one, e.g.,
$$
P=\begin{pmatrix} 1& 0 & 1 \cr 0 & 1 & b \cr
0 & 0 & (c-1)\end{pmatrix}
$$
A: What you’re doing wrong is misinterpreting the result of row-reduction. The eigenspace of an eigenvalue $\lambda$ is the null space of $\lambda I-A$. So, when you end up with $$\pmatrix{0&0&1\\0&0&0\\0&0&0}$$ that doesn’t mean that the eigenspace of $1$ is spanned by $(0,0,1)^T$—that’s a basis for the row space of the matrix. The eigenspace of $1$ is instead spanned by $(1,0,0)^T$ and $(0,1,0)^T$.  
Similarly, when calculating the eigenspace of $c$, you want the null space of $cI-A$, which you can read directly from the matrix. It’s already in echelon form with pivots in the first and second columns, so a basis for the null space will come from the third column: $(1/(1-c),b/(1-c),-1)^T$ or, more conveniently, $(1,b,c-1)^T$.
Note that in this case you didn’t have to go through this process to find the eigenspace of $1$. You know that it’s at most two-dimensional, since you have another distinct eigenvalue of $A$. Recalling that the columns of a matrix are the images of the basis, you can see that both $(1,0,0)^T$ and $(0,1,0)$ are mapped to themselves by $A$, so there’s your basis for the eigenspace.
