Maths Olympiad Prep

Library / /16 of 16

, 2006

Combinatorics Difficulty 7.9 National olympiad, round 2 Prove it Czech-Polish-Slovak Mathematical Match

There are nn children around the round-table. Erika is the oldest among them and she has nn candies. No other child has any candy. Erika decided to distribute the candies and determined following rules. In every round all the children with at least two candies show. Erika chooses one of them and he/she sends one by one candy to both children sitting next to him/her. (So in the first round only Erika shows and sends one by one candy to her two neighbours.) For which n3n \geq 3 is it possible to end the distribution after a finite number of rounds with every child having exactly one candy?

Solution

First we show for nn even the distribution never ends with every child having one candy. In every round only two candies change position and they move in two opposite directions. This leads us to studying the entire sum of distances of candies from one child, say Erika. We label the seats in clockwise direction by numbers 0,1,,n10, 1, \dots, n-1 (as the distance from Erika in this direction). After every round we sum up the distances of all candies. Let the sum be SS (i.e. with every candy we add to SS the number of the seat where the candy actually is). If in the given round Erika chooses child on the seat labeled by kk, whereby 1kn21 \leq k \leq n-2, the value of SS does not change - we sum up (k1)+(k+1)(k-1)+(k+1) instead of 2k2k. If she chooses child on the seat labeled by n1n-1, we sum up (n2)+0(n-2)+0 instead of 2(n1)2(n-1), hence SS decreases by nn. Finally, if she chooses herself, we sum up (n1)+1(n-1)+1 instead of 202 \cdot 0, hence SS increases by nn. At the beginning we have S=0S = 0 and its value can change only by ±n\pm n, hence SS remains divisible by nn after every round. Thus S/nS/n is permanently integer. But in the case when every child has exactly one candy we have
S=0+1+2++(n1)=n(n1)2,i.e.Sn=n12, S = 0 + 1 + 2 + \dots + (n-1) = \frac{n(n-1)}{2}, \quad \text{i.e.} \quad \frac{S}{n} = \frac{n-1}{2},
which is not integer for nn even. Hence such situation never happens.

For odd nn we show there is a distribution ending with every child having one candy. Let n=2k+1n = 2k + 1. We find proper distribution by induction. More precisely we prove that for every i=0,1,,ki = 0, 1, \dots, k we can get position with n2in - 2i candies by Erika, one candy by first ii children sitting to the left side of her, and one candy by first ii children to the right. The value i=0i = 0 represents the beginning of distribution, the value i=1i = 1 the status after the first round (and thus the first step of induction), and the value i=ki = k the status we would like to reach. Suppose we managed to get the specified position for some value i=mi = m with 1m<k1 \leq m < k (and we passed through all positions for i<mi < m). From this status we proceed as follows. First Erika gives one candy to her neighbours (as m<km < k, she has at least three candies thus she can do it). The following rounds are illustrated in the scheme. (The numbers are for amounts of candies by Erika and children on the right side of her. On the left side we proceed simultaneously in the same way.)
n2m,1,,1,0,n2m2,2,1,,1,0,n2m,0,2,1,,1,0,n2m,1,0,2,1,,1,0,n2m,1,1,0,2,1,,1,0,n2m,1,,1,0,2,0,n2m,1,,1,0,1,0,m1 \begin{array}{l} \underline{n-2m, 1, \dots, 1, 0, \dots} \rightarrow \underline{n-2m-2, 2, 1, \dots, 1, 0, \dots} \rightarrow \underline{n-2m, 0, 2, 1, \dots, 1, 0, \dots} \rightarrow \\ \rightarrow \underline{n-2m, 1, 0, 2, 1, \dots, 1, 0, \dots} \rightarrow \underline{n-2m, 1, 1, 0, 2, 1, \dots, 1, 0, \dots} \rightarrow \dots \\ \dots \rightarrow \underline{n-2m, 1, \dots, 1, 0, 2, 0, \dots} \rightarrow \underline{n-2m, 1, \dots, 1, 0, 1, 0, \dots} \\ \qquad \rightarrow \underline{m-1} \end{array}
We get the status, when Erika has n2mn-2m candies, first m1m-1 children on both sides have one candy, the mm-th children have no candy, and the (m+1)(m+1)-st children have one candy. To reach the position for i=m+1i=m+1, it is sufficient to deliver candies to the children on the mm-th seats. But here we can use induction hypothesis. That is if we look apart from candies on the (m+1)(m+1)-st seats, we obtain exactly the position for i=m1i=m-1 (Erika has two candies less, but she still has at least three and thus we can do the same steps). From this position we know how to proceed to the position for i=mi=m. Restoring back prescinded candies we get the position for i=m+1i=m+1.

Thus, finally we also reach the position for i=ki=k.

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

Source: MathNet, licensed CC-BY-4.0. Statement and solution reproduced as published; topic and difficulty added by this site.