Maths Olympiad Prep

Library / IMO Shortlist /258 of 365

IMO Shortlist, 2019

Number theory Difficulty 8.8 Shortlist Prove it IMO

Let H={⌊i2⌋:i∈Z>0}={1,2,4,5,7,…}H=\{\lfloor i \sqrt{2}\rfloor: i \in \mathbb{Z}_{>0}\}=\{1,2,4,5,7, \ldots\}, and let nn be a positive integer. Prove that there exists a constant CC such that, if A⊂{1,2,…,n}A \subset\{1,2, \ldots, n\} satisfies ∣A∣⩾Cn|A| \geqslant C \sqrt{n}, then there exist a,b∈Aa, b \in A such that a−b∈Ha-b \in H. (Here Z>0\mathbb{Z}_{>0} is the set of positive integers, and ⌊z⌋\lfloor z\rfloor denotes the greatest integer less than or equal to zz.)

Solutions — 4

Solution 1

First, observe that if nn is a positive integer, then n∈Hn \in H exactly when
{n2}>1−12(1) \left\{\frac{n}{\sqrt{2}}\right\}>1-\frac{1}{\sqrt{2}} \tag{1}
To see why, observe that n∈Hn \in H if and only if 0<i2−n<10<i \sqrt{2}-n<1 for some i∈Z>0i \in \mathbb{Z}_{>0}. In other words, 0<i−n/2<1/20<i-n / \sqrt{2}<1 / \sqrt{2}, which is equivalent to (1).

Now, write A={a1<a2<⋯<ak}A=\{a_{1}<a_{2}<\cdots<a_{k}\}, where k=∣A∣k=|A|. Observe that the set of differences is not altered by shifting AA, so we may assume that A⊆{0,1,…,n−1}A \subseteq\{0,1, \ldots, n-1\} with a1=0a_{1}=0.

From (1), we learn that {ai/2}<1−1/2\left\{a_{i} / \sqrt{2}\right\}<1-1 / \sqrt{2} for each i>1i>1 since ai−a1∉Ha_{i}-a_{1} \notin H. Furthermore, we must have {ai/2}<{aj/2}\left\{a_{i} / \sqrt{2}\right\}<\left\{a_{j} / \sqrt{2}\right\} whenever i<ji<j; otherwise, we would have
−(1−12)<{aj2}−{ai2}<0 -\left(1-\frac{1}{\sqrt{2}}\right)<\left\{\frac{a_{j}}{\sqrt{2}}\right\}-\left\{\frac{a_{i}}{\sqrt{2}}\right\}<0
Since {(aj−ai)/2}={aj/2}−{ai/2}+1\left\{\left(a_{j}-a_{i}\right) / \sqrt{2}\right\}=\left\{a_{j} / \sqrt{2}\right\}-\left\{a_{i} / \sqrt{2}\right\}+1, this implies that {(aj−ai)/2}>1/2>1−1/2\left\{\left(a_{j}-a_{i}\right) / \sqrt{2}\right\}>1 / \sqrt{2}> 1-1 / \sqrt{2}, contradicting (1).

Now, we have a sequence 0=a1<a2<⋯<ak<n0=a_{1}<a_{2}<\cdots<a_{k}<n, with
0={a12}<{a22}<⋯<{ak2}<1−12 0=\left\{\frac{a_{1}}{\sqrt{2}}\right\}<\left\{\frac{a_{2}}{\sqrt{2}}\right\}<\cdots<\left\{\frac{a_{k}}{\sqrt{2}}\right\}<1-\frac{1}{\sqrt{2}}
We use the following fact: for any d∈Zd \in \mathbb{Z}, we have
{d2}>12d2(2) \left\{\frac{d}{\sqrt{2}}\right\}>\frac{1}{2 d \sqrt{2}} \tag{2}
To see why this is the case, let h=⌊d/2⌋h=\lfloor d / \sqrt{2}\rfloor, so {d/2}=d/2−h\{d / \sqrt{2}\}=d / \sqrt{2}-h. Then
{d2}(d2+h)=d2−2h22⩾12 \left\{\frac{d}{\sqrt{2}}\right\}\left(\frac{d}{\sqrt{2}}+h\right)=\frac{d^{2}-2 h^{2}}{2} \geqslant \frac{1}{2}
since the numerator is a positive integer. Because d/2+h<2d/2d / \sqrt{2}+h<2 d / \sqrt{2}, inequality (2) follows.

Let di=ai+1−aid_{i}=a_{i+1}-a_{i}, for 1⩽i<k1 \leqslant i<k. Then {ai+1/2}−{ai/2}={di/2}\left\{a_{i+1} / \sqrt{2}\right\}-\left\{a_{i} / \sqrt{2}\right\}=\left\{d_{i} / \sqrt{2}\right\}, and we have
1−12>∑i{di2}>122∑i1di⩾(k−1)2221∑idi>(k−1)222⋅1n.(3) 1-\frac{1}{\sqrt{2}}>\sum_{i}\left\{\frac{d_{i}}{\sqrt{2}}\right\}>\frac{1}{2 \sqrt{2}} \sum_{i} \frac{1}{d_{i}} \geqslant \frac{(k-1)^{2}}{2 \sqrt{2}} \frac{1}{\sum_{i} d_{i}}>\frac{(k-1)^{2}}{2 \sqrt{2}} \cdot \frac{1}{n} . \tag{3}
Here, the first inequality holds because {ak/2}<1−1/2\left\{a_{k} / \sqrt{2}\right\}<1-1 / \sqrt{2}, the second follows from (2), the third follows from an easy application of the AM-HM inequality (or Cauchy-Schwarz), and the fourth follows from the fact that ∑idi=ak<n\sum_{i} d_{i}=a_{k}<n.

Rearranging this, we obtain
22−2⋅n>k−1 \sqrt{2 \sqrt{2}-2} \cdot \sqrt{n}>k-1
which provides the required bound on kk.

Solution 2

Let α=2+2\alpha=2+\sqrt{2}, so (1/α)+(1/2)=1(1 / \alpha)+(1 / \sqrt{2})=1. Thus, J={⌊iα⌋:i∈Z>0}J=\{\lfloor i \alpha\rfloor: i \in \mathbb{Z}_{>0}\} is the complementary Beatty sequence to HH (in other words, HH and JJ are disjoint with H∪J=Z>0H \cup J=\mathbb{Z}_{>0} ). Write A={a1<a2<⋯<ak}A=\{a_{1}<a_{2}<\cdots<a_{k}\}. Suppose that AA has no differences in HH, so all its differences are in JJ and we can set ai−a1=⌊αbi⌋a_{i}-a_{1}=\lfloor\alpha b_{i}\rfloor for bi∈Z>0b_{i} \in \mathbb{Z}_{>0}.

For any j>ij>i, we have aj−ai=⌊αbj⌋−⌊αbi⌋a_{j}-a_{i}=\lfloor\alpha b_{j}\rfloor-\lfloor\alpha b_{i}\rfloor. Because aj−ai∈Ja_{j}-a_{i} \in J, we also have aj−ai=⌊αt⌋a_{j}-a_{i}=\lfloor\alpha t\rfloor for some positive integer tt. Thus, ⌊αt⌋=⌊αbj⌋−⌊αbi⌋\lfloor\alpha t\rfloor=\lfloor\alpha b_{j}\rfloor-\lfloor\alpha b_{i}\rfloor. The right hand side must equal either ⌊α(bj−bi)⌋\lfloor\alpha(b_{j}-b_{i})\rfloor or ⌊α(bj−bi)⌋−1\lfloor\alpha(b_{j}-b_{i})\rfloor-1, the latter of which is not a member of JJ as α>2\alpha>2. Therefore, t=bj−bit=b_{j}-b_{i} and so we have ⌊αbj⌋−⌊αbi⌋=⌊α(bj−bi)⌋\lfloor\alpha b_{j}\rfloor-\lfloor\alpha b_{i}\rfloor=\lfloor\alpha(b_{j}-b_{i})\rfloor.

For 1⩽i<k1 \leqslant i<k we now put di=bi+1−bid_{i}=b_{i+1}-b_{i}, and we have
⌊α∑idi⌋=⌊αbk⌋=∑i⌊αdi⌋ \lfloor\alpha \sum_{i} d_{i}\rfloor=\lfloor\alpha b_{k}\rfloor=\sum_{i}\lfloor\alpha d_{i}\rfloor
that is, ∑i{αdi}<1\sum_{i}\{\alpha d_{i}\}<1. We also have
1+⌊α∑idi⌋=1+ak−a1⩽ak⩽n 1+\lfloor\alpha \sum_{i} d_{i}\rfloor=1+a_{k}-a_{1} \leqslant a_{k} \leqslant n
so ∑idi⩽n/α\sum_{i} d_{i} \leqslant n / \alpha.

With the above inequalities, an argument similar to (3) (which uses the fact that {αd}={d2}>1/(2d2)\{\alpha d\}= \{d \sqrt{2}\}>1 /(2 d \sqrt{2}) for positive integers dd ) proves that 1>((k−1)2/(22))(α/n)1>\left((k-1)^{2} /(2 \sqrt{2})\right)(\alpha / n), which again rearranges to give
22−2⋅n>k−1 \sqrt{2 \sqrt{2}-2} \cdot \sqrt{n}>k-1

Solution 3

Again, define J=Z>0\HJ=\mathbb{Z}_{>0} \backslash H, so all differences between elements of AA are in JJ. We start by making the following observation. Suppose we have a set B⊆{1,2,…,n}B \subseteq\{1,2, \ldots, n\} such that all of the differences between elements of BB are in HH. Then ∣A∣⋅∣B∣⩽2n|A| \cdot|B| \leqslant 2 n.

To see why, observe that any two sums of the form a+ba+b with a∈A,b∈Ba \in A, b \in B are different; otherwise, we would have a1+b1=a2+b2a_{1}+b_{1}=a_{2}+b_{2}, and so ∣a1−a2∣=∣b2−b1∣|a_{1}-a_{2}|=|b_{2}-b_{1}|. However, then the left hand side is in JJ whereas the right hand side is in HH. Thus, {a+b:a∈A,b∈B}\{a+b: a \in A, b \in B\} is a set of size ∣A∣⋅∣B∣|A| \cdot|B| all of whose elements are no greater than 2n2 n, yielding the claimed inequality.

With this in mind, it suffices to construct a set BB, all of whose differences are in HH and whose size is at least C′nC' \sqrt{n} for some constant C′>0C'>0.

To do so, we will use well-known facts about the negative Pell equation X2−2Y2=−1X^{2}-2 Y^{2}=-1; in particular, that there are infinitely many solutions and the values of XX are given by the recurrence X1=1,X2=7X_{1}=1, X_{2}=7 and Xm=6Xm−1−Xm−2X_{m}=6 X_{m-1}-X_{m-2}. Therefore, we may choose XX to be a solution with n/6<X⩽n\sqrt{n} / 6<X \leqslant \sqrt{n}.

Now, we claim that we may choose B={X,2X,…,⌊(1/3)n⌋X}B=\{X, 2 X, \ldots,\lfloor(1 / 3) \sqrt{n}\rfloor X\}. Indeed, we have
(X2−Y)(X2+Y)=−12 \left(\frac{X}{\sqrt{2}}-Y\right)\left(\frac{X}{\sqrt{2}}+Y\right)=\frac{-1}{2}
and so
0>(X2−Y)⩾−32n, 0>\left(\frac{X}{\sqrt{2}}-Y\right) \geqslant \frac{-3}{\sqrt{2 n}},
from which it follows that {X/2}>1−(3/2n)\{X / \sqrt{2}\}>1-(3 / \sqrt{2 n}). Combined with (1), this shows that all differences between elements of BB are in HH.

Solution 4

As in Solution 3, we will provide a construction of a large set B⊆{1,2,…,n}B \subseteq\{1,2, \ldots, n\}, all of whose differences are in HH.

Choose YY to be a solution to the Pell-like equation X2−2Y2=±1X^{2}-2 Y^{2}= \pm 1; such solutions are given by the recurrence Y1=1,Y2=2Y_{1}=1, Y_{2}=2 and Ym=2Ym−1+Ym−2Y_{m}=2 Y_{m-1}+Y_{m-2}, and so we can choose YY such that n/(32)<Y⩽n/2n /(3 \sqrt{2})<Y \leqslant n / \sqrt{2}. Furthermore, it is known that for such a YY and for 1⩽x<Y1 \leqslant x<Y,
{x2}+{(Y−x)2}={Y/2}(4) \{x \sqrt{2}\}+\{(Y-x) \sqrt{2}\}=\{Y / \sqrt{2}\} \tag{4}
if X2−2Y2=1X^{2}-2 Y^{2}=1, and
{x2}+{(Y−x)2}=1+{Y/2}(5) \{x \sqrt{2}\}+\{(Y-x) \sqrt{2}\}=1+\{Y / \sqrt{2}\} \tag{5}
if X2−2Y2=−1X^{2}-2 Y^{2}=-1. Indeed, this is a statement of the fact that X/YX / Y is a best rational approximation to 2\sqrt{2}, from below in the first case and from above in the second.

Now, consider the sequence {2},{22},…,{(Y−1)2}\{\sqrt{2}\},\{2 \sqrt{2}\}, \ldots,\{(Y-1) \sqrt{2}\}. The Erdős-Szekeres theorem tells us that this sequence has a monotone subsequence with at least Y−2+1>Y\sqrt{Y-2}+1>\sqrt{Y} elements; if that subsequence is decreasing, we may reflect (using (4) or (5)) to ensure that it is increasing. Call the subsequence {y12},{y22},…,{yt2}\{y_{1} \sqrt{2}\},\{y_{2} \sqrt{2}\}, \ldots,\{y_{t} \sqrt{2}\} for t>Yt>\sqrt{Y}.

Now, set B={⌊yi2⌋:1⩽i⩽t}B=\{\lfloor y_{i} \sqrt{2}\rfloor: 1 \leqslant i \leqslant t\}. We have ⌊yj2⌋−⌊yi2⌋=⌊(yj−yi)2⌋\lfloor y_{j} \sqrt{2}\rfloor-\lfloor y_{i} \sqrt{2}\rfloor=\lfloor(y_{j}-y_{i}) \sqrt{2}\rfloor for i<ji<j (because the corresponding inequality for the fractional parts holds by the ordering assumption on the {yi2}\{y_{i} \sqrt{2}\} ), which means that all differences between elements of BB are indeed in HH. Since ∣B∣>Y>n/32|B|>\sqrt{Y}>\sqrt{n} / \sqrt{3 \sqrt{2}}, this is the required set.

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.