# Clock arithmetic

You may be familar with a straight number line, but what happens if we change the rules and make our number line into a circle?

We are used to using this sort of arithmetic when we use clocks.

The numbers go from 1 to 12, but when you get to "13 o'clock", it actually becomes 1 o'clock again (think of how the 24 hour clock numbering works). So 13 becomes 1, 14 becomes 2, and so on.

This can keep going, so when you get to "25 o'clock'', you are actually back round to where 1 o'clock is on the clock face (and also where 13 o'clock was too).

*Click on "Task 1" to find the first set of questions. Once you have tried these you can check your solutions.*

- What time is 5 hours after 10 o'clock?
- What time is 9 hours after 4 o'clock?
- What time is 13 hours after 6 o'clock?
- What time is 20 hours after 5 o'clock?
- What time is 36 hours after 2 o'clock?

- 3 o'clock
- 1 o'clock
- 7 o'clock
- 1 o'clock
- 2 o'clock

You may have noticed that everytime you add $12$ hours you end back where you were, so instead of adding on 30 hours you can use the fact that $30=12+12+6$ and so just add on $6$ hours instead.

We write $30 \equiv 6 \text{ mod } 12$ which reads as "$30$ is congruent to $6$ mod (or modulo) $12$".

Instead of using the 12 numbers of a clock, we could instead take the portion of the number line between 0 and 7 inclusive and wrap this into a circle so that the 0 and 7 are in the same place (and we write 0 in this position).

You can still use this curved number line to calculate sums like "3+2" but instead of "+2" meaning move two places to the right, it means moving 2 places "clockwise". When working with this clock you are working in modulo 7 (there are 7 numbers, including 0, around the clock), so you would write $4+5 \equiv 2 \text{ mod } 7$.

- $2 + 3 \equiv \text{ ? mod }7$
- $5 + 2 \equiv \text{ ? mod }7$
- $6 + 6 \equiv \text{ ? mod }7$
- $4 \times 2 \equiv \text{ ? mod }7$
- $3 \times 3 \equiv \text{ ? mod }7$

- $\text{ 5 mod }7$
- $\text{ 0 mod }7$
- $\text{ 5 mod }7$
- $\text{ 1 mod }7$
- $\text{ 2 mod }7$

Subtracting can be thought of as a move anticlockwise around the circle. Can you work out the answers to these?

- $2 - 5 \equiv \text{ ? mod }7$
- $1-2 \equiv \text{ ? mod }7$

- $\text{ 4 mod }7$
- $\text{ 6 mod }7$

When using clock arithmetic, subtracting is not really necessary, as instead of moving round anticlockwise we can move clockwise and end up in the same position. We have $1 - 2 \equiv 6$ mod $7$ but we also have $1 + 5 \equiv 6$ mod $7$. This means that the operation "$-2$" is equivalent to "$+5$" when we are working modulo $7$.

- $-1$
- $-3$
- $-5$
- $-6$

- $+6$
- $+4$
- $+2$
- $+1$

We can also keep travelling round our modulo $7$ clock. If we wanted to represent $16$ we would start at $0$ and move $16$ places clockwise until we ended on $2$. We would write $16 \equiv 2 \text{ mod }7$.

- $20 \equiv \text{ ? mod }7$
- $32 \equiv \text{ ? mod }7$
- $50 \equiv \text{ ? mod }7$
- $91 \equiv\text{ ? mod }7$

Can you find a general expression for $x$?

If I know that $x \equiv a \text{ mod } 7$ then can you find a general expression for $x$?

- $20 \equiv \text{ 6 mod }7$
- $32 \equiv \text{ 4 mod }7$
- $50 \equiv \text{ 1 mod }7$
- $91 \equiv\text{ 0 mod }7$

If $x \equiv 3 \text{ mod } 7$ then $x$ could be $... 10, 17, 24, 31... 73... 1403... 777780...$

In general $7n+3$.

If $x \equiv a \text{ mod } 7$ then $x=7n+a$.

You can use some of these ideas to solve problems about days of the week. **Can you use your knowledge of arithmetic modulo 7 to solve this final set of problems?**

- If today is a Monday, what day will it be in $31$ days' time?
- If April $1^{\text{st}}$ is a Thursday, what day will Christmas day be on?
- If Jan $1^{\text{st}}$ is a Friday, and it is a leap year, what day will Jan $1^{\text{st}}$ be on next year?
- Can you use today's date to work out what day of the week your birthday will be on?

*If you have enjoyed working on this problem, then you may enjoy More Adventures with Modular Arithmetic and Clock Squares *

*We are very grateful to the Heilbronn Institute for Mathematical Research for their generous support for the development of this resource.*

When tackling Task 6, the first thing to do is to assign numbers to the days of the week, such as:

- $ 0 \equiv $ Sunday
- $ 1 \equiv $ Monday
- etc.

*Thank you for all the fantastic solutions we received to this problem. Since the answers to tasks 1-5 were shown in the problem, here we have only included the solutions to task 6.*

**If today is a Monday, what day will it be in** $31$ **days' time?**

Ilham from St. Aidan's Catholic Primary Academy in England, Jerry, Lucas and Jaa from Rugby School Thailand and Michelle from Westridge School in the USA used the language of days and weeks. Ilham wrote:

31 days contain 4 weeks (28 days) and 3 days and 3 days onward from Monday is Thursday so in 31 days' time, it will be Thursday.

Aaron from Harrow International School Hong Kong used remainders:

Days in a week: 7

Remainer of (31 days $\div$ 7 days of the week) = 3

7 $\times$ 4 is 28

31 $-$ 28 is 3

Monday plus 3 days is Thursday

Answer: Thursday

Nayanika fom The Tiffin Girls' School in England and Lawson from Aiglon College in Switzerland used a diagram. This is Nayanika's diagram:

Sunhari and Miraya from Heckmondwike Grammar School in the UK used the same idea and the language of modular arithmetic. This is Sunhari's work:

Monday is considered as 0 on the modulus 7 clock, and we start counting

clockwise from there.

No. of Days = 31

31 is congruent to 3 mod 7 [7$n$+$a$ where $n$=4 and $a$=3(by dividing 31 by 7 and finding the remainder)]

Therefore, the answer is (Monday+3) Thursday.

Airi from Japan, Zac from Aiglon College, Emily from The Archer Academy in England, Martin from Prague British International School Prague Libuš in the Czech Republic, Olivia from Roedean in the UK, Mahdi from Mahatma Gandhi International School in India and Professor Pat, Professor Andrew and Peter from Rugby School Thailand also used modular arithmetic to get the correct answer.

**If April** $1^{\text{st}}$ **is a Thursday, what day will Christmas day be on?**

Ilham used weeks and days language:

30 days + 31 + 30 + 31 + 31+ 30 + 31 + 30 + 24 equals 268 days

268 days $\div$ 7 = 38 weeks and 2 days and 2 days onwards from Thursday is... Saturday! (our answer).

Lawson used a diagram:

Miraya, Airi, Nayanika, Zac, Emily, Olivia, Mahdi, Professor Pat and Professor Andrew, Peter and Jerry, Lucas and Jaa got the same answer using modular arithmetic. Airi wrote:

Counting from April 1st, there are 29 days in April, 31 days in May, 30 days in June, 31 days in July, 31 days in August, 30 days in September, 31 days in October, 30 days in November, and 25 days in December until Christmas day. (Remember not to overcount! This goes for Problem 3 and 4 as well.)

$29+31+30+31+31+30+31+30+25$

$= 309+((-1)+1+0+1+1+0+1+0+(-5))=270-2=268$

$268\equiv2\text{ (mod 7)}$

The day that is two days from a Thursday is a Saturday.

*The addition might be easier if you use modulo 7 earlier:*

$29+31+30+31+31+30+31+30+25$

$\equiv 1+3+2+3+3+2+3+2+4\text{ (mod 7)} \equiv 2 \text{ (mod 7)}$

**If Jan** $1^{\text{st}}$ **is a Friday, and it is a leap year, what day will Jan** $1^{\text{st}}$ **be on next year?**

Sunhari, Airi, Nayanika, Zac, Ilham, Emily, Martin, Olivia, Mahdi, Professor Pat and Professor Andrew and Peter answered this correctly using modular arithmetic. This is Olivia's work:

Mahdi asked and answered another question:

Interestingly, we can also know when 1st Jan will be a Friday again.

Exactly 1 year later, we get Sunday. Now, this would be non-leap year with 365 days ≡ 1 mod 7. Hence, 2 years later we get to Monday. This would repeat again for two more non-leap years. And so, 4 years later, 1st Jan is Wednesday. Now the fifth year would be 366 days ≡ 2 mod 7, and moving two days from Wednesday gives Friday again! So we get 1st Jan as a Friday again after 5 years.

**Can you use today's date to work out what day of the week your birthday will be on?**

Airi: Say that my birthday is the 12th of January. Today’s date is Friday, 26 March 2021. Counting from today, there are 5 days left in March, 30 days in April, 31 days in May, 30 days in June, 31 days in July, 31 days in August, 30 days in September, 31 days in October, 30 days in November, 31 days in December, and 12 days in January until my birthday.

5+30+31+30+31+31+30+31+30+31+12=5+309+(0+1+0+1+1+0+1+0+1)+12

=5+270+5+12=292

292≡5 (mod 7)

The day that is five days from a Friday is a __Wednesday__.

Sunhari: Today's date = March 25, 2021

Birthday = January 30, 2022

No of days= 6 + 30 + 31 + 30 +31 + 31 + 30+ 31 + 30 +31+30

=311

311 is congruent to 3 mod 7

My birthday will fall on (Thursday+3) Sunday.

Aaron: Today's date is Tuesday 30th of March while my birthday is on the 28th of September which is 182 days difference. 182 $\div$ 7 (since 7 days in a week) = remainder 0. Tuesday + 0 days = Tuesday

Since, April 30 days, May 31 days, June 30 days, July 31 days, August 31

days and September 28 days.

1 + 30 + 31 + 30 + 31 +31 + 28

1 + 61 + 61 + 59 = 182*28th September will also be a Tuesday*

Miraya: Today is 1st April and my birthday on 20th August. So that would be 141 days. Which is 20 weeks and 1 day. That would be 1 mod 7. So 20th August would be FRIDAY.

Nayanika:

Lawson:

Zac:

Ilham: I don't know about YOU but my birthday is on the 21st of July and today is the 28th of April so, using the same method, we will conclude that this year my birthday will be on a Wednesday.

Emily: I worked out that because my birthday is on March 1st, it is 305 days away from April 30th.

Then, I found the multiple of 7 that is 305 or the closest one below. This is 301, which is 4 below 305, meaning 305 ≡ 4 mod 7.

I had already assigned the number 4 to Tuesday, so if April 30th is a Friday, March 1st will be on a Tuesday.

Martin: Today is a Tuesday, It is the 11th of May 2021. (next year Is not a Leap year) My birthday is on the 4th of March. My birthday is in 298 days.

If we use the mod7 pattern, we notice that 298 ≡ 4 mod7 (42$\times$7+4). This means that if today is a Tuesday, my Birthday would be a Saturday.

Michelle: My birthday is on December 1. Like I solved the other problems, I found the difference between today’s date and my birthday.

Next, I used that to find 216 (amount of days until my birthday) mod 7. The remainder [of 6] was added on to today's day, Thursday, May 6th, and I found out that my birthday is on a Wednesday.

Olivia:

Mahdi: Today is 13 May, Thursday. My birthday is on 1st October.Each month has these days:

May - 18

June - 30

July - 31

August - 31

September - 30

October - 1

141 days ≡ 1 mod 7, 1 day from Thursday is Friday. And 1st October 2021 is a Friday indeed.

Professor Pat and Professor Andrew:

Professor Pat’s BirthDay:

Today is friday 21/5/2021

My Birthday is on 25/1/2022

Tuesday 249 ≡ 4 mod 7 Friday-Saturday-Sunday-Monday-Tuesday

Professor Andrew’s BirthDay:

Today is friday 21/5/2021

My Birthday is on 28/1/2022

Friday 252 ≡ 0 mod 7 Friday

Jerry, Lucas and Jaa (including another method based on the idea that 365 ≡ 1 mod 7):

Jerry=Saturday

I have worked this out by the solutions to this: today is Friday and it’s 21/5/2021, my birthday is on the date of 04/12/2021, today to 12/04 is 10+30+31+31+30+31+30+4=197, it’s divided by 7 and we get 28, left with

1, the next day for Friday is Saturday,s o that’s the working.

Jaa=Tuesday

My birthday this year was on a Monday so it shifts one day.

Monday-Tuesday.

Another way I worked it out is, finding the amount of days from today to my birthday. Divided the number by seven, and then counted from Friday to Tuesday because the remainder of the amount of days divided by 7 is 4. So just like the mod 7 clock. You shift 4 spaces clockwise.

Lucas=Monday

Last time my birthday is Sunday, this year is not a leap year so we add one.

### Why do this problem?

This problem gives an insight into modular arithmetic without worrying too much about notation, by using the image of a clock face and looking at the concept of remainders. It is a good preparation for More Adventures with Modular Arithmetic

### Possible approach

*This problem featured in an NRICH Secondary webinar in April 2021.*

Task 1 to 5 are ideal for students to work on in pairs and justify their results to each other as they go along.

Before students start on the tasks, ask them some questions about time, such as:

- If the time is 10am, what time will it be in 3 hours time?
- If the time is 11pm, what time will it be in 15 hours time?
- If the time is 2pm, what time will it be in 20 hours time?
- If the time is 2pm, what time was it 5 hours ago?

Bring the class together to discuss their results (in particular their results for Task 5) before they tackle Task 6.

Before students start on Task 6, discuss why 702 days after a Monday will be a Wednesday, possibly by thinking about whole numbers of weeks and days left over. Students can then work out what day it will be in 15 days, 26 days, 234 days time.

Pose the question "If today is Monday, how many days from now is Wednesday?" Ask the students to give you as many answers as they can. (Does anyone suggest a negative number of days?).

As students work on Task 6 in pairs, circulate around the class listening out for good explanations that can be shared with the whole class at the end of the session.

### Key questions

See the questions in "Possible approach".

If the first day of this month was a Monday, what can we say about the first day of next month, and why?

### Possible support

Focussing on Tasks 1 to 5 and then moving on to Level 1 of Shifting Times Tables might be a good preparation for Task 6.

### Possible extension

Further reading on modular arithmetic can be found here