Chapter 1. 1.2 - Modular Arithmetic
Chapter 1. 1.2 - Modular Arithmetic
Concepts
1.2 Modular Arithmetic
Modular Arithmetic Abstraction of a method of counting
Answer ______?
Fact: 25 = 2(12) + 1
Observe: You don’t have to count off 25 months starting Feb. There are 12
months in a year, and so 24 months in two years. Hence, simply add one
month to February to get the answer which is March
Modular Arithmetic
Example 1.2.2 It is now Wednesday, you will know that in 23 days it will be
_________________ (what day?)
Answer ______?
Fact: 23 = 3(7) + 2
Observe: You don’t have to count off 23 days starting Wednesday. Instead,
note that there are 7 days a week. Hence, simply add two days to
Wednesday to get the answer which is Friday
Definition 1.2.3 Let x and n integers. The number x mod n is the remainder r
of x when divided by n, that is
x mod n = r
Example 1.2.4
3 mod 2 = 1 since 3 = 1 ( 2) + 1,
6 mod 2 = 0 since 6 = 3 (2) + 0,
11 mod 3 = 2 since 11 = 3 (3) + 2,
62 mod 85 = 62 since 62 = 0 (85) + 62,
-2 mod 15 = 13 since -2 = (-1)15 + 13.
Definition 1.2.5 Lat a and b be integers and n a positive integer. We say a mod
n = b mod n if and only if n divides a - b
Definition 1.2 6. Congruence
For a positive integer n, the integers a and b are congruent mod n, written a
≡ b (mod n), and read as “a congruent to b modulo n” if their remainders
when divided by n are the same.
Recall:
31 (mod 24) is 7 since 1(24) + 7, and
148 (mod 24) is 4 since [ 6(24) + 4]
Example 1.2.11. Find the remainder when
123+234+32+56+22+12+78 is divided by 3.
Solution. Note that applying Property 3, we can take the modulo of each addend.
Thus, we have :
123≡0(mod3) 22≡1(mod3),
234≡0(mod3) 12≡0(mod3),
32≡2(mod3) 78≡0(mod3).
56≡2(mod3)
3. Solve 5x ≡ 4 (mod 6)