ModularArithmetic Worksheets Answers PDF
ModularArithmetic Worksheets Answers PDF
ModularArithmetic Worksheets Answers PDF
4) If your birthday fell on a Sunday this year, what day will it fall on next year?
10) If a running track is 400 metres around, where will I be in relation to the
start after running 6 miles (approximately 9656 metres)?
11) I was facing North and then spun around through 945° clockwise. In what
direction was I facing at the end?
12) If I get on at the bottom of a fairground wheel and the wheel turns through
5000°, whereabouts on the wheel will I be?
In general:
a ≡ b (mod n) if a-b is a multiple of n.
Equivalently:
a ≡ b (mod n) if a and b have the same remainder when divided by n (remainder
modulo n).
When we work modulo n we replace all the numbers by their remainders modulo n, that
is: 0, 1, 2, …, n-1.
a) 31
b) 44
c) 75
d) 751
a) 34 – 15
b) 141 – 78
c) 519 – 444 + 37
a) 31 + 28 + 31 + 30
b) 38 x 4 + 360
c) 66 + 5 + 26
a) 177 ≡ 17 (mod 2)
c) 16 + 30 ≡ 2 (mod 2)
d) 16 + 30 ≡ 2 (mod 3)
a) 16 + 30 ≡ 2 (mod 12)
b) 67 x 73 ≡ 0 (mod 3)
c) 14 x 15 x 16 ≡ 6 (mod 3)
Remember:
• N is divisible by 9 if and only if the sum of its digits is divisible by 9.
• N is divisible by 3 if and only if the sum of its digits is divisible by 3.
• N is divisible by 11 if and only if the alternate sum of its digits is divisible by
11. Start from the right making the units digit positive.
4) The first and fourth digits of the number d63d2 are the same and the number
d63d2 is a multiple of 9. Which digit is represented by d?
5) A four-digit number was written on a piece of paper. The last two digits were
then blotted out (as shown). If the complete number is exactly divisible by
three, by four, and by five, what is the sum of the two missing digits?
8 6
Worksheet 4 - Divisibility 1
You don't have to finish these questions (these are hard
ones).
mod 1010 109 108 107 106 105 104 103 102 101 100
2 0 0 0 0 0 0 0 0 0 0 1
3 1 1 1 1 1 1 1 1 1 1 1
4 0 0 0 0 0 0 0 0 0 2 1
5 0 0 0 0 0 0 0 0 0 0 1
6 4 4 4 4 4 4 4 4 4 4 1
7 4 6 2 3 1 5 4 6 2 3 1
8 0 0 0 0 0 0 0 0 4 2 1
9 1 1 1 1 1 1 1 1 1 1 1
10 0 0 0 0 0 0 0 0 0 0 1
11 1 -1 1 -1 1 -1 1 -1 1 -1 1
12 4 4 4 4 4 4 4 4 4 10 1
a) Could you explain why looking at the last digit is enough for the divisibility
criteria by 2, 5 and 10?
1,000 ≡ –1 (mod 7)
1,000 ≡ –1 (mod 11)
1,000 ≡ –1 (mod 13)
Based on that table could you give divisibility criteria by 7, 11 and 13 that
work for numbers greater than 1,000?
Worksheet 4 - Divisibility 2
Worksheet 5
Powers
You are not allowed to use calculators in this section.
Example:
9 5 1 2 6 10
…2 , 2 , 2 2 4 2, 2, 2 …
3 7 11
12 8 4
…2 , 2 , 2 6 8 2, 2, 2 …
b) 25013
c) 451
Worksheet 5 - Powers 1
2) What is the last digit of:
a) 957
b) 972
c) 3210
d) 2360
b) …69770 by 5?
c) …584320 by 4?
d) …493184 by 4930?
Worksheet 5 - Powers 2
4) Given that the modulo 10 multiplication table is:
x 0 1 2 3 4 5 6 7 8 9
0 0 0 0 0 0 0 0 0 0 0
1 0 1 2 3 4 5 6 7 8 9
2 0 2 4 6 8 0 2 4 6 8
3 0 3 6 9 2 5 8 1 4 7
4 0 4 8 2 6 0 4 8 2 6
5 0 5 0 5 0 5 0 5 0 5
6 0 6 2 8 4 0 6 2 8 4
7 0 7 4 1 8 5 2 9 6 3
8 0 8 6 4 2 0 8 6 4 2
9 0 9 8 7 6 5 4 3 2 1
7) Invent a problem like “What is the remainder when dividing ab by c?” where b
is a big number.
Worksheet 5 - Powers 3
Worksheet 6
Day of the week
Month codes
Month Number Mnemonic
January 6 WINTER has 6 letters
February 2 February is 2nd month
March 2 March 2 the beat.
April 5 APRIL has 5 letters
May 0 MAY-0
June 3 Jun (Jun has 3 letters)
July 5 The SHARD (5) opened on July
August 1 5
August begins with A, the first
September 4 letterTERM (4 letters) at school
First
October 6 SIX or treat!
November 2 11th month (11 => II or
December 4 1+1=2)
LAST (or XMAS) has 4 letters
One way to remember this would be to memorize the following “phone number”
622-503-514-624 or you can memorize one of these tables (or both):
May 0
Aug 1
Feb, Mar, Nov 2
Jan 6 Feb 2 Mar 2 Jun 3
Apr 5 May 0 Jun 3 Sep, Dec 4
Jul 5 Aug 1 Sep 4 Apr, Jul 5
Oct 6 Nov 2 Dec 4 Jan, Oct 6
Exception: in a leap year the January code is 5 and the February code is 1 (both
one less than in non-leap years).
Leap years:
You need to remember that leap years (usually) are the years that are multiples of
4. This should be enough most of the time. It can help to know that the Olympic
Games and the US presidential elections are held only on leap years.
The non-leap years that are multiple of 4 are the years that are multiples of 100 and
are not multiples of 400. Examples:
1600 leap, 1700 not leap, 1800 not leap, 1900 not leap
2000 leap, 2100 not leap, 2200 not leap, 2300 not leap
2400 leap
+ 0 1 2 3 4 5 6
Sunday 0 0 1 2 3 4 5 6
Monday 1 1 2 3 4 5 6 0
Tuesday 2 2 3 4 5 6 0 1
Wednesday 3 3 4 5 6 0 1 2
Thursday 4 4 5 6 0 1 2 3
Friday 5 5 6 0 1 2 3 4
Saturday 6 6 0 1 2 3 4 5
Remember:
Weekday code = code of the year + code of the month + date (mod 7)
Example
References:
a) 23/Apr/1999
b) 14/May/1989
c) 1/Jan/1999
d) 1/Jan/2000
e) 3/Feb/1999
f) 3/Feb/2000
I would like to thank Samantha Durbin and Diane Crann from the Royal Institution for all
their suggestions that allowed me to improve this presentation.
I would like to thank Jim Bumgardner for providing me the video “60 points going around a
circle”. On his website http://whitneymusicbox.org you can see other similar videos. A
description of his Whitney Music Box is in http://krazydad.com/pubs/whitney_paper.pdf. The
videos are based on John Whitney’s visual idea of “incremental drift”. Other related videos
are:
I also would like to thank Charlie Gilderdale and Alison Kiddle from NRICH for their help
and in general to NRICH for all the activities on their website. Here is a list of NRICH
activities related to Modular Arithmetic:
Finally, if you want to learn more about modular arithmetic you could watch on YouTube the
modular arithmetic videos posted by “TheMathsters”.
Thank you!
Gustavo Lau
Answers
2) Charlie and Alison chose numbers that were easy to work with. Can you see
why they were chosen?
Charlie’s numbers are multiples of 7 and Alison’s are (multiples of 7) + 2.
3) If today is Sunday, what day will it be in 15 days? 26 days? 234 days? 1000?
We need to find the remainder of 15, 26, 234 and 1000 when divided by 7. As
we don’t need the quotient we don’t need to do the division. We can find the
remainders writing the numbers as (multiples of 7) plus smaller numbers:
In 15=14+1 days it will be Monday.
In 26=21+5 days it will be Friday.
In 234=210+21+3 days it will be Wednesday.
In 1000=700+280+14+6 days it will be Saturday.
4) If your birthday fell on a Sunday this year, what day will it fall on next year?
Note that 365 = 350 + 15 = 350 + 14 + 1 = (multiple of 7) + 1.
If the next 365 days do not include 29/February it will fall on a Monday.
If the next 365 days include 29/February it will fall on a Tuesday.
If your birthday is on 29/February…?
Answers 1
6) If it is 9 am now, what time will it be in 50 hours?
11 am as 50 = 48 + 2 = (multiple of 12) + 2.
9) A railway line has 27 stations on a circular loop. If I fall asleep and travel
through 312 stations, where will I end up in relation to where I started?
We need to find the remainder of 312 when divided by 27. We write 312 as
(multiples of 27) plus smaller numbers:
312 = 270 + 42 = 270 + 27 + 15
I will end up 15 stations from where I started.
10) If a running track is 400 metres around, where will I be in relation to the
start after running 6 miles (approximately 9656 metres)?
We need to find the remainder of 9656 when divided by 400. We write 9656
as (multiples of 400) plus smaller numbers:
9656 = 8000 + 1656 = 8000 + 1600 + 56
I will be approximately 56 metres from the start.
11) I was facing North and then spun around through 945° clockwise. In what
direction was I facing at the end?
We need to find the remainder of 945 when divided by 360. We write 945 as
(multiples of 360) plus smaller numbers:
945 = 720 + 225
Now 225 = 180 + 45, so at the end I am facing southwest.
12) If I get on at the bottom of a fairground wheel and the wheel turns through
5000°, whereabouts on the wheel will I be?
We need to find the remainder of 5000 when divided by 360. We write 5000
as (multiples of 360) plus smaller numbers:
5000 = 3600 + 1400 = 3600 + 720 + 680 = 3600 + 720 + 360 + 320
I will be 320° from (or 40° to) the bottom of the fairground wheel.
Answers 2
Worksheet 2 - Remainders and congruences
1) Find the remainders modulo 3 of:
a) 31
31= 30 + 1
1 as 31 is (multiple of 3) + 1
b) 44
44 = 30 + 12 + 2
2 as 44 is (multiple of 3) + 2
c) 75
0 as 75 is multiple of 3
d) 751
751 = 750 + 1
1 as 751 is (multiple of 3) + 1
a) 34 – 15
mod 2: 0 – 1 = 1
b) 141 – 78
mod 2: 1 – 0 = 1
c) 519 – 444 + 37
mod 2: 1 – 0 + 1 = 0
a) 31 + 28 + 31 + 30
mod 12: 7 + 4 + 7 + 6 = 24 ≡ 0
b) 38 x 4 + 360
mod 12: 2 x 4 + 0 = 8
c) 66 + 5 + 26
mod 12: 6 + 5 + 2 = 13 = 12 + 1 ≡ 1
a) 177 ≡ 17 (mod 2)
Yes, because when we replace the numbers by their remainders
modulo 2: 1 ≡ 1 (mod 2)
Another way: 177 – 17 = 160 is even so 177 ≡ 17 (mod 2)
Answers 3
b) 1322 ≡ 5294 (mod 12)
5294 – 1322 = 3972
3972 = 3600 + 360 +12
Given that 3600 ≡ 360 ≡ 12 ≡ 0 (mod 12) we have:
3972 ≡ 0 (mod 12)
Therefore 1322 ≡ 5294 (mod 12)
c) 16 + 30 ≡ 2 (mod 2)
Yes, because when we replace the numbers by their remainders
modulo 2:
0 + 0 ≡ 0 (mod 2)
Another way: 16 + 30 - 2 = 44 is even so 16 + 30 ≡ 2 (mod 2)
d) 16 + 30 ≡ 2 (mod 3)
When we replace the numbers by their remainders modulo 3 we get:
1 + 0 ≡ 2 (mod 3)
and this is false.
Another way: 16 + 30 - 2 = 44 and 44 is not a multiple of 3, therefore
16 + 30 and 2 are not congruent modulo 3.
a) 16 + 30 ≡ 2 (mod 12)
When we replace the numbers by their remainders modulo 12 we get:
4 + 6 ≡ 2 (mod 12)
and this is false.
b) 67 x 73 ≡ 0 (mod 3)
When we replace the numbers by their remainders modulo 3 we get:
1 x 1 ≡ 0 (mod 3)
and this is false.
c) 14 x 15 x 16 ≡ 6 (mod 3)
When we replace the numbers by their remainders modulo 3 we get:
2 x 0 x 1 ≡ 0 (mod 3)
and this is true.
Answers 4
Worksheet 3 - Addition and multiplication tables
Answers 5
Modulo 7 multiplication table:
x 0 1 2 3 4 5 6
0 0 0 0 0 0 0 0
1 0 1 2 3 4 5 6
2 0 2 4 6 1 3 5
3 0 3 6 2 5 1 4
4 0 4 1 5 2 6 3
5 0 5 3 1 6 4 2
6 0 6 5 4 3 2 1
Answers 6
Modulo 6 addition table:
+ 0 1 2 3 4 5
0 0 1 2 3 4 5
1 1 2 3 4 5 0
2 2 3 4 5 0 1
3 3 4 5 0 1 2
4 4 5 0 1 2 3
5 5 0 1 2 3 4
Answers 7
Worksheet 4 - Divisibility
4) The first and fourth digits of the number d63d2 are the same and the number
d63d2 is a multiple of 9. Which digit is represented by d?
5) A four-digit number was written on a piece of paper. The last two digits were
then blotted out (as shown). If the complete number is exactly divisible by
three, by four, and by five, what is the sum of the two missing digits?
8 6
Answers 8
6) Based on the following table of the remainders of the powers of 10:
mod 1010 109 108 107 106 105 104 103 102 101 100
2 0 0 0 0 0 0 0 0 0 0 1
3 1 1 1 1 1 1 1 1 1 1 1
4 0 0 0 0 0 0 0 0 0 2 1
5 0 0 0 0 0 0 0 0 0 0 1
6 4 4 4 4 4 4 4 4 4 4 1
7 4 6 2 3 1 5 4 6 2 3 1
8 0 0 0 0 0 0 0 0 4 2 1
9 1 1 1 1 1 1 1 1 1 1 1
10 0 0 0 0 0 0 0 0 0 0 1
11 1 -1 1 -1 1 -1 1 -1 1 -1 1
12 4 4 4 4 4 4 4 4 4 10 1
a) Could you explain why looking at the last digit is enough for the divisibility
criteria by 2, 5 and 10?
All the powers of 10, except 100, are multiples of 2 (they are 0 modulo 2).
Therefore for every natural number N:
The same argument proves that N is divisible by 5 if and only if its last
digit is divisible by 5 (that is if it is 0 or 5) and that N is divisible by 10 if
and only if its last digit is divisible by 10 (that is if it is 0).
All the powers of 10, except 100and 101, are multiples of 4, that is they
are 0 modulo 4. 101 is 2 modulo 4 and 100is 1 modulo 4. Therefore for
every natural number N:
All the powers of 10, except 100, are 4 modulo 6 while 100 is 1 modulo 6.
Therefore for every natural number N:
Answers 9
7) From 1,001=7x11x13 we can conclude that:
1,000 ≡ –1 (mod 7)
1,000 ≡ –1 (mod 11)
1,000 ≡ –1 (mod 13)
Based on that table could you give divisibility criteria by 7, 11 and 13 that
work for numbers greater than 1,000?
Take any number greater than 1,000, say 3,918,915, then we have:
In general we have:
where the groups have to be taken starting from the right. In particular, N is
divisible by 7 if and only if the alternate sum of its groups of 3 digits is
divisible by 7. This is also true mod 11 and mod 13.
More examples:
Answers 10
Worksheet 5 - Powers
1) Given that the modulo 10 multiplication table is:
x 0 1 2 3 4 5 6 7 8 9
0 0 0 0 0 0 0 0 0 0 0
1 0 1 2 3 4 5 6 7 8 9
2 0 2 4 6 8 0 2 4 6 8
3 0 3 6 9 2 5 8 1 4 7
4 0 4 8 2 6 0 4 8 2 6
5 0 5 0 5 0 5 0 5 0 5
6 0 6 2 8 4 0 6 2 8 4
7 0 7 4 1 8 5 2 9 6 3
8 0 8 6 4 2 0 8 6 4 2
9 0 9 8 7 6 5 4 3 2 1
b. 25013
0
c. 451
4 (51 is odd, it would be 6 for an even power)
b. 972
1 (72 is even)
Answers 11
c. 3210
We only need to look at the last digit of 32: 2.
For n>0, the last digit of 2n is:
2 if n is (multiple of 4) + 1
4 if n is (multiple of 4) + 2
8 if n is (multiple of 4) + 3
6 if n is multiple of 4
10 is a (multiple of 4) + 2, therefore the answer is 4.
d. 2360
We only need to look at the last digit of 23: 3.
For n>0, the last digit of 3n is:
3 if n is (multiple of 4) + 1
9 if n is (multiple of 4) + 2
7 if n is (multiple of 4) + 3
1 if n is multiple of 4
60 is a multiple of 4, therefore the answer is 1.
b. …69770 by 5?
1 because 6 ≡ 1 (mod 5)
c. …584320 by 4?
1 because 5 ≡ 1 (mod 4)
d. …493184 by 4930?
1 because 4931 ≡ 1 (mod 4930)
Answers 12
Worksheet 6 - Day of the week
a. 23/Apr/1999
Apr has code 5 and 5+5+23=33 ≡ 5 (mod 7), therefore 23/Apr/1999 was
a Friday.
b. 14/May/1989
c. 1/Jan/1999
d. 1/Jan/2000
2000 code = 0
2000 was leap so Jan code is 5, 0+5+1=6≡ 5 (mod 7), therefore
1/Jan/2000 was a Saturday.
e. 3/Feb/1999
f. 3/Feb/2000
2000 code = 0
2000 was leap so Feb code is 1, 0+1+3=4, therefore 3/Feb/2000 was a
Thursday.
Answers 13