Jordan Canonical Form in Maple
These commands work under the LinearAlgebra package.
with(LinearAlgebra):
A:=Matrix(2,2,[[1,-4],[1,5]]);
Eigenvectors(A);
JordanForm(A);
LinearSolve(A-3,<-2,1>);
The JordanForm command will give the Jordan Canonical Form of A. To find the associated matrix P in the 2x2 case when A is not diagonalizable, you can take the first column of P to be the basis vector \(\vec{v}\) for the eigenspace of A, and the second column of P to be any solution of the equation \((A-\lambda I_2)\vec{u}=\vec{v}\). In the above example, \(\lambda =3\) and \(\vec{v}=\left( \begin{array}{c} -2 \\ 1\end{array}\right)\).