# finding bases for row space and null space of matrix.

My problem is:

For the matrix

$$A = \begin{bmatrix} 1& 4& 5& 6& 9\\ 3& −2& 1& 4& −1\\ −1& 0& −1& −2& −1\\ 2& 3& 5& 7& 8\end{bmatrix}$$

(a) Find a basis for the row space of A.

(b) Find a basis for the null space of A.

(c) Find the rank and nullity of A.

I tried searching online and I became more confused, take the example here.

http://www2.kenyon.edu/Depts/Math/Paquin/PracticeExam1Solns.pdf

As you can see for the column space he takes the columns of the original matrix instead of the rref of A, which I don't understand.

• He uses the columns of the original matrix because elementary row operations change the column space. The column space of ref(A) is not the same as the column space of A (the two spaces are however isometric). Doing elementary row operations do not change the row space. ROw space of the row echelon form of A is the same as the row space of A because elementary row operations are linear combinations of the rows. – Brad S. Mar 21 '14 at 2:11
• Your title is nonsensical. A linear operator is a function, a basis is a set of vectors. Apples and oranges. – Andrés E. Caicedo Mar 21 '14 at 3:10
• sorry Andres you can suggest a better title if you like. – user3424493 Mar 21 '14 at 3:13
• "Finding bases for row space and null space of matrix." – Andrés E. Caicedo Mar 21 '14 at 3:17

We'll begin by simplifying the matrix using elementary row operations. $$\begin{eqnarray*}A = \begin{bmatrix} 1& 4& 5& 6& 9\\ 3& −2& 1& 4& −1\\ −1& 0& −1& −2& −1\\ 2& 3& 5& 7& 8\end{bmatrix}&\xrightarrow{R_4+2R_3}&\begin{bmatrix} 1& 4& 5& 6& 9\\ 3& −2& 1& 4& −1\\ −1& 0& −1& −2& −1\\ 0& 3& 3& 3& 6\end{bmatrix}\\ &\xrightarrow{R_3+\frac{1}{3}R_2}&\begin{bmatrix} 1& 4& 5& 6& 9\\ 3& −2& 1& 4& −1\\ 0& -\frac{2}{3}& -\frac{2}{3}& -\frac{2}{3}& -\frac{4}{3}\\ 0& 3& 3& 3& 6\end{bmatrix}\\ &\xrightarrow{R_2-3R_1}&\begin{bmatrix} 1& 4& 5& 6& 9\\ 0& −14& -14& -14& −28\\ 0& -\frac{2}{3}& -\frac{2}{3}& -\frac{2}{3}& -\frac{4}{3}\\ 0& 3& 3& 3& 6\end{bmatrix}\\ &\xrightarrow{\substack{-(1/14)R_2\\-(3/2)R_3\\(1/3)R_4}}&\begin{bmatrix} 1& 4& 5& 6& 9\\ 0& 1& 1& 1& 2\\ 0& 1& 1& 1& 2\\ 0& 1& 1& 1& 2\end{bmatrix}\\ &\xrightarrow{\substack{R_4-R_3\\R_3-R_2 \\R_1-3R_2}}&\begin{bmatrix} 1& 0& 1& 2& 1\\ 0& 1& 1& 1& 2\\ 0& 0& 0& 0& 0\\ 0& 0& 0& 0& 0\end{bmatrix} \end{eqnarray*}$$ We see that the row space of $A$ is spanned by $(1,0,1,2,1)$ and $(0,1,1,1,2)$, which means that the rank of $A$ is $2$. From this, we know by the Rank-Nullity theorem that the nullity will be $3$, since there are $5$ columns in the matrix - but let's verify that anyway by finding a basis of the null space. We have the following reduced system of equations. $$\begin{eqnarray*} x+z+2s+t&=&0\\ y+z+s+2t&=&0\\ &\downarrow&\\ x&=&-z-2s-t\\ y&=&-z-s-2t\end{eqnarray*}$$ which we can rewrite in vector form as $$\begin{bmatrix} x \\ y \\ z \\ s \\ t \\ \end{bmatrix}=\begin{bmatrix} -z-2s-t \\ -z-s-2t \\ z \\ s \\ t \\ \end{bmatrix}= z\begin{bmatrix}-1\\-1\\1 \\0 \\0 \\\end{bmatrix}+ s\begin{bmatrix}-2\\-1\\0 \\1 \\0 \\\end{bmatrix}+ t\begin{bmatrix}-1\\-2\\0 \\0 \\1 \\\end{bmatrix}$$ So a basis of the null space is $(-1,-1,1,0,0)$, $(-2,-1,0,1,0)$, and $(-1,-2,0,0,1)$.
• +1 Nice answer but, I think the last vector in the basis for the null space should be $\begin{pmatrix} -1& -2 & 0& 0 & 1\end{pmatrix}^T$ – Brad S. Mar 21 '14 at 2:37
• @user3424493 Do you know how to transpose matrices? Do exactly what I did to find the row space, but for $A^\intercal$. Let me know what you get. – splinal tap Mar 21 '14 at 3:02
• @user3424493, the columns of the original matrix which correspond to the pivot columns in the row echelon form of $A$ form a basis for the column space. In this case, columns 1 and 2 of the original matrix form a basis for the column space. There is no need to row reduce $A^T$ – Brad S. Mar 21 '14 at 3:04
The row space is the span of the rows of $A$. (or the column space of $A^{T}$). $$A^{T} = \begin{bmatrix} 1 & 3 & -1 & 2\\ 4 & -2 & 0 & 3 \\ 5 & 1 & -1 & 5 \\ 6 & 4 & -2 & 7\\ 9 & -1 & -1 & 8 \end{bmatrix} \vec{x} = \begin{bmatrix} 1\\ 4 \\ 5 \\ 6 \\ 9\end{bmatrix}x_1 + \begin{bmatrix} 3\\ -2 \\ 1 \\ 4 \\ -1\end{bmatrix}x_2 + \begin{bmatrix} -1\\ 0 \\ -1 \\ -2 \\ -1\end{bmatrix}x_3 + \begin{bmatrix} 2\\ 3 \\ 5 \\ 7 \\ 8\end{bmatrix}x_4$$ So find a maximally linear independent subset $R$ of: $$\left\{\begin{bmatrix} 1\\ 4 \\ 5 \\ 6 \\ 9\end{bmatrix} , \begin{bmatrix} 3\\ -2 \\ 1 \\ 4 \\ -1\end{bmatrix} , \begin{bmatrix} -1\\ 0 \\ -1 \\ -2 \\ -1\end{bmatrix} , \begin{bmatrix} 2\\ 3 \\ 5 \\ 7 \\ 8\end{bmatrix} \right\}$$ Now the null space is the set: $$\{\vec{x}: A\vec{x} = \vec{0} \}$$
$$A = \begin{bmatrix} 1& 4& 5& 6& 9\\ 3& −2& 1& 4& −1\\ −1& 0& −1& −2& −1\\ 2& 3& 5& 7& 8\end{bmatrix}\vec{x} = \vec{0} \longrightarrow \; ?$$ So you must find a maximally linear independent subset $S$ of $$\{\vec{x}: A\vec{x} = \vec{0} \}$$ Now once you find these two things,
$$\text{rank}(A) = |R|, \; \; \text{nullity}(A)= |S|$$