Find the rank of a matrix by row-reducing it to row echelon form (REF) and counting pivot columns. The number of free variables equals the number of columns minus the rank.

Example

Reduce and count pivot rows.

highlighted = computed this step

Step 1 — Set up reduction

Set up the augmented matrix for row reduction.

R=[121243364]R=\left[\begin{array}{cc|c}1&2&1\\2&4&3\\3&6&4\end{array}\right]

Step 2 — Update row 2

Row-reduce with R2 <- R2 - 2*R1.

R=[121001364]R=\left[\begin{array}{cc|c}1&2&1\\\hl{0}&\hl{0}&\hl{1}\\3&6&4\end{array}\right]

Step 3 — Update row 3

Row-reduce with R3 <- R3 - 3*R1.

R=[121001001]R=\left[\begin{array}{cc|c}1&2&1\\0&0&1\\\hl{0}&\hl{0}&\hl{1}\end{array}\right]

Step 4 — Update row 3

Row-reduce with R3 <- R3 - 1*R2.

R=[121001000]R=\left[\begin{array}{cc|c}1&2&1\\0&0&1\\\hl{0}&\hl{0}&\hl{0}\end{array}\right]

Step 5 — State verdict

rank = 2 (two pivot columns).

rank=2\operatorname{rank}=\hl{2}
rank The rank of a matrix is the number of pivot columns in its REF. It equals the dimension of the column space. The nullity (number of free variables) satisfies rank + nullity = number of columns.