Linear Algebra, Live
Strang §2.2 · The idea of elimination

Elimination knocks out one unknown at a time.

Subtract a multiple of one equation from another so an unknown disappears. What is left is one equation with one unknown. Solve it, then work back up.

x − 2y = 1    3x + 2y = 11   →   8y = 8

Think: the café puzzle

A coffee and a croissant cost €5. A coffee and two croissants cost €7. What does a croissant cost?

Nobody reaches for a formula. You compare the two orders. The second one has one extra croissant and costs €2 more. So a croissant is €2, and the coffee is €3.

That comparison is elimination. You subtracted one equation from the other and the coffee disappeared.

The steps

  • Pivot: the first x coefficient, here 1. It is the number you use to clear the column below it.
  • Multiplier: ℓ = (entry to remove) ÷ (pivot) = 3 ÷ 1 = 3.
  • Subtract: equation 2 minus 3 times equation 1.
  • Back substitution: solve the last equation, then put that value into the one above.

Worked example

(3x + 2y) − 3(x − 2y) = 11 − 3·1
8y = 8  →  y = 1
x − 2·1 = 1  →  x = 3

What it looks like

Run the code before and after. The second line changes: it turns flat, y = 1. The crossing point stays at (3, 1).

That is the whole trick. Each step gives a simpler system with exactly the same solution. Anything that solves both old equations also solves the new ones, and the other way round.

Where you meet this

Circuit simulators, finite element programs and many other engineering tools solve equations this way. The systems just have thousands of unknowns instead of two.

Exercise Choose the multiplier l so that the new second row starts with 0. Edit the code and press Run.
slide_1.py Loading Python…
1
Output · Ctrl+Enter runs
Press Run to execute this slide's code. Ctrl+Enter works too.
✎Lesson review
3 more worked examples and 5 mixed problems with solutions
→