Eigenvalues & Eigenvectors (SymPy)
Definition
Let
Rewriting this equation, we see that
where
Here are three examples that we will consider. In each case, we have pre-computed the eigenvalues and eigenvectors (check them yourself).
Notice, for matrix
Warning
Eigenvectors are not unique, any scalar multiple of an eigenvector is an eigenvector. Therefore, some caution is needed when having software compute eigenvectors, they may not be exactly the ones you computed by hand.
.eigenvals
To find the eigenvalues of a matrix, use the .eigenvals
method. eigenvals
returns a dictionary of eigenvalue
: algebraic_multiplicity
pairs.
.eigenvects
To find the eigenvectors of a matrix, use the .eigenvects
method. eigenvects
returns a list of tuples of the form (eigenvalue, algebraic_multiplicity, [eigenvectors])
.
Example
Determine the eigenvalues and eigenvectors of
The eigenvalues are
and the corresponding eigenvectors are
We can check this for ourself.
Example
Determine the eigenvalues and eigenvectors of
Example
Determine the eigenvalues and eigenvectors of