Counting down to doomsday

This article was my submission for the Big Internet Math-Off 2024, ran by Christian Lawson-Perfect and pulished on the Aperiodical. I was pitted against Matt Enlow in the third match of the first round, and sadly lost to his amazing piece on the ‘Triangle of Medians’. It was a great event to take part in nontheless, and the difference in votes were the closest in the entire competition. You can read the original blog post (with Matt’s pit included) here.

DISCLAIMER

In the original article I made a mistake, implying that 27 = 18 + 5. This is obviously not true—the mistake is fixed below.

I Know What Day Of The Week You Were Born On.

No, I’m not performing one of those scams where I state ‘Sunday’ and hope to impress one-seventh of the people reading this piece. My neat little party trick involves asking someone when they were born, and roughly 10 seconds later giving them which day of the week that was.

How on Earth is this possible?

There are two routes a keen mathematician would come up with; either I know that the Gregorian calendar has a 28-year cycle, and so remembering 28 years’ worth of days and dates is a doable task, or I take a modular arithmetic appraoch. The latter is clearly easier to do.

Doomsday

The Doomsday algorithm is a method, an algorithm, popularised by Group Theory legend John Conway that pinpoints exactly what day of the week any given day in recent history was or soon-to-be future would be. It begins with the day of the year that Conway deems Doomsday which will always be the last day of February, no matter if it’s a leap year or not. At the time of writing (2024) it is a Thursday.

The first part of the algorithm uses Doomsday to figure out the day of the week for any day in the same year. An astounding result emerges when considering the even months that follow: the 4th of April, 6th of June, 8th of August, 10th of October, and 12th of December all fall on Doomsday. That is, this year 4/4, 6/6, 8/8, 10/10, and 12/12 are all Thursdays. From here, for any desired date you can simply count up or down from Doomsday.

Suppose I am hosting a birthday party on the 10th of August and I need to let my friends know which night of the week to keep available. I know that the 8th is a Thursday, and so the 10th being two days later makes it a Saturday. They probably have the day off anyway.


I will give a quick note on modular arithmetic as it is the heart of this process. Since we are working with days of the week, there are only seven cycling objects we need to keep track of. That is, after counting seven days we arrive back at the day we started on, which essentially counts zero days. This process works under arithmetic modulo 7. It is convention to relabel the days in terms of numbers as such:

\[\textbf{0} - \text{Sunday}, \textbf{1} - \text{Monday}, \textbf{2} - \text{Tuesday}, \textbf{3} - \text{Wednesday},\\ \textbf{4} - \text{Thursday}, \textbf{5} - \text{Friday}, \textbf{6} - \text{Saturday}.\\\]

For the eager Aperiodical enojyers reading this on the day of release, today is Wednesday, now relabelled as 3. 10 days from now will be $\textbf{3} + 10 \equiv \textbf{3} + 3 = \textbf{6}$ modulo 7, which is a Saturday. All this is saying is that 10 days from now will be the same day as 3 days from now, because $10\equiv3$ modulo 7.


There are other key Doomsday dates to remember in the year; a common mnemonic is ‘‘working a 9-5 in a 7-11 store” because 9/5, 5/9, 7/11, and 11/7 all match with Doomsday too. If my bar steward tells me I need to work late for a fresher’s week event on the 27th of September, I want to know which day of the week I should catch up on sleep for. The mnemonic tells us the 5th of September this year is a Thursday, 4, and the 27th is 22 days away. $22\equiv1$ modulo 7, and $\textbf{4} + 1 \equiv \textbf{5}$ modulo 7. This leaves us with a Friday.

March’s neat trick is that all multiples of 7 are Doomsdays$^{\star}$. For January and February, it us up to each mathemagician to decide which reference dates to use. This is because they are different dependent on the leap year-ness. I like to note that in the years that are not leap years, February has all multiples of 7 being Doomsday and January follows the same as October in that the 10th is Doomsday. In the case of a leap year, February now has all multiples + 1 being Doomsday and January’s Doomsday now follows the same as April and July (4th/11th).

$^{\star}$yes, that means Pi Day is a Doomsday! No, Tau Day is not a Doomsday.


Great Scott!

It might already be an impressive feat knowing what day of the week any day in the year is. But the whole trick of knowing a person’s birth-day requires knowing Doomsday for any year at hand. This requires a bit more finesse.

In order to do this, one notes that Doomsday 2000 was a Tuesday, and Doomsday 1900 was a Wednesday. The importance of this is best described with an example. Let’s say we wanted to work out Doomsday for fifteen years’ time, 2039. It is common knowledge that moving up one year in the calendar shifts the days of the week by one. We first take Doomsday 2000 and add the number of years. 39 more days than Tuesday is $\textbf{2}+39\equiv2+4=6$ modulo 7, a Saturday.

But we mustn’t forget leap years! Leap years shift the week by two days each. One asks how many leap years are between 2000 and 2039; it’s a 39-year difference, and since leap years occur every four years that leaves us with 9 leap years slotted in. Saturday plus 9 days is $\textbf{6}+9\equiv6+2\equiv \textbf{1}$ modulo 7, a Monday. Doomsday 2039 is a Monday.

Having to count how many years and leap years there are between 1900 and 2000 is tedious work though, and not efficient. There is one trick I have come across that involves the multiples of 12. Another astounding fact is that the $n$th multiple of 12 years after a century has its Doomsday $n$ days after the century’s Doomsday. For example, Doomsday 1948 is Wednesday + 4 days = Sunday. Doomsday 2072 is Tuesday + 6 days = Monday.


The final part is to put these two ideas together and test this out on your willing family and friends. Heck, try it out on your own birthday and ask your mum if it was right - she’s bound to remember. Take, for example, Alice’s birthdate on 10th June 1996: 10th June is 4 days more than Doomsday, and Doomsday 1996 is Wednesday + 8 days using the multiple of 12s trick. $\textbf{3} + 8\equiv4$, so 10th June 1996 is $4+4\equiv \textbf{1}}$, a Monday.

My closing thought will be a quick disclaimer. I did say this was a neat little party trick, so by all means perform this at parties. Just make sure that the party in question contains people that know the day of the week they were born on. Otherwise you end up looking like a bit of a creep.