Mathematical Systems
Mathematical Systems
LY
ON
E
US
Mathematical Systems
M
RO
SR
AS
CL
R
FO
Mathematical Systems
Clock Arithmetic and Day-of-the-Week Arithmetic
LY
ON
Determining the time and day-of-the week. For 1-3,
disregarding A.M and P.M, determine the time after or before
E
US
the given time.
M
Answer
RO
1. Determine the time 12 hours after 9 o’clock.
2. Determine the time 24 hours before 4 o’clock.
3. Determine the SR
time 36 hours before 4 o’clock.
AS
4. Determine the day 9 days after Wednesday.
5. Determine the day 12 days after Friday.
CL
LY
Clock Arithmetic
ON
E
Most clocks have the 12-hour design. To differentiate the time
US
before noon and the time after noon, we use A.M and P.M.,
respectively. Thus, when we say 9:00 A.M., it means 9 hours
M
RO
after 12:00 midnight and when we say 9:00 P.M., it means 9
hours after 12:00 noon. In both cases, when 12:00 is reached on
SR
the clock, we begin again by 1. For example, when the time is
AS
2:00 A.M., it means 2 hours after 12:00 midnight.
CL
subtraction.
Mathematical Systems
Clock Arithmetic and Day-of-the-Week Arithmetic
LY
Day-of-the-week-Arithmetic
ON
E
US
Similar to solving the 12-hour clock are problems involving
day-of-the-week arithmetic. In this case, we assign a number to
M
each day:
RO
SR
Monday = 1, Tuesday = 2, Wednesday = 3, Thursday = 4,
Friday = 5, Saturday = 6, Sunday = 7
AS
CL
LY
ON
E
US
Example (1)
M
Determine the time 9 hours after 1 o’clock
RO
SR
Solution. Because we did not pass the 12 o’clock, we add 9
and 1. Thus, the time is 10 o’clock. That is, 9 ⊕ 1 = 10.
AS
CL
R
FO
Mathematical Systems
Clock Arithmetic and Day-of-the-Week Arithmetic
LY
ON
E
Example (2)
US
Determine the time 10 hours after 8 o’clock.
M
RO
Solution. Since we passed 12 o’clock, we begin again with 1.
SR
Therefore, the time is 6 o’clock.AS
Another Solution. Note that 10 + 8 = 18 and when 18 is
CL
LY
ON
Example (3)
E
US
If the time now is 7 o’clock, then 4 hours ago was 3 o’clock.
That is, 7 ⊖ 4 = 3.
M
RO
Example (4)
SR
AS
If the time now is 4 o’clock, then 8 hours ago the time was 8
CL
LY
ON
E
US
Example (5)
8 days after Friday is Saturday
M
RO
SR
Solution. Note that 5 + 8 = 13 and when 13 is divided by 7
the remainder is 6, the number associated with Saturday. Thus,
AS
5 ⊞ 8 = 6.
CL
R
FO
Mathematical Systems
Clock Arithmetic and Day-of-the-Week Arithmetic
LY
ON
E
US
Example (6)
M
20 days after Tuesday is Monday
RO
SR
Solution. Note that 20 + 2 = 22 and when 22 is divided by 7,
AS
the answer is 1. Thus, 20 days after Tuesday is Monday.
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
Congruence
ON
E
US
Let a and b be integers. Then a and b are said to be congruent
modulo n, if
M
a−b
RO
is an integer,
n
SR
where n is a natural number. If a and b are said to be
AS
congruent modulo n, then we write
CL
a ≡ b mod n.
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
Example (1)
ON
Determine whether the congruence is true or not.
(a) 30 ≡ 8 mod 2
E
US
(b) 17 ≡ 3 mod 6
(c) 3 ≡ 28 mod 5
M
RO
Solution.
SR
AS
(a) Since (30 − 8)/2 = 11 and 11 is an integer, 30 ≡ 8 mod 2
is a true congruence.
CL
LY
Operations on Arithmetic Modulo n
ON
E
US
M
To solve problems involving addition modulo n, subtraction
RO
modulo n and multiplication modulo n, we perform first the
operation (addition, subtraction, multiplication) and then
SR
divide the result by the modulus. The answer to the given
AS
problem is the remainder.
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
Example (2)
LY
ON
Evaluate (16 + 8) mod 12.
E
Solution. Note that 16 + 8 = 24 and 24 ÷ 12 is 2 remainder 0.
US
Thus, the answer is 0. That is,
M
(16 + 8) mod 12 = 0.
RO
Example (3) SR
AS
Evaluate (56+13) mod 4
CL
R
LY
ON
E
Example (4)
US
Evaluate (31 − 13) mod 5
M
RO
Solution. Since 31 − 13 = 18 and 18 divided by 5 is 3
SR
remainder 3, the answer is 3. That is,
AS
(31 − 13) mod 5 = 3.
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
Example (5)
ON
Evaluate (15 − 43) mod 7
E
US
Solution. Since 15 − 43 = −28 and −28 is a negative integer,
M
we must find x such that
RO
−28 ≡ x mod 7.
SR
Hence, we will find x so that
AS
−28 − x −(28 + x)
CL
=
7 7
R
FO
LY
−(28 + 0)
ON
If x = 0, = −4
7
−(28 + 1) 29
E
If x = 1, =−
7 7
US
−(28 + 2) 30
If x = 2, =−
M
7 7
−(28 + 3) 31
RO
If x = 3, =−
7 7
SR
−(28 + 4) 32
If x = 4, =−
7 7
AS
−(28 + 5) 33
If x = 5, =−
CL
7 7
−(28 + 6) 34
=−
R
If x = 6,
7 7
FO
LY
ON
E
US
Example (6)
Evaluate: (18 · 33) mod 14
M
RO
Solution. Multiplying 18 and 33, the result is 594. Divide 594
SR
by the modulus which is 14, the quotient is 42 and the
remainder is 6. Therefore, the answer is 6. Hence, (18 · 33)
AS
mod 14 = 6.
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
Congruence Equations
ON
E
US
M
In solving congruence equations, we find for whole numbers x
RO
for which the given congruence equation is true.
SR
Example (7) AS
Solve: 2x + 1 ≡ 4 mod 3
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
relation is true. We substitute x = 0, 1, 2, 3, . . . and so on until we get
ON
the solutions. Note that we always start with 0.
2(0) + 1 ≡ 4 mod 3
E
US
2(1) + 1 ̸≡ 4 mod 3
2(2) + 1 ̸≡ 4 mod 3
M
2(3) + 1 ≡ 4 mod 3
RO
2(4) + 1 ̸≡ 4 mod 3
SR
2(5) + 1 ̸≡ 4
AS mod 3
2(6) + 1 ≡ 4 mod 3
2(7) + 1 ̸≡ 4 mod 3
CL
2(8) + 1 ̸≡ 4 mod 3
R
FO
LY
ON
E
US
In general, if we already found a solution to the given
M
congruence equation, other solutions can be found by repeatedly
RO
adding the modulus of the given congruence equation. Hence,
the solutions in Example 7 are 0, 3, 6, 9, 12, 15, 18, . . . .
SR
AS
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
Additive Inverse in Modular Arithmetic
ON
E
US
M
RO
The sum of a number and its additive inverse equals the
SR
modulus. AS
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
ON
E
US
Example (9)
Find the additive inverse of 9 in mod 21 arithmetic.
M
RO
Solution. Since in mod 21 arithmetic, 9 + 12 = 21, it follows
SR
that 12 is the additive inverse of 9. Also, in mod 21
AS
arithmetic, the additive inverse of 12 is 9.
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
Multiplicative Inverse in Modular Arithmetic
ON
E
US
M
To find the multiplicative inverse of a mod m, solve the
RO
modular equation
SR
ax ≡ 1
AS mod m for x.
LY
Example (10)
ON
In mod 5 arithmetic, find the multiplicative inverse of 3.
E
US
Solution. We solve the equation 3x ≡ 1 mod 5 by
substituting natural numbers less than the modulus. Thus,
M
RO
3(1) ̸≡ 1 mod 5
3(2) ≡ 1
SR
mod 5
3(3) ̸≡ 1 mod 5
AS
3(4) ̸≡ 1 mod 5
CL
R
FO
LY
ON
E
US
We note that the multiplicative inverse in modulo n arithmetic
M
does not always exist. For example in mod 26 arithmetic, 4 has
RO
no multiplicative inverse since there is no natural number (less
than 26) that satisfies the equation 4x ≡ 1 mod 26.
SR
AS
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
Example (11)
ON
September 8, 1987, was a Tuesday. What day of the week is
September 8, 1993?
E
US
Solution. Note that there are 6 years between the two dates.
Each year has 365 days except 1988 and 1992, which has extra
M
day because they are leap years. Thus, the total number of days
RO
between the two dates is
SR
6(365) + 2 = 2, 192.
AS
Since 2192 ÷ 7 = 313 remainder 1, it follows that
CL
2192 ≡ 1 mod 7.
R
Any multiple of 7 past a given day will be the same day of the
FO
LY
Example (12)
ON
Disregarding A.M. or P.M., if it is 7 o’clock now what time was
E
it 63 hours ago?
US
Solution. To solve this problem, we solve (7 − 63) mod 12.
M
Since 7 − 63 = −56 and −56 is negative, we solve for x in
RO
−56 ≡ x mod 12.
SR
AS
−(56 + x)
Thus, we find x such that is an integer by
12
CL
LY
Computing the Day of the Week
ON
E
US
One important application of modular arithmetic is computing
the day of the week for any date on the Gregorian Calendar
M
using Zeller’s congruence. Zeller’s congruence involves a
RO
function called the floor function. In the floor function, when
determining the quotient, we disregard the remainder. Some
SR
values of floor function are the following:
AS
5 1 20 jπ k
CL
= 1, = 0, = 5, = 3.
4 2 5 1
R
FO
Mathematical Systems
Arithmetic Modulo n
Zeller’s Congruence:
LY
j k j k
13m − 1 y c
ON
x≡ + + + d + y − 2c mod 7
5 4 4
E
where
US
d - is the day of the month
M
m - is the month using the following designation: March = 1,
RO
April = 2, May = 3, June = 4, July = 5, August = 6,
September = 7, October = 8, November = 9, December =
SR
10, January = 11 and February = 12
AS
y - is the last two digits of the year if the month is March
through December; if the Month is January or February, y
CL
LY
ON
Example (13)
E
Determine the day of the week on June 12, 1898.
US
M
Solution. Since d = 12, m = 4, y = 98, c = 18 we have
RO
13(4) − 1 98 18
x≡
5
+
4
+
SR4
+ 12 + 98 − 2(18) mod 7
AS
≡ (10 + 24 + 4 + 12 + 98 − 36) mod 7
CL
≡ 112 mod 7.
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
Example (14)
ON
Determine the day of the week on January 1, 1701.
E
US
Solution. Note that d = 1, m = 11, y = 1 − 1 = 0 (since
January), c = 17. Thus,
M
RO
13(11) − 1 0 17
x≡ + + + 1 + 0 − 2(17) mod 7
5 4 4
SR
≡ (28 + 0 + 4 + 1 − 0 − 34) mod 7
AS
≡ −1 mod 7.
CL
x − (−1)
FO
LY
International Standard Book Number (ISBN)
ON
E
International Standard Book Number (ISBN) is a unique
US
13-digit number used in books for them to be identified and
M
classified correctly. The first three digits of an ISBN is 978, the
RO
next digit indicates the country of the publisher (0, and
sometimes 1, for books written in English), the next two to
SR
seven digits indicates the publisher, the next group of digits
AS
indicates the title of the book, and the last digit (the 13th one)
CL
correctly.
FO
Mathematical Systems
Arithmetic Modulo n
LY
ON
E
US
Check Digit Formula for the ISBN
M
d13 = 10−(d1 +3d2 +d3 +3d4 +d5 +3d6 +d7 +3d8 +d9 +3d10 +d11 +3d12 ) mod 10
RO
SR
If d13 = 10, then the check digit is 0.
AS
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
Example (15)
ON
Determine the ISBN check digit for the book “Harry Potter and
the Deathly Hallows” by J.K. Rowling. The first 12 digits of
E
the ISBN are 978-0-5455-8300-?
US
Solution. From the Formula,
M
RO
d13 ≡ 10 − (9 + 3(7) + 8 + 3(0) + 5 + 3(4) + 5 + 3(5) + 8
+ 3(3) + 0 + 3(0)) mod 10
≡ 10 − 92 mod 10 SR
AS
≡ −82 mod 10.
CL
Solving the equation d13 ≡ −82 mod 10, we find d13 such that
R
LY
Example (16)
ON
A librarian typed the ISBN for the book “Linear Algebra with
Applications” by Steven S. Leon incorrectly, where he/she
E
US
interchanged 5 and 9.
Correct ISBN: 978-1-292-07059-9
M
Incorrect ISBN: 978-1-292-07095-9
RO
Solution. Calculating the ISBN that was typed by the
librarian, we get
SR
AS
d13 ≡ 10 − (9 + 3(7) + 8 + 3(1) + 2 + 3(9) + 2 + 3(0) + 7
CL
≡ 10 − 103 mod 10
FO
LY
ON
E
US
Solving the congruence equation d13 ≡ −93 mod 10, we get
M
d13 = 7. Thus, the check digit is 7, which is incorrect because
RO
the correct check digit is 9. Thus, the librarian will know that
he/she typed the ISBN incorrectly.
SR
AS
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
Universal Product Code (UPC)
ON
E
US
Another important coding scheme is the Universal Product
M
Code (UPC). UPC consists of 12 numerical digits and is unique
RO
for every product. It is useful when the store decided to have a
SR
sale of their products because they don’t need to change the
price of each product manually, they only need to update the
AS
price of the products on their computer using the UPC.
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
ON
E
US
Check Digit Formula for UPC:
M
d12 = 10−(3d1 +d2 +3d3 +d4 +3d5 +d6 +3d7 +d8 +3d9 +d10 +3d11 ) mod 10
RO
SR
If d12 = 10, then the check digit is 0.
AS
CL
R
FO
Mathematical Systems
Arithmetic Modulo n
LY
Example (17)
ON
Find the check digit for Iphone X with 64GB memory and with
E
color silver. The first 11 numerical digits are 6-61094-33711-?
US
Solution. From the formula,
M
RO
d12 ≡ 10 − (3(6) + 6 + 3(1) + 0 + 3(9) + 4 + 3(3) + 3 + 3(7) + 1 + 3(1)) mod
≡ 10 − 95 mod 10
≡ −85 mod 10 SR
AS
Solving the congruence equation d12 ≡ −85 mod 10 , that is we find
CL
the check digit of Iphone X with 64GB memory and with color silver
is 5.
Mathematical Systems
Arithmetic Modulo n
LY
Credit Card Numbers
ON
Another application of modular arithmetic is on credit card
E
numbers. A credit card number has usually 13 to 16 digits. The
US
credit card number’s prefix, called the Bank Identification
Number (BIN) is used to determine the bank where the credit
M
card number belong. Bank Identification Number are usually
RO
the first digits of the credit card number. Table below shows
SR
the prefixes used by known card issuers.
AS
Credit Card Issuer Prefix Number of Digits
CL
Master Card 51 to 55 16
Visa 4 13 or 16
R
American Express 34 or 37 15
FO
Discover 6011 16
Mathematical Systems
Arithmetic Modulo n
LY
To determine whether the credit card number is valid or not
ON
valid, the Luhn algorithm is used. The procedure for Luhn
algorithm is the following:
E
US
1 Beginning with the next-to-last digit (the last digit is the
check digit) and reading from right to left, double every
M
other digit.
RO
2 If the digit becomes a two-digit number after being
SR
doubled, treat the number as two individual digits.
AS
3 Find the sum of the new list of digits; the final sum must
equal 0 mod 10.
CL
Thus, if the final sum is equal 0 mod 10, then the credit card
R
LY
Example (18)
ON
Determine whether 5365 1234 1234 1234 is a valid credit card
number.
E
US
Solution. Highlight every other digit, beginning with the
M
next-to-last digit and reading from right to left.
RO
5365123412341234
SR
Next double each of the highlighted digits.
AS
10 3 12 5 2 2 6 4 2 2 6 4 2 2 6 4
CL
single digits.
FO
(1+0)+3+(1+2)+5+2+2+6+4+2+2+6+4+2+2+6+4 = 54
LY
Example (19)
ON
Determine whether 4537 5677 0035 5540 is a valid credit card
number.
E
US
Solution. Highlight every other digit, beginning with the
next-to-last digit and reading from right to left.
M
RO
4537567700355540
SR
Next double each of the highlighted digits.
AS
8 5 6 7 10 6 14 7 0 0 6 5 10 5 8 0
CL
8+5+6+7+(1+0)+6+(1+4)+7+0+0+6+5+(1+0)+5+8+0 = 70.
LY
ON
Modular arithmetic also has an application in cryptology.
E
US
Cryptology is a study of codes. It is about writing and solving
secret codes. The message that is to be transformed into code is
M
called the plaintext. When the message is already transformed
RO
into a code, it is now called a ciphertext. The process of
transforming the message from plaintext to ciphertext is called
SR
encryption. The reverse process of encryption is called
AS
decryption. Thus, decryption is a process of transforming the
CL
LY
Example (1)
ON
Consider the plaintext and its corresponding ciphertext below.
Plaintext: MATHEMATICS IN THE MODERN WORLD
E
Ciphertext: RFYMJRFYNHX NS YMJ RTIJWS BTWQI
US
M
Observe that each letter in the plaintext was substituted by a
RO
letter that is 5 letters after that letter. This coding scheme is
called cyclical coding scheme.
SR
AS
A B C D E F G H I J K L M N O P Q
CL
↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕
F G H I J K L M N O P Q R S T U V
R
FO
R S T U V W X Y Z
↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕
W X Y Z A B C D E
Mathematical Systems
Cryptology
LY
ON
Example (2)
E
Using the coding scheme in Example 1, decrypt the following
US
message:
M
TSQNSJ HQFXX
RO
SR
AS
Solution: From the coding scheme in Example 1, we decode
the message as:
CL
ONLINE CLASS
R
FO
Mathematical Systems
Cryptology
LY
ON
Below is the numerical equivalents for letters in the English
E
alphabet:
US
M
A B C D E F G H I J K L M N O P
↕ ↕ ↕ ↕ ↕ ↕ ↕
RO
↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
Q R S T SRU V W X Y Z
AS
↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕ ↕
CL
17 18 19 20 21 22 23 24 25 0
R
FO
Mathematical Systems
Cryptology
LY
Suppose that in transforming the plaintext message into a
ON
ciphertext message, we shift m positions, then the
corresponding letter in the ciphertext is given by
E
US
c ≡ (p + m) mod 26
M
RO
where
p – the numerical equivalent of the plaintext
SR
c – the numerical equivalent of the ciphertext
AS
Moreover, if we want to convert the ciphertext back to
plaintext, we use the congruence
CL
p ≡ (c + n) mod 26
R
FO
where n = 26 − m.
Mathematical Systems
Cryptology
LY
ON
Example (3)
Each letter in Example 1 was shifted 5 positions (m = 5) to the
E
right. To encrypt the letter M we have
US
c ≡ (p + m) mod 26
M
RO
c ≡ (13 + 5) mod 26
c ≡ 18 mod 26
SR
AS
We solve c ≡ 18 mod 26 by finding an integer from
0, 1, 2, 3, 4, . . . , 25 such that (c − 18)/26 is an integer. Observe
CL
M is coded as R.
Mathematical Systems
Cryptology
LY
ON
Now, suppose we want to decode the letter R using the
congruence
E
c ≡ (p + m) mod 26
US
Note that n = 26 − 5 = 21. Thus, the decoding congruence is
M
RO
p ≡ (c + 21) mod 26.
Hence, SR
AS
p ≡ (c + n) mod 26 ≡ (18 + 21) mod 26 ≡ 39 mod 26 ≡ 13.
CL
decoded as M.
FO
Mathematical Systems
Cryptology
LY
ON
E
US
Example (4)
M
Use cyclical alphabet coding scheme that shifts 8 positions to:
RO
a. Code: CORONA VIRUS DISEASE
b. Decode: EM PMIT
SRIA WVM
AS
CL
R
FO
Mathematical Systems
Cryptology
Solution.
LY
a. Using the formula with m = 8 we have
ON
C c ≡ (3 + 8) mod 26 ≡ 11 mod 26 ≡ 11 C is coded as K
E
O c ≡ (15 + 8) mod 26 ≡ 23 mod 26 ≡ 23 O is coded as W
US
R c ≡ (18 + 8) mod 26 ≡ 26 mod 26 ≡ 0 R is coded as Z
N c ≡ (14 + 8) mod 26 ≡ 22 mod 26 ≡ 22 N is coded as V
M
RO
A c ≡ (1 + 8) mod 26 ≡ 9 mod 26 ≡ 9 A is coded as I
V c ≡ (22 + 8) mod 26 ≡ 30 mod 26 ≡ 4 V is coded as D
I c ≡ (9 + 8) SR
mod 26 ≡ 17 mod 26 ≡ 17 I is coded as Q
AS
U c ≡ (21 + 8) mod 26 ≡ 29 mod 26 ≡ 3 U is coded as C
CL
LY
b. Since m = 8, n = 26 − 8 = 18, the ciphertext is decoded using
ON
the congruence
p ≡ (c + 18) mod 26
E
US
E p ≡ (5 + 18) mod 26 ≡ 23 mod 26 ≡ 23 E is decoded as W
M
M p ≡ (13 + 18) mod 26 ≡ 31 mod 26 ≡ 5 M is decoded as E
RO
P p ≡ (16 + 18) mod 26 ≡ 34 mod 26 ≡ 8 P is decoded as H
SR
I p ≡ (9 + 18) mod 26 ≡ 27 mod 26 ≡ 1 I is decoded as A
T p ≡ (20 + 18) mod 26 ≡ 38 mod 26 ≡ 12 T is decoded as L
AS
A p ≡ (1 + 18) mod 26 ≡ 19 mod 26 ≡ 19 A is decoded as S
CL
LY
Example (5)
ON
Use the congruence c ≡ (3p + 2) mod 26 to encode the message
BLUE SKY.
E
US
Solution. We substitute to p the numerical equivalent of the given
letter. Thus,
M
RO
B c ≡ (3(2) + 2) mod 26 ≡ 8 mod 26 ≡ 8 B is coded as H
L c ≡ (3(12) + 2) mod 26 ≡ 38 mod 26 ≡ 12 L is coded as L
U c ≡ (3(21) + 2) SR
mod 26 ≡ 65 mod 26 ≡ 13 U is coded as M
AS
E c ≡ (3(5) + 2) mod 26 ≡ 17 mod 26 ≡ 17 E is coded as Q
CL
LY
ON
If we want to decode a message that was encrypted using
E
c ≡ (ap + m) mod 26
US
we need the multiplicative inverses of the numbers from the
M
table below:
RO
SR
Table: Multiplicative inverse in c ≡ (ap + m) mod 26
AS
CL
Number 1 3 5 7 9 11 15 17 19 21 23 25
Inverse 1 9 21 15 3 19 7 23 11 5 17 25
R
FO
Mathematical Systems
Cryptology
LY
Note that
ON
0, 2, 4, 6, 8, 10, 12, 13, 14, 16, 18, 20, 22, 24
E
US
has no multiplicative inverse in modulo 26 since the congruence
M
equations
RO
0x ≡ 1 mod 26, 2x ≡ 1 mod 26, 4x ≡ 1 mod 26,
6x ≡ 1 mod 26, SR
8x ≡ 1 mod 26, 10x ≡ 1 mod 26,
AS
12x ≡ 1 mod 26, 13x ≡ 1 mod 26, 14x ≡ 1 mod 26,
CL
has no solution.
Mathematical Systems
Cryptology
Example (6)
LY
ON
Decode the word GULMJCUR using the congruence
c ≡ (3p + 2) mod 26.
E
Solution. Solve the congruence for p. Now,
US
c = 3p + 2
M
c − 2 = 3p
RO
9(c − 2) = 9(3p) (1)
SR
In the last equation above, we multiply both sides of the equation by
the multiplicative inverse of 3 in mod 26. Since 9(3) = 27 and 27 ≡ 1
AS
mod 26, it follows that in mod 26 arithmetic, the multiplicative
CL
LY
ON
Hence, we have
E
p ≡ [9(7 − 2)] mod 26 ≡ 45 mod 26 ≡ 19
US
G G is decoded as S
U p ≡ [9(21 − 2)] mod 26 ≡ 171 mod 26 ≡ 15 U is decoded as O
M
L p ≡ [9(12 − 2)] mod 26 ≡ 90 mod 26 ≡ 12 L is decoded as L
RO
M p ≡ [9(13 − 2)] mod 26 ≡ 99 mod 26 ≡ 21 M is decoded as U
SR
J p ≡ [9(10 − 2)] mod 26 ≡ 72 mod 26 ≡ 20 J is decoded as T
C p ≡ [9(3 − 2)] mod 26 ≡ 9 mod 26 ≡ 9 C is decoded as I
AS
R p ≡ [9(18 − 2)] mod 26 ≡ 144 mod 26 ≡ 14 R is decoded as N
CL
Example (7)
LY
ON
Decode the message HNYG ONQO using the congruence
E
US
Solution. Solve the congruence for p.
M
RO
c = 7p + 5
c − 5 = 7p
SR
15(c − 5) = 15(7p)
AS
we multiply both sides by 15 since 15(7) = 105 and 105 ≡ 1 mod 26.
CL
LY
ON
Hence, we have
E
US
H p ≡ [15(8 − 5)] mod 26 ≡ 45 mod 26 ≡ 19 H is decoded as S
N p ≡ [15(14 − 5)] mod 26 ≡ 135 mod 26 ≡ 5 N is decoded as E
M
Y p ≡ [15(25 − 5)] mod 26 ≡ 300 mod 26 ≡ 14 Y is decoded as N
RO
G p ≡ [15(7 − 5)] mod 26 ≡ 30 mod 26 ≡ 4 H is decoded as D
O p ≡ [15(15 − 5)]
SR
mod 26 ≡ 150 mod 26 ≡ 20 O is decoded as T
AS
Q p ≡ [15(17 − 5)] mod 26 ≡ 180 mod 26 ≡ 24 Q is decoded as X
CL
LY
ON
E
US
M
THANK YOU!!!
RO
SR
AS
CL
R
FO