Maths Olympiad Prep

Library / /126 of 155

Combinatorics Difficulty 6.8 National olympiad Prove it Saudi Arabia

Let pp be a prime number and a table of size (p2+p+1)×(p2+p+1)(p^{2}+p+1) \times (p^{2}+p+1) which is divided into unit cells. The way to color some cells of this table is called nice if there are no four colored cells that form a rectangle (the sides of rectangle are parallel to the sides of given table).

1. Let kk be the number of colored cells in some nice coloring way. Prove that k(p+1)(p2+p+1)k \leq (p+1)(p^{2}+p+1). Denote this number as kmaxk_{\text{max}}.

2. Prove that all ordered tuples (a,b,c)(a, b, c) with 0a,b,c<p0 \leq a, b, c < p and a+b+c>0a+b+c>0 can be partitioned into p2+p+1p^{2}+p+1 sets S1,S2,,Sp2+p+1S_{1}, S_{2}, \ldots, S_{p^{2}+p+1} such that two tuples (a1,b1,c1)(a_{1}, b_{1}, c_{1}) and (a2,b2,c2)(a_{2}, b_{2}, c_{2}) belong to the same set if and only if a1ka2,b1kb2,c1kc2(modp)a_{1} \equiv k a_{2}, b_{1} \equiv k b_{2}, c_{1} \equiv k c_{2} \pmod{p} for some k{1,2,3,,p1}k \in \{1,2,3, \ldots, p-1\}.

3. For 1i,jp2+p+11 \leq i, j \leq p^{2}+p+1, if there exist (a1,b1,c1)Si(a_{1}, b_{1}, c_{1}) \in S_{i} and (a2,b2,c2)Sj(a_{2}, b_{2}, c_{2}) \in S_{j} such that a1a2+b1b2+c1c20(modp)a_{1} a_{2}+b_{1} b_{2}+c_{1} c_{2} \equiv 0 \pmod{p}, we color the cell (i,j)(i, j) of the given table. Prove that this coloring way is nice with kmaxk_{\text{max}} colored cells.

Solution

1)
We will count value SS, the number of the tuples (A,B,C)(A, B, C) with column A,BA, B and row CC in relation AC,BCA-C, B-C intersect at the colored cell.

First way, denote xix_{i} as the number of colored cells on the iith row, then
S=i=1p2+p+1(xi2). S = \sum_{i=1}^{p^{2}+p+1} \binom{x_{i}}{2}.

Second way, choose two columns among p2+p+1p^{2}+p+1 columns, we have (p2+p+12)\binom{p^{2}+p+1}{2} ways. And then, we have at most 1 row CC that cuts A,BA, B at two colored cells (since there are no rectangle), then
S(p2+p+12). S \leq \binom{p^{2}+p+1}{2}.

Notice that i=1p2+p+1xi=k\sum_{i=1}^{p^{2}+p+1} x_{i} = k. Hence, we have
(p2+p+12)i=1p2+p+1(xi2)12(1p2+p+1k2k) \binom{p^{2}+p+1}{2} \geq \sum_{i=1}^{p^{2}+p+1} \binom{x_{i}}{2} \geq \frac{1}{2}\left(\frac{1}{p^{2}+p+1} k^{2} - k\right)
or k(p+1)(p2+p+1)k \leq (p+1)(p^{2}+p+1).

2)
Consider the tuples (a,b,c)(a, b, c) in which 0a,b,cp10 \leq a, b, c \leq p-1 and a+b+c>0a+b+c>0, then we have p31p^{3}-1 tuples in total.

Since two tuples (a,b,c)(a, b, c) and (d,e,f)(d, e, f) are considered to belong to the same set if and only if k{1,2,3,,p1}\exists k \in \{1,2,3, \ldots, p-1\} such that akd,bke,ckf(modp)a \equiv k d, b \equiv k e, c \equiv k f \pmod{p}. We have p1p-1 ways to choose kk, then p31p1=p2+p+1\frac{p^{3}-1}{p-1} = p^{2}+p+1 sets satisfy the given condition.

3)
From the way to color the table, one can check that on each row, there are exactly p+1p+1 colored cells. Indeed, we need to prove that ax+by+cz0(modp)a x + b y + c z \equiv 0 \pmod{p} has exactly p+1p+1 solutions that do not belong to the same set S1,S2,,Sp2+p+1S_{1}, S_{2}, \ldots, S_{p^{2}+p+1}.

There are p21p^{2}-1 pairs (x,y)(x, y) and for each pair, there is a unique number zz such that ax+by+cza x + b y + c z is divisible by pp. Each set has p1p-1 solutions, then there are p+1p+1 solutions that do not belong to the same set. Multiply this number with the number of columns, we have verified that there are (p+1)(p2+p+1)(p+1)(p^{2}+p+1) colored cells on the table.

Then, we shall prove that there are no rectangles. For two tuples (a,b,c)(a, b, c) and (d,e,f)(d, e, f) that do not belong to the same set, we need to prove that the following system of equations has no more than one solution:
{ax+by+cz0(modp)dx+ey+fz0(modp) \begin{cases} a x + b y + c z \equiv 0 & (\bmod p) \\ d x + e y + f z \equiv 0 & (\bmod p) \end{cases}
Without loss of generality, we can suppose that becf\frac{b}{e} - \frac{c}{f} is not divisible by pp or bf≢ce(modp)b f \not\equiv c e \pmod{p}, then for all x0=1,,p1x_{0} = 1, \ldots, p-1, there is exactly one value y0,z0y_{0}, z_{0} such that
by0+cz0=ax0,ey0+fz0=dx0(modp). b y_{0} + c z_{0} = a x_{0}, \quad e y_{0} + f z_{0} = d x_{0} \pmod{p}.
On the other hand, there are pp values x0x_{0} and we do not consider the tuple (0,0,0)(0,0,0), then there are at most p1p-1 solutions.

Note that if (x,y,z)(x, y, z) is a solution, then so is (kx,ky,kz)(k x, k y, k z), then the above system has no more than one solution.

This finishes our proof and kmax=(p+1)(p2+p+1)k_{\text{max}} = (p+1)(p^{2}+p+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.