Finding a basis for a subspace is a fundamental skill in linear algebra, serving as the bridge between abstract vector spaces and concrete computational methods. Whether you are working with the column space of a matrix, the null space of a linear transformation, or a span of vectors in $\mathbb{R}^n$, the core objective remains the same: identify a minimal set of linearly independent vectors that completely describe the subspace. Mastering this process allows you to determine the dimension of the space, simplify calculations, and understand the structural geometry of linear systems Which is the point..
Understanding the Core Concepts
Before diving into algorithms, Make sure you solidify the definitions. It matters. A subspace $W$ of a vector space $V$ is a subset closed under vector addition and scalar multiplication.
- Linear Independence: No vector in the set can be written as a linear combination of the others. The only solution to $c_1\mathbf{v}_1 + \dots + c_k\mathbf{v}_k = \mathbf{0}$ is the trivial solution where all $c_i = 0$.
- Spanning: Every vector in $W$ can be expressed as a linear combination of the basis vectors. $\text{Span}{\mathbf{v}_1, \dots, \mathbf{v}_k} = W$.
The number of vectors in any basis for $W$ is the dimension of $W$, denoted $\dim(W)$. While a subspace has infinitely many possible bases, they all share the same cardinality.
Scenario 1: Basis for a Span of Vectors (Row Space Method)
Often, a subspace is defined explicitly as the span of a given set of vectors $S = {\mathbf{a}_1, \mathbf{a}_2, \dots, \mathbf{a}_m}$. Worth adding: to find a basis, we must extract a linearly independent subset that still spans the same space. The most systematic approach uses row reduction.
Step-by-Step Procedure
- Construct a Matrix: Place the given vectors as rows of a matrix $A$. $ A = \begin{bmatrix} \mathbf{a}_1 \ \mathbf{a}_2 \ \vdots \ \mathbf{a}_m \end{bmatrix} $ Note: Placing vectors as rows preserves the linear dependence relations among the original vectors during row operations.
- Row Reduce: Compute the Reduced Row Echelon Form (RREF) of $A$, denoted $\text{rref}(A)$. You can stop at Row Echelon Form (REF) if you only need to identify pivot rows, but RREF provides the cleanest basis vectors.
- Identify Non-Zero Rows: The non-zero rows in the resulting echelon form are linearly independent and span the same space as the original rows.
- Form the Basis: The set of these non-zero row vectors constitutes a basis for $\text{Span}(S)$.
Why This Works
Elementary row operations do not change the row space of a matrix. Since the row space of $A$ is exactly $\text{Span}(S)$, the non-zero rows of the echelon form provide a "clean," linearly independent spanning set—precisely a basis The details matter here..
Example: Find a basis for $W = \text{Span}{(1, 2, -1, 3), (2, 4, 1, 6), (0, 0, 3, 0)}$. $ A = \begin{bmatrix} 1 & 2 & -1 & 3 \ 2 & 4 & 1 & 6 \ 0 & 0 & 3 & 0 \end{bmatrix} \xrightarrow{\text{RREF}} \begin{bmatrix} 1 & 2 & 0 & 3 \ 0 & 0 & 1 & 0 \ 0 & 0 & 0 & 0 \end{bmatrix} $ The non-zero rows $(1, 2, 0, 3)$ and $(0, 0, 1, 0)$ form a basis. $\dim(W) = 2$.
Scenario 2: Basis for the Column Space of a Matrix
The column space $\text{Col}(A)$ is the subspace spanned by the column vectors of a matrix $A$. Practically speaking, this is arguably the most common subspace encountered in applied linear algebra (e. g., the range of a linear transformation $T(\mathbf{x}) = A\mathbf{x}$) No workaround needed..
The Pivot Column Theorem
Crucial Rule: You cannot simply take the non-zero rows of $\text{rref}(A)$ as the basis for the column space. Row operations change the column space. On the flip side, they preserve the linear dependence relations among the columns.
Step-by-Step Procedure
- Row Reduce: Compute the RREF (or REF) of matrix $A$.
- Locate Pivot Columns: Identify the columns in the echelon form that contain leading 1s (pivots).
- Select Original Columns: Go back to the original matrix $A$. The columns corresponding to the pivot column positions in the echelon form form a basis for $\text{Col}(A)$.
Example: Let $A = \begin{bmatrix} 1 & 2 & 3 \ 2 & 4 & 5 \ 1 & 2 & 2 \end{bmatrix}$. $ \text{rref}(A) = \begin{bmatrix} 1 & 2 & 0 \ 0 & 0 & 1 \ 0 & 0 & 0 \end{bmatrix} $ Pivot columns are column 1 and column 3. Basis for $\text{Col}(A)$: $\left{ \begin{bmatrix} 1 \ 2 \ 1 \end{bmatrix}, \begin{bmatrix} 3 \ 5 \ 2 \end{bmatrix} \right}$.
Scenario 3: Basis for the Null Space (Kernel)
The null space $\text{Nul}(A)$ is the set of all solutions to the homogeneous equation $A\mathbf{x} = \mathbf{0}$. Finding a basis here involves expressing the solution set in parametric vector form That's the part that actually makes a difference..
Step-by-Step Procedure
- Row Reduce: Compute $\text{rref}(A)$. (RREF is highly preferred here for easy back-substitution).
- Identify Variables: Distinguish pivot variables (basic variables) corresponding to pivot columns, and free variables corresponding to non-pivot columns.
- Express Pivot Variables: Write each pivot variable in terms of the free variables.
- Parametric Vector Form: Write the solution vector $\mathbf{x}$ as a sum of vectors weighted by the free variables. $ \mathbf{x} = s\mathbf{v}_1 + t\mathbf{v}_2 + \dots $
- Extract Basis: The vectors $\mathbf{v}_1, \mathbf{v}_2, \dots$ attached to the free parameters form a basis for $\text{Nul}(A)$.
Example: Find a basis for $\text{Nul}(A)$ where $A = \begin{bmatrix} 1 & 3 & 2 \ 2 & 6 & 4 \end{bmatrix}$. $ \text{rref}(A) = \begin{bmatrix} 1 & 3 & 2 \ 0 & 0 & 0 \end{bmatrix} $ Equation: $x_1 + 3x_2 + 2x_3 = 0 \implies x_1 = -3x_2 - 2x_3$. Free variables: $x_2 = s$, $x