# JMO 2018 Solution Notes Evan Chen《陳誼廷》 15 April 2024 #### Abstract This is a compilation of solutions for the 2018 JMO. The ideas of the solution are a mix of my own work, the solutions provided by the competition organizers, and solutions found by the community. However, all the writing is maintained by me. These notes will tend to be a bit more advanced and terse than the "official" solutions from the organizers. In particular, if a theorem or technique is not known to beginners but is still considered "standard", then I often prefer to use this theory anyways, rather than try to work around or conceal it. For example, in geometry problems I typically use directed angles without further comment, rather than awkwardly work around configuration issues. Similarly, sentences like "let $\mathbb{R}$ denote the set of real numbers" are typically omitted entirely. Corrections and comments are welcome! ## Contents 0 Problems ..... 2 1 Solutions to Day 1 1.1 JMO 2018/1, proposed by Zachary Franco, Zuming Feng ..... 3 1.2 JMO 2018/2, proposed by Titu Andreescu ..... 4 1.3 JMO 2018/3, proposed by Ray Li 2 Solutions to Day 2 ..... 7 2.1 JMO 2018/4, proposed by Titu Andreescu ..... 7 2.2 JMO 2018/5, proposed by Ankan Bhattacharya ..... 8 2.3 JMO 2018/6, proposed by Maria Monks Gillespie ## §0 Problems 1. For each positive integer $n$, find the number of $n$-digit positive integers for which no two consecutive digits are equal, and the last digit is a prime. 2. Let $a, b, c$ be positive real numbers such that $a+b+c=4 \sqrt[3]{a b c}$. Prove that $$ 2(a b+b c+c a)+4 \min \left(a^{2}, b^{2}, c^{2}\right) \geq a^{2}+b^{2}+c^{2} $$ 3. Let $A B C D$ be a quadrilateral inscribed in circle $\omega$ with $\overline{A C} \perp \overline{B D}$. Let $E$ and $F$ be the reflections of $D$ over $\overline{B A}$ and $\overline{B C}$, respectively, and let $P$ be the intersection of $\overline{B D}$ and $\overline{E F}$. Suppose that the circumcircles of $E P D$ and $F P D$ meet $\omega$ at $Q$ and $R$ different from $D$. Show that $E Q=F R$. 4. Find all real numbers $x$ for which there exists a triangle $A B C$ with circumradius 2 , such that $\angle A B C \geq 90^{\circ}$, and $$ x^{4}+a x^{3}+b x^{2}+c x+1=0 $$ where $a=B C, b=C A, c=A B$. 5. Let $p$ be a prime, and let $a_{1}, \ldots, a_{p}$ be integers. Show that there exists an integer $k$ such that the numbers $$ a_{1}+k, a_{2}+2 k, \ldots, a_{p}+p k $$ produce at least $\frac{1}{2} p$ distinct remainders upon division by $p$. 6. Karl starts with $n$ cards labeled $1,2, \ldots, n$ lined up in random order on his desk. He calls a pair $(a, b)$ of cards swapped if $a>b$ and the card labeled $a$ is to the left of the card labeled $b$. Karl picks up the card labeled 1 and inserts it back into the sequence in the opposite position: if the card labeled 1 had $i$ cards to its left, then it now has $i$ cards to its right. He then picks up the card labeled 2 and reinserts it in the same manner, and so on, until he has picked up and put back each of the cards $1, \ldots, n$ exactly once in that order. For example, if $n=4$, then one example of a process is $$ 3142 \longrightarrow 3412 \longrightarrow 2341 \longrightarrow 2431 \longrightarrow 2341 $$ which has three swapped pairs both before and after. Show that, no matter what lineup of cards Karl started with, his final lineup has the same number of swapped pairs as the starting lineup. ## §1 Solutions to Day 1 ## §1.1 JMO 2018/1, proposed by Zachary Franco, Zuming Feng Available online at https://aops.com/community/p10226138. ## Problem statement For each positive integer $n$, find the number of $n$-digit positive integers for which no two consecutive digits are equal, and the last digit is a prime. Almost trivial. Let $a_{n}$ be the desired answer. We have $$ a_{n}+a_{n-1}=4 \cdot 9^{n-1} $$ for all $n$, by padding the $(n-1)$ digit numbers with a leading zero. Since $a_{0}=0, a_{1}=4$, solving the recursion gives $$ a_{n}=\frac{2}{5}\left(9^{n}-(-1)^{n}\right) $$ The end. Remark. For concreteness, the first few terms are $0,4,32,292, \ldots$. ## §1.2 JMO 2018/2, proposed by Titu Andreescu Available online at https://aops.com/community/p10226140. ## Problem statement Let $a, b, c$ be positive real numbers such that $a+b+c=4 \sqrt[3]{a b c}$. Prove that $$ 2(a b+b c+c a)+4 \min \left(a^{2}, b^{2}, c^{2}\right) \geq a^{2}+b^{2}+c^{2} $$ WLOG let $c=\min (a, b, c)=1$ by scaling. The given inequality becomes equivalent to $$ 4 a b+2 a+2 b+3 \geq(a+b)^{2} \quad \forall a+b=4(a b)^{1 / 3}-1 $$ Now, let $t=(a b)^{1 / 3}$ and eliminate $a+b$ using the condition, to get $$ 4 t^{3}+2(4 t-1)+3 \geq(4 t-1)^{2} \Longleftrightarrow 0 \leq 4 t^{3}-16 t^{2}+16 t=4 t(t-2)^{2} $$ which solves the problem. Equality occurs only if $t=2$, meaning $a b=8$ and $a+b=7$, which gives $$ \{a, b\}=\left\{\frac{7 \pm \sqrt{17}}{2}\right\} $$ with the assumption $c=1$. Scaling gives the curve of equality cases. ## §1.3 JMO 2018/3, proposed by Ray Li Available online at https://aops.com/community/p10226149. ## Problem statement Let $A B C D$ be a quadrilateral inscribed in circle $\omega$ with $\overline{A C} \perp \overline{B D}$. Let $E$ and $F$ be the reflections of $D$ over $\overline{B A}$ and $\overline{B C}$, respectively, and let $P$ be the intersection of $\overline{B D}$ and $\overline{E F}$. Suppose that the circumcircles of $E P D$ and $F P D$ meet $\omega$ at $Q$ and $R$ different from $D$. Show that $E Q=F R$. Most of this problem is about realizing where the points $P, Q, R$ are. 【 First solution (Evan Chen). Let $X, Y$, be the feet from $D$ to $\overline{B A}, \overline{B C}$, and let $Z=\overline{B D} \cap \overline{A C}$. By Simson theorem, the points $X, Y, Z$ are collinear. Consequently, the point $P$ is the reflection of $D$ over $Z$, and so we conclude $P$ is the orthocenter of $\triangle A B C$. ![](https://cdn.mathpix.com/cropped/2024_11_19_c3196aba41526ceabc46g-5.jpg?height=738&width=1007&top_left_y=1070&top_left_x=533) Suppose now we extend ray $C P$ to meet $\omega$ again at $Q^{\prime}$. Then $\overline{B A}$ is the perpendicular bisector of both $\overline{P Q^{\prime}}$ and $\overline{D E}$; consequently, $P Q^{\prime} E D$ is an isosceles trapezoid. In particular, it is cyclic, and so $Q^{\prime}=Q$. In the same way $R$ is the second intersection of ray $\overline{A P}$ with $\omega$. Now, because of the two isosceles trapezoids we have found, we conclude $$ E Q=P D=F R $$ as desired. Remark. Alternatively, after identifying $P$, one can note $\overline{B Q E}$ and $\overline{B R F}$ are collinear. Since $B E=B D=B F$, upon noticing $B Q=B P=B R$ we are also done. 【I Second solution (Danielle Wang). Here is a solution which does not identify the point $P$ at all. We know that $B E=B D=B F$, by construction. ![](https://cdn.mathpix.com/cropped/2024_11_19_c3196aba41526ceabc46g-6.jpg?height=669&width=1172&top_left_y=242&top_left_x=419) Claim - The points $B, Q, E$ are collinear. Similarly the points $B, R, F$ are collinear. Proof. Work directed modulo $180^{\circ}$. Let $Q^{\prime}$ be the intersection of $\overline{B E}$ with $(A B C D)$. Let $\alpha=\measuredangle D E B=\measuredangle B D E$ and $\beta=\measuredangle B F D=\measuredangle F D B$. Observe that $B E=B D=B F$, so $B$ is the circumcenter of $\triangle D E F$. Thus, $\measuredangle D E P=$ $\measuredangle D E F=90^{\circ}-\beta$. Then $$ \begin{aligned} \measuredangle D P E & =\measuredangle D E P+\measuredangle P D E=\left(90^{\circ}-\beta\right)+\alpha \\ & =\alpha-\beta+90^{\circ} \\ \measuredangle D Q^{\prime} B & =\measuredangle D C B=\measuredangle D C A+\measuredangle A C B \\ & =\measuredangle D B A-\left(90^{\circ}-\measuredangle D B C\right)=-\left(90^{\circ}-\alpha\right)-\left(90^{\circ}-\left(90^{\circ}-\beta\right)\right) \\ & =\alpha-\beta+90^{\circ} . \end{aligned} $$ Thus $Q^{\prime}$ lies on the desired circle, so $Q^{\prime}=Q$. Now, by power of a point we have $B Q \cdot B E=B P \cdot B D=B R \cdot B F$, so $B Q=B P=B R$. Hence $E Q=P D=F R$. ## §2 Solutions to Day 2 ## §2.1 JMO 2018/4, proposed by Titu Andreescu Available online at https://aops.com/community/p10232384. ## Problem statement Find all real numbers $x$ for which there exists a triangle $A B C$ with circumradius 2 , such that $\angle A B C \geq 90^{\circ}$, and $$ x^{4}+a x^{3}+b x^{2}+c x+1=0 $$ where $a=B C, b=C A, c=A B$. The answer is $x=-\frac{1}{2}(\sqrt{6} \pm \sqrt{2})$. We prove this the only possible answer. Evidently $x<0$. Now, note that $$ a^{2}+c^{2} \leq b^{2} \leq 4 b $$ since $b \leq 4$ (the diameter of its circumcircle). Then, $$ \begin{aligned} 0 & =x^{4}+a x^{3}+b x^{2}+c x+1 \\ & =x^{2}\left[\left(x+\frac{1}{2} a\right)^{2}+\left(\frac{1}{x}+\frac{1}{2} c\right)^{2}+\left(b-\frac{a^{2}+c^{2}}{4}\right)\right] \\ & \geq 0+0+0=0 \end{aligned} $$ In order for equality to hold, we must have $x=-\frac{1}{2} a, 1 / x=-\frac{1}{2} c$, and $a^{2}+c^{2}=b^{2}=4 b$. This gives us $b=4, a c=4, a^{2}+c^{2}=16$. Solving for $a, c>0$ implies $$ \{a, c\}=\{\sqrt{6} \pm \sqrt{2}\} $$ This gives the $x$ values claimed above; by taking $a, b, c$ as deduced here, we find they work too. Remark. Note that by perturbing $\triangle A B C$ slightly, we see $a$ priori that the set of possible $x$ should consist of unions of intervals (possibly trivial). So it makes sense to try inequalities no matter what. ## §2.2 JMO 2018/5, proposed by Ankan Bhattacharya Available online at https://aops.com/community/p10232389. ## Problem statement Let $p$ be a prime, and let $a_{1}, \ldots, a_{p}$ be integers. Show that there exists an integer $k$ such that the numbers $$ a_{1}+k, a_{2}+2 k, \ldots, a_{p}+p k $$ produce at least $\frac{1}{2} p$ distinct remainders upon division by $p$. For each $k=0, \ldots, p-1$ let $G_{k}$ be the graph on $\{1, \ldots, p\}$ where we join $\{i, j\}$ if and only if $$ a_{i}+i k \equiv a_{j}+j k \quad(\bmod p) \Longleftrightarrow k \equiv-\frac{a_{i}-a_{j}}{i-j} \quad(\bmod p) $$ So we want a graph $G_{k}$ with at least $\frac{1}{2} p$ connected components. However, each $\{i, j\}$ appears in exactly one graph $G_{k}$, so some graph has at most $\frac{1}{p}\binom{p}{2}=\frac{1}{2}(p-1)$ edges (by "pigeonhole"). This graph has at least $\frac{1}{2}(p+1)$ connected components, as desired. Remark. Here is an example for $p=5$ showing equality can occur: $$ \left[\begin{array}{lllll} 0 & 0 & 3 & 4 & 3 \\ 0 & 1 & 0 & 2 & 2 \\ 0 & 2 & 2 & 0 & 1 \\ 0 & 3 & 4 & 3 & 0 \\ 0 & 4 & 1 & 1 & 4 \end{array}\right] . $$ Ankan Bhattacharya points out more generally that $a_{i}=i^{2}$ is sharp in general. ## §2.3 JMO 2018/6, proposed by Maria Monks Gillespie Available online at https://aops.com/community/p10232393. ## Problem statement Karl starts with $n$ cards labeled $1,2, \ldots, n$ lined up in random order on his desk. He calls a pair $(a, b)$ of cards swapped if $a>b$ and the card labeled $a$ is to the left of the card labeled $b$. Karl picks up the card labeled 1 and inserts it back into the sequence in the opposite position: if the card labeled 1 had $i$ cards to its left, then it now has $i$ cards to its right. He then picks up the card labeled 2 and reinserts it in the same manner, and so on, until he has picked up and put back each of the cards $1, \ldots, n$ exactly once in that order. For example, if $n=4$, then one example of a process is $$ 3142 \longrightarrow 3412 \longrightarrow 2341 \longrightarrow 2431 \longrightarrow 2341 $$ which has three swapped pairs both before and after. Show that, no matter what lineup of cards Karl started with, his final lineup has the same number of swapped pairs as the starting lineup. The official solution is really tricky. Call the process $P$. We define a new process $P^{\prime}$ where, when re-inserting card $i$, we additionally change its label from $i$ to $n+i$. An example of $P^{\prime}$ also starting with 3142 is: $$ 3142 \longrightarrow 3452 \longrightarrow 6345 \longrightarrow 6475 \longrightarrow 6785 . $$ Note that now, each step of $P^{\prime}$ preserves the number of inversions. Moreover, the final configuration of $P^{\prime}$ is the same as the final configuration of $P$ with all cards incremented by $n$, and of course thus has the same number of inversions. Boom.