problem: Find the greatest positive integer $N$ with the following property: there exist integers $x_{1}, \ldots, x_{N}$ such that $x_{i}^{2}-x_{i} x_{j}$ is not divisible by 1111 for any $i \neq j$.

solution:
We prove that the greatest $N$ with the required property is $N=1000$. First note that $x_{i}^{2}-x_{i} x_{j}=x_{i}\left(x_{i}-x_{j}\right)$, and that the prime factorisation of 1111 is $11 \cdot 101$.

We first show that we can find 1000 integers $x_{1}, x_{2}, \ldots, x_{1000}$ such that $x_{i}^{2}-x_{i} x_{j}$ is not divisible by 1111 for any $i \neq j$. Consider the set $\{1,2, \ldots, 1110\}$. This set contains 10 integers divisible by 101 , and it contains 100 integers divisible by 11 . None of the integers in the set are divisible by both 11 and 101. If we delete all of these $10+100$ integers from the set, we are left with 1000 integers. Call these $x_{1}, x_{2}, \ldots, x_{1000}$. Now we have $11 \nmid x_{i}$ and $101 \nmid x_{i}$ for all $i$. Suppose there are $i \neq j$ with $1111 \mid x_{i}\left(x_{i}-x_{j}\right)$, then we must have $1111 \mid x_{i}-x_{j}$, which is a contradiction, since $x_{i}, x_{j} \in\{1,2, \ldots, 1110\}$. So this set satisfies the requirement.

We now prove that given 1001 (or more) integers $x_{1}, x_{2}, \ldots, x_{1001}$ there are $i \neq j$ with $1111 \mid x_{i}\left(x_{i}-x_{j}\right)$. Suppose for a contradiction that for all indices $i \neq j$, we have that $x_{i}\left(x_{i}-x_{j}\right)$ is not divisible by 1111, and write $X=\left\{x_{1}, \ldots, x_{1001}\right\}$. We may (after reducing modulo 1111 if necessary) assume that $x_{i} \in\{0,1, \ldots, 1110\}$ for all $i$. Then we know that $x_{i} \neq 0$ for all $i$, and $x_{i} \neq x_{j}$ for all $i \neq j$. Suppose for some $i$ we have $11 \mid x_{i}$. (Since $x_{i} \neq 0$, we know that $101 \nmid x_{i}$.) Then any integer $a \neq x_{i}$ with $a \equiv x_{i} \bmod 101$ cannot be an element of $X$, since $1111 \mid x_{i}\left(x_{i}-a\right)$. In $\{1,2, \ldots, 1110\}$ there are 10 such integers, all of them coprime with $11 \cdot 101$. If there are exactly $k$ different values of $i$ such that $11 \mid x_{i}$, there are $10 k$ different integers from $\{1,2, \ldots, 1110\}$ that cannot be elements of $X$, all of them coprime with $11 \cdot 101$. Similarly, if there are exactly $m$ different values of $i$ such that $101 \mid x_{i}$, then there are 100 m different integers from $\{1,2, \ldots, 1110\}$ that cannot be elements of $X$, all of them coprime with $11 \cdot 101$. (Note that those $10 k$ and 100 m integers can overlap.)

In $\{1,2, \ldots, 1110\}$ there are 100 multiples of 11 , there are 10 multiples of 101 and there is no multiple of $11 \cdot 101$, so there are 1000 integers that are coprime with $11 \cdot 101$. In $X$ we have $1001-k-m$ integers that are coprime with $11 \cdot 101$, so exactly $k+m-1$ of the coprime integers in $\{1,2, \ldots, 1110\}$ are not in $X$. This implies that $10 k \leqslant k+m-1$ and $100 m \leqslant k+m-1$. Adding these two inequalities we find $8 k+98 m \leqslant-2$, a clear contradiction. So $N<1001$.

problem_match: Problem 1.

solution_match: Solution.


problem: Let $n$ be a positive integer. Suppose that its positive divisors can be partitioned into pairs (i.e. can be split in groups of two) in such a way that the sum of each pair is a prime number. Prove that these prime numbers are distinct and that none of these are a divisor of $n$.

solution:
Let $d_{1}$ and $d_{2}$ be positive divisors of $n$ that form a pair as given in the problem. If $d_{1}$ and $d_{2}$ have a non-trivial prime divisor $p$ in common, then $p \mid d_{1}+d_{2}$ and $p \leqslant d_{1}<d_{1}+d_{2}$, so $d_{1}+d_{2}$ cannot be prime. Hence $\operatorname{gcd}\left(d_{1}, d_{2}\right)=1$, which implies that $d_{1} d_{2} \mid n$. Suppose the number of positive divisors of $n$ is $2 t$ (it is even since the divisors can be split into pairs). If we now multiply all divisors, then on one hand we have the product of all $d_{1} d_{2}$ where $\left\{d_{1}, d_{2}\right\}$ is a pair, so that product is at most $n^{t}$. On the other hand for every divisor $d$ there is another divisor $\frac{n}{d}$ (since the number of divisors is even, the case $d=\frac{n}{d}$ does not occur), and the product of all those is equal to $n^{t}$. Hence there must be equality in every inequality $d_{1} d_{2} \leqslant n$. So the pairs of divisors given in the problem are all of the form $\left\{d, \frac{n}{d}\right\}$.

Now we prove the two statements in the problem. Suppose that $d, d^{\prime}$ are positive divisors of $n$ such that $d+\frac{n}{d}=d^{\prime}+\frac{n}{d^{\prime}}$. Then $d^{2} d^{\prime}+n d^{\prime}=d\left(d^{\prime}\right)^{2}+n d$, so $d d^{\prime}\left(d-d^{\prime}\right)=n\left(d-d^{\prime}\right)$ and hence $\left(d d^{\prime}-n\right)\left(d-d^{\prime}\right)=0$. Therefore either $d=d^{\prime}$ or $d d^{\prime}=n$, which implies that $\left\{d, \frac{n}{d}\right\}=\left\{d^{\prime}, \frac{n}{d^{\prime}}\right\}$, as required.

Now let $d$ be a positive divisor of $n$. Every prime divisor $p$ of $n$ divides precisely one of $d$ and $\frac{n}{d}$, since $d \frac{n}{d}=n$ and $\operatorname{gcd}\left(d, \frac{n}{d}\right)=1$; so $p \nmid d+\frac{n}{d}$. Therefore $\operatorname{gcd}\left(n, d+\frac{n}{d}\right)=1$. Since $d+\frac{n}{d}>1$ we conclude that $d+\frac{n}{d}$ cannot be a divisor of $n$.

problem_match: Problem 2.


problem:
Find all functions $f: \mathbb{R} \rightarrow \mathbb{Z}$ such that

$$
(f(f(y)-x))^{2}+f(x)^{2}+f(y)^{2}=f(y) \cdot(1+2 f(f(y)))
$$

for all $x, y \in \mathbb{R}$.

solution:
Take $x=y=0$ and write $c=f(0)$, then we find $f(c)^{2}+c^{2}+c^{2}=c+2 c f(c)$, so $(f(c)-c)^{2}=c-c^{2}$. The left-hand side is non-negative, so the right-hand side must be non-negative as well, hence $c-c^{2} \geqslant 0$, so $c(1-c) \geqslant 0$. This implies $0 \leqslant c \leqslant 1$, and since $c \in \mathbb{Z}$, we get $c=0$ or $c=1$. In both cases we have $c-c^{2}=0$, so $f(c)-c=0$, hence $f(c)=c$. Now taking $y=0$ we find for all $x \in \mathbb{R}$ that

$$
(f(c-x))^{2}+f(x)^{2}+c^{2}=c+2 c^{2} .
$$

If $c=0$, then this equation reduces to $f(-x)^{2}+f(x)^{2}=0$, and since the left-hand side consists of the sum of two squares, both squares must be zero. Therefore $f(x)=0$ for all $x$. This function is indeed a solution of the given functional equation.

Now we consider the other case: $c=1$. Then (1) reduces to $f(1-x)^{2}+f(x)^{2}=2$. The left-hand side consists of two squares of integers, so they must both be 1 . Therefore for all $x$ we have $f(x)=1$ or $f(x)=-1$.

Suppose there is an $a$ with $f(a)=-1$. We take $y=a$ in the functional equation; using that $f(w)^{2}=1$ for any $w$, we find $1+1+1=-1 \cdot(1+2 f(-1))$. Both with $f(-1)=1$ and with $f(-1)=-1$ this gives a contradiction. So there exists no such $a$, and we conclude that $f(x)=1$ for all $x \in \mathbb{R}$. This is also a solution of the given functional equation.

We conclude that there are two solutions: $f(x)=0$ for all $x$, and $f(x)=1$ for all $x$.

problem_match: Problem 3.

solution_match: Solution I.


solution:
We proceed as in the first solution up to the point of deriving $f(x)= \pm 1$ for all $x \in \mathbb{R}$. Now we take $x=0$ in the original functional equation, and we find

$$
(f(f(y)))^{2}+f(0)^{2}+f(y)^{2}=f(y) \cdot(1+2 f(f(y)))
$$

We can rewrite this as

$$
(f(y)-f(f(y)))^{2}+f(0)^{2}=f(y)
$$

The left-hand side is non-negative, so $f(y) \geqslant 0$ for all $y$. If we combine this with $f(x)= \pm 1$ for all $x$, we can conclude that $f(x)=1$ for all $x \in \mathbb{R}$. And this is a solution.

solution_match: Solution II.


problem: A circle $\omega$ passes through the two vertices $B$ and $C$ of a triangle $A B C$. Furthermore, $\omega$ intersects segment $A C$ in $D \neq C$ and segment $A B$ in $E \neq B$. On the ray from $B$ through $D$ lies a point $K$ such that $|B K|=|A C|$, and on the ray from $C$ through $E$ lies a point $L$ such that $|C L|=|A B|$. Show that the circumcentre $O$ of triangle $A K L$ lies on $\omega$.

solution: Let $M$ be the midpoint of the arc $B C$ of $\omega$ that is on the same side of $B C$ as $A$. Then $|B M|=|C M|$. We also have $|B A|=|C L|$ and $\angle A B M=\angle E B M=\angle E C M=$ $\angle L C M$. Hence $\triangle A B M \cong \triangle L C M$. So $|A M|=|L M|$. (In case $M=E$ the triangles $A B M$ and $L C M$ are degenerate, but then the proof still works, since $|A M|=|A B|-|B M|=$ $|L C|-|C M|=|L M|$.) Similarly, we prove that $|A M|=|K M|$, so $M$ is the circumcentre of $\triangle A K L$. This means that $M=O$, and hence we are done as $M$ was defined to be on $\omega$.

problem_match: Problem 4.


solution:
We consider the configuration where $O$ is in the interior of triangle $A B C$. The proof for other configurations is similar. Furthermore, we exclude the case that $O=D$ or $O=E$; in those cases it is immediate that $O$ is on $\omega$.

We have $\angle A B K=\angle E B D=\angle E C D=\angle L C A$. Together with $|A B|=|C L|$ and $|A C|=$ $|B K|$ this implies $\triangle A B K \cong \triangle L C A$. Hence $|A K|=|A L|, \angle A K B=\angle L A C$ (denote this angle by $\alpha$ ) and $\angle B A K=\angle C L A$ (denote this angle by $\beta$ ). Furthermore, let $\gamma=\angle B E C=$ $\angle B D C$. Then $\angle B A C=180^{\circ}-\angle B D A-\angle A B D=\angle B D C-\angle A B D=\gamma-\angle A B D$. Therefore $\angle K A L=\angle B A K+\angle L A C-\angle B A C=\alpha+\beta-(\gamma-\angle A B D)=\alpha+\beta+\angle A B D-\gamma$. Note that in triangle $A B K$ we have $\alpha+\beta+\angle A B D=180^{\circ}$, hence $\angle K A L=180^{\circ}-\gamma$.

We have $\angle K O L=2\left(180^{\circ}-\angle K A L\right)=2 \gamma$. Since $|A K|=|A L|$, this implies $\angle A O L=\gamma$. As we also have $\angle A E L=\angle B E C=\gamma$, the quadrilateral $O E L A$ is cyclic. Analogously, $O D K A$ is cyclic. Now we have

$$
\begin{gathered}
\angle D O E=360^{\circ}-\angle D O A-\angle A O E=180^{\circ}-\angle D O A+180^{\circ}-\angle A O E \\
=\angle D K A+\angle A L E=\angle B K A+\angle A L C=\alpha+\beta
\end{gathered}
$$

On the other hand

$$
\angle D B E=\angle K B A=180^{\circ}-\angle B A K-\angle A K B=180^{\circ}-\alpha-\beta .
$$

Hence $\angle D O E+\angle D B E=180^{\circ}$, so $O$ is on the circle containing $D, B$ and $E$, which is $\omega$.