Maths Olympiad Prep

Library / /10 of 27

Combinatorics Difficulty 5.8 AIME, harder Prove it Romania

Given any nn positive integers, and a sequence of 2n2^n integers (with terms among them), prove there exists a subsequence made of consecutive terms, such that the product of its terms is a perfect square.
Also show that we cannot replace 2n2^n with any lower value (therefore 2n2^n is the threshold value for this property).

Solution

Since the integers could well be distinct primes, this is equivalent to proving the stricter problem of, given a finite alphabet AA of nn letters a1,a2,,ana_1, a_2, \dots, a_n, and a word ww of length 2n2^n on this alphabet, to show it contains a nonempty contiguous subword xx (w=uxvw = \overline{uxv}, where u,vu, v could be the empty word), in which each letter appears at an even number of times.

Let us, further on, identify the letter aka_k with the element ekZ2n\mathbf{e}_k \in \mathbb{Z}_2^n given by ek=(0,,0,1,0,,0)\mathbf{e}_k = (0, \dots, 0, 1, 0, \dots, 0), where the 1 is at the kkth position. Now the requirement is to find a subword such that the sum of its elements is 0=(0,0,,0)\mathbf{0} = (0, 0, \dots, 0).

We will apply a classical idea of Erdős. Let w=x1x2x2nw = \overline{x_1x_2\dots x_{2^n}} be the word, with xi{e1,e2,,en}x_i \in \{\mathbf{e}_1, \mathbf{e}_2, \dots, \mathbf{e}_n\} for all i=1,2,,2ni = 1, 2, \dots, 2^n. Define σk=i=1kxi\sigma_k = \sum_{i=1}^k x_i for all k=1,2,,2nk = 1, 2, \dots, 2^n. If any of σk=0\sigma_k = \mathbf{0}, we are done, since x1xk\overline{x_1\dots x_k} can be taken as the subword; otherwise there must exist 1p<q2n1 \le p < q \le 2^n such that σp=σq\sigma_p = \sigma_q, so then 0=σqσp=i=1qpxp+i\mathbf{0} = \sigma_q - \sigma_p = \sum_{i=1}^{q-p} x_{p+i}, and we can take the subword xp+1xq\overline{x_{p+1}\dots x_q}.

Let us notice that the result is tight. There exist words of length 2n12^n - 1 without this property. We can build them inductively. Take w1=a1w_1 = \overline{a_1}, and build wn+1=wnan+1wnw_{n+1} = \overline{w_n a_{n+1} w_n} for all n1n \ge 1.

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.