The structure underlying vectors, polynomials, matrices, and functions — a unified language for collections of objects that can be added and scaled
This chapter introduces one of the most powerful organizing ideas in all of mathematics: the concept of a vector space. Until now, you have worked primarily with vectors as arrows in two or three dimensions, or as lists of numbers with specific geometric meaning. You have solved systems, multiplied matrices, studied determinants, and analyzed linear transformations. In every case, the objects you worked with could be added together and scaled by constants. That observation turns out to be the foundation of something much larger.
A vector space is any collection of objects that can be added together and scaled — as long as those operations follow a consistent set of rules. The elements of a vector space do not have to be arrows. They can be polynomials, matrices, lists of numbers in four or more dimensions, sequences, or many other kinds of mathematical objects. What makes them a vector space is not what they look like, but how they behave.
This chapter builds your understanding of vector spaces from the ground up. You will start with the familiar space ℝⁿ, examine the rules that define all vector spaces, explore a range of examples, learn to identify subspaces, and begin connecting vector spaces to the matrices and systems you have already studied.
The ideas introduced here — vector spaces, subspaces, span, independence, basis, and dimension — form the structural core of linear algebra. Everything in the chapters that follow depends on them.
You already know that lines through the origin in ℝ² have a special property: if you take any two points on the line and add them, you stay on the line. If you scale any point on the line by any number, you stay on the line. The line is "closed" under the operations that define vectors.
But a line that does not pass through the origin does not have this property. Add two points on it, and you may leave the line entirely. What is it about passing through the origin that matters so much? And can this idea of a "closed collection" be generalized beyond lines and planes — to collections of polynomials, matrices, or systems of equations? That is exactly what vector spaces answer.
In Chapters 1 through 7, you worked primarily with specific vectors and specific matrices. You solved for particular solutions, computed determinants, and analyzed individual transformations. These are powerful skills. But linear algebra becomes much more powerful when you ask structural questions about whole collections of vectors, not just individual ones.
Questions like these arise naturally once you push beyond simple computation:
| Question | What It Asks |
|---|---|
| What is the set of all solutions to a homogeneous system? | A structural question about all solutions at once, not just one. |
| What is the set of all vectors a matrix can produce as output? | A question about the range of a transformation. |
| Can every vector in a space be described using a small set of vectors? | A question about spanning and efficient description. |
| How many independent directions does a space have? | A question about dimension. |
These questions are answered using the language of vector spaces, subspaces, span, independence, and dimension. Once you know that a collection of objects forms a vector space, every theorem about vector spaces applies to it automatically. You do not have to re-derive ideas about span, independence, and dimension for polynomials, or matrices, or signals. The abstract definition does the work for you.
This chapter will not push you too far into abstraction. The examples will stay concrete, and the connections to geometry and computation will remain clear throughout. But you will begin to see why linear algebra is not just about arrows — it is about structure.
In Chapter 2, a vector was introduced as an arrow with direction and magnitude, or as a list of components. Now consider a different kind of object: a polynomial.
Let p(x) = 3x² − x + 5 and q(x) = x² + 2x − 1. You can add these:
p(x) + q(x) = (3+1)x² + (−1+2)x + (5−1) = 4x² + x + 4
You can also scale p(x) by any real number c:
c · p(x) = 3cx² − cx + 5c
This looks different from adding arrows, but notice the similarity: you are combining objects according to consistent rules, and the result stays in the same family — sums and scalar multiples of polynomials are again polynomials. Now consider a 2 × 2 matrix. Adding two such matrices entry-by-entry gives another 2 × 2 matrix; scaling one by a constant gives another 2 × 2 matrix.
The pattern is the same across arrows, polynomials, and matrices: objects that can be added and scaled, with results that stay in the same family. The key insight is that the structure of addition and scalar multiplication is what matters, not what the objects look like. A vector space is any collection of objects that has this structure, provided a precise list of rules is satisfied.
Arrows, polynomials, and matrices all support addition and scalar multiplication with consistent behavior. Once you recognize this pattern, you can apply the same reasoning — span, independence, basis, dimension — to all of them. That is why the abstract definition of a vector space is so useful.
The central and most important example of a vector space is ℝⁿ — the set of all column vectors with n real number entries. Everything in this book has lived primarily inside ℝ² or ℝ³ so far, but the ideas generalize to any n. In ℝ⁴ vectors have four components; in ℝ¹⁰⁰ they have one hundred components. You cannot draw these spaces, but you can work with them algebraically.
Vector addition. For u = (u₁, u₂, …, uₙ)ᵀ and v = (v₁, v₂, …, vₙ)ᵀ:
u + v = (u₁+v₁, u₂+v₂, …, uₙ+vₙ)ᵀ
Scalar multiplication. For any scalar c ∈ ℝ:
cv = (cv₁, cv₂, …, cvₙ)ᵀ
Zero vector. The vector 0 = (0, 0, …, 0)ᵀ satisfies v + 0 = v for all v.
Additive inverse. For each v, the vector −v = (−v₁, −v₂, …, −vₙ)ᵀ satisfies v + (−v) = 0.
ℝⁿ is the foundation for all the vector spaces you will study. When you encounter a new fact about abstract vector spaces, always check your understanding in ℝⁿ first. Component-wise arithmetic makes the axioms concrete and easy to verify there.
A vector space V is a set of objects — called vectors — together with two operations: addition and scalar multiplication. These operations must satisfy the following ten axioms for all vectors u, v, w ∈ V and all scalars c, d ∈ ℝ.
Closure Properties
u + v ∈ V. Adding two vectors gives a vector still in the set.cv ∈ V. Scaling a vector by any real number gives a vector still in the set.Addition Properties
u + v = v + u.(u + v) + w = u + (v + w).v + 0 = v for all v.v + (−v) = 0.Scalar Multiplication Properties
c(u + v) = cu + cv.(c + d)v = cv + dv.c(dv) = (cd)v.1 · v = v.The axioms ensure consistency. Without the zero vector axiom, there would be no neutral element for addition. Without commutativity, the order of addition would change the result. Without the distributive laws, algebra involving sums and scalars could fail. All ten axioms together create a structure where all familiar algebraic manipulations remain valid. In a vector space, the word "vector" refers to any element of the set, no matter what that element actually looks like.
The following examples all satisfy the ten vector space axioms. Working through them will help you develop a feel for what a vector space is.
Closure under addition:
u + v = (u₁+v₁, u₂+v₂)ᵀ ∈ ℝ² ✓
Closure under scalar multiplication:
cv = (cv₁, cv₂)ᵀ ∈ ℝ² ✓
Commutativity:
u + v = (u₁+v₁, u₂+v₂)ᵀ = (v₁+u₁, v₂+u₂)ᵀ = v + u ✓
Zero vector: 0 = (0, 0)ᵀ; v + 0 = (v₁+0, v₂+0)ᵀ = v ✓
Additive inverse: −v = (−v₁, −v₂)ᵀ; v + (−v) = (0, 0)ᵀ = 0 ✓
(All remaining axioms follow by applying real number
arithmetic component-wise.)
Zero matrix: 0 = [0 0 0; 0 0 0] (a 2×3 matrix of all zeros) ✓
Additive inverse of A: −A, with all entries negated ✓
All other axioms: inherited entry-wise from ℝ ✓
Sum: (a₀ + a₁x + a₂x²) + (b₀ + b₁x + b₂x²)
= (a₀+b₀) + (a₁+b₁)x + (a₂+b₂)x² ∈ 𝒫₂ ✓
Scale: c(a₀ + a₁x + a₂x²) = ca₀ + ca₁x + ca₂x² ∈ 𝒫₂ ✓
Zero polynomial: 0 + 0x + 0x² ✓
Additive inverse: −a₀ − a₁x − a₂x² ✓
Understanding what a vector space is not is just as important as knowing what it is. The most common failure is a violation of one of the two closure conditions: the set fails to be closed under addition or scalar multiplication.
Let v = (1, 2)ᵀ ∈ W.
(−1)v = (−1, −2)ᵀ
Both entries are negative, so (−1, −2)ᵀ ∉ W.
Closure under scalar multiplication fails. ✗
Zero vector: (0, 0)ᵀ has first entry 0 ≠ 1, so 0 ∉ S. ✗
Axiom 5 fails immediately.
Addition test: (1, 2)ᵀ + (1, 3)ᵀ = (2, 5)ᵀ
First entry is 2, not 1, so the sum ∉ S. ✗
If a set does not contain the zero vector, it is automatically not a vector space. This is a fast first check. Always verify the zero vector before testing closure.
u = (1, 0)ᵀ ∈ Q (1² + 0² = 1 ✓)
v = (0, 1)ᵀ ∈ Q (0² + 1² = 1 ✓)
u + v = (1, 1)ᵀ: check 1² + 1² = 2 ≠ 1 ✗
2u = (2, 0)ᵀ: check 4 + 0 = 4 ≠ 1 ✗
p(x) = x² + 3x + 1 (degree 2 ✓)
q(x) = −x² + 2x − 5 (degree 2 ✓)
p(x) + q(x) = 5x − 4 (degree 1, not 2) ✗
Now that you know what a vector space is, you can ask: which subsets of a vector space are themselves vector spaces?
A subspace of a vector space V is a subset H ⊆ V that is itself a vector space under the same operations as V.
A subset H is a subspace of V if and only if it satisfies all three of:
(closed under addition)(closed under scalar multiplication)If these three conditions hold, all ten vector space axioms are automatically satisfied — the arithmetic properties are inherited from V itself. You only need to check three conditions, not ten.
| Space | Subspaces | Geometric Description |
|---|---|---|
| ℝ² | {0} | The origin alone (trivial subspace). |
| ℝ² | Any line through the origin | A line through the origin — not shifted away from it. |
| ℝ² | All of ℝ² | The entire plane. |
| ℝ³ | {0} | The origin alone. |
| ℝ³ | Any line through the origin | A line passing through (0,0,0). |
| ℝ³ | Any plane through the origin | A plane passing through (0,0,0). |
| ℝ³ | All of ℝ³ | All of three-dimensional space. |
This is the key geometric fact about subspaces. Any subspace must contain the zero vector. A line, plane, or higher-dimensional flat that does not pass through the origin is never a subspace — no matter how "linear" it looks.
The three-part subspace test is the standard method for determining whether a subset is a subspace. The process is always the same:
Step 1. Show that 0 ∈ H, or find a counterexample showing 0 ∉ H (which immediately disqualifies H).
Step 2. Take two arbitrary elements of H and verify their sum is in H.
Step 3. Take an arbitrary element of H and an arbitrary scalar, and verify their product is in H.
In steps 2 and 3, you must work with general elements satisfying the defining condition of H, not specific numerical examples. A single counterexample is enough to disprove a subspace; a general argument is required to prove one.
Step 1 — Zero vector:
2(0) − 3(0) = 0 ✓ → 0 ∈ H
Step 2 — Closure under addition:
Let u = (x₁, y₁)ᵀ ∈ H and v = (x₂, y₂)ᵀ ∈ H.
So 2x₁ − 3y₁ = 0 and 2x₂ − 3y₂ = 0.
Check u + v = (x₁+x₂, y₁+y₂)ᵀ:
2(x₁+x₂) − 3(y₁+y₂)
= (2x₁ − 3y₁) + (2x₂ − 3y₂)
= 0 + 0 = 0 ✓
Step 3 — Closure under scalar multiplication:
Let v = (x, y)ᵀ ∈ H, so 2x − 3y = 0. Let c ∈ ℝ.
Check cv = (cx, cy)ᵀ:
2(cx) − 3(cy) = c(2x − 3y) = c · 0 = 0 ✓
u = (1, 1)ᵀ: 1² = 1 ✓
v = (2, 4)ᵀ: 2² = 4 ✓
u + v = (3, 5)ᵀ: 3² = 9 ≠ 5 ✗
Closure under addition fails.
Step 1: 0 + 0 − 0 = 0 ✓ → 0 ∈ H
Step 2: u = (x₁,y₁,z₁)ᵀ and v = (x₂,y₂,z₂)ᵀ both in H.
(x₁+x₂) + (y₁+y₂) − (z₁+z₂)
= (x₁+y₁−z₁) + (x₂+y₂−z₂)
= 0 + 0 = 0 ✓
Step 3: cv = (cx, cy, cz)ᵀ:
cx + cy − cz = c(x + y − z) = c(0) = 0 ✓
Step 1: Zero polynomial = 0x + 0x² ∈ H ✓
Step 2: (a₁x + b₁x²) + (a₂x + b₂x²)
= (a₁+a₂)x + (b₁+b₂)x² ∈ H ✓
Step 3: c(ax + bx²) = cax + cbx² ∈ H ✓
One of the most important sources of subspaces comes directly from solving systems of equations. A homogeneous system is one of the form Ax = 0, where the right-hand side is the zero vector. In Chapter 3, you learned that such systems always have at least the trivial solution x = 0. Now we can say exactly what the full solution set is.
The solution set of a homogeneous system Ax = 0 is a subspace of ℝⁿ.
Proof sketch. Let H = {x ∈ ℝⁿ : Ax = 0}. Apply the three-part test:
Condition 1. A0 = 0, so 0 ∈ H. ✓
Condition 2. If Au = 0 and Av = 0, then A(u + v) = Au + Av = 0 + 0 = 0, so u + v ∈ H. ✓
Condition 3. If Av = 0 and c ∈ ℝ, then A(cv) = c(Av) = c0 = 0, so cv ∈ H. ✓
The solution set of a nonhomogeneous system Ax = b (with b ≠ 0) is generally not a subspace, because the zero vector is typically not a solution. For example, x + y = 5 has no solution with x = 0 and y = 0 simultaneously.
[ 1 2 −1 | 0 ] R₂ − 3R₁ [ 1 2 −1 | 0 ]
[ 3 6 −3 | 0 ] ──────────→ [ 0 0 0 | 0 ]
Pivot: column 1. Free variables: x₂ = s, x₃ = t.
From row 1: x₁ = −2s + t.
Solution:
x = s(−2, 1, 0)ᵀ + t(1, 0, 1)ᵀ
When you multiply a matrix A by a vector x, the result Ax is a linear combination of the columns of A. This observation motivates one of the most important subspaces associated with a matrix.
The column space of a matrix A, written Col(A), is the set of all vectors that can be expressed as Ax for some vector x. Equivalently, it is the set of all linear combinations of the columns of A.
If A is an m × n matrix with columns a₁, a₂, …, aₙ, then:
Col(A) = {c₁a₁ + c₂a₂ + ··· + cₙaₙ : c₁, …, cₙ ∈ ℝ}
Col(A) is a subspace of ℝᵐ — it lives in the output space.
The system Ax = b is consistent if and only if b ∈ Col(A).
c₁(1, 0, 2)ᵀ + c₂(0, 1, 3)ᵀ = (c₁, c₂, 2c₁+3c₂)ᵀ
So Col(A) = {(x, y, z)ᵀ ∈ ℝ³ : z = 2x + 3y}
The null space of a matrix A, written Nul(A), is the set of all vectors x satisfying Ax = 0:
Nul(A) = {x ∈ ℝⁿ : Ax = 0}
Nul(A) is a subspace of ℝⁿ — it lives in the input space.
Col(A) and Nul(A) are two of the four fundamental subspaces associated with a matrix, which will be developed fully in Chapter 10.
If Nul(A) = {0} (only the trivial solution), then every column of A contributes independent information and the transformation T(x) = Ax is one-to-one. If Nul(A) contains nonzero vectors, then multiple inputs produce the same output — some information is collapsed.
[ 2 4 | 0 ] R₁↔R₂ [ 1 2 | 0 ] R₂−2R₁ [ 1 2 | 0 ]
[ 1 2 | 0 ] ───────→ [ 2 4 | 0 ] ────────→ [ 0 0 | 0 ]
x₂ = t is free; x₁ = −2t.
Nul(A) = {t(−2, 1)ᵀ : t ∈ ℝ}
The null space of A lives in ℝⁿ (the input space — where x lives). The column space of A lives in ℝᵐ (the output space — where Ax lives). For an m × n matrix, these two spaces have different dimensions and live in completely different places. Do not confuse them.
The abstraction of vector spaces is not merely theoretical. It appears throughout computing, data science, and applied science.
In data modeling, polynomials of degree at most d form the vector space 𝒫d. Fitting a polynomial to data means finding a vector in this space that best matches the observed data. The idea of "best fit" — least squares — will be formalized in Chapter 11 using projections onto subspaces.
In engineering and signal processing, a discrete signal of length n is a vector in ℝⁿ. The space of all such signals is a vector space. Signal decomposition — separating a signal into frequency components — is a linear algebra operation that finds a specific basis for this space.
In data science, a dataset of n observations with p features is stored as an n × p matrix. Each row is a vector in ℝᵖ (one observation); each column is a vector in ℝⁿ (one feature across all observations). Operations like projecting onto subspaces, finding null spaces, and computing rank all have concrete interpretations about what the data contains and where it repeats information redundantly.
When you fit a linear model to data, the model produces predictions and the differences between predictions and actual values (residuals) form a vector in ℝⁿ. The set of all possible residuals associated with a given model forms a subspace. Minimizing errors geometrically corresponds to projecting the data vector onto the column space of a matrix — a topic you will study in Chapter 11.
The zero vector is necessary but not sufficient. You must also verify closure under addition and under scalar multiplication. Many sets contain the zero vector but fail one of the closure conditions.
To prove a subspace, you must prove the conditions hold for all elements — a general argument, not specific cases. To disprove a subspace, one counterexample is enough. Testing specific cases can only disprove.
These are two separate conditions. A set can fail closure under scalar multiplication while satisfying closure under addition, or vice versa. Check both independently for every candidate subspace.
In an abstract vector space, "vector" refers to any element of the set, regardless of what it looks like. If the set and its operations satisfy the ten axioms, the elements are vectors in the sense of linear algebra. Polynomials, matrices, and sequences can all be vectors.
In ℝ², a non-trivial proper subspace is a line (one equation). But in ℝⁿ, subspaces can have any dimension from 0 to n. In ℝ⁴, a two-dimensional subspace requires two independent linear equations. Subspaces can also be described as the span of a set of vectors, or as the null space of a matrix.
The null space Nul(A) lives in ℝⁿ (the input space — where x lives). The column space Col(A) lives in ℝᵐ (the output space — where Ax lives). For an m × n matrix, these are in completely different spaces. Confusing them leads to errors throughout Chapters 9–14.
Only the solution set of the homogeneous system Ax = 0 is guaranteed to be a subspace. If b ≠ 0, the zero vector is typically not a solution, so the solution set fails the first subspace condition immediately.
This chapter introduced vector spaces and subspaces as collections with consistent structure. You learned to verify the ten vector space axioms, apply the three-part subspace test, and identify important subspaces such as the solution set of a homogeneous system, the column space, and the null space.
The next question is natural: if you have a vector space or subspace, can you describe it efficiently? Rather than listing every vector in the space — impossible for an infinite set — you want to find a small set of vectors that "generates" the whole space. That is the idea of span and linear independence, which Chapter 9 will develop in full.
| Concept | Preview | First Glimpse in Chapter 8 |
|---|---|---|
| Span | The set of all linear combinations of given vectors; what those vectors can "reach." | Col(A) = span of the columns of A. |
| Linear independence | A set of vectors with no redundancy — none can be written as a combination of the others. | When one column of A is a multiple of another, the null space is nontrivial. |
| Basis | A spanning set that is also independent — the most efficient description of a space. | The null space in Example 8.9.1 was spanned by two independent vectors. |
| Dimension | The number of vectors in any basis; how many independent directions a space has. | The null space in Example 8.9.1 was two-dimensional (two free variables). |
Chapter 9 will ask: what is the most efficient way to describe a subspace? You will learn that a span describes every vector a set can produce, linear independence means no vector in a set is redundant, a basis is a spanning set with no redundancy, and dimension counts the independent directions. The null space of Example 8.9.1 — expressed as all combinations of two specific vectors — was already pointing to these ideas. Chapter 9 will give them their full definitions and power.
In calculus, Taylor polynomials express a function as a sum of power terms: 1 + x + x² + x³ + ···. Each power term is a "basis element" for the space of power series. In differential equations, the solution set of a linear equation forms a vector space, and its basis elements are the fundamental solutions. The foundation you build here — vector spaces, subspaces, span, independence, basis, dimension — carries directly into these later subjects. What you are learning is not just linear algebra; it is the structural language of modern mathematics.
For each set, apply the three-part subspace test. If it is not a subspace, identify which condition fails.
For each set, state whether it is a vector space under standard operations, give your reasoning, and name the zero vector if it is a vector space.
For each matrix A, find Nul(A) by solving Ax = 0. Express as a set of scalar multiples or combinations of specific vectors.
For each matrix A, describe Col(A) — what space it lives in and what subspace it is (a line, a plane, all of the space, etc.).
Each problem shows a student's work. Find the error and explain how to correct it.
Find the actual error. Produce a concrete counterexample to show that the closed unit disk fails at least one subspace condition.
What is wrong with this reasoning? State all three conditions and explain why the zero vector alone is not sufficient.
Find the error. Compute Col(A) correctly and describe it geometrically.
What has the student confused? State the correct spaces for each, and explain why the dimensions matter.