RMO 2015! 12

Let f ( x ) = x x x x f(x) = \Large{x^{x^{x^x}}} . Find the last two digits of f ( 17 ) + f ( 18 ) + f ( 19 ) + f ( 20 ) f(17) + f(18) + f(19) + f(20) .


The answer is 32.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

Arjen Vreugdenhil
Oct 17, 2015

Strategy: to determine x n x^n mod a a , we split a a into (powers) of distinct primes and determine the value of x n x^n mod each of these factors. For a = 100 a = 100 , these factors are 4 and 25.

Moreover, for the value of x n x^n mod a a we only need to know n n mod ϕ ( a ) \phi(a) , where ϕ \phi is the totient function. For instance, for x n x^n mod 25 we only need to know n n mod 20.

x = 17:

A = 1 7 B 1 A = 17^B \equiv 1 mod 4. We wish to determine the remainder of A = 1 7 B ( 8 ) B A = 17^B \equiv (-8)^B mod 25. Since ϕ ( 25 ) = 20 \phi(25) = 20 , we know that we only need to know B B modulo 20.

Split 20 as 4 × 5 4\times 5 . The exponent B = 1 7 C 1 B = 17^C \equiv 1 mod 4. We need to find B = 1 7 C 2 C B = 17^C \equiv 2^C mod 5. Since ϕ ( 5 ) = 4 \phi(5) = 4 , we only need to know C C modulo 4. This is easy: C = 1 7 D 1 C = 17^D \equiv 1 mod 4, so that B 2 1 2 B \equiv 2^1 \equiv 2 mod 5.

Now, since B 2 B \equiv 2 mod 5 and B 1 B \equiv 1 mod 4, we have B 17 3 B \equiv 17 \equiv -3 mod 20. This means that A ( 8 ) 3 = ( 2 1 ) 9 A \equiv (-8)^{-3} = -(2^{-1})^9 mod 25. Using 12 2 = 24 1 -12\cdot 2 = -24 \equiv 1 mod 25, we have 2 1 = 12 2^{-1} = -12 and A 1 2 9 3 3 2 A \equiv 12^9 \equiv 3^3 \equiv 2 mod 25.

Finally, from A 1 A \equiv 1 mod 4 and A 2 A \equiv 2 mod 25 it follows that A 77 A \equiv \boxed{77} mod 100.

x = 18:

A = 1 8 B 0 A = 18^B \equiv 0 mod 4, since certainly B 2 B \geq 2 . To determine A = 1 8 B ( 7 ) B A = 18^B \equiv (-7)^B mod 25, we could again determine B B to modulo 20. However, since 7 2 = 49 1 7^2 = 49 \equiv -1 mod 25, we only need to know B B to modulo 4. This is easy because 18 is even: B = 1 8 C 0 B = 18^C \equiv 0 mod 4, and A ( 7 ) 0 = 1 A \equiv (-7)^0 = \equiv 1 mod 25.

Since A 0 A \equiv 0 mod 4 and A 1 A \equiv 1 mod 25, we have A 76 A \equiv \boxed{76} mod 100.

x = 19:

A = 1 9 B ( 1 ) B 1 A = 19^B \equiv (-1)^B \equiv -1 mod 4; we use the fact that B = 1 9 C B = 19^C is odd. Also, A = 1 9 B ( 6 ) B A = 19^B \equiv (-6)^B mod 25. We will once again determine B B modulo 20. (Calculation of 1 9 n 19^n mod 25 shows that we really only need B B mod 10.)

Now B = 1 9 C ( 1 ) C 1 B = 19^C \equiv (-1)^C \equiv -1 mod 4; likewise, B = 1 9 C ( 1 ) C B = 19^C \equiv (-1)^C mod 5. It follows that B 1 B \equiv -1 mod 20. Therefore A ( 6 ) 1 4 A \equiv (-6)^{-1} \equiv 4 mod 25. (We use ( 6 ) 4 = 24 1 (-6)\cdot 4 = -24 \equiv 1 mod 25.)

Combining A 1 A\equiv -1 mod 4 and A 4 A \equiv 4 mod 25, we easily find A 79 A \equiv \boxed{79} mod 100.

x = 20: This is easy since 2 0 B 0 20^B \equiv \boxed{0} mod 100 for B 2 B \geq 2 .

Finally, Adding, we get 79 + 76 + 77 + 0 32 79 + 76 + 77 + 0 \equiv \boxed{32} mod 100.

Sir can you explain it in brief

Ashu Chaurasia - 1 year, 5 months ago

Log in to reply

This is a rather brief solution. The first two lines describe my method. Study Fermat's Little Theorem and the Euler totient function ϕ \phi for more details.

In the details, I use A = x x x x A = x^{x^{x^x}} , B = x x x B = x^{x^x} , C = x x C = x^x .

Arjen Vreugdenhil - 1 year, 5 months ago

Great use of Euler's theorem..........

Anubhav Mahapatra - 3 years, 10 months ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...