A subspace is a subset of a vector space that is itself a vector space under the same operations. Lines and planes through the origin in R³, null spaces and column spaces of matrices, and solution sets of homogeneous systems are all subspaces. A simple two-condition test determines whether a given subset qualifies.
Definition
A subspace of a vector space V is a nonempty subset W⊆V that is itself a vector space when equipped with the same addition and scalar multiplication as V.
Most of the ten axioms — commutativity, associativity, distributivity, the identity 1v=v — hold automatically in W because they hold for all vectors in V, and vectors in W are vectors in V. The properties that can fail are the closure conditions: the sum of two vectors in W might land outside W, or scaling a vector in W might produce something not in W. These are the only things that need checking.
The Subspace Test
A nonempty subset W⊆V is a subspace if and only if it satisfies two conditions:
Closure under addition: for all u,v∈W, the sum u+v is in W.
Closure under scalar multiplication: for all c∈R and all v∈W, the product cv is in W.
These two conditions can be compressed into one: W is a subspace if and only if cu+dv∈W for all u,v∈W and all scalars c,d. This single condition captures both closure properties simultaneously.
The requirement that W be nonempty is essential. Once at least one vector v is known to lie in W, closure under scalar multiplication with c=0 guarantees 0=0v∈W. So the zero vector belongs to every subspace. Conversely, if 0∈/W, then W cannot be a subspace — this is often the fastest way to disqualify a candidate.
Trivial Subspaces
Every vector space V has two subspaces that require no verification. The set {0} containing only the zero vector is a subspace: adding 0 to itself gives 0, and scaling 0 by any scalar gives 0, so both closure conditions hold. This is the smallest possible subspace, with dimension zero.
The entire space V is also a subspace of itself — trivially, since every vector in V is in V and every operation on V stays in V. This is the largest possible subspace.
Every other subspace lies strictly between these two extremes: it contains 0 but does not contain everything. Finding and classifying these intermediate subspaces is one of the central tasks of linear algebra.
Subspaces of R² and R³
The subspaces of R2 are completely classified: {0}, lines through the origin, and R2 itself. There is nothing else. Every line through the origin has the form {tv:t∈R} for some nonzero vector v, and it is straightforward to verify that this set is closed under addition and scalar multiplication.
The subspaces of R3 are: {0}, lines through the origin (dimension 1), planes through the origin (dimension 2), and R3 itself (dimension 3).
A line that does not pass through the origin — say the set {(1,0)+t(2,3):t∈R} — is not a subspace. It does not contain 0, and adding two vectors on this line produces a vector that is generally not on the line. Similarly, a plane that does not contain the origin fails the subspace test.
The geometric intuition is that subspaces are the "flat" subsets that pass through the origin. In Rn, every subspace is a span of some set of vectors, and its dimension equals the number of independent vectors needed to span it.
the set of all vectors that A maps to the zero vector. This is a subspace of Rn.
Verification is direct. The zero vector satisfies A0=0, so 0∈Null(A). If Au=0 and Av=0, then A(u+v)=Au+Av=0+0=0, so u+v∈Null(A). If Av=0, then A(cv)=cAv=c0=0, so cv∈Null(A). Both closure conditions hold.
The dimension of the null space is the nullity. By the rank-nullity theorem, rank(A)+nullity(A)=n. When A has full column rank (rank=n), the null space is {0} and the map x↦Ax is injective. When the rank is less than n, the null space is nontrivial and the map collapses some directions to zero.
The Column Space
For an m×n matrix A with columns a1,…,an, the column space is
Col(A)={Ax:x∈Rn}=Span{a1,a2,…,an}
It is the set of all possible outputs of the linear transformationx↦Ax, and it lives in Rm.
The column space is a subspace because the span of any set of vectors is always a subspace. Its dimension equals the rank of A.
The column space answers the solvability question: the system Ax=b has a solution if and only if b lies in Col(A). If b is a linear combination of the columns of A, the coefficients in that combination are a solution vector x. If b is not in the column space, no solution exists.
To find a basis for the column space, row reduce A and identify the pivot columns. The corresponding columns of the original matrix A — not the echelon form — form a basis for Col(A).
The Row Space
The row space of an m×n matrix A is the span of the rows of A, viewed as vectors in Rn. Equivalently, it is the column space of AT:
Row(A)=Col(AT)
The row space lives in Rn and has dimension equal to the rank of A — the same dimension as the column space, despite the two spaces living in different ambient spaces.
A key property is that elementary row operations do not change the row space. Each row operation replaces rows with linear combinations of existing rows, so every row of the echelon form lies in the span of the original rows, and vice versa. The nonzero rows of the echelon form therefore provide a basis for the row space.
The row space and the null space together account for all of Rn. They are orthogonal complements: every vector in the null space is perpendicular to every row of A (since Ax=0 means the dot product of x with each row is zero), and their dimensions add up to n.
Subspaces from Operations
New subspaces can be built from existing ones through set-theoretic operations, though not all operations preserve the subspace property.
The intersection of two subspaces W1 and W2 is always a subspace. If u and v both lie in W1∩W2, then u+v lies in W1 (since W1 is a subspace) and in W2 (since W2 is a subspace), so it lies in W1∩W2. The same argument works for scalar multiples. The intersection can be anything from {0} (if the two subspaces share only the zero vector) to one of the original subspaces (if one contains the other).
The union of two subspaces is almost never a subspace. If u∈W1∖W2 and v∈W2∖W1, the sum u+v typically lies in neither W1 nor W2, violating closure. The only exception is when one subspace contains the other.
The sum W1+W2={w1+w2:w1∈W1,w2∈W2} is always a subspace — it is the smallest subspace containing both W1 and W2. Its dimension satisfies
dim(W1+W2)=dim(W1)+dim(W2)−dim(W1∩W2)
When W1∩W2={0}, the sum is called a direct sum, written W1⊕W2, and every vector in the sum has a unique decomposition as w1+w2.
Solution Sets and Subspaces
The solution set of a linear systemAx=b is a subspace only when b=0. In that case, the solution set is the null space of A, which passes the subspace test as shown above.
When b=0, the solution set is not a subspace. It does not contain 0 (since A0=0=b), and it is not closed under addition or scalar multiplication in general. However, the solution set has a clean geometric description in terms of subspaces.
If xp is any one particular solution to Ax=b, then every solution has the form
x=xp+xh
where xh∈Null(A) is a solution to the homogeneous system Ax=0. The full solution set is a translated copy of the null space — shifted away from the origin by the vector xp. In geometry, this is an affine subspace (also called a coset or a flat): a subspace that has been displaced from the origin.
This decomposition separates the particular and homogeneous contributions. The particular solution xp accounts for the right-hand side b, while the null-space component xh parametrizes the freedom in the solution. When the null space is trivial (Null(A)={0}), the solution is unique: x=xp with no freedom.