Olympiad Maths Prep

Track / Stage 5 / 215 of 400 #815 of 2000

Problem 815

AIME late
Number theory Difficulty 5.5 Find the answer

102410 \cdot 24 Find all natural numbers nn such that the fractions 1n\frac{1}{n} and 1n+1\frac{1}{n+1} can both be expressed as finite decimal fractions.
(Moscow Mathematical Olympiad, 45th, 1982)

Official solution

[Solution] If the fractions 1n\frac{1}{n} and 1n+1\frac{1}{n+1} can be expressed as finite decimal numbers, then it must be that
{n=2a5b,n+1=2c5d. \left\{\begin{array}{l} n=2^{a} \cdot 5^{b}, \\ n+1=2^{c} \cdot 5^{d} . \end{array}\right.

where a,b,c,da, b, c, d are non-negative integers.
Thus, we have 2c5d2a5b=1\quad 2^{c} \cdot 5^{d}-2^{a} \cdot 5^{b}=1.
When ac,bda \leqslant c, \quad b \leqslant d, we have
2a5b(2ca5db1)=1. 2^{a} \cdot 5^{b}\left(2^{c-a} \cdot 5^{d-b}-1\right)=1 .

That is
{2a5b=1,2ca5db1=1. \left\{\begin{array}{l} 2^{a} \cdot 5^{b}=1, \\ 2^{c-a} \cdot 5^{d-b}-1=1 . \end{array}\right.

From this, we solve a=0,b=0,c=1,d=0a=0, b=0, c=1, d=0.
Thus, n=1,n+1=2n=1, n+1=2.
When ca,bdc \leqslant a, \quad b \leqslant d, we have
2c5b(5db2ac)=1 2^{c} \cdot 5^{b}\left(5^{d-b}-2^{a-c}\right)=1 \text {. }

That is
{2c5b=1,5db2ac=1. \left\{\begin{array}{l} 2^{c} \cdot 5^{b}=1, \\ 5^{d-b}-2^{a-c}=1 . \end{array}\right.

From this, we solve c=0,b=0c=0, \quad b=0, thus
5d2a=1. 5^{d}-2^{a}=1 .

Next, we find all non-negative integer solutions to (1).
Considering mod3\bmod 3, we have
22k1(mod3)22k+12(mod3) \begin{array}{l} 2^{2 k} \equiv 1 \quad(\bmod 3) \\ 2^{2 k+1} \equiv 2 \quad(\bmod 3) \end{array}

where kk is a non-negative integer.
Thus, from
1=5d2a2d2a(mod3), 1=5^{d}-2^{a} \equiv 2^{d}-2^{a}(\bmod 3),

we know that dd is odd, and aa is even, so
2a=5d1=(51)(5d1+5d2++1).5d1+5d2++1 \begin{aligned} 2^{a} & =5^{d}-1 \\ & =(5-1)\left(5^{d-1}+5^{d-2}+\cdots+1\right) . \\ & 5^{d-1}+5^{d-2}+\cdots+1 \end{aligned}

Notice that
is the sum of dd odd numbers, and is a factor of 2a2^{a}, so it can only be 1, thus d=1d=1, and hence a=2a=2.
That is, the non-negative integer solutions to (1) are only a=2,d=1a=2, d=1.
At this time
n=2a5b=4 n=2^{a} \cdot 5^{b}=4 \text {. }

Therefore, only
n=1 and n=4 n=1 \text { and } n=4 \text {. }

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