4.5.9 · D2Linear Algebra (Full)

Visual walkthrough — Gaussian elimination — forward elimination, back substitution

2,178 words10 min readBack to topic

We will solve this exact system all the way through:

Before we touch it, let us make sure every symbol is earned.


Step 0 — Reading the symbols (nothing assumed)

Look at the figure: the left panel is the messy word-equations, the right panel is the tidy grid. Same information, less ink.


Step 1 — The goal shape: a staircase of zeros

WHY this shape and no other? Because a triangular system can be read off one variable at a time. The bottom row will mention only ; the middle row only and ; the top row all three. That staircase is the entire payoff.

PICTURE. The amber staircase in the figure traces the diagonal; everything in the cyan shaded region beneath it must become . Our job for the next steps is to fill that region with zeros without changing the answer.


Step 2 — Clear column 1 under the first pivot

Target (Row 2). Multiplier: Do . The new first entry:

Target (Row 3). Multiplier: New first entry:

The grid becomes

WHY it's safe: adding a multiple of one true equation to another keeps both true and is reversible — the solution set never moves.

PICTURE. Watch the two amber arrows in the figure fire from the pivot row down into Rows 2 and 3; the red targets snap to . Column 1 is now clean below the pivot.


Step 3 — Clear column 2 under the second pivot

Multiplier: Check the target:

Do the whole row so the RHS rides along:

  • column 3:
  • RHS:

WHY only one arrow this time? Because after column 1 was cleared, Row 3 already had a where its old -coefficient was. We only fight the entries that are still nonzero below the current pivot.

PICTURE. A single amber arrow from Row 2 into Row 3. The whole cyan under-diagonal region is now zeros — the staircase is built.

Recall Why we never touch entries

above the diagonal Forward elimination only zeros below the pivots. The upper part is allowed to be messy — back substitution will handle it. Trying to clear above too is a different (more expensive) method called Gauss–Jordan, heading toward Reduced Row Echelon Form.


Step 4 — Read the bottom row: the first unknown falls out

Bottom row means

  • = the pivot .
  • = the RHS .
  • Divide RHS by pivot: .

WHY start here? No other row is this simple. Every row above still mixes two or three unknowns. The bottom is the only door that opens with one key.

PICTURE. The bottom row glows amber; a single value pops out on the right. The rows above are dimmed — not their turn yet.


Step 5 — Climb one row: substitute the known, solve the new one

Row 2 reads Substitute :

  • = pivot .
  • = the already-known part; we push it to the right side.
  • What remains, , divides straight down to .

WHY it always works going up: each step up adds exactly one fresh unknown, and everything to its right was solved on the previous step. One new unknown, one equation — always solvable.

PICTURE. The value slides from Step 4 into Row 2 (amber trail), and emerges.


Step 6 — Top row: the last unknown

Row 1 reads Substitute :

Answer: .

Sanity check on an original equation (the one we changed most):

PICTURE. All three solved values feed into the top row; drops out; a final green tick confirms the check.


Step 7 — The degenerate cases you must never be surprised by

Elimination doesn't only solve — it also diagnoses. Three things can happen to the bottom row.

WHY a zero pivot mid-way forces a swap. If the pivot slot itself is , the multiplier would divide by zero. The fix: swap in a lower row that has a nonzero entry in that column (this is partial pivoting). If no lower row has one, that column has no pivot — its variable is free.

PICTURE. Three mini-staircases side by side: unique (amber pivot, tick), inconsistent (amber , cross), infinite (amber , an arrow labelled "free variable").

Common mistake The trap: reading the bottom row wrong

A row of zeros with RHS is not "no solution" — it is the opposite, infinitely many. The killer is a zero row with a nonzero RHS. Say it out loud: "? Impossible." That is the only inconsistency signal.

Recall Where these cases connect

The number of nonzero pivots is the rank. Compare the rank of with the rank of to decide the ending — spelled out in Solving Linear Systems — Consistency. And multiplying the pivots gives the Determinant (zero determinant ⇔ a missing pivot ⇔ not a unique solution).


The one-picture summary

Everything above, on a single flight of stairs: DOWN the columns to plant zeros (forward elimination), then UP the rows to read off unknowns (back substitution).

Recall Feynman retelling of the whole walkthrough

You've got three riddles, each mixing three secret numbers. First you tidy them into a grid so you stop copying everywhere. Then you go down: take the top riddle, scale a copy of it, and subtract it from the ones below so they forget about the first secret — do it column by column until the last riddle mentions only one secret. That bottom riddle you solve on sight. Now turn around and go up: plug that answer into the riddle above, which then mentions only one new secret — solve it, climb, repeat. When you reach the top you know all three, and you plug them back into an original riddle to be sure. If somewhere the bottom riddle turns into "zero equals five," someone lied — no solution. If it turns into "zero equals zero," you're missing a clue — infinitely many answers. Down to plant zeros, up to read the answers. That's the whole trick.


Recall checkpoint

Why start back substitution at the bottom row?
Only the bottom row of the staircase contains a single unknown; every higher row still mixes several.
In Step 3, why is ?
Because , the number of pivot rows that cancel the target .
A staircase's last row is with — meaning?
Inconsistent — no solution (it claims ).
A staircase's last row is all zeros — meaning?
A free variable — infinitely many solutions.
What operation replaces a zero pivot?
A row swap (partial pivoting) bringing up a lower row with a nonzero entry in that column.

Connections