Skip to main content

Welcome to a Grasp lesson

Create a free account to keep studying and create your own study path.

Lesson 39

Eigenvalues and Eigenvectors Explained

Recommended resources

Hello! Welcome to the sixth lesson in our module on Linear Algebra Foundations.

In our last lesson, we investigated how matrices transform space by scaling area (determinant) and how to reverse these transformations (inverse). We ended with a question: are there certain vectors that are "special" under a transformation, specifically vectors that don't get knocked off their original direction?

Today, we will answer that question. Our goal is to explain the concepts of eigenvalues and eigenvectors. This is one of the most fundamental ideas in linear algebra. Understanding it will give you a much deeper insight into the "true" action of a matrix and is a prerequisite for many advanced machine learning techniques, most notably Principal Component Analysis (PCA).

1. The Core Idea: Vectors That Don't Change Direction

When a matrix transforms space, it can feel chaotic—vectors are rotated, sheared, and stretched all at once. However, for any given transformation, there are almost always a few special vectors that don't get rotated off their original line. The only thing the transformation does to them is stretch, shrink, or flip them. These special vectors are called eigenvectors.

The word "eigen" is German for "own" or "characteristic," so an eigenvector is a characteristic vector of a matrix. It reveals the natural axes of the transformation.

To build a strong visual intuition for this, let's watch a segment from the excellent "Essence of linear algebra" series by 3Blue1Brown.

Eigenvectors and eigenvalues | Chapter 14, Essence of linear algebra

This video provides a superb geometric intuition for what eigenvectors are and why they are special. Focus on how most vectors are moved off their original line (span), while a few special ones stay on it.

Watch from 01:19 to 04:07. Pay attention to the distinction between vectors that get knocked off their span and the special 'eigenvectors' that remain on their span, only being scaled.

As the video showed, eigenvectors are the vectors that stay on their own span after the transformation.

Here's another great visual using the Mona Lisa. Imagine the transformation is shearing the image.

Eigenvectors and Eigenvalues — Topic 28 of Machine Learning Foundations

This video from Jon Krohn's Machine Learning Foundations series offers another clear, practical example using image transformations.

Watch from 00:25 to 03:35. Notice how after a shearing transformation, the horizontal blue vector stays on its original line (making it an eigenvector), while the vertical red vector is knocked off its line (so it is not an eigenvector).

Geometric Interpretation of Eigenvectors and Eigenvalues
This image provides a perfect summary. A matrix transformation `A` is applied to several vectors. While most vectors (like 1, 2, 3, 5) change direction, vector 4 stays on its original line. It only changes in length. Therefore, vector 4 is an eigenvector of matrix A.

2. Eigenvalues: The Scaling Factor

So, an eigenvector keeps its direction. But by how much is it stretched or shrunk? This scaling factor is called the eigenvalue, usually denoted by the Greek letter lambda ().

Every eigenvector has a corresponding eigenvalue.

  • If , the eigenvector is stretched.
  • If , the eigenvector is shrunk.
  • If , the eigenvector is unchanged. This is a "steady state."
  • If is negative, the eigenvector is flipped and then scaled.
  • If , the eigenvector is squashed to the origin. This means the eigenvector is in the nullspace of the matrix.

Let's continue with the Jon Krohn video, where he explains eigenvalues in the context of the same Mona Lisa example.

Eigenvectors and Eigenvalues — Topic 28 of Machine Learning Foundations

This next segment introduces the eigenvalue as the scaling factor associated with an eigenvector.

Watch from 03:35 to 07:20. See how the eigenvalue represents how much the blue eigenvector's length changes, and how a negative eigenvalue corresponds to a flip in direction.

To get a hands-on feel for this, the following interactive visualization is excellent. You can move the matrix columns (the green and red arrows) to define a transformation and then drag the blue vector around to find the directions where it becomes an eigenvector.

Eigenvectors and Eigenvalues explained visually

This interactive webpage by Victor Powell and Lewis Lehe allows you to explore the concepts of eigenvalues and eigenvectors visually.

Read the initial explanation and then spend a few minutes playing with the visualization. Drag the columns of the matrix A (the red and green arrows) to define different transformations. Then drag the vector v (the blue dot) and try to line it up with the transformed vector Av (the purple dot) so that they are on the same line through the origin. When you succeed, you've found an eigenvector! Notice the eigenspaces (the gray lines) that appear.


3. The Formal Definition and Characteristic Equation

Now that we have the intuition, let's formalize it. We said that multiplying an eigenvector by a matrix has the same effect as multiplying by a scalar eigenvalue . This gives us the fundamental eigenvalue equation:

Where:

  • is an matrix (the transformation).
  • is an column vector (the eigenvector).
  • is a scalar (the eigenvalue).

This single equation elegantly captures the entire concept.

How do we use this to find the eigenvalues and eigenvectors? We can rearrange the equation. Your experience with algebra and programming will make this manipulation straightforward.

  1. Move to the left side:

  2. To factor out the vector , we need both terms to be matrix-vector products. We can't subtract a scalar from a matrix . So, we cleverly multiply by the identity matrix . Since , this doesn't change the equation:

  3. Now we can factor out :

Let's pause and think about this equation. It states that the (non-zero) eigenvector is in the nullspace of the matrix .

In our previous lesson, we learned a crucial fact: for a matrix to have a non-trivial nullspace (i.e., for it to collapse space and have non-zero solutions to ), its determinant must be zero.

Therefore, for a non-zero eigenvector to exist, the matrix must be singular. This leads us to the characteristic equation:

This is the key to finding the eigenvalues of a matrix. It's a polynomial equation in , and its roots are the eigenvalues of .

The following video segment walks through this exact derivation visually.

Eigenvectors and eigenvalues | Chapter 14, Essence of linear algebra

Let's return to the 3Blue1Brown video to see a visual explanation of how the characteristic equation is derived.

Watch from 05:15 to 09:28. This part is critical. It connects the symbolic equation Av = λv back to the geometric idea of determinants and squishing space, which we covered in the last lesson. Follow the logic from Av = λv to (A - λI)v = 0 and finally to det(A - λI) = 0.

For a more formal, text-based explanation of this process, the following resource from MIT OpenCourseWare is a standard reference.

Chapter 6 Eigenvalues and Eigenvectors

This chapter from Gilbert Strang's renowned textbook provides a concise and authoritative explanation of how to find eigenvalues and eigenvectors.

Read the section titled 'The Equation for the Eigenvalues' (pages 292-293). It walks through the same derivation we just saw, from Ax = λx to det(A - λI) = 0, and shows a worked example.

Test your understanding!

A linear transformation is represented by a matrix . You discover that for the vector , applying the transformation gives you .

  1. Is an eigenvector of ? Why or why not?
  2. If it is, what is its corresponding eigenvalue ?
Show answer
  1. Yes, is an eigenvector. The transformed vector points in the exact opposite direction of , so it lies on the same line (span) as the original vector.
  2. The transformed vector is , which is exactly times the original vector . Therefore, the eigenvalue is .

Conclusion

In this lesson, we've built a strong conceptual foundation for eigenvalues and eigenvectors. You now understand them not just as abstract mathematical objects, but as fundamental properties of linear transformations with clear geometric meaning.

Key Takeaways:

  • Eigenvectors are the special, non-zero vectors that do not change their direction (they stay on their span) when a linear transformation is applied.
  • Eigenvalues () are the scalar factors by which the eigenvectors are stretched, shrunk, or flipped.
  • The relationship is defined by the core equation: .
  • To find the eigenvalues, we solve the characteristic equation , which forces the matrix to be singular.

Preview of the Next Lesson:

We have focused on the "what" and "why" of eigenvalues. In the next lesson, we will shift to the "how." While solving the characteristic equation by hand is instructive, in practice, we always use numerical libraries. You will learn how to calculate eigenvalues and eigenvectors for any given matrix using NumPy's numpy.linalg module, a practical skill you'll use throughout your machine learning journey.