8.3 Rank of a Matrix

INTRODUCTION

In a general m × n matrix,

,

the rows

u1 = (a11 a12 . . . a1n), u2 = (a21 a22 . . . a2n), . . . , um = (am1 am2 . . . amn)

and columns

are called the row vectors of A and the column vectors of A, respectively.

A Definition

As vectors, the set u1, u2, . . . , um is either linearly independent or linearly dependent. We have the following definition.

DEFINITION 8.3.1 Rank of a Matrix

The rank of an m × n matrix A, denoted by rank(A), is the maximum number of linearly independent row vectors in A.

EXAMPLE 1 Rank of a 3 × 4 Matrix

Find the rank of the 3 × 4 matrix

(1)

SOLUTION

With u1 = (1 1 −1 3), u2 = (2 −2 6 8), and u3 = (3 5 −7 8), we see that 4u1u2u3 = 0. In view of Definition 7.6.3 and the discussion following it, we conclude that the set u1, u2, u3 is linearly dependent. On the other hand, since neither u1 nor u2 is a constant multiple of the other, the set of row vectors u1, u2 is linearly independent. Hence by Definition 8.3.1, rank(A) = 2.

Row Space

In the terminology of the preceding chapter, the row vectors u1, u2, u3 of the matrix (1) are a set of vectors in the vector space R4. Since RA = Span(u1, u2, u3) (the set of all linear combinations of the vectors u1, u2, u3) is a subspace of R4, we are justified in calling RA the row space of the matrix A. Now the set of vectors u1, u2 is linearly independent and also spans RA; in other words, the set u1, u2 is a basis for RA. The dimension (the number of vectors in a basis) of the row space RA is 2, which is rank(A).

See pages 359 and 360 in Section 7.6.

Rank by Row Reduction

Example 1 notwithstanding, it is generally not easy to determine the rank of a matrix by inspection. Although there are several mechanical ways of finding rank(A), we examine one way that uses the elementary row operations introduced in the preceding section. Specifically, the rank of A can be found by row reducing A to a row-echelon matrix B. To understand this, first recall that an m × n matrix B is row equivalent to an m × n matrix A if the rows of B were obtained from the rows of A by applying elementary row operations. If we simply interchange two rows in A to obtain B, then the row space RA of A and the row space RB of B are equal because the row vectors of A and B are the same. When the row vectors of B are linear combinations of the rows of A, it follows that the row vectors of B are in the row space RA, and so RB is a subset of RA (written RBRA). Conversely, A is row equivalent to B, since we can obtain A by applying row operations to B. Hence the rows of A are linear combinations of the rows of B, and so it follows that RA is a subset of RB (RARB). From RBRA and RARB, we conclude that RA = RB. Finally, if we row-reduce A into a row-echelon matrix B, then the nonzero rows of B are linearly independent. (Why?) The nonzero rows of B form a basis for the row space RA, and so we have the result that rank(A) = dimension of RA.

We summarize these conclusions in the next theorem.

THEOREM 8.3.1 Rank of a Matrix by Row Reduction

If a matrix A is row equivalent to a row-echelon form B, then

(i) the row space of A = the row space of B,

(ii) the nonzero rows of B form a basis for the row space of A, and

(iii) rank(A) = the number of nonzero rows in B.

EXAMPLE 2 Rank by Row Reduction—Example 1 Revisited

We row-reduce a matrix A to a row-echelon form B in exactly the same manner as we row-reduced the augmented matrix of a system of linear equations to an echelon form when we solved the system using Gaussian elimination. Using the matrix (1) in Example 1, elementary row operations give

Since the last matrix is in row-echelon form, and since the last matrix has two nonzero rows, we conclude from (iii) of Theorem 8.3.1 that rank(A) = 2.

EXAMPLE 3 Linear Independence/Dependence

Determine whether the set of vectors u1 = 〈2, 1, 1〉, u2 = 〈0, 3, 0〉, u3 = 〈3, 1, 2〉, in R3 is linearly dependent or linearly independent.

SOLUTION

It should be clear from the discussion above that if we form a matrix A with the given vectors as rows, and if we row-reduce A to a row-echelon form B with rank 3, then the set of vectors is linearly independent. If rank(A) < 3, then the set of vectors is linearly dependent. In this case, it is easy to carry the row reduction all the way to a reduced row-echelon form:

Thus rank(A) = 3 and the set of vectors u1, u2, u3 is linearly independent.

As mentioned previously, the vectors in the row-echelon form of a matrix A can serve as a basis for the row space of the matrix A. In Example 3, we see that a basis for the row space of A is the standard basis 〈1, 0, 0〉, 〈0, 1, 0〉, 〈0, 0, 1〉 of R3.

Rank and Linear Systems

The concept of rank can be related back to solvability of linear systems of algebraic equations. Suppose AX = B is a linear system and that (A|B) denotes the augmented matrix of the system. In Example 7 of Section 8.2, we saw that the system

was inconsistent. The inconsistency of the system is seen in the fact that, after row reduction of the augmented matrix (A|B),

(2)

the last row of the reduced row-echelon form is nonzero. Of course, this reduction shows that rank(A|B) = 3. But note, too, that the result in (2) indicates that rank(A) = 2 because

We have illustrated a special case of the next theorem.

THEOREM 8.3.2 Consistency of AX = B

A linear system of equations AX = B is consistent if and only if the rank of the coefficient matrix A is the same as the rank of the augmented matrix of the system (A|B).

In Example 6 of Section 8.2, we saw that the system

(3)

was consistent and had an infinite number of solutions. We solved for two of the variables, x1 and x2, in terms of the remaining variable x3, which we relabeled as a parameter t. The number of parameters in a solution of a system is related to the rank of the coefficient matrix A.

THEOREM 8.3.3 Number of Parameters in a Solution

Suppose a linear system AX = B with m equations and n variables is consistent. If the coefficient matrix A has rank r, then the solution of the system contains nr parameters.

For the system (3), we can see from the row reduction

that rank(A) = rank(A|B) = 2, and so the system is consistent by Theorem 8.3.2. With n = 3, we see from Theorem 8.3.3 the number of parameters in the solution is 3 − 2 = 1.

FIGURE 8.3.1 outlines the connection between the concept of rank of a matrix and the solution of a linear system.

Two flow diagrams. The first flow diagram has 3 levels and is as follows. Level 1, A X equals to 0. Level 2, always consistent. Level 3 has two components. Component 1, unique solution: X equals to 0, rank (A) equals to n. Component 2, infinity of solutions: rank (A) less than n, n minus r arbitrary parameters in solution. The second diagram has 3 levels and is as follows. Level 1, A X = B, B not equal to 0. Level 2 has 2 components. Component 1, consistent: rank (A) = rank (A divided by B). Component 2, inconsistent: rank (A) less than rank (A divided by B). Component 1 of level 2 branches out to level 3 which has 2 components. Component 1 of level 3, unique solution: rank (A) equals to n. Component 2 of level 3, infinity of solutions: rank (A) less than n, n minus r arbitrary parameters in solution.

FIGURE 8.3.1 For m linear equations in n variables AX = B. Two cases: B = 0, B0. Let rank(A) = r.

REMARKS

We have not mentioned the connection between the columns of a matrix A and the rank of A. It turns out that the maximum number of independent columns that a matrix A can have must equal the maximum number of independent rows. In the terminology of vector spaces, the row space RA of matrix A has the same dimension as its column space CA. For example, if we take the transpose of the matrix in (1) and reduce it to a row-echelon form

we see that the maximum number of rows of AT is 2, and so the maximum number of linearly independent columns of A is 2.

8.3 Exercises Answers to selected odd-numbered problems begin on page ANS-18.

In Problems 1–10, use (iii) of Theorem 8.3.1 to find the rank of the given matrix.

In Problems 11–14, determine whether the given set of vectors is linearly dependent or linearly independent.

  1. u1 = 〈1, 2, 3〉, u2 = 〈1, 0, 1〉, u3 = 〈1, −1, 5〉
  2. u1 = 〈2, 6, 3〉, u2 = 〈1, −1, 4〉, u3 = 〈3, 2, 1〉, u4 = 〈2, 5, 4〉
  3. u1 = 〈1, −1, 3, −1〉, u2 = 〈1, −1, 4, 2〉, u3 = 〈1, −1, 5, 7〉
  4. u1 = 〈2, 1, 1, 5〉, u2 = 〈2, 2, 1, 1〉, u3 = 〈3, −1, 6, 1〉, u4 = 〈1, 1, 1, −1〉
  5. Suppose the system AX = B is consistent and A is a 5 × 8 matrix and rank(A) = 3. How many parameters does the solution of the system have?
  6. Let A be a nonzero 4 × 6 matrix.
    1. What is the maximum rank that A can have?
    2. If rank(A|B) = 2, then for what value(s) of rank(A) is the system AX = B, B0, inconsistent? Consistent?
    3. If rank(A) = 3, then how many parameters does the solution of the system AX = 0 have?
  7. Let v1, v2, and v3 be the first, second, and third column vectors, respectively, of the matrix

    What can we conclude about rank(A) from the observation 2v1 + 3v2v3 = 0? [Hint: Read the Remarks at the end of this section.]

Discussion Problems

  1. Suppose the system AX = B is consistent and A is a 6 × 3 matrix. Suppose the maximum number of linearly independent rows in A is 3. Discuss: Is the solution of the system unique?
  2. Suppose we wish to determine whether the set of column vectors

    is linearly dependent or linearly independent. By Definition 7.6.3, if

    c1v1 + c2v2 + c3v3 + c4v4 + c5v5 = 0 (4)

    only for c1 = 0, c2 = 0, c3 = 0, c4 = 0, c5 = 0, then the set of vectors is linearly independent; otherwise the set is linearly dependent. But (4) is equivalent to the linear system

    Without doing any further work, explain why we can now conclude that the set of vectors is linearly dependent.

Computer Lab Assignment

  1. A CAS can be used to row-reduce a matrix to a row-echelon form. Use a CAS to determine the ranks of the augmented matrix (A|B) and the coefficient matrix A for

    Is the system consistent or inconsistent? If consistent, solve the system.