Maths Olympiad Prep

Library / /816 of 860

Number theory Difficulty 5.6 AIME, harder Find the answer

For positive integers a,b,aba, b, a \uparrow \uparrow b is defined as follows: a1=aa \uparrow \uparrow 1=a, and ab=aa(b1)a \uparrow \uparrow b=a^{a \uparrow \uparrow(b-1)} if b>1b>1. Find the smallest positive integer nn for which there exists a positive integer aa such that a6≢a7a \uparrow \uparrow 6 \not \equiv a \uparrow \uparrow 7 modn\bmod n.

A number or a short expression. Spacing and $ signs are ignored.

Solution

We see that the smallest such nn must be a prime power, because if two numbers are distinct mod nn, they must be distinct mod at least one of the prime powers that divide nn. For k2k \geq 2, if aka \uparrow \uparrow k and a(k+1)a \uparrow \uparrow(k+1) are distinct modpr\bmod p^{r}, then a(k1)a \uparrow \uparrow(k-1) and aka \uparrow \uparrow k must be distinct modϕ(pr)\bmod \phi\left(p^{r}\right). In fact they need to be distinct modϕ(pr)2\bmod \frac{\phi\left(p^{r}\right)}{2} if p=2p=2 and r3r \geq 3 because then there are no primitive roots modpr\bmod p^{r}. Using this, for 1k51 \leq k \leq 5 we find the smallest prime pp such that there exists aa such that aka \uparrow \uparrow k and a(k+1)a \uparrow \uparrow(k+1) are distinct modp\bmod p. The list is: 3,5,11,23,473,5,11,23,47. We can easily check that the next largest prime for k=5k=5 is 139 , and also any prime power other than 121 for which a5a \uparrow \uparrow 5 and a6a \uparrow \uparrow 6 are distinct is also larger than 139 . Now if a6a \uparrow \uparrow 6 and a7a \uparrow \uparrow 7 are distinct mod pp, then p1p-1 must be a multiple of 47 or something that is either 121 or at least 139. It is easy to see that 283 is the smallest prime that satisfies this. If nn is a prime power less than 283 such that a6a \uparrow \uparrow 6 and a7a \uparrow \uparrow 7 are distinct modn\bmod n, then the prime can be at most 13 and clearly this doesn't work because ϕ(pr)=pr1(p1)\phi\left(p^{r}\right)=p^{r-1}(p-1). To show that 283 works, choose aa so that aa is a primitive root mod283,47,23,11,5\bmod 283,47,23,11,5 and 3 . This is possible by the Chinese Remainder theorem, and it is easy to see that this aa works by induction.

Want a route through all this instead of an archive? The track puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.

Source: Omni-MATH, licensed Apache-2.0. Statement and solution reproduced as published; topic and difficulty added by this site.