32.10 Computing Eigenvalues and Eigenvectors on a Spreadsheet

You can build a spreadsheet that will find same for any 3 by 3 matrix that has three real eigenvalues, as follows. It is very worthwhile for you to attempt to do this.

First find the trace determinant and second invariant (A) of the given matrix.

How?

The trace is easy, the determinant is a single command in excel.

To get the second invariant in excel is also easy: extend the matrix by making a fourth row and column which are the same as the first ones, and make the 44 entry the same as the 11 entry.

Then find the two by two diagonal matrices in columns and rows 1, 2 in columns and rows 2, 3 and in columns and rows 3, 4. The sum of these three will be A.

Then solve the characteristic equation. This can be done by starting with very large values say +1000 and -1000 and homing in on a solution using the divide and conquer approach.

Then find the other two eigenvalues by solving the quadratic equation previously described.

They will not always exist, since the roots of the quadratic could be complex; if so change your matrix to make them real.

It is barely possible that your matrix is not diagonalizable, in which case it does not have three eigenvectors, but this can only happen if two of the eigenvalues are the same.

Now find eigenvectors.

How?

Here is a good try: write down the matrix M - zI where z is one of your eigenvalues.

Extend the matrix to a fourth and fifth column by copying the first column to the fourth and second to fifth.

Then take the two by two determinants given by the first two rows and columns 23, 34 and 45. Arrange these as a column. This should be your eigenvector.

It could be that these two by two determinants are all 0. If so you can try again with the second and third rows and you could even copy the first row to a fourth row and do the same for the third and fourth rows.

If you always fail that means that you had a double eigenvalue (at least two of your three eigenvalues are the same). Eigenvectors are actually easier to find in this case, when they exist.

If all the eigenvalues are the same then M was a multiple of the identity, and every vector is an eigenvector.

Otherwise you can find a column eigenvector for that eigenvalue as described, and find a row eigenvector by doing the same thing interchanging rows and columns.

Then the column eigenvectors for your double eigenvalue will be any vectors normal to your row eigenvector for the other eigenvalue.

Once you have three column eigenvectors, you can form them into a matrix, A and examine A-1 and A-1MA, which should come out to be diagonal. (These are very easy to find in excel using the mmult and minverse functions.)