Mathematical-Reasoning Β· Unit 10 Β· Video 6 Β· Interactive Practice

Cases Modulo n: Every Integer Is Congruent to Its Remainder

IKey Formulas

StatementNameRole
a=nq+ra = nq + r with 0≀r<n0 \le r < n, for unique integers qq and rrDivision AlgorithmGives every integer aa a remainder rr on division by n∈Nn \in \mathbb{N}
If a=nq+ra = nq + r and 0≀r<n0 \le r < n, then a≑r(modn)a \equiv r \pmod{n}TheoremAn integer is congruent to its own remainder, since aβˆ’r=nqa - r = nq
Each a∈Za \in \mathbb{Z} is congruent modulo nn to precisely one of 0,1,…,nβˆ’10, 1, \dots, n - 1CorollarySplits a proof about every integer into nn cases
If a≑̸0(mod5)a \not\equiv 0 \pmod{5}, then a2≑1a^2 \equiv 1 or a2≑4(mod5)a^2 \equiv 4 \pmod{5}PropositionFour cases, each settled by the power and transitive properties

Key Insight: An integer is congruent to many integers (9≑2≑16β‰‘βˆ’5(mod7)9 \equiv 2 \equiv 16 \equiv -5 \pmod{7}), but to exactly one of 0,1,…,nβˆ’10, 1, \dots, n - 1, so the cases a≑0a \equiv 0, a≑1a \equiv 1, …, a≑nβˆ’1a \equiv n - 1 cover every integer with no overlap.

IIRow q, Column r: The Remainder Decides the Congruence

The Division Algorithm puts aa in row qq and column rr, and every entry of column rr is congruent to rr.

IIIFour Cases Settle the Squares Modulo 5

When 5∀a5 \nmid a, the corollary leaves four cases, and each one sends a2a^2 to 11 or 44 modulo 55.

IVWhich Remainders Can a Square Have?

Modulo any nn, the nn cases a≑0,1,…,nβˆ’1a \equiv 0, 1, \dots, n - 1 decide every remainder a square can have.

VQuiz Questions

Problem 1 Β· The Remainder of a Negative Integer

Given: a=βˆ’23a = -23 and n=6n = 6. Which Division Algorithm form gives the remainder rr, the one integer with 0≀r<60 \le r < 6 and βˆ’23≑r(mod6)-23 \equiv r \pmod{6}?

βœ… Correct! 6(βˆ’4)+1=βˆ’24+1=βˆ’236(-4) + 1 = -24 + 1 = -23 and 0≀1<60 \le 1 < 6, so r=1r = 1; indeed βˆ’23βˆ’1=βˆ’24=6(βˆ’4)-23 - 1 = -24 = 6(-4), so βˆ’23≑1(mod6)-23 \equiv 1 \pmod{6}.
❌ Not quite. This divides 2323, not βˆ’23-23. Check the congruence: βˆ’23βˆ’5=βˆ’28-23 - 5 = -28, which is not a multiple of 66, so βˆ’23≑̸5(mod6)-23 \not\equiv 5 \pmod{6}.
❌ Not quite. The equation is true, and βˆ’23β‰‘βˆ’5(mod6)-23 \equiv -5 \pmod{6} holds, but βˆ’5-5 is not a remainder: the Division Algorithm requires 0≀r<60 \le r < 6. Lower the quotient by one to make the remainder non-negative.
❌ Not quite. The equation is true, but 77 is not less than 66, so this is not the Division Algorithm form. Raise the quotient by one: βˆ’23=6(βˆ’4)+1-23 = 6(-4) + 1.
Show solution

We need integers qq and rr with βˆ’23=6q+r-23 = 6q + r and 0≀r<60 \le r < 6. The largest multiple of 66 that is at most βˆ’23-23 is βˆ’24=6(βˆ’4)-24 = 6(-4), so q=βˆ’4q = -4 and r=βˆ’23βˆ’(βˆ’24)=1r = -23 - (-24) = 1:

βˆ’23=6(βˆ’4)+1,0≀1<6.-23 = 6(-4) + 1, \qquad 0 \le 1 < 6.

By the theorem, βˆ’23≑1(mod6)-23 \equiv 1 \pmod{6}: indeed βˆ’23βˆ’1=βˆ’24=6(βˆ’4)-23 - 1 = -24 = 6(-4). For a negative integer the quotient is negative and the remainder stays in 0,1,…,50, 1, \dots, 5. The forms with r=βˆ’5r = -5 and r=7r = 7 are true equations, but neither remainder satisfies 0≀r<60 \le r < 6.

Problem 2 Β· Congruent to Exactly One β€” of What?

Given: 30=7β‹…4+230 = 7 \cdot 4 + 2. Which statement about 3030 modulo 77 is true?

βœ… Correct! 30βˆ’9=21=7β‹…330 - 9 = 21 = 7 \cdot 3 and 30βˆ’(βˆ’5)=35=7β‹…530 - (-5) = 35 = 7 \cdot 5, so 3030 is congruent to infinitely many integers; the corollary only says exactly one of them lies in 0,1,…,60, 1, \dots, 6, and that one is the remainder 22.
❌ Not quite. 3030 is congruent to many integers modulo 77: for example 30βˆ’9=21=7β‹…330 - 9 = 21 = 7 \cdot 3, so 30≑9(mod7)30 \equiv 9 \pmod{7}. Uniqueness holds only among 0,1,…,60, 1, \dots, 6.
❌ Not quite. Both congruences are true, but there is no contradiction: the corollary is about the numbers 0,1,…,60, 1, \dots, 6, and 99 is not one of them.
❌ Not quite. The congruence picks out the remainder, not the quotient: 30βˆ’4=2630 - 4 = 26 is not a multiple of 77, so 30≑̸4(mod7)30 \not\equiv 4 \pmod{7}.
Show solution

From 30=7β‹…4+230 = 7 \cdot 4 + 2 with 0≀2<70 \le 2 < 7, the theorem gives 30≑2(mod7)30 \equiv 2 \pmod{7}.

The integer 3030 is also congruent to 99, since 30βˆ’9=21=7β‹…330 - 9 = 21 = 7 \cdot 3, and to βˆ’5-5, since 30βˆ’(βˆ’5)=35=7β‹…530 - (-5) = 35 = 7 \cdot 5. So statement (a) is false, and statement (b) misreads the corollary.

The corollary says that exactly one of 0,1,…,60, 1, \dots, 6 is congruent to 3030: at least one because 3030 is congruent to its remainder 22, and at most one by the uniqueness of the Division Algorithm. Among 22, 99 and βˆ’5-5, only 22 lies in that range, so statement (d) is true. Statement (c) uses the quotient: 30βˆ’4=2630 - 4 = 26 is not a multiple of 77.

Problem 3 Β· Cubes Modulo 7 by Cases

Given: aa is an integer with 7∀a7 \nmid a. Using one case for each possible value of rr with a≑r(mod7)a \equiv r \pmod{7}, and the power property with exponent 33, find exactly which of 0,1,…,60, 1, \dots, 6 the cube a3a^3 can be congruent to modulo 77.

βœ… Correct! The six cases give 13=11^3 = 1, 23=8≑12^3 = 8 \equiv 1, 33=27≑63^3 = 27 \equiv 6, 43=64≑14^3 = 64 \equiv 1, 53=125≑65^3 = 125 \equiv 6 and 63=216≑66^3 = 216 \equiv 6.
❌ Not quite. Those are the remainders of the squares modulo 77 (121^2, 32=9≑23^2 = 9 \equiv 2, 22=42^2 = 4). Cube instead: for example a≑3a \equiv 3 gives a3≑27=7β‹…3+6a^3 \equiv 27 = 7 \cdot 3 + 6, so a3≑6a^3 \equiv 6.
❌ Not quite. Different cases can land on the same value. Reduce each cube: 23=8=7β‹…1+12^3 = 8 = 7 \cdot 1 + 1, so case 22 also gives 11.
❌ Not quite. a3≑0a^3 \equiv 0 would need the case a≑0a \equiv 0, which the hypothesis 7∀a7 \nmid a rules out: a≑0(mod7)a \equiv 0 \pmod{7} means 7∣a7 \mid a.
Show solution

Since 7∀a7 \nmid a, we have a≑̸0(mod7)a \not\equiv 0 \pmod{7}, so by the corollary aa is congruent to exactly one of 1,2,3,4,5,61, 2, 3, 4, 5, 6. In each case the power property gives a3≑r3a^3 \equiv r^3, and transitivity lets us replace r3r^3 by its remainder (all congruences modulo 77):

  • a≑1a \equiv 1: a3≑13=1a^3 \equiv 1^3 = 1.
  • a≑2a \equiv 2: a3≑8a^3 \equiv 8, and 8βˆ’1=78 - 1 = 7, so a3≑1a^3 \equiv 1.
  • a≑3a \equiv 3: a3≑27a^3 \equiv 27, and 27βˆ’6=21=7β‹…327 - 6 = 21 = 7 \cdot 3, so a3≑6a^3 \equiv 6.
  • a≑4a \equiv 4: a3≑64a^3 \equiv 64, and 64βˆ’1=63=7β‹…964 - 1 = 63 = 7 \cdot 9, so a3≑1a^3 \equiv 1.
  • a≑5a \equiv 5: a3≑125a^3 \equiv 125, and 125βˆ’6=119=7β‹…17125 - 6 = 119 = 7 \cdot 17, so a3≑6a^3 \equiv 6.
  • a≑6a \equiv 6: a3≑216a^3 \equiv 216, and 216βˆ’6=210=7β‹…30216 - 6 = 210 = 7 \cdot 30, so a3≑6a^3 \equiv 6.

Every case ends at 11 or 66, and both occur (for example a=1a = 1 and a=3a = 3). So a3a^3 can be congruent to exactly 11 and 66 among 0,1,…,60, 1, \dots, 6.

Problem 4 Β· Sums of Two Squares Modulo 4

Given: The four cases x≑0,1,2,3(mod4)x \equiv 0, 1, 2, 3 \pmod{4} give x2≑0x^2 \equiv 0 or x2≑1(mod4)x^2 \equiv 1 \pmod{4} for every integer xx. Which of these integers is not equal to x2+y2x^2 + y^2 for any integers xx and yy?

βœ… Correct! 2023=4β‹…505+32023 = 4 \cdot 505 + 3, so 2023≑3(mod4)2023 \equiv 3 \pmod{4}, while x2+y2x^2 + y^2 is congruent to 00, 11 or 22 modulo 44.
❌ Not quite. 2020=422+162=1764+2562020 = 42^2 + 16^2 = 1764 + 256. Look for the integer whose remainder modulo 44 no sum of two squares can have.
❌ Not quite. 2025=452+022025 = 45^2 + 0^2. Look for the integer whose remainder modulo 44 no sum of two squares can have.
❌ Not quite. 2026=452+12=2025+12026 = 45^2 + 1^2 = 2025 + 1. Look for the integer whose remainder modulo 44 no sum of two squares can have.
Show solution

Squares modulo 4. By the corollary each integer xx is congruent to exactly one of 0,1,2,30, 1, 2, 3 modulo 44. The power property gives x2≑0x^2 \equiv 0, 11, 44 or 99, and since 4≑04 \equiv 0 and 9≑1(mod4)9 \equiv 1 \pmod{4}, transitivity gives x2≑0x^2 \equiv 0 or x2≑1(mod4)x^2 \equiv 1 \pmod{4}.

Sums. Adding congruences, x2+y2x^2 + y^2 is congruent modulo 44 to 0+0=00 + 0 = 0, 0+1=10 + 1 = 1, 1+0=11 + 0 = 1 or 1+1=21 + 1 = 2.

The integer 2023. Suppose, for a contradiction, that 2023=x2+y22023 = x^2 + y^2. Since 2023=4β‹…505+32023 = 4 \cdot 505 + 3, the theorem gives 2023≑3(mod4)2023 \equiv 3 \pmod{4}, so x2+y2≑3x^2 + y^2 \equiv 3. But x2+y2x^2 + y^2 is also congruent to one of 0,1,20, 1, 2, and by the corollary an integer is congruent to only one of 0,1,2,30, 1, 2, 3 modulo 44. This contradiction shows 20232023 is not a sum of two squares.

The other three are sums of two squares: 2020=422+1622020 = 42^2 + 16^2, 2025=452+022025 = 45^2 + 0^2 and 2026=452+122026 = 45^2 + 1^2.

Solved: 0 / 4