Maths Olympiad Prep

Library / CGMO /9 of 14

CGMO, 2022

Number theory Difficulty 7.0 National Olympiad, round 2 Prove it China

Find all positive integers nn with the following property: there exist nonempty finite sets of integers A,BA, B, such that for every integer mm, exactly one of the following three statements is true,
(i) there exists a∈Aa \in A, such that m≡a(modn)m \equiv a \pmod{n};
(ii) there exists b∈Bb \in B, such that m≡b(modn)m \equiv b \pmod{n};
(iii) there exist a∈Aa \in A and b∈Bb \in B, such that m≡a+b(modn)m \equiv a+b \pmod{n}.

Solution

Proof. Let A+B={a+b∣a∈A,b∈B}A+B = \{a+b \mid a \in A, b \in B\}. The problem can be understood as the remainders of AA modulo nn, the remainders of BB modulo nn, and the remainders of (A+B)(A+B) modulo nn form a partition of all remainders modulo nn.

(1) If n>1n > 1 is an odd number, let n=2k+1n = 2k+1, k∈Z>0k \in \mathbb{Z}_{>0}. Take A={k}A = \{k\}, B={k+1,k+2,…,2k}B = \{k+1, k+2, \dots, 2k\}, then A+B={2k+1,2k+2,…,3k}A+B = \{2k+1, 2k+2, \dots, 3k\}, so A,B,A+BA, B, A+B are pairwise disjoint, and their union is exactly the consecutive 2k+12k+1 numbers, forming a complete system modulo 2k+12k+1, satisfying the condition.

(2) If n>1n > 1 satisfies the condition, then for any integer d>1d > 1, dndn also satisfies the condition. In fact, let the sets corresponding to nn be A,BA, B. Set
A′={a+xn∣a∈A,x=0,1,…,d−1},B′={b+xn∣b∈B,x=0,1,…,d−1} A' = \{a+xn \mid a \in A, x = 0, 1, \dots, d-1\}, \quad B' = \{b+xn \mid b \in B, x = 0, 1, \dots, d-1\}
We verify that A′,B′A', B' satisfy the problem requirements for dndn.
Since the remainders of A′,B′,A′+B′A', B', A' + B' modulo nn are exactly the remainders of A,B,A+BA, B, A+B modulo nn, the remainders of A′,B′,A′+B′A', B', A' + B' modulo nn and modulo dndn have no intersection, so no more than one statements of (i), (ii), and (iii) can hold. Considering any integer mm, if there exists a∈Aa \in A such that m≡a(modn)m \equiv a \pmod{n}, then mm is congruent modulo dndn with one of a+xna+xn (x=0,1,…,d−1x = 0, 1, \dots, d-1), (i) holds. Similarly, if there exists b∈Bb \in B such that m≡b(modn)m \equiv b \pmod{n}, then (ii) holds. If there exist a∈A,b∈Ba \in A, b \in B, such that m≡a+b(modn)m \equiv a+b \pmod{n}, then mm is congruent modulo dndn with one of a+(b+xn)a+(b+xn) (x=0,1,…,d−1x = 0, 1, \dots, d-1), (iii) holds. Therefore, exactly one of (i), (ii), and (iii) holds. A′,B′A', B' satisfy the problem requirements for dndn.
By (1) and (2), all integers n>1n > 1 except powers of 2 satisfy the problem conditions.

(3) When n=8n = 8, it is easy to verify that A={1,2}A = \{1, 2\}, B={3,6}B = \{3, 6\}, A+B={4,5,7,8}A+B = \{4, 5, 7, 8\}, satisfying the requirements. Combining with (2), we know that all 2k2^k (k≥3k \ge 3) satisfy the requirements.

Since A,B,A+BA, B, A+B are all non-empty sets, there are at least three different remainders modulo nn, n≥3n \ge 3, so n=1,2n = 1, 2 do not satisfy the conditions.
When n=4n = 4, if A,BA, B have only one remainder modulo 4, then A+BA+B also has only one remainder modulo 4, which does not satisfy the requirement. If either AA or BB has at least two different remainders modulo 4, assume a1,a2∈Aa_1, a_2 \in A have different remainders modulo 4, and take any b∈Bb \in B, then a1+ba_1+b and a2+ba_2+b also have different remainders modulo 4, so A+BA+B has at least two remainders modulo 4, which also does not satisfy the requirement. Therefore, n=4n = 4 does not satisfy the condition either.

In conclusion, the desired nn are all positive integers except 1, 2, and 4. □\Box

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

Source: MathNet, licensed CC-BY-4.0. Statement reproduced verbatim; metadata (topic, difficulty) added by this project.