Femtobytes
Problem type

Reduced row echelon form of a matrix

What it solves
Reduce any matrix of up to four rows and six columns to reduced row echelon form, with every row operation worked entry by entry, and read off its rank, pivot columns and free columns.
Subject
Linear Algebra
Topic
Row reduction and systems
Also called
Gaussian elimination, rref, reduced row echelon, echelon form, row reduce
Your problem

Reduce this matrix to reduced row echelon form.

[2452−5−525−5−420]\left[ \begin{array}{rrrr} 2 & 4 & 5 & 2 \\ -5 & -5 & 2 & 5 \\ -5 & -4 & 2 & 0 \end{array} \right]
The matrix
Rows3
Columns4
Whole numbers or fractions. Up to 4 rows and 6 columns.
Invent a new one:
The problem

Reduce this matrix to reduced row echelon form.

[2452−5−525−5−420]\left[ \begin{array}{rrrr} 2 & 4 & 5 & 2 \\ -5 & -5 & 2 & 5 \\ -5 & -4 & 2 & 0 \end{array} \right]
The result
[2452−5−525−5−420]  ∼  [10014429010−50017029]\left[ \begin{array}{rrrr} 2 & 4 & 5 & 2 \\ -5 & -5 & 2 & 5 \\ -5 & -4 & 2 & 0 \end{array} \right] \;\sim\; \left[ \begin{array}{rrrr} 1 & 0 & 0 & \frac{144}{29} \\ 0 & 1 & 0 & -5 \\ 0 & 0 & 1 & \frac{70}{29} \end{array} \right]

The rank is 33. The sign ∼\sim means "can be turned into, by row operations".

checked 52 lines of this solution were evaluated with exact arithmetic before it was shown to you. A solution with a false line is never served.
Picture 1 of 2Step 1: Say what the target looks like, and which moves are allowed
The matrix we start from
22445522−5-5−5-52255−5-5−4-42200
Every number in its own place. Row reduction never moves a number to a different column; it only changes what the numbers ARE, using the three legal moves, until the pivots step down the matrix like a staircase and each pivot is the only number left in its column.
1

Say what the target looks like, and which moves are allowed

Why this step

Row reduction is not a bag of tricks; it is a journey to one specific destination using three legal moves. Knowing the destination precisely is what tells us, at every moment, which move to make next, so we state it before touching a number.

[2452−5−525−5−420]\left[ \begin{array}{rrrr} 2 & 4 & 5 & 2 \\ -5 & -5 & 2 & 5 \\ -5 & -4 & 2 & 0 \end{array} \right]
The matrix we start from. It has 33 rows and 44 columns.
2

Pivot 1: column 1, row 1

Why this step

We work one column at a time, left to right. The goal for a column is a single 11 (the pivot) with zeros everywhere else in it. A column in that state says something very plain: its variable appears in exactly one equation, with nothing in front of it. Each cleared column is one variable pinned down.

Multiply row 1 by 12\frac{1}{2}, which turns the pivot 22 into 11. Multiplying an equation through by a number that is not zero keeps it true for exactly the same values.

columnworkingnew entry
1112⋅2\frac{1}{2} \cdot 211
2212⋅4\frac{1}{2} \cdot 422
3312⋅5\frac{1}{2} \cdot 552\frac{5}{2}
4412⋅2\frac{1}{2} \cdot 211
Row 1, entry by entry.
[12521−5−525−5−420]\left[ \begin{array}{rrrr} \boxed{1} & 2 & \frac{5}{2} & 1 \\ -5 & -5 & 2 & 5 \\ -5 & -4 & 2 & 0 \end{array} \right]
The matrix now. The boxed entry is the pivot being worked on. checked

Replace row 2 by R2+5R1R_{2} + 5 R_{1}. The multiplier is chosen so that the entry under attack, −5-5, is cancelled exactly by the pivot: −5+5⋅1=0-5 + 5 \cdot 1 = 0.

columnworkingnew entry
11−5+5⋅1-5 + 5 \cdot 100
22−5+5⋅2-5 + 5 \cdot 255
332+5⋅522 + 5 \cdot \frac{5}{2}292\frac{29}{2}
445+5⋅15 + 5 \cdot 11010
Row 2, entry by entry: old entry plus the multiple of row 1.
[125210529210−5−420]\left[ \begin{array}{rrrr} \boxed{1} & 2 & \frac{5}{2} & 1 \\ 0 & 5 & \frac{29}{2} & 10 \\ -5 & -4 & 2 & 0 \end{array} \right]
The matrix now. The boxed entry is the pivot being worked on. checked

Replace row 3 by R3+5R1R_{3} + 5 R_{1}. The multiplier is chosen so that the entry under attack, −5-5, is cancelled exactly by the pivot: −5+5⋅1=0-5 + 5 \cdot 1 = 0.

columnworkingnew entry
11−5+5⋅1-5 + 5 \cdot 100
22−4+5⋅2-4 + 5 \cdot 266
332+5⋅522 + 5 \cdot \frac{5}{2}292\frac{29}{2}
440+5⋅10 + 5 \cdot 155
Row 3, entry by entry: old entry plus the multiple of row 1.
[125210529210062925]\left[ \begin{array}{rrrr} \boxed{1} & 2 & \frac{5}{2} & 1 \\ 0 & 5 & \frac{29}{2} & 10 \\ 0 & 6 & \frac{29}{2} & 5 \end{array} \right]
The matrix now. The boxed entry is the pivot being worked on. checked
3

Pivot 2: column 2, row 2

4

Pivot 3: column 3, row 3

5

Confirm the form and read off the rank