Column space, null space and rank

The question
Can you move one column of a 3×3 matrix so that every output lies in a plane?
Then find the input directions the map cannot distinguish.
- 1 SeeMove a column into a plane.
- 2 TryTest what the map can distinguish.
- 3 ProveAccount for every input direction.
- 4 ApplySolve five problems.
Before you start · 3 quick checks on column combinations, zero vectors and composition
Two ideas before you start
2 ideasOutputs are combinations of columns
A dashed vector changes as you choose the input below.
Scale each column by the corresponding input coordinate, then add. The collection of all possible outputs is the column space.
Exact definition
For a real \(m\times n\) matrix \(A\) with columns \(a_1,\ldots,a_n\), the column space is
\[\operatorname{Col}(A)=\{Ax:x\in\mathbb R^n\}.\]Equivalently, it is the span of the columns: all real linear combinations \(x_1a_1+\cdots+x_na_n\). It lies in the output space \(\mathbb R^m\). This extends the column picture in a matrix as a map to rectangular matrices.
Some inputs may disappear
Choose an input to compare it with its output under a horizontal projection.
The null space collects inputs whose output is zero. A nonzero input can belong to it.
Exact definition
The null space, also called the kernel, is
\[\operatorname{Null}(A)=\{x\in\mathbb R^n:Ax=0\}.\]It lies in the input space \(\mathbb R^n\). The zero on the right is the output zero vector in \(\mathbb R^m\). The input zero always belongs to the null space because a linear map sends zero to zero. A null space containing only zero has dimension zero; it is not an empty set.
Refresher: independence, basis and dimension
A subspace contains zero and is closed under vector addition and multiplication by real scalars. Both spaces above meet these conditions by linearity. A line or plane through the origin is a subspace. A line or plane that misses the origin is not, because it does not contain zero.
Vectors are linearly independent if a combination equal to zero forces every coefficient to be zero. Otherwise, at least one vector is redundant in their span. A basis is an independent list that spans the space. The dimension is the number of vectors in any basis. A finite spanning list can be reduced to a basis by discarding redundant vectors; all bases of the same finite-dimensional space have the same length.
The rank of \(A\) is the dimension of its column space. The nullity is the dimension of its null space. These count independent directions, not points: even a line contains infinitely many points. The empty list is a basis of the subspace containing only zero. Throughout this lesson, vectors written as tuples still represent columns, and all input coefficients may be any real numbers.
Make the output fit in a plane
- Drag the tip of the dashed column vertically, use its arrow keys, or move the height slider.
- Make the image of the cube lie entirely in the shaded plane. Check your position to explain what happened.
The first two columns stay fixed. Only the last entry of the third column changes. The controls use exact quarter steps, so reaching the plane is an exact condition.
What this perspective drawing can show
The wireframe is the image of inputs in the unit cube, not the entire column space. A linear subspace continues without a boundary. The shaded patch is also only a finite piece of a plane. This oblique view preserves straight lines and incidence, but lengths and angles on the screen are not three-dimensional lengths and angles.
The input and output pictures use separate coordinate spaces. A line in the input picture may collapse to one point in the output picture. Do not identify vectors from the two pictures simply because both have three coordinates.
What can the output distinguish?
Decide what happens in the nearby case below before opening its calculation. Treat the stated decimal as exact, rather than as a rounded measurement.
In numerical work, deciding whether a measured matrix is effectively lower rank requires a scale and a tolerance. That question is different from the exact rank used here. A small determinant by itself is not a dimension count. For square matrices, the determinant detects whether the columns are dependent, but zero does not tell you how many independent columns remain.
Use what you found: keep the output fixed
- Move the parameter to meet each coordinate goal. The page checks the whole input and its output.
A particular solution is one input that works. Adding any null vector leaves its output unchanged. Conversely, if two inputs give the same output, their difference lies in the null space. Thus a nonempty solution set is a shifted copy of the null space. It need not pass through the origin.
The equation \(Ax=b\) has a solution exactly when \(b\) belongs to the column space. Once a solution exists, the null space tells you its ambiguity. A target outside the column space has no solution, even if there are many null vectors. These are separate questions: reachability and distinguishability.
Account for all input directions
Let \(A\) be a real \(m\times n\) matrix with positive integers \(m,n\). Write \(r=\operatorname{rank}(A)\). Then
\[r+\dim\operatorname{Null}(A)=n.\]The total is the input dimension, the number of columns. Rank cannot exceed either the number of rows or the number of columns. No invertibility, square shape, or nonzero entry is assumed.
First consider \(r\lt n\). Select column indices \(p_1,\ldots,p_r\) whose columns form a basis of the column space. For each unselected index \(j\), write \(a_j=\sum_i c_{ij}a_{p_i}\). The coefficients exist because the selected columns span. Let \(e_j\) be the input vector with a single unit coordinate at position \(j\).
Define \(v_j=e_j-\sum_i c_{ij}e_{p_i}\). The sum runs over the selected columns; if the rank is zero, it is an empty sum. Build the argument below, including this edge case.
What if \(r=n\)? Then every column is selected, so the columns are independent. The equation \(Ax=0\) forces every coefficient in the column combination to vanish. The null space contains only zero, and the same dimension formula holds. At the other extreme, rank zero means all columns are zero, so every input belongs to the null space.
Notice what was counted. Each unselected column supplied one null vector, with a one at its own unselected coordinate and zeros at the other unselected coordinates. Those coordinates make the vectors independent even when several columns are equal or zero. The proof does not count nonzero columns or rely on a picture.
The same linearity underlies matrix multiplication as composition. If a first map loses an input difference, a later linear map cannot recover it: applying the later map to a zero difference still gives zero. Rank measures available output directions, not the size of matrix entries.
Find the directions and the ambiguity
Each problem has hints and a worked solution. Enter one number. Dimension questions require an exact integer; the calibration problem states its numerical tolerance.
Further reading
- G. Strang, Introduction to Linear Algebra, chapter 3, “Vector Spaces and Subspaces.”
- S. Axler, Linear Algebra Done Right, chapter 3, “Linear Maps.”