Eigenvalues and Eigenvectors
8.1 Definitions and examples
So far in Linear Transformations we have studied linear maps where the domain and codomain could be completely different spaces. In this chapter we specialise to the case , where a vector and its image live in the same space, so that it actually makes sense to ask how compares to itself. Two questions drive everything that follows:
- Given a map , are there vectors that are related in a very simple way to their images ?
- [X] Is there a choice of basis for that makes the matrix representing take a very simple form?
The answer to both is yes, and remarkably it is the same answer. The simplest possible relationship between and is that they are parallel; does nothing to except stretch it.
Note
Definition
Let be a linear map. If a scalar and a non-zero vector satisfy
then is called an eigenvalue of and is called an eigenvector of for the eigenvalue .
Basically, an eigenvector is a direction that the map leaves alone; every other vector gets rotated or sheared off into some new direction, but an eigenvector just gets scaled by . The whole power of the subject comes from the fact that if you can find enough of these directions to build a basis, then the map is nothing but a collection of independent stretches, which is about as simple as a linear map can get.
It is important to note the asymmetry in the definition: an eigenvector must be non-zero, but zero is perfectly allowed to be an eigenvalue. The reason for banning is that holds for every scalar , so if we allowed it then every number would be an eigenvalue of every map and the definition would say nothing at all. On the other hand is genuinely informative; it says exactly that , i.e. that is not one-to-one.
Example. For infinitely differentiable real-valued functions , the derivative
defines a linear map (we checked in Section 7.5 that differentiation is linear). The exponential function satisfies
so is an eigenvector of with eigenvalue . Notice that this is not a curiosity; the enormous importance of exponentials in calculus is precisely that they are the only functions whose derivative is a multiple of themselves. Every time you solved in Ordinary Differential Equations and wrote down , you were computing an eigenvector of .
Calculus is a very rich source of eigenvalue problems, but in this course we are mainly concerned with algebraic problems on finite-dimensional spaces. Those maps can always be represented by matrices, so from here on "eigenvalue" means "eigenvalue of a matrix".
There is one important piece of housekeeping first. When dealing with eigenvalues of matrices we are forced to use as our field of scalars. The reason is that eigenvalues turn out to be the zeroes of a polynomial, and we can only be certain of finding zeroes when the polynomial is complex. So the natural scalar field here is and the natural vector spaces are the complex spaces from Section 6.1. Real matrices are still allowed; we just have to accept that a perfectly innocent real matrix can have complex eigenvalues, and refusing to look at them would leave the theory full of holes.
Note
Definition
Let be a square matrix. If a scalar and a non-zero vector satisfy
then is an eigenvalue of and is an eigenvector of for the eigenvalue .
Example. For the diagonal matrix
the standard basis vectors and satisfy
Therefore is an eigenvector with eigenvalue and is an eigenvector with eigenvalue . Geometrically, if and , then this matrix stretches everything on the -axis by a factor of and flips everything on the -axis while doubling its length; the two axes are the two eigen-directions. For a diagonal matrix the eigenvalues are just the diagonal entries and the standard basis vectors are the eigenvectors; there is nothing to calculate. This is the whole reason we will spend Section 8.2 trying to turn other matrices into diagonal ones.
Example. For the matrix and vector
direct multiplication gives
Therefore is an eigenvector of for the eigenvalue . Notice how cheap verifying an eigenvector is compared to finding one; it is one matrix-vector product. If a question hands you a candidate eigenvector, never go through the characteristic polynomial — just multiply.
8.1.1 Some fundamental results
We now need a way of finding eigenvalues rather than checking them. The trick is to turn the eigenvector equation into a statement about a kernel, which is something we already know how to compute by row reduction.
Note
Theorem
A scalar is an eigenvalue of a square matrix if and only if
and then is an eigenvector of for if and only if is a non-zero solution of the homogeneous equation ; that is, if and only if and .
Proof. By definition, an eigenvalue and corresponding eigenvector satisfy with . Rearranging,
where is the identity matrix of the same size as . Now is a square matrix, and a square homogeneous system has a non-zero solution if and only if its determinant vanishes. Hence is an eigenvalue if and only if . Given that, is an eigenvector precisely when it is a non-zero solution of that homogeneous system, i.e. precisely when .
The insertion of in the second line is the single most important step in this chapter, and it is the step students most often get wrong. You cannot write , because is a matrix minus a scalar, which is meaningless. You must turn into first.
Basically, this theorem converts an eigenvalue problem into two things we already know how to do: computing a determinant, and computing a kernel. It also tells us something structurally nice. The set of eigenvectors for , together with , is exactly , and a kernel is a subspace by the theorem in Section 7.4.1.
Note
Definition
For an eigenvalue of , the subspace is called the eigenspace of for .
So an eigenvalue never has just one eigenvector; it has a whole subspace of them (minus the origin), and in particular there are always infinitely many. When we "write down the eigenvector for " we are really recording a basis for the eigenspace, and any non-zero multiple of it would have done just as well. Do not be alarmed if your eigenvector is a different multiple from the answer in the back of the book; check whether the two are parallel before assuming you are wrong.
Note
Theorem
If is an matrix and , then is a complex polynomial of degree in .
This can be proved by direct expansion of the determinant; it is straightforward but tedious, so we will just look at the case to see why it happens. We have
and expanding along the first column,
Notice where the comes from: only the product of the three diagonal entries contributes a term, and it arrives with a sign of . In general the leading term is , which is why the degree is exactly and never less.
Note
Definition
For a square matrix , the polynomial is called the characteristic polynomial of , and the equation is called the characteristic equation of .
Example. Find the characteristic polynomial of
Subtracting from each diagonal entry and expanding along the first row,
Therefore the characteristic polynomial is . A useful sanity check at this point: the coefficient of is always , the sum of the diagonal entries, and . Here , matching the term, and . If either check fails you have made an arithmetic slip; this catches errors far faster than redoing the expansion.
Note
Theorem
An matrix has exactly eigenvalues in , counted according to their multiplicities. These eigenvalues are the zeroes of the characteristic polynomial .
Proof. The characteristic polynomial has degree over by the previous theorem, so by the Factorisation Theorem for complex polynomials it has exactly zeroes counted with multiplicity. By the fundamental theorem above, those zeroes are exactly the eigenvalues of .
This is where the insistence on complex scalars pays off. Over the statement is simply false — a rotation matrix has no real eigenvalues at all — but over every matrix has its full complement of eigenvalues, no exceptions.
Example. For the matrix of the previous example, the roots of are, to four significant figures, , and , and these are the three eigenvalues of .
You are not expected to solve nasty cubics like that by hand; note the complex pair appearing as conjugates, which always happens when the matrix has real entries. The theorem is of enormous theoretical importance because it guarantees eigenvalues exist, but with the exception of matrices and specially constructed larger ones, modern numerical methods for finding eigenvalues do not go anywhere near the characteristic polynomial — they are iterative, and vastly more stable.
8.1.2 Calculation of eigenvalues and eigenvectors
The working method is now fixed, and every exam question in this chapter follows it:
- Form by subtracting from each diagonal entry.
- Compute and solve for the eigenvalues.
- For each eigenvalue in turn, row reduce and find a basis for .
Example. Find the eigenvalues and eigenvectors of .
The characteristic polynomial is
so the eigenvalues are and . As promised, a matrix has two of them.
For the eigenvectors are the non-zero vectors of . Row reducing,
so , giving and
For we have , which row reduces to a single equation , so and
Therefore the eigenvalues are and , with eigenvectors and respectively, for any . Notice that being an eigenvalue is exactly the statement that is singular, which it obviously is — its two rows are identical.
Since turning up as an eigenvalue keeps happening, it is worth boxing the general principle:
Example. Find the eigenvalues and eigenvectors of .
The characteristic equation is
so there is a single eigenvalue , of multiplicity . For its eigenvectors,
whose rows are identical, so the system collapses to and
Therefore the only eigenvalue is and its eigenvectors are for . Here the eigenvalue has multiplicity as a root, but its eigenspace is only -dimensional; there is nowhere near enough eigenvectors to build a basis for .
Note
Definition
A square matrix with fewer linearly independent eigenvectors than it has columns is called a defective matrix.
The two multiplicities involved here have names, and telling them apart is the single most examinable distinction in the chapter.
Note
Definition
For an eigenvalue of , the algebraic multiplicity of is its multiplicity as a root of the characteristic polynomial, and the geometric multiplicity of is , the dimension of its eigenspace.
Basically, the algebraic multiplicity is how many times the eigenvalue was promised to you by the characteristic polynomial, and the geometric multiplicity is how many independent eigenvectors actually turned up. It is always true that
and a matrix is defective exactly when the inequality on the right is strict for at least one eigenvalue. In the example above, had algebraic multiplicity but geometric multiplicity , so the matrix is defective.
A repeated eigenvalue does not automatically mean the matrix is defective. The next two examples show both outcomes, and the only way to tell is to actually compute the eigenspace.
Example. The matrix has characteristic polynomial , so with algebraic multiplicity . But is the zero matrix, so and
is -dimensional. Therefore the geometric and algebraic multiplicities agree at and the matrix is not defective — indeed every non-zero vector is an eigenvector, since scales everything equally.
Example. Find the eigenvalues and eigenspaces of
and determine whether is defective.
Rather than expand a determinant, notice that where is the matrix of all ones. Every row of sums to , so
giving the eigenvalue with eigenvector for free. For the rest, , so
which is a single equation in three unknowns and hence a -dimensional subspace with basis
Checking one of them, , as required. So the eigenvalues are (algebraic and geometric multiplicity ) and (algebraic and geometric multiplicity ), and since we have found linearly independent eigenvectors, is not defective. Therefore has a repeated eigenvalue and is still perfectly well behaved; contrast this with the earlier , where the repeated eigenvalue only produced one direction.
Example. Find all eigenvalues and eigenvectors of .
The characteristic equation is
whose roots are
So and . For ,
and row reducing (multiply row 1 by to get , which is times row 2) gives the single equation , i.e. . Taking gives , so
Checking, and , which agree. Therefore the eigenvectors for are , and for they are — taking complex conjugates of both the eigenvalue and the eigenvector, which always works for a real matrix and saves you doing the second calculation.
Example. Find the eigenvalues and eigenvectors of the lower triangular matrix
Since is still lower triangular, its determinant is just the product of the diagonal entries:
so the eigenvalues are . For any triangular matrix — upper or lower — the eigenvalues are exactly the diagonal entries, so never expand the determinant. For the eigenvectors:
For : . Row 1 gives , then row 2 gives , and is free; so .
For : . Row 1 gives and row 3 gives ; so .
For : . Row 2 gives and row 3 gives ; taking gives , , so .
Checking the last one, . Therefore the eigenvalues are with eigenvectors , and .
Before moving on it is worth cataloguing what can happen for a real matrix, since the characteristic polynomial is then a real quadratic and there are only three possibilities:
| Discriminant | Eigenvalues | Example above |
|---|---|---|
| two distinct real eigenvalues | , eigenvalues | |
| one real eigenvalue of multiplicity | and | |
| a conjugate pair of complex eigenvalues | , eigenvalues |
Notice that the middle row splits further depending on whether the matrix is defective, which the discriminant alone cannot tell you.
8.2 Eigenvectors, bases, and diagonalisation
In every example of the last section except the defective one, a matrix gave us two linearly independent eigenvectors — and two independent vectors in form a basis for , by the results of Section 6.6. That is exactly the situation we want, so let us find out when it happens.
Note
Theorem
If an matrix has distinct eigenvalues, then it has linearly independent eigenvectors.
[X] Proof. Let the distinct eigenvalues be with corresponding eigenvectors , and suppose
We show ; the same argument with the indices permuted gives , which is exactly linear independence.
Apply the matrix to both sides of . For any eigenvector we have , so the whole product acts on as multiplication by . If then one of those brackets is , so every term except the first is annihilated. What survives is
The eigenvalues are distinct, so every bracket is non-zero, and because it is an eigenvector. Hence .
The converse of this theorem is false, and assuming otherwise is the classic error. Distinct eigenvalues are sufficient for a full set of independent eigenvectors but not necessary — the matrix above had a repeated eigenvalue and still gave three independent eigenvectors. What we actually need is stated next.
Note
Theorem
If an matrix has linearly independent eigenvectors, then there exists an invertible matrix and a diagonal matrix such that
Further, the diagonal entries of are the eigenvalues of and the columns of are the corresponding eigenvectors, the th column of being an eigenvector for the th diagonal entry of . Conversely, if with diagonal, then the columns of are linearly independent eigenvectors of .
[X] Proof. Let be linearly independent eigenvectors and form the matrix with these as its columns,
Multiplying a matrix on the right by acts column by column, so
Since the columns of are a basis for , the system has a unique solution for every , so is invertible. Multiplying on the left by gives .
Conversely, if then , and comparing the th columns of each side gives ; so each column of is an eigenvector. Finally, the columns of an invertible matrix are always linearly independent.
Look carefully at the third line of that proof, because it is where the ordering rule comes from. The th column of must be an eigenvector for the th diagonal entry of ; if you shuffle the eigenvalues in without shuffling the columns of to match, the result is simply wrong. This is the most common way to lose marks in this chapter.
Note
Definition
A square matrix is diagonalisable if there exists an invertible matrix and a diagonal matrix with .
Combining the two theorems gives the practical criterion:
In terms of the two multiplicities, is diagonalisable precisely when the geometric multiplicity equals the algebraic multiplicity for every eigenvalue, since the geometric multiplicities are exactly the number of independent eigenvectors each eigenvalue contributes and the algebraic ones always add up to .
Example. Show that is diagonalisable and find and with .
The characteristic equation is
so and . For , gives , so . For , gives , so . These are linearly independent — guaranteed in advance by the distinct-eigenvalues theorem, since — so is diagonalisable with
Checking directly, so , and
Therefore is diagonalisable with the and above.
The choice of and is never unique. We could have listed the eigenvalues the other way round, taking
and any non-zero multiple of any column of also works, since non-zero multiples of eigenvectors are eigenvectors. So there are infinitely many correct answers; what is not free is the pairing between column of and entry of .
Example. Is diagonalisable?
We found earlier that its only eigenvalue is , with a -dimensional eigenspace spanned by . So has only one linearly independent eigenvector, not two, and is defective. Therefore is not diagonalisable. Notice we did not need to try and fail to construct ; counting the dimension of the eigenspaces settles it immediately.
8.3 Applications of eigenvalues and eigenvectors
Many of the applications listed at the start of this chapter arise from studying dynamical systems — essentially any system that changes over time. An electrical network, a bridge oscillating in wind, the population of a city, an ant colony, an atomic nucleus and the Australian economy are all dynamical systems. The common thread in what follows is that a system evolving by repeated application of a matrix is hard to understand directly, but becomes trivial once you look at it in a basis of eigenvectors, where the coordinates simply evolve independently of one another.
8.3.1 Powers of
A typical problem is to compute for large . Multiplying by itself times is hopeless for large ; two propositions rescue us.
Note
Proposition
Let be the diagonal matrix with diagonal entries . Then for , is the diagonal matrix with diagonal entries .
Proof. By induction on . The result is obvious for . Assume it holds for . Then multiplying out,
since off-diagonal entries of a product of diagonal matrices are all zero. So the result holds for , and hence for all positive integers .
Note
Proposition
If is diagonalisable with , then
Proof. By induction on . Multiplying the diagonalisation equation on the left by and the right by gives , which is the case . Assuming the result for ,
so the result holds for and hence for all .
Basically, the telescoping in the middle of that proof is the entire point of diagonalisation. Every adjacent pair cancels, so a product of copies of costs you only one , one , and powers of scalars.
Example. Find for .
From the previous section is diagonalisable with
Then
As a check, substituting gives and substituting gives ; and gives , which agrees with computed directly. Therefore . Always run the and checks; they cost one line each and catch a transposed or a swapped eigenvalue instantly.
Example. (Fibonacci.) Let , and . Show that the Fibonacci numbers can be extracted from powers of a matrix, and hence explain where the golden ratio comes from.
The recurrence says exactly that
so with we get . The characteristic equation of is
whose roots are and . Since the matrix is diagonalisable, so where has and on its diagonal; every entry of is therefore a fixed linear combination of and . Carrying this through gives Binet's formula
As a check, , as the recurrence demands. Therefore the golden ratio is not a mystical constant that happens to show up in the Fibonacci numbers; it is simply the dominant eigenvalue of the recurrence matrix, and since the term dies away and consecutive Fibonacci numbers approach a ratio of .
[X] As an aside, diagonalisation also lets us make sense of the exponential of a matrix. Substituting into the power series
replacing by , and writing , the same telescoping as before gives
and the bracket is diagonal with entries . So for a diagonalisable matrix,
One can define , and so on in exactly the same way. This is not a party trick; the matrix exponential is precisely what solves the systems of differential equations in the next section.
8.3.2 Solution of first-order linear differential equations
A very common problem is to solve a pair of coupled first-order linear ODEs with constant coefficients,
with and given. In Ordinary Differential Equations we could only handle one equation at a time; the difficulty here is that the two are coupled, since each derivative depends on both unknowns. Writing
the system becomes the single matrix equation
In this form nothing restricts us to two components, and equations of this type are important enough in dynamical systems to have a name — state-space equations, with called the state vector.
This is the obvious generalisation of the scalar equation with , whose solution you already know to be . So it is entirely plausible to guess an exponential solution of the form for a constant scalar and constant vector . Substituting the guess,
and since for all , the guess works exactly when .
Note
Proposition
is a solution of if and only if is an eigenvalue of and is an eigenvector for .
Basically, the eigenvectors are the directions in which the coupled system decouples; along an eigenvector the whole vector just grows or decays exponentially at the rate given by its eigenvalue, exactly as in the one-dimensional case.
Note
Proposition
If and are solutions of , then so is any linear combination of them.
Proof. Let for scalars . Then
which is what we needed.
This is the same superposition principle you met for second order linear ODEs, and for the same reason — the equation is linear.
Example. Find the general solution of where , and then the particular solution with .
We already know the eigenvalues and eigenvectors of this matrix:
So two solutions are and , and by superposition the general solution is
(That this is the general solution — that every solution has this form — is true but not proved here.) Substituting and matching the initial condition,
Adding gives , so and . Therefore
Checking at : , as required.
One reason for caring about first-order systems is that every linear differential equation can be turned into one, by introducing the derivatives as new variables.
Example. Convert into a system of first-order equations, and solve it both ways.
Define and . Differentiating and using the original equation,
so the second-order equation is equivalent to
Matrix method. The characteristic equation is
with roots and . Solving gives and gives , so
and reading off the first component, .
Calculus method. Guessing directly in the original equation gives the characteristic equation with roots and , so .
The two answers agree, and notice that the two characteristic equations are literally identical — the matrix method's reproduces the calculus method's auxiliary equation exactly. For a single equation the calculus method is obviously quicker. The matrix method earns its keep because it handles a much larger class of problems: turning one high-order equation into a system is easy, but turning a system back into one high-order equation is extremely awkward. The matrix method as described fails if is not diagonalisable; the repair uses Jordan forms, which is a second-year topic.
Example. The atoms in a laser exist in an "excited state" or a "ground state". The laser is initially pumped so that of its atoms are excited and are in the ground state. During operation, of the excited atoms decay to the ground state per second, while of the ground state atoms are pumped up per second. Find the percentage in each state at time .
Let and be the percentages in the excited and ground states. Excited atoms leave at rate and arrive from the ground state at rate , so
(The printed course notes write this matrix with entries , which contradicts the eigenvalue they then quote; the rates are per second as decimals, not percentages. Use the matrix above.) The columns of sum to zero — no atoms are created or destroyed — so and is an eigenvalue; the other is . For we solve , giving ; for , gives and . So
Applying ,
and adding gives , so and . Therefore
which correctly gives and . As the exponential dies and the laser settles into a steady state with excited and in the ground state. Notice that the steady state is a scalar multiple of , the eigenvector for — the zero eigenvalue is exactly the direction that does not decay, and every other direction is scrubbed away exponentially. This observation is the whole content of the next section.
8.3.3 [X] Markov chains
Matrices are equally useful for discrete-time dynamical systems, where the state at stage depends only on the state at stage .
Example. A psychologist tests the learning ability of rats by having them run a maze. She starts with rats, none of which has run the maze before. On average, of the rats that fail at one attempt succeed on the next, while of the rats that succeed at one attempt succeed again. Approximately how many rats succeed on the 3rd, 20th and 50th runs?
Let and be the numbers succeeding and failing on the th run. Then
Iterating, the unique solution is , and here since initially no rat has succeeded. So we need , which by the powers proposition means diagonalising. The characteristic equation is
so and . For , gives , so ; for , gives . Hence
using . Then
Checking at gives , and at it gives , which agrees with computing directly. Evaluating:
| rats succeeding | |||
|---|---|---|---|
Therefore about , and rats succeed on the 3rd, 20th and 50th runs. As we have and , so in the long run about rats succeed on any given run. Once again the limit is a scalar multiple of the eigenvector for , the eigenvalue of largest magnitude, and every other eigenvalue contributes a term that decays like .
Note
Definition
A Markov chain is a system modelled by , where records the number of individuals in each of states at time , and the matrix has all entries non-negative with every column summing to ; the entry is the probability that an individual moves from state to state .
The column sums being is just the statement that everybody has to end up somewhere — no individuals are created or destroyed. The behaviour we saw in the rat example is typical: for any such matrix, is an eigenvalue and is the eigenvalue of largest magnitude, and in almost all cases converges to a multiple of the corresponding eigenvector. Strikingly, that limit depends only on the total number of individuals and not at all on how they were distributed at the start. We finish by proving the first of these claims.
Note
Lemma
If is an eigenvalue of , then is also an eigenvalue of .
Proof. Determinants are unchanged by transposition, and since . Hence
so and have the same characteristic polynomial and therefore the same eigenvalues.
Note
Theorem
Suppose is an matrix in which every column sums to . Then has as an eigenvalue.
Proof. The hypothesis is that for each column . But the th column sum of is exactly the th row sum of , so multiplying by the all-ones vector gives
The all-ones vector is non-zero, so is an eigenvalue of , and by the lemma it is therefore an eigenvalue of .
Be careful with what that proof does and does not give you. It shows is an eigenvalue of , but the all-ones vector is the eigenvector of , not of ; in general it is not an eigenvector of . In the rat example the eigenvector of for was , nothing like . To find the steady state you must still solve properly.
To summarise the working method for the whole chapter:
- To find eigenvalues, subtract from each diagonal entry and solve . Check your characteristic polynomial against and before going further, and remember that for a triangular matrix the eigenvalues are simply the diagonal entries.
- To find eigenvectors, row reduce and read off a basis for its kernel. The eigenvector is only determined up to a non-zero multiple.
- To test diagonalisability, compare the geometric multiplicity with the algebraic multiplicity for each eigenvalue. Distinct eigenvalues guarantee success, but repeated eigenvalues can still succeed, so you must check.
- To diagonalise, put the eigenvectors in the columns of and the corresponding eigenvalues in the matching diagonal positions of — matching being the part people get wrong.
- To iterate or to solve , work in the eigenvector basis, where each coordinate evolves independently as or , and the long-run behaviour is dictated entirely by the eigenvalue of largest magnitude.