Calculating Jordan Basis for a matrix I am calculating the Jordan normal Form and Jordan Basis for this matrix
\begin{bmatrix}
    0 & 1 & 1 & 1 \\
    0 & 0 & 0 & -1 \\
    0 & 0 & 0 & 1 \\
    0 & 0 &0 & 1
\end{bmatrix}
First I calculated the characteristic polynomial $(-\lambda)^3(1-\lambda)$. The Eigenvectors are then 0 and 1 with algebraic multiplicities 3 and 1 respectively.
Then we have
$$\text{Eig}(A;1) = \text{Span}\{(1,-1,1,1)\}$$
$$\text{Eig}(A;0) = \text{Span}\{(1,0,0,0),(0,-1,1,0)\}$$
$$\text{null}(A-0.Id)^2 = \text{null}(A^2) = \text{Span}\{(1,0,0,0),(0,1,0,0),(0,0,1,0)\}$$
and the Jordan normal form would be
\begin{bmatrix}
    0 & 0 & 0 & 0 \\
    0 & 0 & 1 & 0 \\
    0 & 0 & 0 & 0 \\
    0 & 0 & 0 & 1
\end{bmatrix}
I am  confused with finding the Jordan Basis. For Basis $B = (v_1, v_2, v_3, v_4)$ I would take $v_1 = (1,-1,1,1)$ Not sure how to proceed with the rest.
Help?
 A: From the condition 
$$A=PJP^{-1}\implies AP=PJ$$
we obtain


*

*$Av_1=0\implies v_1=(0,1,-1,0)$

*$Av_2=0\implies v_2=(1,0,0,0)$

*$Av_3=v_2\implies v_3=(0,1,0,0)$

*$Av_4=v_4 \implies v_4=(1,-1,1,1)$

A: Given that you have written the Jordan matrix like this:
\begin{bmatrix}
    0 & 0 & 0 & 0 \\
    0 & 0 & 1 & 0 \\
    0 & 0 & 0 & 0 \\
    0 & 0 & 0 & 1
\end{bmatrix}
you are looking for a basis $\{ v_1, v_2, v_3, v_4 \}$ such that
$$ Av_1 = 0, \ \ \ Av_2 = 0, \ \ \ Av_3 = v_2, \ \ \ Av_4 = v_4.$$
As you say, it is clear that $v_4 = (1, -1, 1, 1)$ works.
As for the rest, it's probably best if we start with $v_3$. For $v_3$, you can choose any vector in ${\rm Ker}(A^2)$ that is not in ${\rm Ker}(A)$. Once you have chosen $v_3$, you are then forced to take $v_2 = Av_3$. (You can easily prove that if $v_3$ is contained in ${\rm Ker}(A^2)$ but not ${\rm Ker}(A)$, then $Av_3$ is a non-zero element of ${\rm Ker}(A)$.) Finally, you should choose $v_1$ to be any element of ${\rm Ker}(A)$ that is not a multiple of $v_2$. (Thus $v_1$ and $v_2$ form a basis of ${\rm Ker}(A)$.)
For example, as gimusi says, one possible choice is $v_3 = (0, 1, 0, 0)$, $v_2 = (1, 0, 0, 0)$, $v_1 = (0, 1, -1, 0)$.
Another possible choice is $v_3 = (0, 0, 1, 0)$, $v_2 = (1, 0, 0, 0)$, $v_1 = (0, 1, -1, 0)$.
A third possibility is $v_3 = (0, 2, 1, 0)$, $v_2 = (3, 0, 0, 0)$, $v_1 = (-2, 5, -5, 0)$.
And there are many more possibilities besides these...
