Chapter 4 is where the logic of Chapters 2 and 3 starts paying back: we use it to prove and disprove real claims about integers. The objects are familiar (even, odd, prime, rational, divisible), but the discipline is new. Every claim is either proved by the generic-particular method or disproved by a single counterexample.
Where it is used. Number theory is the foundation of cryptography (RSA, Diffie-Hellman), hashing, error-correcting codes, and modular arithmetic in every CPU. More immediately, the proof techniques here are the toolkit you will use in every later chapter: induction (Chapter 5), set theory (Chapter 6), functions and relations (Chapters 7 and 8).
Two definitions to memorise word for word. Both directions of "if and only if" are used: the rightward direction tells you what to do when you see an even (or odd) integer; the leftward direction is what you conclude when you have produced the right form.
Watch. To show n is prime, you must rule out every non-trivial factorisation (a universal claim). To show n is composite, you need to exhibit one non-trivial factorisation (an existential claim). By convention 1 is neither prime nor composite.
Counterexample: n = 5.
So n = 5 makes the hypothesis true and the conclusion false: one such case is enough to disprove the universal claim.
Other counterexamples in a small range: n = 1 ((1−1)/2 = 0, even), n = 9 ((9−1)/2 = 4, even).
Suppose n is a particular but arbitrarily chosen odd integer. [We must show n² is odd.]
By definition of odd, n = 2k + 1 for some integer k. Then
n² = (2k + 1)² = 4k² + 4k + 1 = 2(2k² + 2k) + 1.
Let t = 2k² + 2k. Then t is an integer (products and sums of integers are integers). So n² = 2t + 1, hence odd by definition.
False. The conjecture lab cannot settle this by failing to find a witness; we need an argument that no integer works.
Proof. Suppose, for contradiction, that 6n² + 27 is prime for some integer n. Notice 6n² + 27 = 3(2n² + 9). Since 2n² + 9 ≥ 9 > 1 is an integer, 6n² + 27 has 3 as a divisor different from itself, so it is composite. Contradiction. Hence no such n exists.
Sample values: n = 0 gives 27 = 3·9; n = 1 gives 33 = 3·11; n = 2 gives 51 = 3·17. All composite.
Suppose m, n are particular but arbitrarily chosen integers with m + n even. [We must show m − n is even.]
By definition of even, m + n = 2k for some integer k. Then m = 2k − n, so
m − n = (2k − n) − n = 2k − 2n = 2(k − n).
Let t = k − n. Then t is an integer (difference of integers is an integer), and m − n = 2t. Therefore m − n is even by definition.
Theorem. The sum of any two even integers is even.
"Proof". Suppose m and n are even integers. By definition of even, m = 2k and n = 2k for some integer k. Then m + n = 2k + 2k = 4k = 2(2k), which is even, with witness 2k.
The mistake. The flawed "proof" uses the same letter k for two independent witnesses. The definition of even says n = 2k for some integer k; the k that witnesses m need not be the same as the k that witnesses n.
For example, m = 2 has witness k = 1, but n = 6 has witness k = 3. Forcing both to use the same k shrinks the claim from "any two even integers" to "any two identical even integers", which is much weaker.
Correct proof. Suppose m and n are particular but arbitrarily chosen even integers. By definition of even, m = 2r and n = 2s for some integers r and s (possibly different).
m + n = 2r + 2s = 2(r + s).
Let t = r + s (an integer, sum of integers). Then m + n = 2t, so m + n is even.
Why we drill on this. "Find the mistake" exercises catch the most common error in proof writing: collapsing two independent existential witnesses into one. The slides flag these as high-value for the midterm.
The word "rational" contains "ratio". A rational number is, literally, a ratio of integers.
True.
Suppose r and s are rational. By definition, r = a/b and s = c/d for integers a, b, c, d with b ≠ 0 and d ≠ 0. Then
r − s = a/b − c/d = (ad − bc) / bd.
Let p = ad − bc and q = bd. Both are integers (differences and products of integers are integers), and q ≠ 0 by the zero-product property. Hence r − s = p/q is rational.
Suppose r and s are rational and s ≠ 0. By definition, r = a/b and s = c/d for integers a, b, c, d with b ≠ 0 and d ≠ 0. Since s ≠ 0, also c ≠ 0 (otherwise s = 0/d = 0). Then
r / s = (a/b) / (c/d) = (a · d) / (b · c) = ad / bc.
Let p = ad and q = bc. Both are integers; q = bc ≠ 0 by the zero-product property. Hence r/s = p/q with q ≠ 0, so r/s is rational.
True. Suppose a is any odd integer. Then a = 2k + 1 for some integer k. So
a² + a = (2k + 1)² + (2k + 1) = 4k² + 4k + 1 + 2k + 1 = 4k² + 6k + 2 = 2(2k² + 3k + 1).
Let t = 2k² + 3k + 1 (an integer). Then a² + a = 2t, hence even by definition.
Sharper insight. a² + a = a(a + 1) is the product of two consecutive integers, one of which is always even. The proof above only handles a odd; the general fact follows from Theorem 4.4.2 (Section 4.4).
Suppose r and s are rational. By definition, r = a/b and s = c/d for some integers a, b, c, d with b ≠ 0 and d ≠ 0. Then
r · s = (a/b) · (c/d) = (a · c) / (b · d) = ac / bd.
Let p = ac and q = bd. Both are integers (products of integers are integers), and q = bd ≠ 0 by the zero-product property. Hence r · s = p/q with q ≠ 0, so r · s is rational.
Together with Exercises 4.2.A and 4.2.B: the rationals are closed under all four basic operations (with division requiring a nonzero divisor). This is the closure result that makes ℚ a field.
Suppose m is even and n is odd.
Therefore 5m + 3n is odd.
What this exercises. Citing pre-proved results by number, instead of re-expanding the definitions of even and odd. Once the seven properties are established, every later proof reads as a short chain of citations.
Watch the distinction. a | b is a sentence (true or false). a / b is a number (may or may not be an integer). Example: 3 | 12 is true; 3 | 7 is false; 12 / 3 = 4; 7 / 3 ≈ 2.333.
Suppose a, b, c are integers with a | b and a | c. By definition, b = ar and c = as for some integers r, s. Then
b − c = ar − as = a(r − s).
Let t = r − s (an integer). Then b − c = at, so a | (b − c) by definition.
True. Suppose a, b are integers with a | b. Then b = ak for some integer k. So
b² = (ak)² = a² k² = a · (ak²).
Let t = ak² (an integer). Then b² = at, hence a | b².
False. Counterexample: a = 6, b = 4, c = 9.
The hypothesis is true and the conclusion is false, so the universal claim is disproved.
Why this happens. 6 = 2·3 splits its prime factors between b (which has a factor of 2) and c (which has a factor of 3). The product gathers both, but neither side alone has both. The statement does hold when a is prime (Euclid's lemma); composite a can fail.
Strip out one prime at a time.
3,300 = 100 · 33 = 4 · 25 · 3 · 11 = 2 · 2 · 5 · 5 · 3 · 11.
Sort the primes ascending and collect powers:
3,300 = 2² · 3 · 5² · 11.
Verify: 4 · 3 · 25 · 11 = 4 · 3 · 275 = 12 · 275 = 3,300. ✓
The factorisation explorer above produces the same result for any n ≥ 2. By the unique factorisation theorem, this representation is the only one.
Yes. Argue by unique factorisation.
Pattern. This is the same argument as Epp's 17 | m worked example. Whenever a prime p appears on one side of an equation but is "too large" to be hidden in any of the other factors on the other side, it must show up in the unknown.
Long division from grade school, formalised. The theorem fixes unique integers q and r for any pair (n, d) with d > 0.
(1) 3 = 11·0 + 3. So q = 0, r = 3. (Verify: 0 ≤ 3 < 11 ✓.)
(2) −45 = 11·(−5) + 10. So q = −5, r = 10. (Verify: 11·(−5) = −55, and −55 + 10 = −45 ✓. 0 ≤ 10 < 11 ✓.)
The quotient is −5, not −4. We "overshoot" below n so the remainder stays non-negative.
50 div 7 = 7; 50 mod 7 = 1. Verify: 7·7 + 1 = 50 ✓; 0 ≤ 1 < 7 ✓.
Suppose n is any integer. By the quotient-remainder theorem with d = 2, either n = 2q or n = 2q + 1 for some integer q.
Case 1: n = 2q. n² + n = 4q² + 2q = 2(2q² + q). Let t = 2q² + q (an integer). Then n² + n = 2t, hence even.
Case 2: n = 2q + 1. n² + n = (2q+1)² + (2q+1) = 4q² + 4q + 1 + 2q + 1 = 4q² + 6q + 2 = 2(2q² + 3q + 1). Let t = 2q² + 3q + 1 (an integer). Then n² + n = 2t, hence even.
In both cases n² + n is even.
Quicker insight. n² + n = n(n + 1) is the product of two consecutive integers, one of which is even by Theorem 4.4.2.
Translate the hypothesis using the quotient-remainder theorem:
a mod 7 = 3 ⇔ a = 7q + 3 for some integer q.
Multiply by 5:
5a = 5(7q + 3) = 35q + 15.
Rewrite 15 as a multiple of 7 plus a remainder in [0, 7): 15 = 7·2 + 1.
5a = 35q + 14 + 1 = 7(5q + 2) + 1.
5q + 2 is an integer, and 0 ≤ 1 < 7. So 5a mod 7 = 1.
Method. Same template as Epp Example 4.4.4 (the m mod 11 problem): translate the hypothesis to a = dq + r, do the algebra, then rewrite the constant term as d · (something) + (new remainder in [0, d)).
Suppose n is any integer. By the quotient-remainder theorem with d = 3, exactly one of the following holds: n = 3q, n = 3q + 1, or n = 3q + 2, for some integer q.
Case 1: n = 3q. Then n itself is a multiple of 3, so n(n+1)(n+2) = 3q · (n+1)(n+2) = 3 · [q(n+1)(n+2)]. The bracket is an integer, so the product is divisible by 3.
Case 2: n = 3q + 1. Then n + 2 = 3q + 3 = 3(q + 1) is a multiple of 3, so n(n+1)(n+2) = n(n+1) · 3(q+1) = 3 · [n(n+1)(q+1)]. Divisible by 3.
Case 3: n = 3q + 2. Then n + 1 = 3q + 3 = 3(q + 1) is a multiple of 3, so n(n+1)(n+2) = n · 3(q+1) · (n+2) = 3 · [n(q+1)(n+2)]. Divisible by 3.
In every case 3 | n(n+1)(n+2).
Intuition. Three consecutive integers always include one multiple of 3. Cases mod 3 makes the argument formal.