# Verifying the row-rank and column-rank of a matrix are equal by finding bases for each

My question concerns the following exercise: My thought process is as follows:

• Reducing a matrix to row-reduced echelon form renders it to its basis vectors.

• If I row reduce the row space, which is just taking this matrix and reducing it to row-reduced echelon form, I'll have the bases.

• If I take the columns as rows and do the same as the above, I'll have bases for the column space.

• For both subspaces of $\mathbb R$ to have the same rank, they must have the same number of basis vectors.

Okay, so I first row reduced the row-space. Here is the matrix:

$$\begin{pmatrix} 1 & 0 & 0 & 1 \\ 0 & 1 & 0 & -2 \\ 0 & 0 & 1 & -1 \\ \end{pmatrix}$$

From here, I postulated that the basis is (I'm not sure whether it's this or $4$ column vectors, because I'm not sure if I take row or column vectors for my bases from this matrix, but intuition says row vectors since this is a row space):

$$B_1:={(1,0,0,1),(0,1,0,-2),(0,0,1,-1)}$$

Then, the column space (which I got just by basically rotating the row-space matrix clockwise 90 degrees):

$$\begin{pmatrix} 1 & 1 & 1 \\ 0 & 0 & 1 \\ 0 & 1 & -1 \\ 1 & 0 & 0 \\ \end{pmatrix}$$

Reduces to $I_3$.

So, if I say that the basis for this column-space is:

$$B_2:={(1,0,0), (0,1,0), (0,0,1)}$$

Then, $B_1$ and $B_2$ have the same number of basis vectors, so $dim B_1 = dim B_2$? The thing is though, $B_1$ contains vectors in $\mathbb R^4$ while $B_2$ contains vectors in $\mathbb R^3$. Have I got this mucked up? Because this lack of agreement of dimensions bother me. I reckon my way of determining dimension is wrong or my way of taking the basis vectors from the reduced matrix is wrong.

• Just a quick comment on the notation, a basis is a set of vectors that generate some space, so it would be a good idea to write the elements of the set in brackets: $B_1 = \{(1,0,0,1),(0,1,0,-2),(0,0,1,-1) \}$, and the same for $B_2$. Nov 9 '17 at 0:35

That's correct, the dimension of the column space should be equal to the dimension of the row space. More clearly, if $A$ is an $m \times n$ matrix, then

$$Rank(A) = \dim(RS(A)) = \dim(CS(A))$$

where $RS(A)$ and $CS(A)$ denote the row and column space of $A$, respectively. So, when you reduce a matrix to echelon form, then the number of pivots must equal $Rank(A)$. What you have done is found a basis , $B_1$, for the row space of $A$ and a basis, $B_2$, for the column space of $A$. Then you have noticed that indeed, $B_1$ and $B_2$ each have 3 linearly independent vectors, to which we can conclude

$$\dim(RS(A)) = \dim(CS(A)) = 3.$$

Now, since this is a $3 \times 4$ matrix, clearly each row vector should be in $\mathbb{R}^4$, and each column vector in $\mathbb{R}^3$. So no, there is not a lack of agreement in the dimensions, you are actually correct. If you had an $n \times n$ matrix, then the rows and the column vectors would both be in $\mathbb{R}^n$, however in your example the matrix isn't square.

Perhaps easier for this particular question, if not a general method:

The first row of the matrix is not a scalar multiple of the second, so the first two rows are linear independent. The third row is not a linear combination of the first two, because of the fourth coordinate, so the matrix’s three rows are linear independent and therefore a basis of the row space. The dimension of the column space must be 3 (same as the dimension of the row space), so any three linearly independent column vectors in the column space form a basis. The rightmost three columns of the matrix are fairly clearly linearly independent and therefore make a basis for the column space.