Skip to main content

Linear Algebra: Notes for MATH 341

Section 4.1 Basis and Dimension

In the previous chapter, we saw that if a set \(S\) spans a vector space \(V\text{,}\) then \(S\) is big enough to write everything in \(V\) (as a linear combination of \(S\)). We also saw that a linearly independent set \(S\) had a unique way to represent elements in \(span(S)\text{.}\) A convenient and minimal way to describe a vector space is to give a set of vectors that spans all of \(V\) but does not include anything extra.

Definition 4.1.

A basis for a vector space \(V\) is a set of vectors that is linearly independent and spans \(V\text{.}\)
In this way, a basis is big enough (spans \(V\)) and contains nothing extra (linearly independent).

Question 4.1.

Can a set of 4 vectors be a basis for \(\mathbb{R}^3\text{?}\) Why or why not? Be sure to justify using ideas from Chapter 1 and not any theorems past this point.

Question 4.2.

Can a set of 2 vectors be a basis for \(\mathbb{R}^3\text{?}\) Why or why not?

Proof.

Assume by way of contradiction that \(V\) is a vector space with bases \(S_0 = \{v_1,v_2,\dots,v_n\}\) and \(S'=\{u_1,u_2,\dots,u_m\}\) with \(n\lt m\text{.}\) Since \(u_1\in V\) and \(S_0\) is a basis for \(V\text{,}\) there are scalars \(c_i\) such that \(\displaystyle u_1 = \sum_{i=1}^n c_i v_i\text{.}\) Since \(S'\) is linearly independent, \(u_1\neq \vec{0}\) and at least one \(c_i\neq 0\text{.}\) Without loss of generality, assume that \(c_1\neq 0\text{.}\) Now let \(S_1 = \{u_1,v_2,\dots,v_n\}\text{.}\) We claim that \(S_1\) is a basis for \(V\text{.}\) Notice that we can write
\begin{equation*} v_1 = \frac{1}{c_1}u_1 + \sum_{i=2}^n \frac{-c_i}{c_1}v_i. \end{equation*}
Thus, \(v_1\in span(S_1)\) and so any vector in \(span(S_0)=V\) can be written to demonstrate that it is also in \(span(S_1)\text{.}\) To see that \(S_1\) is linearly independent, suppose that
\begin{equation*} \vec{0} = d_1 u_1 + d_2v_2 + \cdots + d_nv_n \end{equation*}
is a nontrivial linear combination of vectors in \(S_1\) that sums to the zero vector. Notice that if \(d_1=0\text{,}\) then we have a nontrivial linear combination of vectors from \(S_0\) that sums to the zero vector, which contradicts that \(S_0\) is linearly independent. Thus, \(d_1\neq 0\text{.}\) In this case, substitute \(u_1 = \sum_{i=1}^n c_i v_i\) and combine like terms. Since \(c_1\neq 0\neq d_1\text{,}\) we now have a nontrivial linear combination of vectors from \(S_0\) that sums to \(\vec{0}\text{,}\) which contradicts that \(S_0\) is a basis for \(V\text{.}\) We will now show, as with using mathematical induction, that we can continue to move vectors from \(S'\) into our basis. To do so, we assume for some \(i\) such that \(1\leq i\lt n\) that \(S_i=\{u_1,u_2,\dots,u_i,v_{i+1},\dots,v_n\}\) is a basis for \(V\text{.}\) We will show that \(S_{i+1}=\{u_1,u_2,\dots,u_{i+1},v_{i+2},\dots,v_n\}\) is also a basis for \(V\text{.}\) We know that \(u_{i+1}\in span(S_i)\text{,}\) so there are scalars \(f_i\) such that
\begin{equation} u_{i+1}=f_1u_1+f_2u_2+\cdots+f_iu_i+f_{i+1}v_{i+1}+\cdots+f_nv_n\text{.}\tag{4.1} \end{equation}
Notice that this requires some \(f_j\) with \(j\gt i\) be nonzero, as otherwise we would have written \(u_{i+1}\) as a linear combination of elements of \(S'\) (other than \(u_{i+1}\)), which would mean that \(S'\) is not linearly independent. Without loss of generality, assume that \(f_{i+1}\neq 0\text{.}\) Notice that equation (4.1) can be rearranged to show that \(v_{i+1}\in span(S_{i+1})\) as we did with \(v_1\) earlier, so \(S_{i+1}\) spans \(V\text{.}\) To prove that \(S_{i+1}\) is linearly independent, suppose that
\begin{equation*} \vec{0} = a_1u_1 + a_2u_2+\cdots + a_{i+1}u_{i+1}+a_{i+2}v_{i+2}+\cdots a_nv_n \end{equation*}
is a nontrivial linear combination that sums to the zero vector. Notice that \(a_{i+1}\neq 0\) or else we have demonstrated that \(S_i\) is linearly dependent. However, we now have
\begin{equation*} u_{i+1} = \frac{-a_1}{a_{i+1}}u_1 +\cdots + \frac{-a_i}{a_{i+1}}u_i + \frac{-a_{i+2}}{a_{i+1}}v_{i+2}+\cdots + \frac{-a_n}{a_{i+1}}v_n\text{.} \end{equation*}
Notice that \(v_{i+1}\) is not present in this sum, but otherwise this is a linear combination of elements of \(S_i\text{.}\) Since (4.1) has a nonzero coefficient on \(v_{i+1}\text{,}\) this is a different linear combination summing to \(u_{i+1}\text{.}\) Thus, \(S_i\) is not linearly independent, which is a contradiction.
Thus, we can produce a sequence \(S_0,S_1,S_2,\dots,S_n\) of bases for \(V\text{.}\) Notice that \(S_n=\{u_1,u_2,\dots,u_n\}\) and that \(u_m\) is not in this set as \(m\gt n\text{.}\) However, since \(S_n\) is a basis, we can write \(u_m\) as a linear combination of elements of \(S_n\text{.}\) Thus, there are two ways to write \(u_m\) as a linear combination of elements of \(S'\text{,}\) contradicting that \(S'\) is linearly independent.
The previous theorem does not imply that there is only one basis for a vector space, just that any two bases for the same vector space will have the exact same number of vectors. The idea that every basis for a vector space \(V\) has the same number of vectors gives rise to the idea of dimension.

Definition 4.3.

If a vector space \(V\) has a basis with a finite number of elements, \(n\text{,}\) then we say that \(V\) has dimension \(n\) or that \(V\) is \(n\)-dimensional, also written as \(\dim(V)=n\text{.}\)

Question 4.3.

Show that \(\{ \vec{e}_1, ... ,\vec{e}_n \}\) is a basis for \(\mathbb{R}^n\) and thus that \(\mathbb{R}^n\) is an \(n\)-dimensional vector space.

Question 4.4.

Give a set of 3 different vectors in \(\mathbb{R}^3\) that are not a basis for \(\mathbb{R}^3\text{.}\) Be sure to show why the set does not satisfy the definition of a basis.

Question 4.5.

Give a basis for \(\mathbb{P}_3\) and compute the dimension of \(\mathbb{P}_3\text{.}\)

Question 4.6.

What is \(\dim(\mathbb{P}_n)\text{?}\) Be sure to justify.

Question 4.7.

Recall that the set \(\{\vec{0} \}\) is the trivial vector space. What is a basis for \(\{\vec{0} \}\text{?}\) What is \(\dim(\{\vec{0} \})\text{?}\)
This is an enormously helpful theorem since we know that a linearly independent set of \(n\) vectors from a \(n\)-dimensional vector space is a basis (no need to show spanning). This goes the other way as well, namely if a set of \(n\) vectors, \(S\text{,}\) spans a \(n\)-dimensional vector space, \(V\text{,}\) then \(S\) is a basis for \(V\) (no need to show linear independence).

Question 4.8.

Prove that \(\{ 1+t,t+t^2,1+t^2 \}\) is a basis for \(\mathbb{P}_2\text{.}\)

Question 4.9.

Give two different bases for \(M_{2 \times 2}\text{.}\)

Question 4.10.

What is the dimension of \(Sym_{3 \times 3}\text{,}\) the vector space of symmetric 3 by 3 matrices?

Question 4.11.

What is the dimension of \(Sym_{n \times n}\text{?}\)

Question 4.12.

What is the dimension of \(\mathbb{P}\text{?}\)

Question 4.13.

(a)

Prove that \(H=\{ \colvec{t\\t\\0} \mid t \in \mathbb{R} \} \) is a subspace of \(\mathbb{R}^3\text{.}\)

(b)

Is \(Span(\{ \colvec{1\\0\\0} , \colvec{0\\1\\0} \}) =H\text{?}\)

(c)

What dimension is \(H\text{?}\)

Rank and nullity.

Recall that if \(T: V \rightarrow W\) is linear, then \(Null(T)\) and \(\mathrm{im}(T)\) are subspaces of \(V\) and \(W\) respectively.

Definition 4.5.

The rank of a transformation \(T\) is \(\dim(\mathrm{im}(T))\) and the nullity of \(T\) is \(\dim(Null(T))\text{.}\)

Question 4.14.

Let \(A=\begin{bmatrix} 1\amp 2\amp 3 \\4\amp 5\amp 6 \end{bmatrix}\text{.}\)
(a)
Find \(rank(T)\) and \(nullity(T)\) where \(T(\vec{x}) =A \vec{x}\text{.}\)
(b)
Find a basis for \(Null(T)\text{.}\)
(c)
Find a basis for \(\mathrm{im}(T)\text{.}\)

Exercise 4.6.

Let \(T\) from \(\mathbb{R}^2\) to \(\mathbb{P}_2\) be given by \(T \left( \colvec{a\\ b} \right) = a +(a+b)t+(a-b)t^2\text{.}\)
(a)
\(rank(T)=\)
Solution.
We already worked out what the image of \(T\) was in an earlier problem and found that
\begin{equation*} \mathrm{im}(T) = \{\frac{\beta+\gamma}{2} + \beta t + \gamma t^2\colon \beta,\gamma\in\mathbb{R}\}\text{.} \end{equation*}
Notice that we can rewrite the polynomials in the image to have the form \(\beta + \gamma + 2\beta t + 2\beta t^2\text{,}\) and grouping based on the scalar, we have
\begin{equation*} \beta(1+2t) + \gamma(1+2t^2)\text{.} \end{equation*}
Thus, every vector in the image is a linear combination of \(1+2t\) and \(1+2t^2\text{.}\) I will leave it to you to verify that these vectors are linearly independent, but this shows that the rank of \(T\) is 2. (Since we have found a basis, this also answers the last part of this question.
(b)
\(nullity(T)=\)
Solution.
Notice that to be sent to the zero polynomial, a vector in the domain must have \(a=0\) to get the constant term to be zero. But then this forces \(b=0\text{.}\) Thus, \(nullity(T)=0\) as the null space is the trivial vector space.
(c)
Find a basis for \(Null(T)\text{.}\)
Solution.
Since the null space is trivial, the basis is the empty set.
(d)
Find a basis for \(\mathrm{im}(T)\text{.}\)

Question 4.15.

Let \(T:\mathbb{P}_3 \rightarrow \mathbb{R}^2\) be given by \(T(f)=\colvec{f(0)\\ f(1)}\text{.}\) Compute \(rank(T)\) and \(nullity(T)\text{.}\)
If \(T\) is a matrix transformation (\(T(\vec{x})=A\vec{x}\)), then
\begin{align*} rank(T)\amp= rank(A)=dim(Col(A))\\ \end{align*}

and

\begin{align*} nullity\amp (T)=nullity(A)=dim(Null(A))\text{.} \end{align*}

Question 4.16.

Using previous work, prove the Dimension Theorem for \(T: \mathbb{R}^n \rightarrow \mathbb{R}^m\) given by \(T(\vec{x})=A\vec{x}\text{,}\) where \(A\) is a \(m\) by \(n\) matrix.

Exercise 4.8.

List out all possible echelon forms of 3 by 3 matrices using the symbols \(\blacksquare\) for pivot, \(*\) for non-pivot entry (possibly \(0\)), and \(0\) if an entry must be \(0\text{.}\) For each form, give the rank of the matrix and the dimension of the null space.

Coordinate vectors relative to a basis.

Given an ordered basis \(\beta =\{ \vec{v}_1, ...,\vec{v}_k \}\) of a vector space \(V\text{,}\) the coordinate vector of \(\vec{x}\) relative to \(\beta\), denoted \([\vec{x}]_\beta\text{,}\) is a vector of the coefficients of the unique way to write \(\vec{x}\) as a linear combination of \(\beta\text{.}\) Namely, if \(\vec{x} = c_1 \vec{v_1}+c_2 \vec{v_2} +...+c_k \vec{v_k}\text{,}\) then \([\vec{x}]_\beta = \colvec{c_1\\ c_2\\ \vdots\\ c_k}\text{.}\)

Question 4.17.

For each of the following vectors, compute \([\vec{v}]_{\beta}\) where \(\beta =\{ \colvec{0\\ 0\\ 1}, \colvec{0\\ 1\\ 1},\colvec{1\\ 1\\ 1} \}\)
(a)
\(\vec{v}=\colvec{2\\ 2\\ 2}\)
(b)
\(\vec{v}=\colvec{3\\ 0\\ 0}\)
(c)
\(\vec{v}=\colvec{-1\\ -1\\ 0}\)
(d)
\(\vec{v}=\colvec{-2\\ 0\\ 3}\)
(e)
\(\vec{v}=\colvec{a\\ b\\ c}\)

Question 4.18.

In the previous problem, you wrote out the coordinate vectors relative to \(\beta =\{ \colvec{0\\ 0\\ 1}, \colvec{0\\ 1\\ 1},\colvec{1\\ 1\\ 1} \}\text{.}\) Note that the first three vectors you used form a basis as well, which we will call \(\gamma =\{ \colvec{2\\ 2\\ 2}, \colvec{3\\ 0\\ 0},\colvec{-1\\ -1\\ 0} \}\text{.}\)
(a)
Compute \([\vec{v}]_{\gamma}\) for \(v=\colvec{-2\\ 0\\ 3}\text{.}\)
(b)
The coordinate vectors of \(\gamma\) relative to \(\beta\) can be used to make the change of basis matrix from \(\gamma\) to \(\beta\text{.}\) Specifically, the change of basis matrix from \(\gamma\) to \(\beta\) is given by \([ [\vec{\gamma_1}]_\beta [\vec{\gamma_2}]_\beta [\vec{\gamma_3}]_\beta ] \text{.}\) Use your work from the previous question, to construct the change of basis matrix from \(\gamma\) to \(\beta\text{.}\)
(c)
Multiplying by this change of basis matrix will convert a coordinate vector relative to \(\gamma\) to a coordinate vector relative to \(\beta\text{.}\) Verify that if you multiply your change of basis matrix from \(\gamma\) to \(\beta\) by \([\vec{v}]_{\gamma}\) you get \([\vec{v}]_{\beta}\) where \(v=\colvec{-2\\ 0\\ 3}\text{.}\)
The above process of constructing a change of basis matrix works for any two bases of the same vector space (even if the vector space is not \(\mathbb{R}^n\)).

Exercise 4.9.

For each of the following vectors, compute \([\vec{v}]_{\beta}\) where \(\beta =\{ 1+t,t+t^2,1+t^2 \}\text{.}\)
(a)
\(\vec{v}=2+2t\)
Solution.
\([\vec{v}]_\beta = \colvec{2\\ 0 \\ 0}\)
(b)
\(\vec{v}=4-t^2+t\)
Solution.
\([\vec{v}]_\beta = \colvec{3\\ -2 \\ 1}\)
(c)
\(\vec{v}=3\)
Solution.
\([\vec{v}]_\beta = \colvec{3/2\\ -3/2 \\ 3/2}\)
(d)
\(\vec{v}=t\)
Solution.
\([\vec{v}]_\beta = \colvec{1/2\\ 1/2 \\ -1/2}\)
(e)
\(\vec{v}=6t^2\)
Solution.
\([\vec{v}]_\beta = \colvec{-3\\ 3\\ 3}\)
The coordinate vector allows us to state problems in a vector space like \(\mathbb{P}_n\) in the same way we state problems in \(\mathbb{R}^n\text{.}\)

Exercise 4.10.

For each of the following vectors, compute \([\vec{v}]_{\beta}\) where
\begin{equation*} \beta =\{ \begin{bmatrix} 1\amp 2\\3\amp 4 \end{bmatrix}, \begin{bmatrix} 1\amp 0\\0\amp 1 \end{bmatrix}, \begin{bmatrix} 0\amp 1\\1\amp 0 \end{bmatrix}, \begin{bmatrix} 1\amp 0\\0\amp 0 \end{bmatrix} \}\text{.} \end{equation*}
(a)
\(\vec{v}=\begin{bmatrix} 1\amp 1\\1\amp 1 \end{bmatrix}\)
Solution.
\([\vec{v}]_\beta = \colvec{0\\ 1\\ 1\\ 0}\)
(b)
\(\vec{v}=\begin{bmatrix} 1\amp 0\\1\amp 1 \end{bmatrix}\)
Solution.
\([\vec{v}]_\beta = \colvec{1\\ -3\\ -2\\ 3}\)