1. Home
  2. Explore
  3. Mathematics
  4. Advanced Linear Algebra

Study methods

Flashcards
Quiz
Fill in the blanks
Written test
Lesson
Notes
Podcast
Content

Advanced Linear Algebra

Eigenvalues and Eigenvectors: Directions a Matrix Preserves

Linear algebra can be understood from several connected viewpoints. Numerical methods focus on computation, algebra focuses on solving equations, and geometry reveals how transformations move vectors and reshape space. Eigenvalues and eigenvectors bring these viewpoints together: they describe directions that a transformation treats in a particularly simple way.

That simplicity is useful in many areas. Eigenvalue methods appear in physical sciences, in the study of vibration modes, in computer science and algorithms, and in mathematical methods used in fields such as quantum mechanics. The central question is geometric, but the answer can be found using algebra.

From a matrix to a transformation

An m×nm \times nm×n matrix AAA takes an input vector from Rn\mathbb{R}^nRn and produces an output vector in Rm\mathbb{R}^mRm:

A:Rn⟶Rm.A:\mathbb{R}^n \longrightarrow \mathbb{R}^m.A:Rn⟶Rm.

When the matrix is square, with size n×nn \times nn×n, the input and output have the same number of components. The transformation takes vectors in Rn\mathbb{R}^nRn to other vectors in Rn\mathbb{R}^nRn. It can therefore be viewed as a transformation from a space back into itself.

A matrix may rotate, reflect, project, permute, or shear vectors. Most vectors change both length and direction under such a transformation. An eigenvector is a special nonzero vector whose direction is preserved: after the transformation, it lies along the same line as before. Its length may change, and its direction may reverse.

The formal definition is

As=λs,As=\lambda s,As=λs,

where AAA is a square matrix, sss is a nonzero vector, and λ\lambdaλ is a scalar. The vector sss is an eigenvector of AAA, and λ\lambdaλ is its eigenvalue. A positive eigenvalue preserves the vector’s orientation along its line; a negative eigenvalue reverses it; and an eigenvalue of zero sends it to the zero vector.

An eigenvector identifies a direction that a matrix does not turn away from. The eigenvalue tells how the matrix scales that direction.

Although AAA may have only real entries, its eigenvalues and eigenvectors need not be real. Some transformations have eigenvectors only when vectors with complex components are allowed.

Eigenvectors represent directions

If sss is an eigenvector with eigenvalue λ\lambdaλ, then any nonzero multiple of sss is also an eigenvector with the same eigenvalue. For a scalar rrr,

A(rs)=r(As)=r(λs)=λ(rs).A(rs)=r(As)=r(\lambda s)=\lambda(rs).A(rs)=r(As)=r(λs)=λ(rs).

Thus, an eigenvector is not a single uniquely determined vector; it represents an eigendirection. Applications often choose a normalized eigenvector, one whose length is 111, to give that direction a standard representative.

An n×nn \times nn×n matrix has at most nnn eigenvalues when counted with multiplicity, and at most nnn linearly independent eigenvectors. There may be infinitely many vectors in an eigendirection or eigenspace, but only a limited number can be linearly independent.

The zero vector is excluded from the definition of eigenvector. If it were allowed, it would satisfy A0=λ0A0=\lambda 0A0=λ0 for every matrix and every scalar, making the definition uninformative. The eigenvalue itself, however, may be zero.

Think About It

If a matrix changes a vector’s length but leaves it on the same line, which part of the eigenvalue equation describes the direction, and which part describes the change in scale?

Familiar transformations and their eigenvectors

The idea becomes clearer by examining transformations that act in different ways.

Permuting coordinates

A permutation matrix rearranges vector components. In two dimensions, the matrix that swaps the coordinates is

A=[0110].A= \begin{bmatrix} 0 & 1\\ 1 & 0 \end{bmatrix}.A=[01​10​].

For a vector with components xxx and yyy,

A[xy]=[yx].A \begin{bmatrix} x\\ y \end{bmatrix} = \begin{bmatrix} y\\ x \end{bmatrix}.A[xy​]=[yx​].

If the components are equal, swapping them makes no change:

A[11]=[11].A \begin{bmatrix} 1\\ 1 \end{bmatrix} = \begin{bmatrix} 1\\ 1 \end{bmatrix}.A[11​]=[11​].

So [11]\begin{bmatrix}1\\1\end{bmatrix}[11​] is an eigenvector with eigenvalue 111. More generally, any nonzero vector along the line y=xy=xy=x is unchanged.

There is another preserved direction. If the components are opposites, swapping them reverses the vector:

A[1−1]=[−11]=−1[1−1].A \begin{bmatrix} 1\\ -1 \end{bmatrix} = \begin{bmatrix} -1\\ 1 \end{bmatrix} = -1 \begin{bmatrix} 1\\ -1 \end{bmatrix}.A[1−1​]=[−11​]=−1[1−1​].

This vector is an eigenvector with eigenvalue −1-1−1. The transformation reverses its orientation but keeps it on the same line.

Projecting onto a plane

Consider projection in three dimensions onto the xyxyxy-plane. This projection leaves the first two coordinates unchanged and sets the third coordinate to zero:

P=[100010000],P[xyz]=[xy0].P= \begin{bmatrix} 1 & 0 & 0\\ 0 & 1 & 0\\ 0 & 0 & 0 \end{bmatrix}, \qquad P \begin{bmatrix} x\\ y\\ z \end{bmatrix} = \begin{bmatrix} x\\ y\\ 0 \end{bmatrix}.P=​100​010​000​​,P​xyz​​=​xy0​​.

Any vector already in the xyxyxy-plane has z=0z=0z=0, so the projection leaves it unchanged. Every nonzero vector in that plane is therefore an eigenvector with eigenvalue 111.

Vectors along the zzz-axis behave differently. Projection sends them to the zero vector:

P[00z]=[000].P \begin{bmatrix} 0\\ 0\\ z \end{bmatrix} = \begin{bmatrix} 0\\ 0\\ 0 \end{bmatrix}.P​00z​​=​000​​.

For any nonzero zzz, this is the eigenvector equation with eigenvalue 000. This illustrates why an eigenvalue can be zero even though an eigenvector cannot.

There are infinitely many eigenvectors in the xyxyxy-plane, but only two can be linearly independent. For example, the vectors along the xxx- and yyy-axes form a basis for that plane. The plane is the eigenspace associated with eigenvalue 1‘;itsdimensionis1`; its dimension is 1‘;itsdimensionis2.

Shearing a plane

A shear changes one coordinate in proportion to another. Consider the matrix

S=[10.501].S= \begin{bmatrix} 1 & 0.5\\ 0 & 1 \end{bmatrix}.S=[10​0.51​].

Its action on a general vector is

S[xy]=[x+0.5yy].S \begin{bmatrix} x\\ y \end{bmatrix} = \begin{bmatrix} x+0.5y\\ y \end{bmatrix}.S[xy​]=[x+0.5yy​].

The yyy-coordinate stays the same, while the xxx-coordinate gains an amount proportional to yyy. A vector along the xxx-axis has y=0y=0y=0, so it is unchanged:

S[10]=[10].S \begin{bmatrix} 1\\ 0 \end{bmatrix} = \begin{bmatrix} 1\\ 0 \end{bmatrix}.S[10​]=[10​].

Thus, the xxx-axis gives an eigendirection with eigenvalue 111. In this example, it is the only eigendirection: there is only one linearly independent eigenvector.

The matrix’s columns show how it transforms the coordinate basis vectors. The first basis vector is unchanged, while the second becomes

[0.51].\begin{bmatrix} 0.5\\ 1 \end{bmatrix}.[0.51​].

Geometrically, a square built from the coordinate directions is slanted into a parallelogram. That slanting effect is the shear.

Rotating a plane

A rotation through angle θ\thetaθ in two dimensions is represented by

Qθ=[cos⁡θ−sin⁡θsin⁡θcos⁡θ].Q_\theta= \begin{bmatrix} \cos\theta & -\sin\theta\\ \sin\theta & \cos\theta \end{bmatrix}.Qθ​=[cosθsinθ​−sinθcosθ​].

The columns describe where the two coordinate basis vectors are sent. For a rotation by 90∘90^\circ90∘, or π2\frac{\pi}{2}2π​ radians,

Qπ/2=[0−110].Q_{\pi/2}= \begin{bmatrix} 0 & -1\\ 1 & 0 \end{bmatrix}.Qπ/2​=[01​−10​].

Every nonzero real vector is turned to a different direction by this rotation, so there is no real eigenvector. Complex vectors are needed to find eigenvectors for this matrix, as discussed later.

Think About It

A projection has eigenvalue 000 for vectors in a direction it removes. How does that differ from the eigenvalue 111 for vectors it leaves unchanged?

Eigenvectors beyond ordinary vectors

The eigenvalue idea also applies to operations that act on functions. A function can be treated as a vector with one value for every input position. For example, recording the values of a function across an interval creates a vector of sampled values; if every point in the interval is included, the vector has infinitely many components.

Differentiation provides a useful example. For the exponential function eaxe^{ax}eax,

ddxeax=aeax.\frac{d}{dx}e^{ax}=a e^{ax}.dxd​eax=aeax.

Differentiation returns the same function multiplied by the scalar aaa. In this sense, eaxe^{ax}eax is an eigenfunction of differentiation, and aaa is its eigenvalue.

A second derivative gives another example:

d2dx2sin⁡(x)=−sin⁡(x).\frac{d^2}{dx^2}\sin(x)=-\sin(x).dx2d2​sin(x)=−sin(x).

The function sin⁡(x)\sin(x)sin(x) is an eigenfunction of the second-derivative operation, with eigenvalue −1-1−1. The output has the same shape as the input but is scaled by −1-1−1.

This viewpoint connects the finite-dimensional idea of eigenvectors to transformations of functions. It underlies mathematical tools such as Fourier transforms and is also relevant to the mathematical ideas used in quantum mechanics.

Computing eigenvalues and eigenvectors

The definition of an eigenvector gives a systematic way to calculate eigenvalues. Begin with

As=λs.As=\lambda s.As=λs.

Move the right-hand side to the left:

As−λs=0.As-\lambda s=0.As−λs=0.

Because λs=λIs\lambda s=\lambda Isλs=λIs, where III is the identity matrix, the equation can be factored as

(A−λI)s=0.(A-\lambda I)s=0.(A−λI)s=0.

The vector sss is required to be nonzero. Therefore, the matrix A−λIA-\lambda IA−λI must have a nontrivial nullspace: it must send at least one nonzero vector to zero. That means its columns are linearly dependent, so the matrix is singular. A square matrix is singular exactly when its determinant is zero, giving the equation

det⁡(A−λI)=0.\det(A-\lambda I)=0.det(A−λI)=0.

The expression det⁡(A−λI)\det(A-\lambda I)det(A−λI) is a polynomial in λ\lambdaλ, called the characteristic polynomial. Setting it equal to zero gives the characteristic equation. For an n×nn \times nn×n matrix, this polynomial has degree $n`; its roots give the eigenvalues, including complex roots when necessary.

Once an eigenvalue λ\lambdaλ is known, the corresponding eigenvectors are found by solving

(A−λI)s=0.(A-\lambda I)s=0.(A−λI)s=0.

In other words, the eigenvectors for λ\lambdaλ are the nonzero vectors in the nullspace of A−λIA-\lambda IA−λI. A basis for that nullspace gives a basis for the associated eigenspace.

Worked example: the coordinate swap

For the permutation matrix

A=[0110],A= \begin{bmatrix} 0 & 1\\ 1 & 0 \end{bmatrix},A=[01​10​],

subtracting λI\lambda IλI gives

A−λI=[−λ11−λ].A-\lambda I= \begin{bmatrix} -\lambda & 1\\ 1 & -\lambda \end{bmatrix}.A−λI=[−λ1​1−λ​].

Its determinant is

det⁡(A−λI)=λ2−1.\det(A-\lambda I)=\lambda^2-1.det(A−λI)=λ2−1.

The characteristic equation is λ2−1=0\lambda^2-1=0λ2−1=0, so the eigenvalues are λ=1\lambda=1λ=1 and λ=−1\lambda=-1λ=−1.

For λ=1\lambda=1λ=1, solving (A−I)s=0(A-I)s=0(A−I)s=0 gives the eigendirection spanned by

s1=[11].s_1= \begin{bmatrix} 1\\ 1 \end{bmatrix}.s1​=[11​].

For λ=−1\lambda=-1λ=−1, solving (A+I)s=0(A+I)s=0(A+I)s=0 gives the eigendirection spanned by

s2=[1−1].s_2= \begin{bmatrix} 1\\ -1 \end{bmatrix}.s2​=[1−1​].

These eigenvectors are orthogonal because their dot product is

[11][1−1]=0.\begin{bmatrix} 1 & 1 \end{bmatrix} \begin{bmatrix} 1\\ -1 \end{bmatrix} =0.[1​1​][1−1​]=0.

Eigenspaces and multiplicity

An eigenvalue may occur more than once as a root of the characteristic polynomial. Its algebraic multiplicity is the number of times it appears as a root. The dimension of its eigenspace—the number of linearly independent eigenvectors associated with it—is its geometric multiplicity.

Projection example

For projection onto the xyxyxy-plane,

P=[100010000],P= \begin{bmatrix} 1 & 0 & 0\\ 0 & 1 & 0\\ 0 & 0 & 0 \end{bmatrix},P=​100​010​000​​,

the characteristic polynomial can be written as

det⁡(P−λI)=(1−λ)2(−λ).\det(P-\lambda I)=(1-\lambda)^2(-\lambda).det(P−λI)=(1−λ)2(−λ).

The eigenvalues are 000, 111, and 111. Thus, eigenvalue 111 has algebraic multiplicity 222, while eigenvalue 000 has algebraic multiplicity 111.

The eigenspace for λ=1\lambda=1λ=1 is the xyxyxy-plane, which has dimension 222. Its geometric multiplicity is therefore 222. The eigenspace for λ=0\lambda=0λ=0 is the zzz-axis, which has dimension 111. In both cases, the geometric and algebraic multiplicities agree.

Shear example

For the shear matrix

S=[10.501],S= \begin{bmatrix} 1 & 0.5\\ 0 & 1 \end{bmatrix},S=[10​0.51​],

the characteristic polynomial is

det⁡(S−λI)=(1−λ)2.\det(S-\lambda I)=(1-\lambda)^2.det(S−λI)=(1−λ)2.

The only eigenvalue is λ=1\lambda=1λ=1, with algebraic multiplicity 222. But its eigenspace is only the xxx-axis, so it has geometric multiplicity 111. This is a case where there are not enough linearly independent eigenvectors to match the repeated root.

In general, the geometric multiplicity of an eigenvalue cannot exceed its algebraic multiplicity, but it can be smaller. The shear illustrates why both multiplicities matter: knowing the eigenvalues alone does not reveal how many independent eigenvector directions are available.

Symmetric and skew-symmetric matrices

A real symmetric matrix is a real matrix equal to its transpose. Such matrices have a full set of orthogonal eigenvectors: an n×nn \times nn×n real symmetric matrix has nnn linearly independent eigenvectors that can be chosen to be orthogonal. This makes them especially useful when a transformation needs to be understood through independent directions.

A key example in data analysis is the Gram matrix ATAA^\mathsf{T}AATA. It is square and symmetric, since

(ATA)T=ATA.(A^\mathsf{T}A)^\mathsf{T}=A^\mathsf{T}A.(ATA)T=ATA.

When the columns of AAA are linearly independent, this matrix is also full rank. Its symmetry is important in data science and machine learning because it guarantees a full set of orthogonal eigenvectors.

A skew-symmetric matrix is the opposite kind of matrix: its transpose is its negative. The 90∘90^\circ90∘ rotation matrix is skew-symmetric. For this matrix, the characteristic equation is

λ2+1=0,\lambda^2+1=0,λ2+1=0,

so its eigenvalues are iii and −i-i−i, where i2=−1i^2=-1i2=−1. Corresponding eigenvectors can be chosen as

[1−i]for λ=i,[1i]for λ=−i.\begin{bmatrix} 1\\ -i \end{bmatrix} \quad\text{for }\lambda=i, \qquad \begin{bmatrix} 1\\ i \end{bmatrix} \quad\text{for }\lambda=-i.[1−i​]for λ=i,[1i​]for λ=−i.

These vectors belong to C2\mathbb{C}^2C2, not R2\mathbb{R}^2R2. The rotation has no real eigendirection, but it does have eigenvectors when complex components are allowed. Real skew-symmetric matrices have purely imaginary eigenvalues.

Think About It

The shear and projection examples both have repeated eigenvalues, but their eigenspaces have different dimensions. Why is the dimension of the eigenspace important in addition to the list of eigenvalues?

Visualizing the eigenvalue equation

A useful geometric test begins with a candidate vector sss and compares it with its transformed vector AsAsAs. If the two vectors lie along the same line, then the candidate is an eigenvector. The scale relating them is the eigenvalue.

For the coordinate-swap matrix, vectors along the line y=xy=xy=x are unchanged, giving eigenvalue 111. Vectors along y=−xy=-xy=−x reverse direction, giving eigenvalue −1-1−1. For projection, vectors in the target plane are unchanged, while vectors in a direction removed by the projection are sent to zero. For a shear, only the horizontal eigendirection remains fixed in the example considered. For a 90∘90^\circ90∘ rotation, no real vector lines up with its rotated image.

These examples show how the eigenvalue equation links geometry and computation. The geometry suggests what an eigenvector should do; the characteristic polynomial finds the eigenvalues algebraically; and a nullspace calculation finds the eigenspaces.

Comprehensive review

Eigenvalues and eigenvectors describe how a square matrix acts on special directions in a space. The defining equation is

As=λs,As=\lambda s,As=λs,

where sss must be nonzero. The matrix may stretch or shrink that direction, reverse it, or send it to zero. Any nonzero multiple of an eigenvector remains an eigenvector with the same eigenvalue, so the key object is the direction or eigenspace rather than one particular vector.

The calculation proceeds in two stages. First, solve the characteristic equation

det⁡(A−λI)=0\det(A-\lambda I)=0det(A−λI)=0

to find the eigenvalues. Then, for each eigenvalue, solve

(A−λI)s=0(A-\lambda I)s=0(A−λI)s=0

to find its eigenspace. The dimension of that eigenspace is the geometric multiplicity, while the number of repetitions of the eigenvalue in the characteristic polynomial is its algebraic multiplicity.

Permutations, projections, shears, and rotations illustrate different possibilities. Symmetric matrices have a full set of orthogonal eigenvectors; a shear can have fewer independent eigenvectors than its repeated eigenvalue might suggest; and a real rotation can require complex eigenvectors. Together, these ideas make eigenvalues and eigenvectors a way to reveal the internal structure of a transformation rather than merely compute its output.

Ask anything

We've read this whole study set, so questions about it get the best answers.

FlashcardsQuizFill in the blanksWritten testLessonNotesPodcastContent