Olympiad Maths Prep

Track / Stage 7 / 109 of 300 #1509 of 2000

Problem 1509

National olympiad second round; IMO P1/P4
Number theory Difficulty 7.2 Prove it

Prove that for any natural n2n \geq 2, the number 222n times222n1 times \underbrace{2^{2^{\cdots^2}}}_{n \textrm{ times}}- \underbrace{2^{2^{\cdots^2}}}_{n-1 \textrm{ times}} is divisible by nn.

I know, that it is a very old problem :blush: but it is a problem from olympiad.

This one wants a proof. Work it on paper, read the official solution, then mark yourself honestly — the ladder only means something if the record is true.

Official solution

1. Define the functions f(n) f(n) and g(n) g(n) as follows:
f(n)=222n times,g(n)=f(n)f(n1) f(n) = \underbrace{2^{2^{\cdots^2}}}_{n \text{ times}}, \quad g(n) = f(n) - f(n-1)
Here, f(n) f(n) represents the tower of exponents with n n layers of 2's.

2. Observe that:
g(n)=f(n1)(2g(n1)1) g(n) = f(n-1) \left( 2^{g(n-1)} - 1 \right)
This follows from the fact that f(n)=2f(n1) f(n) = 2^{f(n-1)} .

3. Let n n be an odd number and let ord2(n) \text{ord}_2(n) be the minimal positive integer k k such that n2k1 n \mid 2^k - 1 . This is the order of 2 modulo n n .

4. Define x(n) x(n) as the maximal odd divisor of n n and c(n)=x(ord2(x(n))) c(n) = x(\text{ord}_2(x(n))) .

5. We need to show that nf(n)f(n1) n \mid f(n) - f(n-1) . We will use induction on n n .

6. Base case: For n=2 n = 2 , we have:
f(2)=22=4,f(1)=2 f(2) = 2^2 = 4, \quad f(1) = 2
Thus,
f(2)f(1)=42=2 f(2) - f(1) = 4 - 2 = 2
Clearly, 22 2 \mid 2 .

7. Inductive step: Assume that for some k2 k \geq 2 , kf(k)f(k1) k \mid f(k) - f(k-1) . We need to show that k+1f(k+1)f(k) k+1 \mid f(k+1) - f(k) .

8. By the induction hypothesis, kf(k)f(k1) k \mid f(k) - f(k-1) . We need to show that k+1f(k+1)f(k) k+1 \mid f(k+1) - f(k) .

9. Consider the expression:
f(k+1)=2f(k) f(k+1) = 2^{f(k)}
and
f(k)=2f(k1) f(k) = 2^{f(k-1)}
Therefore,
f(k+1)f(k)=2f(k)2f(k1) f(k+1) - f(k) = 2^{f(k)} - 2^{f(k-1)}

10. Since kf(k)f(k1) k \mid f(k) - f(k-1) , we have f(k)f(k1)(modk) f(k) \equiv f(k-1) \pmod{k} . Thus,
2f(k)2f(k1)(modk) 2^{f(k)} \equiv 2^{f(k-1)} \pmod{k}
This implies that:
2f(k)2f(k1)0(modk) 2^{f(k)} - 2^{f(k-1)} \equiv 0 \pmod{k}

11. Now, we need to show that k+12f(k)2f(k1) k+1 \mid 2^{f(k)} - 2^{f(k-1)} . Since k+1 k+1 is coprime to k k , we can use the Chinese Remainder Theorem to conclude that k+12f(k)2f(k1) k+1 \mid 2^{f(k)} - 2^{f(k-1)} .

12. Therefore, by induction, nf(n)f(n1) n \mid f(n) - f(n-1) for all n2 n \geq 2 .

\blacksquare

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