I'm having a lot of trouble understanding the process of finding a basis for the Jordan canonical form (the "algorithm"). My textbook (Friedberg 4E) isn't very clear, and I can't seem to find anything online.
If we consider the example $A$ = $\begin{bmatrix}6 & -2 & -1\\3 & 1 & -1\\2 & -1 & 2\end{bmatrix}$, we get the characteristic polynomial $p(t)$ = ($3 - t$)$^3$.
I understand the process of finding the matrix $J$ in $A = P^{-1}JP$, but I just can't seem to grasp finding $P$. Any clarification/explanation on the steps to do so would be incredibly helpful. Thank you.
The matrix $A$ has only one true eigenvector $\vec{z} = (1,1,1)$ corresponding to the eigenvalue $\lambda = 3$. In other words, $(A-3I)\vec{z} = \vec{0}$. Though we can't find any other linearly independent vectors that have this same property, we can find linearly independent vectors such that $(A-3I)^2\vec{y} = \vec{0}$ i.e. $(A-3I)\vec{y} = \vec{z}$. Solving this system is just solving a 3x3 linear system. Similarly, it is possible to find a third vector $\vec{x}$ such that $(A-3I)\vec{x} = \vec{y}$. Let's say we have the eigenvector $\vec{z}$ above and we have two generalized eigenvectors $\vec{x}$ and $\vec{y}$ such that
$$(A-3I): \vec{x} \mapsto \vec{y} \mapsto \vec{z} \mapsto \vec{0}$$
A "3-cycle" if you will (regular eigenvectors are all "1 cycles").
Construct the following matrix as column vectors: $$ \left(A\vec{z} |A\vec{y} |A\vec{x} \right) = \left(3\vec{z}|3\vec{y}+\vec{z}|3\vec{x} + \vec{y} \right)$$ $$(A)(\vec{z}|\vec{y}|\vec{x}) = (\vec{z}|\vec{y}|\vec{x}) \begin{pmatrix}3&1&0\\0&3&1\\0&0&3 \end{pmatrix}$$ Letting $P = (\vec{z}|\vec{y}|\vec{x})$ gives us $AP = PJ$.
That's the theory. Now in practice, you can usually just guess at a vector (not a multiple of $\vec{z}$) that will be a desired "3-cycle". Check it out: $$(A-3I)(1,0,0) = (3,3,2)$$ $$(A-3I)(3,3,2) = (1,1,1) = \vec{z}$$ $$(A-3I)(1,1,1) = (0,0,0)$$ So, your 3-cycle is $(1,0,0) \mapsto (3,3,2) \mapsto(1,1,1) \mapsto \vec{0}$. So, your change of basis matrix $P$ is then $$\begin{pmatrix} 1&3&1\\1&3&0\\1&2&0\\ \end{pmatrix}$$
Does this help?