Olympiad Maths Prep

Track / Stage 8 / 53 of 180 #1753 of 2000

Problem 1753

IMO Shortlist mid-range; USAMO P2/P5
Number theory Difficulty 8.1 Find the answer imo_shortlist

Determine all integers n2n\geqslant 2 with the following property: every nn pairwise distinct integers whose sum is not divisible by nn can be arranged in some order a1,a2,,ana_1,a_2,\ldots, a_n so that nn divides 1a1+2a2++nan.1\cdot a_1+2\cdot a_2+\cdots+n\cdot a_n.

[i]Arsenii Nikolaiev, Anton Trygub, Oleksii Masalitin, and Fedir Yudin[/i]

Official solution

To solve the problem, we need to determine all integers n2 n \geq 2 such that for any set of n n pairwise distinct integers whose sum is not divisible by n n , there exists a permutation of these integers a1,a2,,an a_1, a_2, \ldots, a_n satisfying:

n(1a1+2a2++nan). n \mid (1 \cdot a_1 + 2 \cdot a_2 + \cdots + n \cdot a_n).

### Analysis:

1. Understanding the Conditions:
- We are given n n integers a1,a2,,an a_1, a_2, \ldots, a_n such that their sum is not divisible by n n :
a1+a2++an≢0(modn). a_1 + a_2 + \cdots + a_n \not\equiv 0 \pmod{n}.

2. Objective:
- Find integers n n for which no matter how the integers are arranged, the weighted sum 1a1+2a2++nan0(modn) 1 \cdot a_1 + 2 \cdot a_2 + \cdots + n \cdot a_n \equiv 0 \pmod{n} .

3. Consideration for Powers of 2:
- Let us consider n n being a power of 2, say n=2k n = 2^k . The important property of powers of 2 is that each number 1,2,,2k 1, 2, \ldots, 2^k appears with equal frequency in any modular arithmetic computation involving 2k 2^k .

4. Consideration for Odd Numbers:
- For odd n n , a notable property is that the cyclic sums and permutations tend to distribute residues in a way such that they cover all possible remainders when divided by n n .

5. Constructing Examples:
- Construct examples for small odd numbers and powers of 2 and verify the conditions:
- For n=3 n = 3 , consider numbers such as {1,2,4}\{1, 2, 4\}: arranging them as {2,1,4}\{2, 1, 4\} yields a sum not divisible by 3 but:
12+21+34=2+2+12=16, 1 \cdot 2 + 2 \cdot 1 + 3 \cdot 4 = 2 + 2 + 12 = 16,
which is divisible by 3.

6. Conclusion:
- Through analysis, it becomes evident that if n n is odd or of the form n=2k n = 2^k , then regardless of the initial sum, we can always find such permutations where the weighted sum is divisible by n n .

Thus, the integers n n that satisfy the given property are all odd numbers and powers of 2. Therefore, the solution to the problem is:
Odd numbers and powers of 2. \boxed{\text{Odd numbers and powers of 2}}.

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