Null Space, Column Space, and Rank–Nullity
Null space
Null(A) = {x ∈ Rⁿ : Ax = 0}Its dimension is the number of free variables: nullity(A) = n − rank(A).
Column space
Col(A) = span{pivot columns of original A}Its dimension is rank(A). Each column-space vector has one coordinate per matrix row.
Rank–nullity theorem
dim Col(A) + dim Null(A) = nFor an m × n matrix, the dimensions add to n, the number of columns.
How to Find the Null Space and Column Space
- Select the row and column counts for
A, then enter every value or paste a rectangular matrix. - Keep the standard tolerance for typical decimal data, or change it when the scale and precision of your data require another pivot threshold.
- Select Find null and column spaces.
- Use the free columns to interpret the null-space basis. Use the pivot positions to select the basis columns from the original matrix.
Worked 3×4 Example
For the default matrix, RREF has pivots in columns 1 and 3, so columns 2 and 4 are free.
Matrix
A = [[1,2,1,0], [2,4,0,2], [3,6,1,2]]Null-space basis
{(−2,1,0,0), (−1,0,1,1)}Column-space basis
{(1,2,3), (1,0,1)}The two null-space vectors correspond to the two free variables. The column-space basis uses original columns 1 and 3—not columns from RREF.
How to Interpret the Results
Null(A) lives in Rⁿ, so every null-space basis vector has n entries. If there are no free columns, the null space contains only the zero vector and its basis is empty.
Col(A) lives in Rᵐ, so every column-space basis vector has m entries. Row operations locate the pivot positions, but because row operations can change the column space, the basis must use those columns from the original matrix.
Null Space and Column Space FAQs
How do you find a basis for the null space?
Row-reduce A, identify the free variables in Ax = 0, and set one free variable at a time to 1 while all other free variables are 0. The resulting solution vectors form a basis.
How do you find a basis for the column space?
Find the pivot-column positions in RREF, then take the columns at those positions from the original matrix. Those original columns are independent and span Col(A).
Why does a null-space vector have one entry per column?
An m × n matrix multiplies vectors from Rⁿ. Therefore every input vector, including every vector in Null(A), has n coordinates.
Can the null space contain only the zero vector?
Yes. If every column is a pivot column, there are no free variables. Then Ax = 0 has only x = 0, nullity is 0, and the null-space basis is empty.
Can this calculator handle rectangular matrices?
Yes. It accepts real matrices from 1×1 through 8×8. Wide matrices necessarily have at least as many free variables as columns minus rows, while tall matrices can have full column rank.
Why can changing tolerance change the bases?
For floating-point decimal data, a tiny pivot can represent information or numerical noise. The tolerance controls when the calculator treats that pivot as zero, which can change rank, free variables, and both reported bases.
Are my matrix entries private?
Yes. Calculation, copying, and download creation happen locally. The calculator code does not transmit or store matrix entries.
Calculation Notes
Last reviewed: August 5, 2026 by the Starlight Tools editorial team.
The verification reports the largest absolute entry of Av across the displayed null-space basis vectors. All displayed spaces follow the numerical pivot decisions made at the selected tolerance.
