In one sentence
Integers come in two kinds, odd and even. The properties used most often:
- and have the same parity;
- a sum of an odd number of odd numbers is odd, and a sum of an even number of odd numbers is even;
- a product of integers is odd if and only if every factor is odd.
The power of a parity argument: it keeps just one piece of information, the value “mod ”, and that is often exactly the part of the problem that does not change.
Predict first
The board shows . Each move erases any two numbers and writes . After moves one number is left. Can that number be ?
No. and have the same parity, so after every move the parity of the sum of all the numbers on the board is unchanged. At the start the sum is , which is odd; so the last number left must be odd too.
Example: erase two of 1 to 10, write the difference; the last number is odd
Step 1 / 4- Find a quantity
Each move touches only two numbers, so look at the sum of all the numbers, . At the start .
Stop 1 · The Principle of Classification (Vol. 1)
Sort the integers into two classes by parity, and the problem becomes one about how the two classes are arranged.
Example: can 1, 2, …, n be arranged in a circle so that every two neighbors have an odd sum?
Step 1 / 4- What an odd sum means
A sum of two numbers is odd one is odd and one is even. So odd and even numbers must alternate around the circle.
Stop 2 · Periodic Sequences (Vol. 5)
The sequence itself keeps growing, but its parity has only two states, and it is often periodic.
Example: a₁ = a₂ = 1, aₙ₊₂ = aₙ₊₁·aₙ + 1. Is a₁₀₀ odd or even?
Step 1 / 4- Track only the parity
odd × odd + 1 = even, odd × even + 1 = odd, even × odd + 1 = odd.
Stop 3 · The Fibonacci Sequence (Vol. 5)
One problem, several solutions
The Fibonacci sequence: , . Prove that is even if and only if .
The parity is periodic
Mod : . Each term is decided by the two before it, and , so the shadow has period .
So .
CostThe most direct: squash the sequence down to its mod 2 “shadow”.
Induction with step 3
, so .
Check that are odd and is even, then use induction with step size : three chains cover .
CostNo mention of periods, just induction; first stretch the recurrence over three steps.
Practice
The board shows . Each move erases two numbers and writes the absolute value of their difference. What remainder does the last number leave when divided by ?
How many of the first Fibonacci numbers are even?
is a polynomial with integer coefficients, and and are both odd. Prove that has no integer root.
Each of is or , and . What is the smallest positive integer for which this is possible?