When a matrix transforms space, the dimensions of its Column Space and its Null Space are locked together: every input dimension that gets flattened out of the output shows up inside the Null Space.
1
Surviving and crushed dimensions
When you multiply space by a matrix, any dimension of input space that doesn't survive in the output doesn't just vanish. It gets squished straight into the origin, zero.
Surviving and crushed dimensions
Because no input direction can disappear without landing on zero, the dimensions always balance out:
Every dimension the output loses gets added to the set of inputs landing on zero.
Each dimension you flatten in the output collapses one dimension of input points onto zero, so the surviving and crushed dimensions always add up to 3.
2
Rank, nullity, and the number of columns
The Rank-Nullity Theorem is this balance of dimensions written in terms of the Column Space and the Null Space. Let's see how the starting, surviving, and crushed dimensions match up with the parts of an m×n matrix A.
Rank, nullity, and the number of columns
To multiply a matrix by a vector x, you need one entry in x to weight each column, so the number of columns always tells you how many input dimensions you start with:
3 columns[100123]inputs in R3x1x2x3=outputs in R2[x1+2x3x2+3x3]
Splitting those n starting dimensions into the ones that survive in the Column Space and the ones that get crushed to zero, which make up the Null Space, gives the Rank-Nullity Theorem:
Number of columns(starting dimensions)n=Rank(surviving dimensions)dim(Col A)+Nullity(crushed dimensions)dim(Null A)
3
Why a dependent column trades rank for nullity
Inside a matrix, each column shows where the unit vector along one of the starting axes lands. Let's look at why a column that is a combination of earlier columns takes 1 away from the Rank and adds 1 to the Nullity at the same time for this 3×3 matrix:
A=100010110
Why a dependent column trades rank for nullity
Text solution
Count the independent directions to find the RankColumns 1 and 2 point along two independent axes, while Column 3 lands in their plane as their sum, so only 2 dimensions survive in the Column Space.
Col 3⟹Rank=100+010=Col 1+Col 2=2
Rearrange the equation so the columns cancel to zeroMoving Column 3 to the other side gives the weights (1,1,−1) that make the columns cancel out, giving a 1D line in the Null Space.
So the third column fails to add a 3rd dimension to the Column Space and instead creates a 1D line of solutions to Ax=0, keeping Rank+Nullity=2+1=3.
The instant the third column drops into the plane of the first two, the Column Space loses a dimension and the Null Space gains one.
4
Pivot columns and free columns
When a matrix is too messy to spot column combinations by eye, we need a step-by-step way to find its Rank, its Nullity, and bases for both spaces. Let's find them for this 3×4 matrix:
A=1212421325138
Row reduction simplifies the matrix without changing how the columns combine, making it easy to spot the independent columns (pivot columns) and the combinations of earlier columns (free columns).
Pivot columns and free columns
A=
121
242
132
5138
Rank=?
Nullity=?
Text solution
Row-reduce A to separate pivot columns from free columnsRow-reducing A to reduced row echelon form R shows pivots in Columns 1 and 3, leaving Columns 2 and 4 as free columns.
Take the pivot columns from A for the Column Space basisThe 2 pivot columns mark the independent directions that survive, so taking Columns 1 and 3 from the original matrix A gives a basis for Col A.
Basis for Col A⟹Rank=⎩⎨⎧121,132⎭⎬⎫=2
Build one basis vector from each free column in R for the Null SpaceIn R,Col 2=2Col 1 and Col 4=2Col 1+3Col 3, so each free column gives one independent way to cancel that free column against the pivot columns to get zero.
Basis for Null A=⎩⎨⎧−2100,−20−31⎭⎬⎫⟹Nullity=2
Out of the 4 total columns, the 2 pivot columns build the 2D Column Space and the 2 free columns build the 2D Null Space, giving Rank+Nullity=2+2=4.
In practice, always read the free-column combinations off R to build your Null Space basis, but go back to the original matrix A to take the pivot columns for your Column Space basis (since row reduction changes the column vectors themselves).
5
Why wide matrices always crush dimensions
The Rank-Nullity Theorem lets us figure out what a matrix does to space without knowing a single number inside it. Suppose A is a wide 3×5 matrix. Is it possible that only the zero vector x=0 gets crushed to zero?
A=
3×5
R5
5 columns
R3
3 rows
Rank≤3
0
Nullity≥2
Why wide matrices always crush dimensions
A=
3×5
Nullity=0?
Text solution
Cap the Rank using the number of rowsBecause A has 3 rows, the outputs live in R3, which means at most 3 dimensions can survive in the Column Space.
Outputs in R3⟹Rank≤3
Subtract from the starting columns to bound the NullityStarting with 5 columns and keeping at most 3 dimensions forces at least 2 dimensions of inputs to be crushed to zero.
Nullity=5−Rank≥5−3=2
So the Null Space is at least a 2D plane, which means a 3×5 matrix can never have only x=0 as a solution to Ax=0.
6
When Ax=b has a solution for every b
Now let's flip the question around: if someone tells us how many dimensions a matrix crushes into zero, we can tell whether Ax=b has a solution for every target vector b. Let's test a 4×5 matrix A whose Null Space is a 1D line, and then a 3×3 matrix where only x=0 lands on zero.
When Ax = b has a solution for every b
A=
4×5
Null A: 1D line
Ax=b
for every b in R4?
Text solution
Find the Rank from the starting columns and the Nullity (4×5 matrix)Starting with 5 columns and losing 1 dimension to the 1D Null Space leaves 4 surviving dimensions.
Rank=5−Nullity=5−1=4
Compare the Rank to the output space R4Because A has 4 rows, the outputs live in R4, and a 4D Column Space fills all of R4.
dim(Col A)=4=number of rows⟹Col A=R4
So Ax=b has a solution for every b in R4 (whereas if Null A were a 2D plane, the Rank would drop to 5−2=3, leaving a 3D Column Space inside R4 that misses most vectors b).
Now for the square 3×3 matrix where the only solution to Ax=0 is x=0:
Use zero crushed dimensions to find the Rank (3×3 matrix)When only the single point x=0 lands on zero, Nullity=0, so all 3 starting columns survive and fill the 3D output space R3.
Rank=3−0=3=number of rows⟹Col A=R3
So for a square 3×3 matrix, crushing zero dimensions guarantees that space stays fully 3-dimensional and Ax=b has a solution for every b in R3.
Key concepts
Everything here comes back to a single balance of dimensions for an m×n matrix A:
Number of columns(starting dimensions)n=dim(Col A)(pivot columns)Rank+dim(Null A)(free columns)Nullity
You don't always need to row-reduce. If you already know the Rank or the Nullity, or if you can spot how the columns combine by eye, use Rank+Nullity=n directly. Save row reduction for messy matrices where you can't see the pivot and free columns right away.
To keep the number of columns (n) and the number of rows (m) straight, ask which space the question is about:
Columns (n) tell you about the inputs and the Null Space
Always add Rank+Nullity=n, and check whether only x=0 lands on zero by seeing if Nullity=0 (meaning all n columns are pivot columns, Rank=n).
Rows (m) tell you about the output space Rm
The number of rows caps how many dimensions can survive (Rank≤m) and tells you whether Ax=b has a solution for every b in Rm. Even if all columns survive (Nullity=0), Ax=b only has a solution for every b in Rm when Rank=m so that Col A fills the entire output space.
7
Practice
1
A 6×4 matrix A has a 3-dimensional Column Space. What is the Nullity of A, and what kind of geometric object is its Null Space?
Watch out for the common mistake of using the 6 rows to get Nullity=6−3=3 in R6; the 6 rows tell us where the outputs land, not what we start with.
To multiply a 6×4 matrix by x, how many entries does x need, and which number (6 or 4) is your starting dimension?
Because A has 4 columns, we start with 4 input dimensions in R4. (Watch out for the common mistake of using the 6 rows to get Nullity=6−3=3 in R6; the 6 rows tell us where the outputs land, not what we start with.) By the Rank-Nullity Theorem:
4=Rank+Nullity=3+Nullity⟹Nullity=1
The Null Space has Nullity 1 and is a 1D line through the origin in R4.
2
Without row-reducing, find the Rank, the Nullity, and a basis for the Null Space of A=1000103−20.
How is Column 3 built from Columns 1 and 2, and what weights on all three columns make them cancel to the zero vector?
Columns 1 and 2 point in two independent directions, while Col 3=3(Col 1)−2(Col 2), so 2 dimensions survive in the Column Space and Rank=2. Rearranging that equation so the columns cancel to zero gives:
3100−2010−13−20=000
(Be careful not to just copy the weights (3,−2,1) without flipping the sign on Column 3 to make them cancel. Plugging in (3,−2,1) gives (6,−4,0) instead of zero.) This single cancelling combination gives Nullity=1 and a basis for Null A of ⎩⎨⎧3−2−1⎭⎬⎫ (or ⎩⎨⎧−321⎭⎬⎫).
3
The 3×4 matrix A=121363132154 row-reduces to R=100300010−230. Find a basis for Col A, a basis for Null A, the Rank, and the Nullity, and verify the Rank-Nullity Theorem.
Once you spot the pivot columns and free columns in R, remember which matrix (A or R) holds the original Column Space vectors, and how each free column in R cancels the pivot columns.
In R, the pivot columns are Columns 1 and 3. Taking Columns 1 and 3 from the original matrix A (don't take 100 and 010 from R, since row operations changed the Column Space) gives:
Basis for Col ARank=⎩⎨⎧121,132⎭⎬⎫,=2
The free columns in R are Columns 2 and 4: Col 2=3(Col 1) gives the basis vector (−3,1,0,0), and Col 4=−2(Col 1)+3(Col 3) gives (2,0,−3,1) (watch out for forgetting to flip the signs on the pivot weights, which would give the wrong vectors (3,1,0,0) and (−2,0,3,1)). Thus:
Basis for Null ANullity=⎩⎨⎧−3100,20−31⎭⎬⎫,=2
Verifying Rank-Nullity: Rank+Nullity=2+2=4, the total number of columns.
4
Suppose A is a 3×6 matrix with unknown entries. What is the smallest possible dimension of Null A? Can Ax=0 have only the zero vector as a solution?
The outputs of A live in R3. What is the largest number of dimensions that can survive in R3 out of the 6 starting dimensions?
With 6 columns, the inputs start in 6D space, and with 3 rows, the outputs live in R3, so at most 3 dimensions can survive: Rank≤3. By Rank-Nullity:
Nullity=6−Rank≥6−3=3
(Don't confuse "at most 3 pivots" with "could have 0 free columns". Even if every row has a pivot, 3 of the 6 columns are still left over as free columns.) The smallest possible dimension of Null A is 3, so Ax=0 can never have only the zero vector as a solution.
5
Suppose A is a 4×6 matrix whose Null Space is a 2D plane. Does Ax=b have a solution for every b in R4? What if the Null Space were 3-dimensional instead?
Subtract the Nullity from the number of columns to find how many dimensions survive, then check whether those surviving dimensions fill the output space R4.
Starting with 6 columns and Nullity=2, we get Rank=6−2=4. (Be careful not to subtract the Nullity from the 4 rows to get Rank=4−2=2, which would make it look like the Column Space doesn't fill R4.) Because the outputs live in R4 (4 rows), a 4D Column Space fills all of R4, so Ax=b has a solution for every b in R4. If the Null Space were 3-dimensional instead, then Rank=6−3=3, which only forms a 3D subspace inside R4, so Ax=b would not have a solution for every b in R4.
6
For both a 4×4 matrix A and a 5×4 matrix B, the only vector that lands on zero is x=0. Does Ax=b have a solution for every b in R4? Does Bx=b have a solution for every b in R5?
Both matrices have Nullity=0 and 4 starting columns, so all 4 dimensions survive in both cases. Compare that 4D Column Space to R4 for A and to R5 for B.
Because only x=0 is crushed to zero, both matrices have Nullity=0, and since both have 4 columns, both have Rank=4−0=4. For the 4×4 matrix A, the outputs live in R4, so its 4D Column Space fills all of R4. For the 5×4 matrix B, the outputs live in R5, and a 4D Column Space cannot fill 5D space (don't assume that Nullity=0 automatically means every b has a solution; that only works when the matrix is square). Thus Ax=b has a solution for every b in R4, while Bx=b does not have a solution for every b in R5.