Mathematical Induction
How to prove a statement true for every positive integer by checking one case and one step — the domino-chain argument behind formulas for sums, compounding, and recursive algorithms.
Suppose you want to prove that compounding at rate for years multiplies your money by , for every whole number of years — not just the five or six you happened to check on a spreadsheet. Checking one at a time never finishes; there is always another year to test. Mathematical induction is a way of proving a claim for every single positive integer using only two finite checks, no matter how large "every" turns out to be.
The analogy: a row of dominoes
Line up an infinite row of dominoes, one for each year, and imagine each domino carries a claim: "domino " says "the formula is true for year ." You want every domino to fall. You do not need to push each one by hand — you need two things: the first domino falls when pushed, and the dominoes are spaced so that any falling domino knocks over the next one. Given both, the whole infinite row falls, one after another, forever. That is the entire logic of induction; the algebra below is just how you check those two conditions precisely.
Writing it down
Let be a statement depending on a positive integer — for instance, "." Induction has two steps.
Base case. Show is true directly — push the first domino and check it falls.
Inductive step. Assume is true for some arbitrary (this assumption is called the inductive hypothesis — it is not something you're proving, it's a temporary "suppose"), and use that assumption to show must also be true. In words: show that whichever domino falls, the next one falls too.
Read left to right: if the first case holds, and truth always carries forward one step, then it holds for every case. Nothing here requires checking , , and so on by hand — the inductive step proves the pattern of carrying forward, once, for a generic , and that single proof covers infinitely many transitions.
Worked example 1: the sum of the first n integers
Claim: .
Base case, . Left side: just . Right side: . They match, so holds.
Inductive step. Assume : . Now look at the sum for : it is the sum up to , plus one more term:
using the inductive hypothesis to replace the first terms. Factor out : . That is exactly the formula with replaced by , so holds. The domino chain is complete: true for every .
Worked example 2: compounding grows by exactly
Claim: after years of compounding at rate , $1 becomes .
Base case, . After one year, $1 grows by a factor , which is . Matches.
Inductive step. Assume after years $1 has become (the inductive hypothesis). Year multiplies whatever you have by one more time: . That is the claim for . So for every , one dollar becomes — the formula compounding calculators use is not an approximation, it is a proven identity for every whole year.
What this means in practice
Induction is how you certify that a recursive algorithm terminates correctly for every input size, not just the sizes you tested — the same logic that justifies "if the loop invariant holds before the loop and each iteration preserves it, it holds after the loop." It is also how closed-form formulas for sums, compounding, and recurrence relations get proved rather than merely observed on a few examples.
Induction proves a statement for every positive integer using two finite checks: a base case (the first domino falls) and an inductive step (any falling domino knocks the next one over). The inductive step never proves — it assumes and derives from it.
The classic error is skipping or fudging the base case, or subtly assuming the very thing you're trying to prove inside the inductive step (circular reasoning). A famous fake "proof" that all horses are the same colour fails exactly at the base case: the inductive step secretly requires at least two horses to overlap between groups, which breaks going from to . Always check the base case explicitly, and make sure the inductive step's logic actually works at the smallest transition, not just "in general."
Related concepts
Practice in interviews
Further reading
- Rosen, Discrete Mathematics and Its Applications (ch. 5)
- Graham, Knuth & Patashnik, Concrete Mathematics (ch. 2)