Section 4.2 Congruences and their Properties
Objectives
- Define congruence modulo
and show it is an equivalence relation. - Prove properties about congruence relations.
In part (d) of Checkpoint 4.1.6 you would have proven that
Video: Congruence
Definition 4.2.1. Congruence.
Let
The number
Example 4.2.2. Simple Example.
Since \(6 \mid (55-13)\text{,}\) 55 and 13 are congruent modulo 6, and we write \(55 \equiv 13 \Mod{6}\text{.}\)
However \(6 \nmid (30-11)\) so 30 and 11 are not congruent modulo 6, or \(30 \not\equiv 11 \Mod{6}\text{.}\)
Checkpoint 4.2.3. Congruent iff Same Remainder.
Show that two integers \(a\) and \(b\) are congruent modulo \(n\) if and only if they have the same remainder when divided by \(n\text{.}\)
Use Theorem 1.3.2.
One real-life example is that of computing what day of the week it is, which uses congruence modulo
Example 4.2.4. Days of the Week.
Modulo 7, the numbers 26 and 47 are congruent because \(7 \mid (26-47)\text{.}\) This means 26 and 47 are ‘equivalent’ under this particular relation.
One way to see this is the fact that if today were Sunday, then 26 days from today it will be Friday, and 47 days from today is also a Friday. Abstracting only the property we care about (remainder when divided by 7) allows us to generate conclusions like this without having to manually count 47 days forward.
As another example, if today were Sunday, then we can confidently claim that 2020 days from today, it will be Thursday. This is because \(2020 \equiv 4 \Mod{7}\text{,}\) and four days after Sunday is Thursday. (We've effectively removed as many 7's as possible to reduce the calculation.)
Checkpoint 4.2.5. New Relationship.
Today, two of your friends bought each other matching couple shirts to celebrate being in a relationship for 100 days. If today is Wednesday, what day did their relationship begin?
Definition 4.2.6. Congruence Class.
The equivalence classes of congruence modulo
corresponding to the possible remainders when dividing by
Example 4.2.7. Modulo 5.
Modulo 5, the congruence classes are
Video: Properties of Congruence
Observe that if two numbers
We can perform addition and multiplication modulo
Proposition 4.2.8. Modular Arithmetic.
Let
for any
Checkpoint 4.2.9. Prove Proposition 4.2.8.
Prove Proposition 4.2.8, using the definition of congruence.
Importantly, Proposition 4.2.8 implies that in any congruence, we can replace any number with another number it is congruent to, and obtain an equivalent statement.
Example 4.2.10. Substituting Congruent Numbers.
Suppose we wanted to compute the remainder when 4133 is divided by 4. We first write \(4133 = 4000 + 100 + 30 + 3\text{,}\) so that
Hence the remainder when \(4133\) is divided by \(4\) is \(1\text{.}\)
Checkpoint 4.2.11. Modulo 9.
Show that an integer is congruent to the sum of its digits modulo 9.
The integer \(a_ka_{k-1}\cdots a_2 a_1 a_0\) can be expressed as \(a_k\left(10^k\right) + a_{k-1}\left(10^{k-1}\right) + \cdots + a_1(10) + a_0\text{.}\)
Definition 4.2.12. The Modulo Operation.
Given two integers
read as
Checkpoint 4.2.13. Compute Remainders.
Compute the following:
- \(\displaystyle 2139138 \mmod 9\)
- \(\displaystyle 2^{1000} \mmod 7\)
- \(\displaystyle 10! \mmod 17\)
While Proposition 4.2.8 allows us to perform addition, subtraction and multiplication, when we try dividing we find that we run into some issues.
Example 4.2.14. Division is not as Nice.
We know that
If we divide both sides by 3, we would get
which is false. However \(13 \equiv 41 \Mod{4}\) is true.
Proposition 4.2.15. Dividing both sides of a Congruence.
Let
If
Proof.
Suppose that \(ad \equiv bd \Mod{n}\text{.}\) This means \(ad = bd + kn\) for some \(k \in \mathbb{Z}\text{.}\)
Since \(\gcd(d,n)\) divides both \(d\) and \(n\text{,}\) we can divide through to get
This is equivalent to
Since \(\gcd\left(\dfrac{d}{\gcd(d,n)},\dfrac{n}{\gcd(d,n)}\right) = 1\text{,}\) we can apply the result of Checkpoint 1.3.13 to obtain
or that \(a \equiv b \Mod{\dfrac{n}{\gcd(d,n)}}\text{,}\) as desired.
If \(\gcd(d,n) = 1\text{,}\) the statement reduces to \(a \equiv b \Mod{n}\text{.}\)
Checkpoint 4.2.16. Justify It.
Explain why
in the proof of Proposition 4.2.15.
Contradiction.
The second statement of Proposition 4.2.15 is also called the cancellation law, since it gives a condition under which one can divide both sides of a congruence by a number.