5 Mathematical Systems
5 Mathematical Systems
Mathematical Systems
MTHS101: Mathematics in the Modern World
Department of Mathematics
College of Science and Engineering
Ateneo de Naga University
Learning Objectives
Division Algorithm
Theorem
Given integers a and b, with b > 0, there exist unique integers q
and r satisfying
a = qb + r 0 ≤ r < b
The integers q and r are called, respectively, the quotient and
remainder in the division of a by b.
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Division Algorithm
Theorem
Given integers a and b, with b > 0, there exist unique integers q
and r satisfying
a = qb + r 0 ≤ r < b
The integers q and r are called, respectively, the quotient and
remainder in the division of a by b.
Theorem (Corollary)
If a and b are integers, with b 6= 0, then there exist unique integers
q and r such that
a = qb + r 0 ≤ r < |b|
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 1
When 63 is divided by 5,
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 1
When 63 is divided by 5, we have
63 = 12(5) + 3
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 1
When 63 is divided by 5, we have
63 = 12(5) + 3
where q = 12 and r = 3.
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 1
When 63 is divided by 5, we have
63 = 12(5) + 3
where q = 12 and r = 3.
Example 2
When 12 is divided by 7,
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 1
When 63 is divided by 5, we have
63 = 12(5) + 3
where q = 12 and r = 3.
Example 2
When 12 is divided by 7, we have
12 = 1(7) + 5
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 1
When 63 is divided by 5, we have
63 = 12(5) + 3
where q = 12 and r = 3.
Example 2
When 12 is divided by 7, we have
12 = 1(7) + 5
where q = 1 and r = 5.
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 1
When 63 is divided by 5, we have
63 = 12(5) + 3
where q = 12 and r = 3.
Example 2
When 12 is divided by 7, we have
12 = 1(7) + 5
where q = 1 and r = 5.
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 3
When 3 is divided by 9,
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 3
When 3 is divided by 9, we have
3 = 0(9) + 3
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 3
When 3 is divided by 9, we have
3 = 0(9) + 3
where q = 0 and r = 3.
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 3
When 3 is divided by 9, we have
3 = 0(9) + 3
where q = 0 and r = 3.
Example 4
When 10 is divided by −4,
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 3
When 3 is divided by 9, we have
3 = 0(9) + 3
where q = 0 and r = 3.
Example 4
When 10 is divided by −4, we have
10 = (−2)(−4) + 2
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 3
When 3 is divided by 9, we have
3 = 0(9) + 3
where q = 0 and r = 3.
Example 4
When 10 is divided by −4, we have
10 = (−2)(−4) + 2
where q = −2 and r = 2.
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 3
When 3 is divided by 9, we have
3 = 0(9) + 3
where q = 0 and r = 3.
Example 4
When 10 is divided by −4, we have
10 = (−2)(−4) + 2
where q = −2 and r = 2.
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 5
When 1 is divided by −7,
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 5
When 1 is divided by −7, we have
1 = 0(−7) + 1
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 5
When 1 is divided by −7, we have
1 = 0(−7) + 1
where q = 0 and r = 1.
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 5
When 1 is divided by −7, we have
1 = 0(−7) + 1
where q = 0 and r = 1.
Example 6
When −59 is divided by −7,
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 5
When 1 is divided by −7, we have
1 = 0(−7) + 1
where q = 0 and r = 1.
Example 6
When −59 is divided by −7, we have
−59 = 9(−7) + 4
Mathematical Systems
Theory of Divisibility and Congruences
Division Algorithm
Example 5
When 1 is divided by −7, we have
1 = 0(−7) + 1
where q = 0 and r = 1.
Example 6
When −59 is divided by −7, we have
−59 = 9(−7) + 4
where q = 9 and r = 4.
Mathematical Systems
Theory of Divisibility and Congruences
Divides
Divides
Definition
An integer b is said to be divisible by an integer a 6= 0, in symbols
a | b, if there exists some integer c such that b = ac. We write
a - b to indicate that b is not divisible by a.
Mathematical Systems
Theory of Divisibility and Congruences
Divides
Divides
Definition
An integer b is said to be divisible by an integer a 6= 0, in symbols
a | b, if there exists some integer c such that b = ac. We write
a - b to indicate that b is not divisible by a.
Example
6 | 24 because there exist c = 4 such that 24 = 6(4).
Mathematical Systems
Theory of Divisibility and Congruences
Divides
Divides
Definition
An integer b is said to be divisible by an integer a 6= 0, in symbols
a | b, if there exists some integer c such that b = ac. We write
a - b to indicate that b is not divisible by a.
Example
6 | 24 because there exist c = 4 such that 24 = 6(4).
13 | 78 because there exist c = 6 such that 78 = 13(6).
Mathematical Systems
Theory of Divisibility and Congruences
Divides
Divides
Definition
An integer b is said to be divisible by an integer a 6= 0, in symbols
a | b, if there exists some integer c such that b = ac. We write
a - b to indicate that b is not divisible by a.
Example
6 | 24 because there exist c = 4 such that 24 = 6(4).
13 | 78 because there exist c = 6 such that 78 = 13(6).
Non-example
9 does not divide 21.
Hence, we write that 9 - 21 since, by definition, c 6∈ Z when
21 = 9c.
Mathematical Systems
Theory of Divisibility and Congruences
Congruences
Congruence
Definition
Let n be a fixed positive integer. Two integers a and b are said to
be congruent modulo n, symbolized by
a ≡ b (mod n)
Congruence
Definition
Let n be a fixed positive integer. Two integers a and b are said to
be congruent modulo n, symbolized by
a ≡ b (mod n)
Congruence
Definition
Let n be a fixed positive integer. Two integers a and b are said to
be congruent modulo n, symbolized by
a ≡ b (mod n)
−31 ≡ 11 (mod 7)
because 7 | −31 − 11
Mathematical Systems
Theory of Divisibility and Congruences
Congruences
Theorem
For arbitrary integers a and b, a ≡ b (mod n) if and only if a and
b leave the same nonnegative remainder when divided by n.
Mathematical Systems
Theory of Divisibility and Congruences
Congruences
Theorem
For arbitrary integers a and b, a ≡ b (mod n) if and only if a and
b leave the same nonnegative remainder when divided by n.
Example
The integers 56 and 11 can be expressed as
Theorem
For arbitrary integers a and b, a ≡ b (mod n) if and only if a and
b leave the same nonnegative remainder when divided by n.
Example
The integers 56 and 11 can be expressed as
Both leave the same remainder 2. Hence, the theorem tells us that
56 ≡ 11 (mod 9).
Mathematical Systems
Telling Time
Telling the Time of the Day
Problem
If it is now 10:45 a.m., what time will it be in 143,999,999,995
minutes from now?
Mathematical Systems
Telling Time
Telling the Time of the Day
Problem
What time will it be 8 hours after 5 o’clock in the afternoon?
Mathematical Systems
Telling Time
Telling the Time of the Day
Problem
What time will it be 8 hours after 5 o’clock in the afternoon?
Problem
What time will it be 8 hours after 5 o’clock in the afternoon?
Problem
What time will it be 8 hours after 5 o’clock in the afternoon?
Problem
What time will it be 8 hours after 5 o’clock in the afternoon?
Problem
What time will it be 8 hours after 5 o’clock in the afternoon?
Problem
What time will it be 8 hours after 5 o’clock in the afternoon?
Problem
What time will it be 8 hours after 5 o’clock in the afternoon?
Problem
What time will it be 8 hours after 5 o’clock in the afternoon?
Problem
What time will it be 8 hours after 5 o’clock in the afternoon?
Solution
We use the notation ⊕ to denote addition on a 12-hour clock.
Mathematical Systems
Telling Time
Telling the Time of the Day
Solution
We use the notation ⊕ to denote addition on a 12-hour clock.
5⊕8=
Mathematical Systems
Telling Time
Telling the Time of the Day
Solution
We use the notation ⊕ to denote addition on a 12-hour clock.
5⊕8=1
Mathematical Systems
Telling Time
Telling the Time of the Day
Solution
We use the notation ⊕ to denote addition on a 12-hour clock.
5⊕8=1
10 7 =
Mathematical Systems
Telling Time
Telling the Time of the Day
10 7 = 3
Mathematical Systems
Telling Time
Telling the Time of the Day
10 7 = 3
10 7 = 3
10 7 = 3
3 7
Mathematical Systems
Telling Time
Telling the Time of the Day
10 7 = 3
3 7=8
Mathematical Systems
Telling Time
Telling the Time of the Day
10 7 = 3
3 7=8
Examples
Try these:
1. What time will it be seventeen hours after 8:30 in the
morning?
2. What time was it 21 hours before 8 P.M.?
3. What time will it be 40 hours after 7 A.M.?
4. What time was it 50 hours before 2:00 P.M.?
Mathematical Systems
Telling Time
Telling the Day of the Week
Telling the day of the week is similar to telling the time of the day.
Mathematical Systems
Telling Time
Telling the Day of the Week
Telling the day of the week is similar to telling the time of the day.
Associating the Days to Numbers
Mathematical Systems
Telling Time
Telling the Day of the Week
Telling the day of the week is similar to telling the time of the day.
Associating the Days to Numbers
1 → Monday
Mathematical Systems
Telling Time
Telling the Day of the Week
Telling the day of the week is similar to telling the time of the day.
Associating the Days to Numbers
1 → Monday
2 → Tuesday
Mathematical Systems
Telling Time
Telling the Day of the Week
Telling the day of the week is similar to telling the time of the day.
Associating the Days to Numbers
1 → Monday
2 → Tuesday
3 → Wednesday
Mathematical Systems
Telling Time
Telling the Day of the Week
Telling the day of the week is similar to telling the time of the day.
Associating the Days to Numbers
1 → Monday
2 → Tuesday
3 → Wednesday
4 → Thursday
Mathematical Systems
Telling Time
Telling the Day of the Week
Telling the day of the week is similar to telling the time of the day.
Associating the Days to Numbers
1 → Monday
2 → Tuesday
3 → Wednesday
4 → Thursday
5 → Friday
Mathematical Systems
Telling Time
Telling the Day of the Week
Telling the day of the week is similar to telling the time of the day.
Associating the Days to Numbers
1 → Monday
2 → Tuesday
3 → Wednesday
4 → Thursday
5 → Friday
6 → Saturday
Mathematical Systems
Telling Time
Telling the Day of the Week
Telling the day of the week is similar to telling the time of the day.
Associating the Days to Numbers
1 → Monday
2 → Tuesday
3 → Wednesday
4 → Thursday
5 → Friday
6 → Saturday
7 → Sunday
Mathematical Systems
Telling Time
Telling the Day of the Week
Problem
What day will it be in 16 days if today is Wednesday?
Mathematical Systems
Telling Time
Telling the Day of the Week
Problem
What day will it be in 16 days if today is Wednesday?
Solution
We use to denote addition for the days of the week. (This is to
distinguish it from ⊕ for clock arithmetic.)
Mathematical Systems
Telling Time
Telling the Day of the Week
Problem
What day will it be in 16 days if today is Wednesday?
Solution
We use to denote addition for the days of the week. (This is to
distinguish it from ⊕ for clock arithmetic.)
3 16
Mathematical Systems
Telling Time
Telling the Day of the Week
Problem
What day will it be in 16 days if today is Wednesday?
Solution
We use to denote addition for the days of the week. (This is to
distinguish it from ⊕ for clock arithmetic.)
3 16 = 5
Mathematical Systems
Telling Time
Telling the Day of the Week
Problem
What day will it be in 16 days if today is Wednesday?
Solution
We use to denote addition for the days of the week. (This is to
distinguish it from ⊕ for clock arithmetic.)
3 16 = 5
Recall: Congruence
Congruence Modulo n
Two integers a and b are said to be congruent modulo n, where
n is a natural number, if a−b
n is an integer. In this case, we write
a ≡ b (mod n) The number n is called the modulus. The
statement a ≡ b (mod n) is called a congruence.
Mathematical Systems
Telling Time
Telling the Day of the Week
Recall: Congruence
Congruence Modulo n
Two integers a and b are said to be congruent modulo n, where
n is a natural number, if a−b
n is an integer. In this case, we write
a ≡ b (mod n) The number n is called the modulus. The
statement a ≡ b (mod n) is called a congruence.
7 + 8 = 15
Mathematical Systems
Telling Time
Telling the Day of the Week
Recall: Congruence
Congruence Modulo n
Two integers a and b are said to be congruent modulo n, where
n is a natural number, if a−b
n is an integer. In this case, we write
a ≡ b (mod n) The number n is called the modulus. The
statement a ≡ b (mod n) is called a congruence.
7 + 8 = 15
Recall: Congruence
Congruence Modulo n
Two integers a and b are said to be congruent modulo n, where
n is a natural number, if a−b
n is an integer. In this case, we write
a ≡ b (mod n) The number n is called the modulus. The
statement a ≡ b (mod n) is called a congruence.
7 + 8 = 15
Problem
Suppose today is Friday. What day will it be 16 days after Friday?
Mathematical Systems
Telling Time
Telling the Day of the Week
Problem
Suppose today is Friday. What day will it be 16 days after Friday?
Solution
We observe that one week has 7 days.
Mathematical Systems
Telling Time
Telling the Day of the Week
Problem
Suppose today is Friday. What day will it be 16 days after Friday?
Solution
We observe that one week has 7 days.
Fourteen days after Friday will still be Friday.
Mathematical Systems
Telling Time
Telling the Day of the Week
Problem
Suppose today is Friday. What day will it be 16 days after Friday?
Solution
We observe that one week has 7 days.
Fourteen days after Friday will still be Friday.
Hence, 16 days after Friday is a Sunday.
Mathematical Systems
Telling Time
Telling the Day of the Week
Problem
Suppose today is Friday. What day will it be 16 days after Friday?
Solution
We observe that one week has 7 days.
Fourteen days after Friday will still be Friday.
Hence, 16 days after Friday is a Sunday.
Using modular arithmetic,
16 ≡ 2 (mod 7)
Mathematical Systems
Telling Time
Telling the Day of the Week
Problem
Suppose today is Friday. What day will it be 16 days after Friday?
Solution
We observe that one week has 7 days.
Fourteen days after Friday will still be Friday.
Hence, 16 days after Friday is a Sunday.
Using modular arithmetic,
16 ≡ 2 (mod 7)
Example
Problem
June 12, 2017 was a Monday. What day will it be on June 12,
2022?
Mathematical Systems
Telling Time
Telling the Day of the Week
Example
Problem
June 12, 2017 was a Monday. What day will it be on June 12,
2022?
Solution
There are 5 years in between the two dates.
(Note: 2020 is a leap year )
Mathematical Systems
Telling Time
Telling the Day of the Week
Example
Problem
June 12, 2017 was a Monday. What day will it be on June 12,
2022?
Solution
There are 5 years in between the two dates.
(Note: 2020 is a leap year )
The total number of days between the two days is
365 · 5 + 1
Mathematical Systems
Telling Time
Telling the Day of the Week
Example
Problem
June 12, 2017 was a Monday. What day will it be on June 12,
2022?
Solution
There are 5 years in between the two dates.
(Note: 2020 is a leap year )
The total number of days between the two days is
365 · 5 + 1 = 1826
Mathematical Systems
Telling Time
Telling the Day of the Week
Example
Problem
June 12, 2017 was a Monday. What day will it be on June 12,
2022?
Solution
There are 5 years in between the two dates.
(Note: 2020 is a leap year )
The total number of days between the two days is
365 · 5 + 1 = 1826
1826 ÷ 7
Mathematical Systems
Telling Time
Telling the Day of the Week
Example
Problem
June 12, 2017 was a Monday. What day will it be on June 12,
2022?
Solution
There are 5 years in between the two dates.
(Note: 2020 is a leap year )
The total number of days between the two days is
365 · 5 + 1 = 1826
1826 ÷ 7 = 260
Mathematical Systems
Telling Time
Telling the Day of the Week
Example
Problem
June 12, 2017 was a Monday. What day will it be on June 12,
2022?
Solution
There are 5 years in between the two dates.
(Note: 2020 is a leap year )
The total number of days between the two days is
365 · 5 + 1 = 1826
Example
Problem
June 12, 2017 was a Monday. What day will it be on June 12,
2022?
Solution
There are 5 years in between the two dates.
(Note: 2020 is a leap year )
The total number of days between the two days is
365 · 5 + 1 = 1826
Example
Problem
June 12, 2017 was a Monday. What day will it be on June 12,
2022?
Solution
There are 5 years in between the two dates.
(Note: 2020 is a leap year )
The total number of days between the two days is
365 · 5 + 1 = 1826
Problem
If it is now 10:45 a.m., what time will it be in 143,999,999,995
minutes from now?
Mathematical Systems
Telling Time
Telling the Day of the Week
Problem
If it is now 10:45 a.m., what time will it be in 143,999,999,995
minutes from now?
Solution
By congruence,
Problem
If it is now 10:45 a.m., what time will it be in 143,999,999,995
minutes from now?
Solution
By congruence,
Problem
If it is now 10:45 a.m., what time will it be in 143,999,999,995
minutes from now?
Solution
By congruence,
Problem
If it is now 10:45 a.m., what time will it be in 143,999,999,995
minutes from now?
Solution
By congruence,
Addition Modulo n
Rule
Given a ≡ b (mod n) and c ≡ d (mod n), a + c ≡ b + d (mod n).
Mathematical Systems
Arithmetic Operations Modulo n
Addition Modulo n
Rule
Given a ≡ b (mod n) and c ≡ d (mod n), a + c ≡ b + d (mod n).
Problem
Evaluate (23 + 38) (mod 12).
Mathematical Systems
Arithmetic Operations Modulo n
Addition Modulo n
Rule
Given a ≡ b (mod n) and c ≡ d (mod n), a + c ≡ b + d (mod n).
Problem
Evaluate (23 + 38) (mod 12).
Mathematical Systems
Arithmetic Operations Modulo n
Solution 1
Mathematical Systems
Arithmetic Operations Modulo n
Solution 1
Add 23 and 38.
Mathematical Systems
Arithmetic Operations Modulo n
Solution 1
Add 23 and 38. 23 + 38 = 61.
Mathematical Systems
Arithmetic Operations Modulo n
Solution 1
Add 23 and 38. 23 + 38 = 61.
Divide the sum by 12 and get the remainder.
Mathematical Systems
Arithmetic Operations Modulo n
Solution 1
Add 23 and 38. 23 + 38 = 61.
Divide the sum by 12 and get the remainder.
61 = 5(12) + 1
Mathematical Systems
Arithmetic Operations Modulo n
Solution 1
Add 23 and 38. 23 + 38 = 61.
Divide the sum by 12 and get the remainder.
61 = 5(12) + 1
Hence, (23 + 38) (mod 12) = 1.
Mathematical Systems
Arithmetic Operations Modulo n
Solution 1
Add 23 and 38. 23 + 38 = 61.
Divide the sum by 12 and get the remainder.
61 = 5(12) + 1
Hence, (23 + 38) (mod 12) = 1.
Solution 2
We get the remainder when 23 and 38 are divided by 12.
Mathematical Systems
Arithmetic Operations Modulo n
Solution 1
Add 23 and 38. 23 + 38 = 61.
Divide the sum by 12 and get the remainder.
61 = 5(12) + 1
Hence, (23 + 38) (mod 12) = 1.
Solution 2
We get the remainder when 23 and 38 are divided by 12.
Solution 1
Add 23 and 38. 23 + 38 = 61.
Divide the sum by 12 and get the remainder.
61 = 5(12) + 1
Hence, (23 + 38) (mod 12) = 1.
Solution 2
We get the remainder when 23 and 38 are divided by 12.
Solution 1
Add 23 and 38. 23 + 38 = 61.
Divide the sum by 12 and get the remainder.
61 = 5(12) + 1
Hence, (23 + 38) (mod 12) = 1.
Solution 2
We get the remainder when 23 and 38 are divided by 12.
Solution 1
Add 23 and 38. 23 + 38 = 61.
Divide the sum by 12 and get the remainder.
61 = 5(12) + 1
Hence, (23 + 38) (mod 12) = 1.
Solution 2
We get the remainder when 23 and 38 are divided by 12.
Subtraction Modulo n
Problem
Evaluate (33 − 16) (mod 6).
Mathematical Systems
Arithmetic Operations Modulo n
Subtraction Modulo n
Problem
Evaluate (33 − 16) (mod 6).
Solution 1
Mathematical Systems
Arithmetic Operations Modulo n
Subtraction Modulo n
Problem
Evaluate (33 − 16) (mod 6).
Solution 1
Subtract 33 and 16.
Mathematical Systems
Arithmetic Operations Modulo n
Subtraction Modulo n
Problem
Evaluate (33 − 16) (mod 6).
Solution 1
Subtract 33 and 16. 33 − 16 = 17.
Mathematical Systems
Arithmetic Operations Modulo n
Subtraction Modulo n
Problem
Evaluate (33 − 16) (mod 6).
Solution 1
Subtract 33 and 16. 33 − 16 = 17.
Divide the sum by 6 and get the remainder.
Mathematical Systems
Arithmetic Operations Modulo n
Subtraction Modulo n
Problem
Evaluate (33 − 16) (mod 6).
Solution 1
Subtract 33 and 16. 33 − 16 = 17.
Divide the sum by 6 and get the remainder.
17 = 2(6) + 5
Mathematical Systems
Arithmetic Operations Modulo n
Subtraction Modulo n
Problem
Evaluate (33 − 16) (mod 6).
Solution 1
Subtract 33 and 16. 33 − 16 = 17.
Divide the sum by 6 and get the remainder.
17 = 2(6) + 5
Hence, (33 − 16) (mod 6) = 5.
Mathematical Systems
Arithmetic Operations Modulo n
Subtraction Modulo n
Problem
Evaluate (33 − 16) (mod 6).
Solution 1
Subtract 33 and 16. 33 − 16 = 17.
Divide the sum by 6 and get the remainder.
17 = 2(6) + 5
Hence, (33 − 16) (mod 6) = 5.
Mathematical Systems
Arithmetic Operations Modulo n
Solution 2
We get the remainder when 33 and 16 are divided by 6.
Mathematical Systems
Arithmetic Operations Modulo n
Solution 2
We get the remainder when 33 and 16 are divided by 6.
Solution 2
We get the remainder when 33 and 16 are divided by 6.
Solution 2
We get the remainder when 33 and 16 are divided by 6.
33 − 16 ≡ 3 − 4 (mod 6) → 17 ≡ −1
Mathematical Systems
Arithmetic Operations Modulo n
Solution 2
We get the remainder when 33 and 16 are divided by 6.
33 − 16 ≡ 3 − 4 (mod 6) → 17 ≡ −1 ≡ 5 (mod 6)
Mathematical Systems
Arithmetic Operations Modulo n
Solution 2
We get the remainder when 33 and 16 are divided by 6.
33 − 16 ≡ 3 − 4 (mod 6) → 17 ≡ −1 ≡ 5 (mod 6)
Problem
Evaluate 14 − 27 (mod 5)
Mathematical Systems
Arithmetic Operations Modulo n
Problem
Evaluate 14 − 27 (mod 5)
Solution
Subtract 14 − 27 = −13.
Mathematical Systems
Arithmetic Operations Modulo n
Problem
Evaluate 14 − 27 (mod 5)
Solution
Subtract 14 − 27 = −13.
Since the answer is negative, we find x such that −13 ≡ x
(mod 5).
Mathematical Systems
Arithmetic Operations Modulo n
Problem
Evaluate 14 − 27 (mod 5)
Solution
Subtract 14 − 27 = −13.
Since the answer is negative, we find x such that −13 ≡ x
(mod 5).
Recall that the congruence is true if −13−x
5 is an integer.
Mathematical Systems
Arithmetic Operations Modulo n
Problem
Evaluate 14 − 27 (mod 5)
Solution
Subtract 14 − 27 = −13.
Since the answer is negative, we find x such that −13 ≡ x
(mod 5).
Recall that the congruence is true if −13−x
5 is an integer.
If x = 2, −13−2
5 = −3.
Mathematical Systems
Arithmetic Operations Modulo n
Problem
Evaluate 14 − 27 (mod 5)
Solution
Subtract 14 − 27 = −13.
Since the answer is negative, we find x such that −13 ≡ x
(mod 5).
Recall that the congruence is true if −13−x
5 is an integer.
If x = 2, −13−2
5 = −3.
Thus, 14 − 27 ≡ 2 (mod 5).
Mathematical Systems
Arithmetic Operations Modulo n
Multiplication Modulo n
Rule
Given a ≡ b (mod n) and c ≡ d (mod n), ac ≡ bd (mod n).
Mathematical Systems
Arithmetic Operations Modulo n
Multiplication Modulo n
Rule
Given a ≡ b (mod n) and c ≡ d (mod n), ac ≡ bd (mod n).
Problem
Evaluate (15)(23) (mod 11).
Mathematical Systems
Arithmetic Operations Modulo n
Solution 1
Find the product of (15)(23) = 345
Mathematical Systems
Arithmetic Operations Modulo n
Solution 1
Find the product of (15)(23) = 345
Divide the product by 11.
345 = 31(11) + 4
Mathematical Systems
Arithmetic Operations Modulo n
Solution 1
Find the product of (15)(23) = 345
Divide the product by 11.
345 = 31(11) + 4
The remainder is 4.
Mathematical Systems
Arithmetic Operations Modulo n
Solution 1
Find the product of (15)(23) = 345
Divide the product by 11.
345 = 31(11) + 4
The remainder is 4.
Solution 2
Find the remainder when 15 and 23 are divided by 11.
Solution 1
Find the product of (15)(23) = 345
Divide the product by 11.
345 = 31(11) + 4
The remainder is 4.
Solution 2
Find the remainder when 15 and 23 are divided by 11.
Solution 1
Find the product of (15)(23) = 345
Divide the product by 11.
345 = 31(11) + 4
The remainder is 4.
Solution 2
Find the remainder when 15 and 23 are divided by 11.
Solution 1
Find the product of (15)(23) = 345
Divide the product by 11.
345 = 31(11) + 4
The remainder is 4.
Solution 2
Find the remainder when 15 and 23 are divided by 11.
The answer is 4.
Mathematical Systems
Solving Congruence Equations
Problem
Find all solutions to 3x + 5 ≡ 3 (mod 4).
Mathematical Systems
Solving Congruence Equations
Problem
Find all solutions to 3x + 5 ≡ 3 (mod 4).
Solution
We must find all values of x that will satisfy the given congruence.
Mathematical Systems
Solving Congruence Equations
Problem
Find all solutions to 3x + 5 ≡ 3 (mod 4).
Solution
We must find all values of x that will satisfy the given congruence.
3(0) + 5 6≡ 3 (mod 4)
Mathematical Systems
Solving Congruence Equations
Problem
Find all solutions to 3x + 5 ≡ 3 (mod 4).
Solution
We must find all values of x that will satisfy the given congruence.
3(0) + 5 6≡ 3 (mod 4)
3(1) + 5 6≡ 3 (mod 4)
Mathematical Systems
Solving Congruence Equations
Problem
Find all solutions to 3x + 5 ≡ 3 (mod 4).
Solution
We must find all values of x that will satisfy the given congruence.
3(0) + 5 6≡ 3 (mod 4)
3(1) + 5 6≡ 3 (mod 4)
3(2) + 5 ≡ 3 (mod 4)
Mathematical Systems
Solving Congruence Equations
Problem
Find all solutions to 3x + 5 ≡ 3 (mod 4).
Solution
We must find all values of x that will satisfy the given congruence.
3(0) + 5 6≡ 3 (mod 4)
3(1) + 5 6≡ 3 (mod 4)
3(2) + 5 ≡ 3 (mod 4) 2 is a solution.
Mathematical Systems
Solving Congruence Equations
Problem
Find all solutions to 3x + 5 ≡ 3 (mod 4).
Solution
We must find all values of x that will satisfy the given congruence.
3(0) + 5 6≡ 3 (mod 4)
3(1) + 5 6≡ 3 (mod 4)
3(2) + 5 ≡ 3 (mod 4) 2 is a solution.
3(3) + 5 6≡ 3 (mod 4)
Mathematical Systems
Solving Congruence Equations
Problem
Find all solutions to 3x + 5 ≡ 3 (mod 4).
Solution
We must find all values of x that will satisfy the given congruence.
3(0) + 5 6≡ 3 (mod 4)
3(1) + 5 6≡ 3 (mod 4)
3(2) + 5 ≡ 3 (mod 4) 2 is a solution.
3(3) + 5 6≡ 3 (mod 4)
3(4) + 5 6≡ 3 (mod 4)
Mathematical Systems
Solving Congruence Equations
Problem
Find all solutions to 3x + 5 ≡ 3 (mod 4).
Solution
We must find all values of x that will satisfy the given congruence.
3(0) + 5 6≡ 3 (mod 4)
3(1) + 5 6≡ 3 (mod 4)
3(2) + 5 ≡ 3 (mod 4) 2 is a solution.
3(3) + 5 6≡ 3 (mod 4)
3(4) + 5 6≡ 3 (mod 4)
3(5) + 5 6≡ 3 (mod 4)
Mathematical Systems
Solving Congruence Equations
Problem
Find all solutions to 3x + 5 ≡ 3 (mod 4).
Solution
We must find all values of x that will satisfy the given congruence.
3(0) + 5 6≡ 3 (mod 4)
3(1) + 5 6≡ 3 (mod 4)
3(2) + 5 ≡ 3 (mod 4) 2 is a solution.
3(3) + 5 6≡ 3 (mod 4)
3(4) + 5 6≡ 3 (mod 4)
3(5) + 5 6≡ 3 (mod 4)
3(6) + 5 ≡ 3 (mod 4)
Mathematical Systems
Solving Congruence Equations
Problem
Find all solutions to 3x + 5 ≡ 3 (mod 4).
Solution
We must find all values of x that will satisfy the given congruence.
3(0) + 5 6≡ 3 (mod 4)
3(1) + 5 6≡ 3 (mod 4)
3(2) + 5 ≡ 3 (mod 4) 2 is a solution.
3(3) + 5 6≡ 3 (mod 4)
3(4) + 5 6≡ 3 (mod 4)
3(5) + 5 6≡ 3 (mod 4)
3(6) + 5 ≡ 3 (mod 4) 6 is a solution.
If we continue, we find that 10 and 14 are also solutions.
Mathematical Systems
Solving Congruence Equations
Problem
Find all solutions to 3x + 5 ≡ 3 (mod 4).
Solution
We must find all values of x that will satisfy the given congruence.
3(0) + 5 6≡ 3 (mod 4)
3(1) + 5 6≡ 3 (mod 4)
3(2) + 5 ≡ 3 (mod 4) 2 is a solution.
3(3) + 5 6≡ 3 (mod 4)
3(4) + 5 6≡ 3 (mod 4)
3(5) + 5 6≡ 3 (mod 4)
3(6) + 5 ≡ 3 (mod 4) 6 is a solution.
If we continue, we find that 10 and 14 are also solutions.
Hence the solutions are x = 2, 6, 10, 14, ...
Mathematical Systems
Solving Congruence Equations
General Rule
Once a solution is determined, additional solutions can be found by
adding or subtracting the modulus to the original solution.
Mathematical Systems
Solving Congruence Equations
General Rule
Once a solution is determined, additional solutions can be found by
adding or subtracting the modulus to the original solution.
Note: You only need to look for solutions from 0 until n (the
modulus). Then just add or subtract from there.
Mathematical Systems
Solving Congruence Equations
Problem
Find the solutions to the congruence 5x + 1 ≡ 3 (mod 5).
Mathematical Systems
Additive and Multiplicative Inverses in Modular Arithmetic
Recall
Additive Inverse
If the sum of two numbers is zero, then the numbers are additive
inverses of each other.
Mathematical Systems
Additive and Multiplicative Inverses in Modular Arithmetic
Recall
Additive Inverse
If the sum of two numbers is zero, then the numbers are additive
inverses of each other.
Multiplicative Inverse
If the product of two numbers is one, then the numbers are
multiplicative inverses of each other.
Mathematical Systems
Additive and Multiplicative Inverses in Modular Arithmetic
Recall
Additive Inverse
If the sum of two numbers is zero, then the numbers are additive
inverses of each other.
Multiplicative Inverse
If the product of two numbers is one, then the numbers are
multiplicative inverses of each other.
The same concept is used in modular arithmetic.
Mathematical Systems
Additive and Multiplicative Inverses in Modular Arithmetic
Examples
Problem
What is the additive inverse of 3 in modulo 8 arithmetic?
Mathematical Systems
Additive and Multiplicative Inverses in Modular Arithmetic
Examples
Problem
What is the additive inverse of 3 in modulo 8 arithmetic?
Problem
What is the multiplicative inverse of 3 in modulo 8 arithmetic?
Mathematical Systems
Additive and Multiplicative Inverses in Modular Arithmetic
Examples
Problem
What is the additive inverse of 3 in modulo 8 arithmetic?
Problem
What is the multiplicative inverse of 3 in modulo 8 arithmetic?
Problem
What is the additive inverse of 7 in modulo 16 arithmetic?
Mathematical Systems
Additive and Multiplicative Inverses in Modular Arithmetic
Examples
Problem
What is the additive inverse of 3 in modulo 8 arithmetic?
Problem
What is the multiplicative inverse of 3 in modulo 8 arithmetic?
Problem
What is the additive inverse of 7 in modulo 16 arithmetic?
Problem
What is the multiplicative inverse of 2 in modulo 7 arithmetic?
Mathematical Systems
Additive and Multiplicative Inverses in Modular Arithmetic
Exercises
1
Answer on 2
crosswise sheet