Subfield: Combinatorics


Question: For $n \geq 2$, let $S_{1}, S_{2}, \ldots, S_{2^{n}}$ be $2^{n}$ subsets of $A=\left\{1,2,3, \ldots, 2^{n+1}\right\}$ that satisfy the following property: There do not exist indices $a$ and $b$ with $a<b$ and elements $x, y, z \in A$ with $x<y<z$ such that $y, z \in S_{a}$ and $x, z \in S_{b}$. Prove that at least one of the sets $S_{1}, S_{2}, \ldots, S_{2^{n}}$ contains no more than $4 n$ elements.

Solution:
We prove that there exists a set $S_{a}$ with at most $3 n+1$ elements.

Given a $k \in\{1, \ldots, n\}$, we say that an element $z \in A$ is $k$-good to a set $S_{a}$ if $z \in S_{a}$ and $S_{a}$ contains two other elements $x$ and $y$ with $x<y<z$ such that $z-y<2^{k}$ and $z-x \geq 2^{k}$. Also, $z \in A$ will be called $\operatorname{good}$ to $S_{a}$ if $z$ is $k$-good to $S_{a}$ for some $k=1, \ldots, n$.

We claim that each $z \in A$ can be $k$-good to at most one set $S_{a}$. Indeed, suppose on the contrary that $z$ is $k$-good simultaneously to $S_{a}$ and $S_{b}$, with $a<b$. Then there exist $y_{a} \in S_{a}$, $y_{a}<z$, and $x_{b} \in S_{b}, x_{b}<z$, such that $z-y_{a}<2^{k}$ and $z-x_{b} \geq 2^{k}$. On the other hand, since $z \in S_{a} \cap S_{b}$, by the condition of the problem there is no element of $S_{a}$ strictly between $x_{b}$ and $z$. Hence $y_{a} \leq x_{b}$, implying $z-y_{a} \geq z-x_{b}$. However this contradicts $z-y_{a}<2^{k}$ and $z-x_{b} \geq 2^{k}$. The claim follows.

As a consequence, a fixed $z \in A$ can be good to at most $n$ of the given sets (no more than one of them for each $k=1, \ldots, n$ ).

Furthermore, let $u_{1}<u_{2}<\cdots<u_{m}<\cdots<u_{p}$ be all elements of a fixed set $S_{a}$ that are not good to $S_{a}$. We prove that $u_{m}-u_{1}>2\left(u_{m-1}-u_{1}\right)$ for all $m \geq 3$.

Indeed, assume that $u_{m}-u_{1} \leq 2\left(u_{m-1}-u_{1}\right)$ holds for some $m \geq 3$. This inequality can be written as $2\left(u_{m}-u_{m-1}\right) \leq u_{m}-u_{1}$. Take the unique $k$ such that $2^{k} \leq u_{m}-u_{1}<2^{k+1}$. Then $2\left(u_{m}-u_{m-1}\right) \leq u_{m}-u_{1}<2^{k+1}$ yields $u_{m}-u_{m-1}<2^{k}$. However the elements $z=u_{m}, x=u_{1}$, $y=u_{m-1}$ of $S_{a}$ then satisfy $z-y<2^{k}$ and $z-x \geq 2^{k}$, so that $z=u_{m}$ is $k$-good to $S_{a}$.

Thus each term of the sequence $u_{2}-u_{1}, u_{3}-u_{1}, \ldots, u_{p}-u_{1}$ is more than twice the previous one. Hence $u_{p}-u_{1}>2^{p-1}\left(u_{2}-u_{1}\right) \geq 2^{p-1}$. But $u_{p} \in\left\{1,2,3, \ldots, 2^{n+1}\right\}$, so that $u_{p} \leq 2^{n+1}$. This yields $p-1 \leq n$, i. e. $p \leq n+1$.

In other words, each set $S_{a}$ contains at most $n+1$ elements that are not good to it.

To summarize the conclusions, mark with red all elements in the sets $S_{a}$ that are good to the respective set, and with blue the ones that are not good. Then the total number of red elements, counting multiplicities, is at most $n \cdot 2^{n+1}$ (each $z \in A$ can be marked red in at most $n$ sets). The total number of blue elements is at most $(n+1) 2^{n}$ (each set $S_{a}$ contains at most $n+1$ blue elements). Therefore the sum of cardinalities of $S_{1}, S_{2}, \ldots, S_{2^{n}}$ does not exceed $(3 n+1) 2^{n}$. By averaging, the smallest set has at most $3 n+1$ elements.
We show that one of the sets $S_{a}$ has at most $2 n+1$ elements. In the sequel $|\cdot|$ denotes the cardinality of a (finite) set.

Claim. For $n \geq 2$, suppose that $k$ subsets $S_{1}, \ldots, S_{k}$ of $\left\{1,2, \ldots, 2^{n}\right\}$ (not necessarily different) satisfy the condition of the problem. Then

$$
\sum_{i=1}^{k}\left(\left|S_{i}\right|-n\right) \leq(2 n-1) 2^{n-2}
$$

Proof. Observe that if the sets $S_{i}(1 \leq i \leq k)$ satisfy the condition then so do their arbitrary subsets $T_{i}(1 \leq i \leq k)$. The condition also holds for the sets $t+S_{i}=\left\{t+x \mid x \in S_{i}\right\}$ where $t$ is arbitrary.

Note also that a set may occur more than once among $S_{1}, \ldots, S_{k}$ only if its cardinality is less than 3, in which case its contribution to the sum $\sum_{i=1}^{k}\left(\left|S_{i}\right|-n\right.$ ) is nonpositive (as $n \geq 2$ ).

The proof is by induction on $n$. In the base case $n=2$ we have subsets $S_{i}$ of $\{1,2,3,4\}$. Only the ones of cardinality 3 and 4 need to be considered by the remark above; each one of



them occurs at most once among $S_{1}, \ldots, S_{k}$. If $S_{i}=\{1,2,3,4\}$ for some $i$ then no $S_{j}$ is a 3 -element subset in view of the condition, hence $\sum_{i=1}^{k}\left(\left|S_{i}\right|-2\right) \leq 2$. By the condition again, it is impossible that $S_{i}=\{1,3,4\}$ and $S_{j}=\{2,3,4\}$ for some $i, j$. So if $\left|S_{i}\right| \leq 3$ for all $i$ then at most 3 summands $\left|S_{i}\right|-2$ are positive, corresponding to 3 -element subsets. This implies $\sum_{i=1}^{k}\left(\left|S_{i}\right|-2\right) \leq 3$, therefore the conclusion is true for $n=2$.

Suppose that the claim holds for some $n \geq 2$, and let the sets $S_{1}, \ldots, S_{k} \subseteq\left\{1,2, \ldots, 2^{n+1}\right\}$ satisfy the given property. Denote $U_{i}=S_{i} \cap\left\{1,2, \ldots, 2^{n}\right\}, V_{i}=S_{i} \cap\left\{2^{n}+1, \ldots, 2^{n+1}\right\}$. Let

$$
I=\left\{i|1 \leq i \leq k,| U_{i} \mid \neq 0\right\}, \quad J=\{1, \ldots, k\} \backslash I
$$

The sets $S_{j}$ with $j \in J$ are all contained in $\left\{2^{n}+1, \ldots, 2^{n+1}\right\}$, so the induction hypothesis applies to their translates $-2^{n}+S_{j}$ which have the same cardinalities. Consequently, this gives $\sum_{j \in J}\left(\left|S_{j}\right|-n\right) \leq(2 n-1) 2^{n-2}$, so that

$$
\sum_{j \in J}\left(\left|S_{j}\right|-(n+1)\right) \leq \sum_{j \in J}\left(\left|S_{j}\right|-n\right) \leq(2 n-1) 2^{n-2}\tag{1}
$$

For $i \in I$, denote by $v_{i}$ the least element of $V_{i}$. Observe that if $V_{a}$ and $V_{b}$ intersect, with $a<b$, $a, b \in I$, then $v_{a}$ is their unique common element. Indeed, let $z \in V_{a} \cap V_{b} \subseteq S_{a} \cap S_{b}$ and let $m$ be the least element of $S_{b}$. Since $b \in I$, we have $m \leq 2^{n}$. By the condition, there is no element of $S_{a}$ strictly between $m \leq 2^{n}$ and $z>2^{n}$, which implies $z=v_{a}$.

It follows that if the element $v_{i}$ is removed from each $V_{i}$, a family of pairwise disjoint sets $W_{i}=V_{i} \backslash\left\{v_{i}\right\}$ is obtained, $i \in I$ (we assume $W_{i}=\emptyset$ if $V_{i}=\emptyset$ ). As $W_{i} \subseteq\left\{2^{n}+1, \ldots, 2^{n+1}\right\}$ for all $i$, we infer that $\sum_{i \in I}\left|W_{i}\right| \leq 2^{n}$. Therefore $\sum_{i \in I}\left(\left|V_{i}\right|-1\right) \leq \sum_{i \in I}\left|W_{i}\right| \leq 2^{n}$.

On the other hand, the induction hypothesis applies directly to the sets $U_{i}, i \in I$, so that $\sum_{i \in \mathcal{I}}\left(\left|U_{i}\right|-n\right) \leq(2 n-1) 2^{n-2}$. In summary,

$$
\sum_{i \in I}\left(\left|S_{i}\right|-(n+1)\right)=\sum_{i \in I}\left(\left|U_{i}\right|-n\right)+\sum_{i \in I}\left(\left|V_{i}\right|-1\right) \leq(2 n-1) 2^{n-2}+2^{n}\tag{2}
$$

The estimates (1) and (2) are sufficient to complete the inductive step:

$$
\begin{aligned}
\sum_{i=1}^{k}\left(\left|S_{i}\right|-(n+1)\right) & =\sum_{i \in I}\left(\left|S_{i}\right|-(n+1)\right)+\sum_{j \in J}\left(\left|S_{j}\right|-(n+1)\right) \\
& \leq(2 n-1) 2^{n-2}+2^{n}+(2 n-1) 2^{n-2}=(2 n+1) 2^{n-1}
\end{aligned}
$$

Returning to the problem, consider $k=2^{n}$ subsets $S_{1}, S_{2}, \ldots, S_{2^{n}}$ of $\left\{1,2,3, \ldots, 2^{n+1}\right\}$. If they satisfy the given condition, the claim implies $\sum_{i=1}^{2^{n}}\left(\left|S_{i}\right|-(n+1)\right) \leq(2 n+1) 2^{n-1}$. By averaging again, we see that the smallest set has at most $2 n+1$ elements.