Maths Olympiad Prep

Library /

Combinatorics Difficulty 9.1 IMO level Prove it Bulgaria

Let nn be a natural number. King Arthur has invited 2n12^n - 1 knights to an audience in Camelot. Merlin the Magician arranged the knights in a list numbered from 11 to 2n12^n - 1. It turned out that any two knights with numbers a,b,a<ba, b, a < b are friends if and only if 0b2a10 \le b - 2a \le 1. The king chose a natural number kk and ordered Merlin to make a new list with the following requirement. For each 1i2nk11 \le i \le 2^n - k - 1, all friends of the knight with sequence number ii (in the new list) must be in positions among 1,2,,i+k1, 2, \dots, i + k. Prove that the smallest kk, for which Merlin can fulfil Arthur's wish, satisfies the condition
11002nnk1002nn. \frac{1}{100} \cdot \frac{2^n}{n} \le k \le 100 \cdot \frac{2^n}{n}.
(Dragomir Grozev)

Solution

Let us construct a graph TT with vertex-set which is the set of all knights, numbered as in the first list. Two vertices are adjacent if the corresponding knights are friends. It can be seen that TT is a fully balanced binary tree - see fig. 1. We label each vertex with the knight's number in the first list. Let us assume the vertices can be arranged in a row i1,i2,,imi_1, i_2, \dots, i_m as King Arthur requested, where m=2n1m = 2^n - 1 and iji_j refers to the label of the corresponding vertex. There is a unique path in TT, i1=v1v2v=imi_1 = v_1v_2\dots v_\ell = i_m that connects the vertex labeled as i1i_1 and imi_m. Clearly, 2(n1)+1\ell \le 2(n-1) + 1, because the longest path in TT has length 2(n1)2(n-1). Note that the distance between the positions of viv_i and vi+1v_{i+1} in the new list, is at most kk. This means that (1)km1(\ell - 1)k \ge m - 1 which yields
k2n22n2>2n4n, k \ge \frac{2^n - 2}{2n - 2} > \frac{2^n}{4n},
which proves the lower bound for kk.

Now we will arrange the vertices of TT in a list. Let \ell be a natural number which will be determined later. Denote by v1,v2,,vs,s:=2v_1, v_2, \dots, v_s, s := 2^\ell the vertices of TT on the \ell-th level, and let T(v1),T(v2),,T(vs)T(v_1), T(v_2), \dots, T(v_s) be the subtrees with roots in these points - see fig. 1. Each of them has exactly 2n12^{n-1-\ell} leaves.

We successively put in a list the vertices of TT as follows. First, we place the last level of vertices of T(v1)T(v_1), that is, its leaves. Then we put down the second to last level of T(v1)T(v_1) and the last level of T(v2)T(v_2). At the ii-th step we place the ii-th level of T(v1)T(v_1), counting from the bottom up (fig. 1), then the i1i-1-th level of T(v2)T(v_2) (from the bottom up) and so on, and finally - the last layer of T(vi)T(v_i) (i.e. its leaves). The number of vertices we place at the ii-th step i=1,2,,s1i = 1, 2, \dots, s-\ell-1 is equal to
j=0i12n1j2n. \sum_{j=0}^{i-1} 2^{n-1-\ell-j} \le 2^{n-\ell}.
We follow these steps until one of the two events happens. 1) We reach the root v1v_1 of T(v1)T(v_1). 2) We place in the list the leaves of T(vs)T(v_s). The first event will

Figure 1

happen after nn-\ell steps and the second one - after s=2s = 2^\ell steps. To ensure that the second event occurs first we choose \ell to be the largest positive integer for which s=2ns = 2^\ell \le n - \ell.

In this situation, at the s-th step we have put the leaves of T(vs)T(v_s) in the list. On the s + 1-th step we put in the list the remaining vertices of T. The number of all vertices in T(vs)T(v_s) without its last level does not exceed 2n12^{n-\ell-1}. The number of vertices in T(vs1)T(v_{s-1}) without its last two layers does not exceed 2n22^{n-\ell-2} and so on. Adding the vertices of T up to its l-th level, we obtain that the number of the vertices ordered at the last step is at most
22+2n22n82nn 2 \cdot 2^{\ell} + 2^{n-\ell} \le 2 \cdot 2^{n-\ell} \le 8 \cdot \frac{2^n}{n}
since 2n+2n2^{n+2} \ge n. Clearly, for any vertex vv, placed at position jj in the first ss steps, all of its neighbours in TT, that are placed after it, are in positions with numbers not exceeding j+22nj+82nnj+2 \cdot 2^{n-\ell} \le j+8 \cdot \frac{2^n}{n}. Taking into account the number of vertices added in the last step, we get that in the constructed list the condition imposed by the king holds for
k:=162nn k := \left\lceil 16 \cdot \frac{2^n}{n} \right\rceil

This proves the upper bound. □

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.