exam: IZho

problem:
Let $\alpha, \beta, \gamma$ be the angles of a triangle opposite to the sides $a, b, c$ respectively. Prove the inequality

$$
2\left(\cos ^{2} \alpha+\cos ^{2} \beta+\cos ^{2} \gamma\right) \geq \frac{a^{2}}{b^{2}+c^{2}}+\frac{b^{2}}{a^{2}+c^{2}}+\frac{c^{2}}{a^{2}+b^{2}}
$$

solution:
By the Law of Sines, RHS equals $\frac{\sin ^{2} \alpha}{\sin ^{2} \beta+\sin ^{2} \gamma}+\frac{\sin ^{2} \beta}{\sin ^{2} \alpha+\sin ^{2} \gamma}+\frac{\sin ^{2} \gamma}{\sin ^{2} \alpha+\sin ^{2} \beta}$. Applying Cauchy-Bunyakowski inequality we have

$$
\sin ^{2} \alpha=\sin ^{2}(\beta+\gamma)=(\sin \beta \cos \gamma+\sin \gamma \cos \beta)^{2} \leq\left(\sin ^{2} \beta+\sin ^{2} \gamma\right)\left(\cos ^{2} \gamma+\cos ^{2} \beta\right)
$$

therefore $\cos ^{2} \beta+\cos ^{2} \gamma \geq \frac{\sin ^{2} \alpha}{\sin ^{2} \beta+\sin ^{2} \gamma}$.

Adding similar inequalities for $\cos ^{2} \gamma+\cos ^{2} \alpha$ and $\cos ^{2} \alpha+\cos ^{2} \beta$ we get the desired result.

solution_match: Solution.


problem: Points $N, K, L$ lie on the sides $A B, B C, C A$ of a triangle $A B C$ respectively so that $A L=B K$ and $C N$ is the bisector of the angle $C$. The segments $A K$ and $B L$ meet at the point $P$. Let $I$ and $J$ be the incentres of the triangles $A P L$ and $B P K$ respectively. The lines $C N$ and $I J$ meet at point $Q$. Prove that $I P=J Q$.

solution:
The case $C A=C B$ is trivial. If $C A \neq C B$, we may suppose, without loss of generality, that $C N$ meets the segment $P K$.

Let the circumcircles $\omega_{1}$ and $\omega_{2}$ of the triangles $A P L$ and $B P K$ respectively meet again at point $T$. Then

$$
\angle L A T=\angle T P B=\angle T K B
$$

and $\angle A L T=\angle A P T=\angle T B K$, that is, $\triangle A L T=\triangle K B T$, hence

$$
A T=T K
$$

It follows from (1) that the quadrilateral $A C K T$ is cyclic; together with (2) this means that $\angle A C T=\angle T C K$, i.e. $T$ lies on the bisector of $C N$.

Let $I J$ meet $\omega_{1}$ and $\omega_{2}$ at $I_{1}$ and $J_{1}$ respectively. Since $\omega_{1}$ and $\omega_{2}$ have equal radii and $A L=B K$, the triangles $A L I_{1}$ and $B K J_{1}$ are equal. We use Mansion's lemma: the midpoint of arc $X Y$ of the circumcircle of $X Y Z$ lies at equal distances from the ends of this arc and the incentre. It follows from this lemma that $I_{1} I=I_{1} L=J_{1} K=J_{1} J$. Moreover, $\angle P I_{1} T=\angle P A T=\angle P K T=$ $\angle P J_{1} T$, therefore, $I_{1} T=J_{1} T$. Thus $T$ lies on the median bisector of $I_{1} J_{1}$ and

![](https://cdn.mathpix.com/cropped/2024_06_04_861a2633df2bc09b1be5g-1.jpg?height=534&width=671&top_left_y=932&top_left_x=1298)

Figure 1: image on the median bisector of $I J$.

It remains to prove that $T$ lies on the median bisector of $P Q$. Let $R=A K \cap C T$. Then $\angle A R T=\angle R A C+\angle A C R=$ $\angle R A C+\angle A K T=\angle R A C+\angle K A T=\angle L A T=\angle B P T$. Since $P Q$ bisects the angle $R P B, \angle P Q T=\angle P R T+\angle R P Q=$ $\angle P B T+\angle B P J=\angle T P Q$, therefore $T$ belongs to the median bisector of $P Q$ and $I P=J Q$.


problem: Prove that there exist infinitely many pairs $(m, n)$ of positive integers such that $m+n$ divides $(m!)^{n}+(n!)^{m}+1$.

solution:
We shall find a pair such that $m+n=p$ is prime and $n$ is even. Applying Wilson's theorem we have

$$
m!=(p-n)!=\frac{(p-1)!}{(p-n+1) \ldots(p-2)(p-1)} \equiv \frac{-1}{-(n-1) \ldots(-2)(-1)} \equiv \frac{1}{(n-1)!} \equiv \frac{n}{n!} \quad(\bmod p)
$$

It follows from Fermat's Little Theorem that $(n!)^{p} \equiv n!(\bmod p)$, therefore

$$
(m!)^{n}+(n!)^{m}+1 \equiv\left(\frac{n}{n!}\right)^{n}+(n!)^{p-n}+1 \equiv \frac{n^{n}+n!+(n!)^{n}}{(n!)^{n}} \quad(\bmod p)
$$

thus it suffices to prove that the number $n^{n}+n!+(n!)^{n}$ has a prime divisor $p>n$ for infinitely many even $n$.

We prove that this condition is satisfied, for instance, by all the numbers of the form $n=2 q$, where $q>2$ is prime. Let $A=(2 q)^{2 q}+(2 q)!+((2 q)!)^{2 q}$. For a prime $p$ and integer $k$ we denote by $v_{p}(k)$ the largest integer $\ell$ such that $p^{\ell}$ divides $k$.

If $r<2 q$ is prime and $r \notin\{2, q\}$ then $A \equiv(2 q)^{2 q} \not \equiv 0(\bmod r)$. The largest degree of $q$ dividing $(2 q)!$ is $q^{2}$, while for $(2 q)^{2 q}$ and $((2 q)!)^{2 q}$ it is $2 q$ and $4 q$ respectively, therefore $v_{q}(A)=2$.

Finally, $v_{2}((2 q)!)=\left[\frac{2 q}{2}\right]+\left[\frac{2 q}{4}\right]+\left[\frac{2 q}{8}\right]+\cdots<\frac{2 q}{2}+\frac{2 q}{4}+\frac{2 q}{8}+\cdots=2 q$, so $v_{2}((2 q)!)<v_{2}\left((2 q)^{2 q}\right)$ and obviously $v_{2}((2 q)!)<v_{2}\left((2 q)!^{2 q}\right)$, thus $v_{2}(A) \leq 2 q-1$. On the other hand, $A>(2 q)^{2 q}>2^{2 q-1} q^{2}$, therefore $A$ has a prime divisor $p>2 q$, q.e.d.


problem:
The Crocodile thought of four unit squares of a $2018 \times 2018$ forming a rectangle with sides 1 and 4 . The Bear can choose any square formed by 9 unit squares and ask whether it contains at least one of the four Crocodile's squares. What minimum number of questions should he ask to be sure of at least one affirmative answer?

The answer is $\frac{673^{2}-1}{2}=226464$.

solution:
We call checked any square chosen by the Bear, and all its unit squares. The position of a unit square in the table can be defined by the numbers of its row and column, that is, the square $(x, y)$ is in the $x$-th row and $y$-th column.

First we prove that $\frac{673^{2}-1}{2}$ questions is enough even on a $2019 \times 2019$ table. Let us divide this table into $3 \times 3$ squares and apply chess colouring to these large squares so that the corners are white. Thet it is enough to check all the black $3 \times 3$ squares: no row or column contains four consecutive white squares.

To prove that we need so many questions, we select all the unit squares with coordinates $(3 m+1,3 n+1)$, where $0 \leqslant m, n \leqslant 672$. A $3 \times 3$ square obviously can not contain two selected unit squares. On the other hand, if two selected squares lie at distance 3 (i.e., one of them is $(x, y)$, and another is $(x, y+3)$ or $(x+3, y)$ ), the Bear must check at least one of these two squares (because if neither is checked, then so are the two unit squares between them, and the Crocodile can place his rectangle on the unchecked squares).

Thus it is enough to produce $\frac{673^{2}-1}{2}$ pairs of selected unit squares at distance 3 . One can take pairs $(6 k+1,3 n+1)$, $(6 k+4,3 n+1), 0 \leqslant k \leqslant 335,0 \leqslant n \leqslant 672$, and $(2017,6 n+1),(2017,6 n+4), 0 \leqslant n \leqslant 335$.


problem:
Find all real $a$ for which there exists a function $f: \mathbb{R} \rightarrow \mathbb{R}$ such that $f(x-f(y))=f(x)+a[y]$ for every real $x$ и $y$ ( $[y]$ denotes the integral part of $y$ ).

Answer: $a=-n^{2}$ for arbitrary integer $n$.

solution:
First note that $a=0$ satisfies the problem condition (for example, the equation is satisfied by the function $f(x) \equiv 0)$.

Now suppose $a \neq 0$.

Lemma. $f(y)=f(z)$ if and only if $[y]=[z]$.

Suppose $f(y)=f(z)$ for some $y, z$. Then the given equation implies $f(x)+a[y]=f(x-f(y))=f(x-f(z))=f(x)+a[z]$ whence $[y]=[z]$. Conversely, if $[y]=[z]$ then $f(x-f(y))=f(x)+a[y]=f(x)+a[z=f(x-f(z))]$. It follows from previous observation that $[x-f(y)]=[x-f(z)]$ for all $x$. Set $x=\frac{f(y)+f(z)}{2}$, then $\left[\frac{f(y)-f(z)}{2}\right]=\left[-\frac{f(y)-f(z)}{2}\right]$, so $f(y)=f(z)$. The lemma is proved.

Now we claim that $f(m) \in \mathbb{Z}$ for any $m \in \mathbb{Z}$. Setting $y=m$ in the given equation we obtain $f(x-f(m))=f(x)+$ am for any $m \in \mathbb{Z}, x \in \mathbb{R}$. Suppose that $f(m) \notin \mathbb{Z}$ for some $m \in \mathbb{Z}$. Choose $t \in(0,1)$ such that $[f(m)]=[f(m)+t]$. Then for $x=0$ we have $f(-f(m))=f(0)+$ am and for $x=-t$ we have $f(-t-f(m))=f(-t)+a m$. Using the lemma we have $f(-f(m))=f(-t-f(m))$, so $f(0)=f(-t)=f(-1)$, which contradicts the lemma.

From now on we will use in the given equation $f(x-f(y))=f(x)+a y$ (1) only integer numbers $x, y$. Setting $y=1$ in (1) we obtain that $a \in \mathbb{Z}$. Further, for $y=0$ we have $f(x-f(0))=f(x)$ and therefore $x-f(0)=x$ (by lemma), whence $f(0)=0$. Now set $x=f(y)$, then $f(f(y))=-a y$ (2); replacing $y$ by $f(y)$ in (1) we get $f(x+a y)=f(x)+a f(y)$ (3). Denoting $f(1)$ by $n$ and setting $y=1$ in (3) we obtain $f(x+a)=f(x)+a n$ (4). Applying (4) to $x=0$ we get $f(a)=$ an. From (4) we easily conclude that $f(k a)=k a n$ for any $k \in \mathbb{Z}$; in particular $f(a n)=a n^{2}$. Now setting $y=a$ in (2) gives $-a^{2}=f(f(a))=a n^{2}$ as stated.

It remains to note that if $a=-n^{2}$ then the function $f(x)=n[x]$ satisfies the given condition: $n[x-n[y]]=n[x]-n^{2}[y]$, which is obvious.


problem: A convex hexagon $A B C D E F$ is inscribed in a circle with radius $R$. Diagonals $A D$ and $B E, B E$ and $C F, A D$ and $C F$ of the hexagon meet at points $M, N, K$ respectively. Let $r_{1}, r_{2}, r_{3}, r_{4}, r_{5}, r_{6}$ be the inradii of the triangles $A B M$, $B C N, C D K, D E M, E F N, A F K$ respectively. Prove that $r_{1}+r_{2}+r_{3}+r_{4}+r_{5}+r_{6} \leqslant R \sqrt{3}$.

solution:
We start with a lemma.

Lemma. Let $R$ be the circumradius of a quadrilateral $X Y Z T$, the diagonals of $X Y Z T$ meet at $U$, and $\varphi=\frac{1}{2} \angle X U Y$. Then the radii $r_{1}$ and $r_{2}$ of the incentres of $X Y U$ and $Z T U$ satisfy

$$
\frac{r_{1}+r_{2}}{R} \leqslant 2 \tan \varphi(1-\sin \varphi)
$$

Indeed, let $\angle U X Y=2 \psi, \angle U Y X=2 \vartheta$, then $\angle U T Z=\angle U X Y=2 \psi, \angle U Z T=\angle U Y X=2 \vartheta$ (and obviously $\left.\psi+\vartheta+\varphi=\frac{\pi}{2}\right)$. We have $X Y+Z T=\left(r_{1}+r_{2}\right)(\cot \psi+\cot \vartheta)=2 R \sin \angle X T Y+2 R \sin (2 \varphi-\angle X T Y)=2 R(\sin \angle X T Y+$ $\sin (2 \varphi-\angle X T Y)=2 R \cdot 2 \sin \varphi \cos (\varphi-\angle X T Y) \leqslant 4 R \sin \varphi$. Therefore

$$
\begin{gathered}
\frac{r_{1}+r_{2}}{R} \leqslant \frac{4 \sin \varphi}{\cot \psi+\cot \vartheta}=\frac{4 \sin \varphi \sin \psi \sin \vartheta}{\sin (\psi+\vartheta)}=\frac{4 \sin \varphi \sin \psi \sin \vartheta}{\cos \varphi}=4 \tan \varphi \sin \psi \sin \vartheta= \\
=4 \tan \varphi \cdot \frac{1}{2}(\cos (\psi-\vartheta)-\cos (\psi+\vartheta)) \leqslant 2 \tan \varphi(1-\sin \varphi)
\end{gathered}
$$

q.e.d.

Returning to the problem, let $\angle A M B=2 \alpha, \angle B N C=2 \beta, \angle C K D=2 \gamma$, then $\alpha+\beta+\gamma=\frac{\pi}{2}$.

Applying the inequality (1) to the quadrilaterals $A B D E, B C E F$ и $C D F A$ we get

$$
\frac{r_{1}+r_{2}+r_{3}+r_{4}+r_{5}+r_{6}}{R}=\frac{r_{1}+r_{4}}{R}+\frac{r_{2}+r_{5}}{R}+\frac{r_{3}+r_{6}}{R} \leqslant 2 \tan \alpha(1-\sin \alpha)+2 \tan \beta(1-\sin \beta)+2 \tan \gamma(1-\sin \gamma)
$$

We claim that if $\alpha+\beta+\gamma=\frac{\pi}{2}$ then

$$
2 \tan \alpha(1-\sin \alpha)+2 \tan \beta(1-\sin \beta)+2 \tan \gamma(1-\sin \gamma) \leqslant \sqrt{3}
$$

To prove that we consider the function $f(x)=2 \tan x(1-\sin x)$ for $x \in\left(0 ; \frac{\pi}{2}\right)$.

Since $f^{\prime \prime}(x)=-2 \frac{(1-\sin x)^{2}+\cos ^{4} x}{\cos ^{3} x}<0$ for $x \in\left(0 ; \frac{\pi}{2}\right)$, it follows from Jensen's inequality that

$$
f(\alpha)+f(\beta)+f(\gamma) \leqslant 3 f\left(\frac{\alpha+\beta+\gamma}{3}\right)=3 f\left(\frac{\pi}{6}\right)=\sqrt{3}
$$

Thus (2) is proved, and $r_{1}+r_{2}+r_{3}+r_{4}+r_{5}+r_{6} \leqslant \sqrt{3} R$.

solution_match: ## Solution.