This was a fun problem, thanks Akash for sharing it!

My first thought was, * it seems really unlikely for and to be prime as well!* And indeed, that’s true: if both and are odd, then both and are even! The only way they can be even and prime is if they are equal to 2. But , so we can’t have both being equal to 2. We conclude that at least one of and has to be even, and since we must have , we conclude that .

With this piece of information, let’s rephrase the question:

is a prime number. and are also prime. If you divide by a composite number , where , you’ll get a remainder of 14. If you divide by the same number, what will you get as the remainder?

Now, and both being prime happens a lot (3 & 7, 7 & 11, 13 & 17, …), but I’m not sure whether both and being prime happens that much. * It’s often easier to work with addition rather than subtraction*, so I’ll let . must be prime.

Rewriting in terms of :

.

With this, the divisibility condition reads as

Seems like we’re getting somewhere! We have that . * What I really hope to get out of this is that or *, since that would give me the answer to my problem right away. To do so, I have to show that or .

* Is it possible that ?* No, it’s not. Since we can get a remainder of 14, , and so . This in turn implies that , so in order for , we must have . But is composite! Hence, we conclude that .

With this information, we can conclude that , or , and therefore . The answer is **6**.

To that end, I just started a new blog Statistical Odds and Ends! The idea for this began when I found myself spending a lot of time googling relatively simple things in the course of my studies and research. For example:

- Why does the ridge regression solution exist and why is it unique?
- What is the formula for the matrix such that the projection of the vector onto the column space of a matrix is ?
- Can I switch supremums and expectations and still have equality? If not, can I get an inequality instead?
- How can I derive the bias-variance decomposition?

I was often googling for the same things over and over again, and trying to re-understand what others were writing.

Hence the idea of Statistical Odds and Ends. The blog will be a place for me to pen down my understanding of these statistical tidbits, and to share it with others. Hopefully some of the material there will be of interest to you! If the content is relevant to this audience, I will cross-post over on this blog too.

]]>While heading to a conference on board a train, three statisticians meet three biologists. The biologists complain about the cost of the train fare, but the statisticians reveal a cost-saving trick. As soon as they hear the inspector’s voice, the statisticians squeeze into the toilet. The inspector knocks on the toilet door and shouts: “Tickets, please!” The statisticians pass a single ticket under the door, and the inspector stamps it and returns it. The biologists are impressed. Two days later, on the return train, the biologists showed the statisticians that they have bought only one ticket, but the statisticians reply: “Well, we have no ticket at all.” Before they can ask any questions, the inspector’s voice is heard in the distance. This time the biologists bundle into the toilet. One of the statisticians secretly follows them, knocks on the toilet door and asks: “Tickets please!” The biologists slip the ticket under the door. The statistician takes the ticket, dashes into a another toilet with his colleagues, and waits for the real inspector. The moral of the story is simple: “Don’t use a statistical technique that you don’t understand.”

]]>Let . Prove that as ,

a) the distribution of converges to for some real number ,

b) but converges to 2.

(*Credits:* I learnt of this problem from Persi Diaconis in my probability class.)

For each , let be the * simple truncation* of , i.e. , or equivalently

It is easy to calculate the following:

If we let , then

Let us check that * Lyapounov’s condition* holds for :

Since , as , the denominator of the above goes to infinity, which means that the entire RHS goes to zero, i.e. Lyapounov’s condition holds. Hence, we can use * Lyapounov’s Central Limit Theorem* to conclude that

(Here, means “converges in distribution”.) Next, note that

By the * first Borel-Cantelli lemma*, we conclude that . From this, we can further conclude that

where .

It is straightforward to show that converges to 2:

**Done!**

For , define the random variable

Let . Prove that as ,

a) the distribution of converges to for some real number ,

b) but converges to 2.

**Hint:** Simple truncation. Let . Use Lyapounov’s Central Limit Theorem and Borel-Cantelli’s 1st Lemma.

Let . Prove that as ,

a) the distribution of converges to for some real number ,

b) but converges to 2.

(*Credits:* I learnt of this problem from Persi Diaconis in my probability class.)

Show that the infinite series converges and find its sum.

The recurrence relation is begging to be * exponentiated* so that we have on both sides:

and now this looks like a * telescoping series* that allows cancellation of terms:

To show that converges, we have to show that exists. There are many different techniques to show that a limit exists, we can decide which is appropriate by playing around with the sequence.

After working out the first few terms of the sequence, it may become clear that * the sequence is decreasing*. The recurrence relation seems to suggest it as well: if we can state with confidence that is non-negative, then

It seems reasonable that should be positive as well. Let’s try using * induction to prove both statements at once*:

**Induction statement** : For , and .

It is clear that is true. Let us assume that is true for some . To prove , we can work backwards:

which is a true statement for all real numbers ! Hence the sequence is non-negative and we can use the earlier argument to show that . We have shown that , so by induction, the induction statement is true.

* Since we have a decreasing sequence with a fixed lower bound, it means that the sequence converges.* It remains to figure out what the limit is. We can use the recurrence relation to figure that out:

Hence, , and

**Done!**

Show that the infinite series converges and find its sum.

]]>In the meantime, I thought I’d share the data I’ve scraped so far so that others who have the time and interest might have a go at analysing the data. Data is available at my Github repo.

All data was scraped from imo-official.org; the scripts I used to scrape them are in the ETL folder of the same repo. The data generally looks clean except some minor issues for “Contestant” (i.e. names of contestants). For example, my name is written in one order for 2003 and 2005 but in a different way for 2004. I have no idea how widespread this issue is, although a cursory glance at contestants in my country suggest the issue is a minor one.

]]>* Congratulations to my country, Singapore’s team, for coming in 4th overall!* And for winning the country’s:

**Best**medal haul (4G 2S, previous best was 4G 1S 1B in 2011)**Highest**absolute score (196 out of a possible 252, previous best was 179 in 2011)**2nd best**overall team ranking (4th, best was 3rd in 2011)

Some factoids on the results:

- The Gold, Silver and Bronze medal score cutoffs were
**29, 22 and 16**respectively. Nothing too out of the ordinary. (Interestingly, IMO 2014 had the exact same cutoffs.) - The top 3 countries were the
**United States, South Korea and China**. (These 3 countries were the top 3 in 2015 as well, just a different order: USA, China, South Korea.)- Team USA won a best possible 6 Gold medals. (Next best was 4G 2S by South Korea, China and Singapore.)

- There were
**6**contestants with perfect scores: 3 from South Korea, 2 from USA and 1 from China.- 3 of them were first-time participants of the competition. 2 of them had won Gold in 2015, while the remaining contestant (Allen Liu, USA) had won Gold in 2014 and 2015.

**Question 3**was the most difficult question, with a mean score of 0.251, 91% of students scoring 0 points and only 10 contestants scoring a perfect 7 points. The easiest was**Question 1**with a mean score of 5.272. (The questions from easiest to hardest: 1, 4, 2, 5, 6, 3.)

And finally, some useful links:

- IMO 2016 official website (At the time of writing of this post, the results have not been posted on this website.)
- AoPS forum on Contests and Problem Sets (All the latest threads are related to IMO 2016.)
- imo-official.org page for IMO 2016 (Contains all the stats you could dream of for IMO 2016.)