Hello! Welcome back to our journey through linear algebra.
In the last lesson, we explored the two most important subspaces associated with any matrix : the column space, , which is the set of all possible outputs, and the null space, , which is the set of all inputs that get mapped to the zero vector. You learned how to find a basis for each.
At the very end, we noticed a curious relationship in our example: for a matrix, the dimension of its column space (1) plus the dimension of its null space (2) equaled the number of columns (3). This was no accident. Today, we'll formalize this observation into a cornerstone of linear algebra: the Rank-Nullity Theorem.
Our goal is to apply the Rank-Nullity Theorem to relate the dimensions of the domain, kernel, and image of a linear transformation. This theorem provides a powerful "accounting equation" for dimensions, revealing a fundamental trade-off between the information a transformation preserves and the information it loses.
1. Defining Rank and Nullity
First, let's give formal names to the dimensions of the subspaces we studied.
- The rank of a matrix , denoted , is the dimension of its column space.
- The nullity of a matrix , denoted , is the dimension of its null space.
From our last lesson, we know how to find these dimensions by row reducing a matrix to its reduced row echelon form (RREF):
Since every column in the RREF either contains a pivot or corresponds to a free variable, the total number of columns must be the sum of these two counts. This simple observation gives us our theorem.
The article 'Rank and Nullity' from LibreTexts provides a concise statement of these definitions and the resulting theorem. Please read the following sections to formalize these ideas.
Read the sections 'Definition: Rank and Nullity' and 'Theorem: Rank-Nullity Theorem'. These sections directly connect the concepts of rank and nullity to the number of pivot and non-pivot columns, leading to the main theorem.
So, the theorem is surprisingly straightforward to state:
The Rank-Nullity Theorem
For any matrix ,
where is the number of columns of .
Thinking in terms of a linear transformation where , this translates to:
This is a profound statement. It says the dimension of the input space is split between the dimensions of the part that gets collapsed to zero (the kernel) and the part that survives as the output (the image).
2. Building Intuition: A Conservation of Dimension
To truly understand why this theorem holds, it's helpful to visualize what's happening to the basis vectors of the domain.
Let's say our domain has dimension . We can construct a basis for in a clever way. First, find a basis for the null space (kernel) of our transformation . Let's say the nullity is , so this basis has vectors: .
These vectors all get sent to by the transformation. We can then extend this set to a full basis for the domain by adding more vectors: .
What happens when we apply the transformation to these basis vectors?
- are all . They contribute nothing to the image.
- What about ? It turns out these vectors form a basis for the image of . Therefore, the dimension of the image (the rank) is exactly .
So, we have:
- Nullity =
- Rank =
- Rank + Nullity = , which is the dimension of the domain.
Rank-Nullity Intuition | Rank-Nullity Theorem for Vector Space
The video 'Rank-Nullity Intuition' by Mohamed Omar provides an excellent visual and conceptual walkthrough of this exact idea. It will help solidify why this 'conservation of dimension' makes sense.
Watch the entire video (up to 10:11). Pay close attention to how he separates the basis of the domain (V) into two parts: the vectors that form a basis for the null space, and the remaining vectors whose images form a basis for the range (image).
This intuitive proof shows that the dimensions must add up. The dimensions of the domain are perfectly partitioned—some dimensions collapse into the null space, and the remaining dimensions are preserved to form the image.
3. Applying the Theorem: Computation
The Rank-Nullity theorem is extremely practical. If you know any two of the three quantities (rank, nullity, number of columns), you can immediately find the third. Often, it's easier to compute the rank and then use the theorem to find the nullity, rather than solving the entire homogeneous system .
The standard workflow is:
- Take your matrix and reduce it to row echelon form.
- Count the number of pivots. This is the rank.
- The nullity is then simply the total number of columns minus the rank.
How to Find Rank and Nullity of a Matrix | Linear Algebra Exercises
This short video, 'How to Find Rank and Nullity of a Matrix', demonstrates this exact computational workflow with two examples.
Watch the full video. Notice how for each matrix, the rank is found by counting leading ones (pivots) in the row echelon form, and the nullity is then calculated using the theorem.
Test your understanding!
Consider the matrix
The RREF of this matrix is
- What is the rank of ?
- What is the nullity of ?
- Does equal the number of columns?
Show answer
- Rank: The RREF has two pivot columns (the first and second). Therefore, .
- Nullity: The matrix has columns. Using the Rank-Nullity Theorem:
So, .
(We could also see this directly from the RREF, as there are two free variables, and , corresponding to the non-pivot columns). - Verification: Yes, . The theorem holds.
4. Application Beyond Computation
The real power of the Rank-Nullity Theorem is in making qualitative statements about systems and transformations without solving them. It provides constraints on what's possible.
Let's consider a practical example.
The following example from LibreTexts demonstrates how to use the theorem to deduce properties of a system of equations.
Read 'Example 12: Using rank and nullity'. Follow the logic of how knowing something about the column space (that the system is always consistent) allows you to determine the dimension of the null space (the number of independent solutions to the homogeneous system).
Let's break down the logic from that example:
- The Problem: We have a system of 3 equations in 5 variables, represented by a matrix . We are told the system is consistent for all possible right-hand sides in . We need to find the number of linearly independent solutions to the homogeneous system .
- Translation:
- "5 variables" means the domain is , so .
- "Consistent for all in " means the column space of must be all of . Therefore, .
- "Number of linearly independent solutions to " is just another way of asking for the dimension of the null space, .
- Applying the Theorem:
- Conclusion: There are exactly 2 linearly independent solutions to the homogeneous system.
This shows how the theorem connects the properties of the input space, output space, and the transformation itself into a single, powerful equation.
Conclusion
In this lesson, we formalized the relationship between the dimensions of the kernel and image of a linear transformation.
Key Takeaways:
- Rank is the dimension of the column space (image), and it equals the number of pivot columns in the matrix.
- Nullity is the dimension of the null space (kernel), and it equals the number of free variables.
- The Rank-Nullity Theorem states that for an matrix , .
- This theorem expresses a fundamental trade-off: for a given input dimension, a transformation that collapses more dimensions (higher nullity) must produce a lower-dimensional output (lower rank), and vice-versa.
Preview of the Next Lesson:
We've seen that a transformation with a nullity greater than zero maps multiple inputs to the same output (it's not one-to-one). This has a direct consequence for whether the transformation can be "reversed." In our next lesson, we will investigate the concept of invertibility. We will see how the Rank-Nullity Theorem provides one of several powerful criteria for determining if a linear transformation is invertible.