i'm a bit confused when trying to calculating generalized eigenvectors if there is more than one eigenvectors for a specific eigenvalue.
Example: $A=\begin{pmatrix}0&1&-1&-1\\0&0&0&0\\0&-1&2&2\\0&1&-2&-2\end{pmatrix}$
This matrix has the only eigenvalue $\lambda=0$ with algebraic multiplicity $m=4$
$Eig_\lambda(A)=span\bigg\{\begin{pmatrix}1\\0\\0\\0\end{pmatrix},\begin{pmatrix}1\\0\\1\\-1\end{pmatrix}\bigg\}=span\{v_1,v_2\}$
so geometric multiplicity $g=2$
From what I know, I'd say, that we now should be able to find two generalized eigenvectors. ($4-2=2$)
What I usually do to calculate generalized eigenvectors, if we have an eigenvector $x_1$ to some eigenvalue $p$ is:
$(A-pI)x_1=0$ [gives us the ordinary eigenvector]
$(A-pI)x_2=x_1$
$(A-pI)x_3=x_2$
so that we get the generalized eigenvectors $x_2,x_3$
Back to my example: If I do this: (Note that $(A-\lambda I)=A$
$Aw_1=v_1$ gives:
$w_1\in \{\begin{pmatrix}0\\1\\1\\0\end{pmatrix}+t\begin{pmatrix}1\\0\\0\\0\end{pmatrix}+s\begin{pmatrix}0\\0\\-1\\1\end{pmatrix} | s,t\in\mathbb R\}$
$Aw_2=v_2$ gives:
$w_2\in \{\begin{pmatrix}0\\2\\1\\0\end{pmatrix}+o\begin{pmatrix}1\\0\\0\\0\end{pmatrix}+u\begin{pmatrix}0\\0\\-1\\1\end{pmatrix} | u,o\in\mathbb R\}$
We choose $t=s=o=u=1$ and get
$w_1 = \begin{pmatrix}1\\1\\0\\1\end{pmatrix}$
$w_2 = \begin{pmatrix}1\\2\\0\\1\end{pmatrix}$
So, we get the matrix$ M=(v_1,w_1,v_2,w_2)$
Is that correct? How do I go about such a case?