Understanding the column space calculator — concept and principle
This calculator finds a basis and the dimension of the column space of a matrix, using its pivot columns. It also shows the reduced row echelon form, the pivot positions, a basis of the row space and whether the columns span all of ℝᵐ. Use it for linear algebra homework on span, rank and the solvability of Ax = b.
How it is calculated
- Row-reduce A to reduced row echelon form (RREF).
- Note the columns that contain a pivot (leading 1).
- The pivot columns of the original matrix A form a basis of Col(A).
- Dimension of Col(A) = number of pivots = rank of A.
- The non-zero rows of the RREF form a basis of Row(A), which has the same dimension.
- Pivots are found with a small relative tolerance, so decimal inputs with rounding noise are handled sensibly.
The principle
The column space is the set of all combinations of the columns of A, which is exactly the set of vectors b for which Ax = b has a solution. Row operations change the columns, so the RREF's columns are not a basis of Col(A); but they keep the linear relations between columns. A non-pivot column in the RREF is a combination of earlier pivot columns, and the same combination holds in A. So the original pivot columns span everything and are independent. Row operations do not change the row space, which is why the RREF rows can be used for Row(A).
Worked example
Default input: A = [1 2 0 −1; −2 −3 4 5; 2 4 0 −2].
- RREF of A = [1 0 −8 −7; 0 1 4 3; 0 0 0 0].
- Pivot columns: 1, 2.
- Basis of Col(A): columns 1 and 2 of A, (1, −2, 2) and (2, −3, 4).
- Dimension of Col(A) = rank = 2.
- Basis of Row(A): (1, 0, −8, −7) and (0, 1, 4, 3). Col(A) does not fill ℝ³: no — it is a 2-dimensional subspace of ℝ³.
How to read the result
If the rank equals the number of rows m, every b in ℝᵐ is reachable. Here the rank is 2, so Col(A) is a plane through the origin in ℝ³, and Ax = b has solutions only for b in that plane. The RREF also shows the dependencies: column 3 = −8 × column 1 + 4 × column 2, which you can check in A.
Common mistakes
- Taking the pivot columns of the RREF instead of the original matrix.
- Confusing the column space (in ℝᵐ) with the row space (in ℝⁿ).
- Counting non-zero entries instead of pivots for the rank.
- Making an arithmetic slip during row reduction; check a dependency in the original matrix.
Frequently asked questions
What is the column space of a matrix?
The set of all linear combinations of its columns, a subspace of ℝᵐ.
Why use the original columns, not the RREF columns?
Row operations change the columns but keep their linear relations, so only the original pivot columns lie in Col(A).
Is the dimension of the column space the rank?
Yes, and it equals the dimension of the row space.
Sources: D. Margalit & J. Rabinoff, Interactive Linear Algebra, §2.7 Basis and Dimension