problem: Determine all infinite strings of letters with the following properties: (a) Each letter is either $T$ or $S$, (b) If position $i$ and $j$ both have the letter $T$, then position $i+j$ has the letter $S$, (c) There are infinitely many integers $k$ such that position $2 k-1$ has the $k$ th $T$.

solution: We wish to find all infinite sequences $a_{1}, a_{2}, \ldots$ of positive integers satisfying the following properties: (a) $a_{1}<a_{2}<a_{3}<\cdots$, (b) there are no positive integers $i, j, k$, not necessarily distinct, such that $a_{i}+a_{j}=a_{k}$, (c) there are infinitely many $k$ such that $a_{k}=2 k-1$.  If $a_{k}=2 k-1$ for some $k>1$, let $A_{k}=\left\{a_{1}, a_{2}, \ldots, a_{k}\right\}$. By (b) and symmetry, we have  $$ 2 k-1 \geq \frac{\left|A_{k}-A_{k}\right|-1}{2}+\left|A_{k}\right| \geq \frac{2\left|A_{k}\right|-2}{2}+\left|A_{k}\right|=2 k-1 . $$  But in order for $\left|A_{k}-A_{k}\right|=2\left|A_{k}\right|-1$, we must have $A_{k}$ an arithmetic progression, whence $a_{n}=2 n-1$ for all $n$ by taking $k$ arbitrarily large.


problem: Let $A B C D$ be a quadrilateral with $A C=B D$. Diagonals $A C$ and $B D$ meet at $P$. Let $\omega_{1}$ and $O_{1}$ denote the circumcircle and circumcenter of triangle $A B P$. Let $\omega_{2}$ and $O_{2}$ denote the circumcircle and circumcenter of triangle $C D P$. Segment $B C$ meets $\omega_{1}$ and $\omega_{2}$ again at $S$ and $T$ (other than $B$ and $C$ ), respectively. Let $M$ and $N$ be the midpoints of minor arcs $\widehat{S P}$ (not including $B$ ) and $\overparen{T P}$ (not including $C$ ). Prove that $\overline{M N} \| \overline{O_{1} O_{2}}$.

solution: Let $Q$ be the second intersection point of $\omega_{1}, \omega_{2}$. Suffice to show $\overline{Q P} \perp \overline{M N}$. Now $Q$ is the center of a spiral congruence which sends $\overline{A C} \mapsto \overline{B D}$. So $\triangle Q A B$ and $\triangle Q C D$ are similar isosceles. Now,  $$ \measuredangle Q P A=\measuredangle Q B A=\measuredangle D C Q=\measuredangle D P Q $$  and so $\overline{Q P}$ is bisects $\angle B P C$. ![](https://cdn.mathpix.com/cropped/2024_11_19_b4303c9fa48a8c74b45cg-05.jpg?height=673&width=1200&top_left_y=1234&top_left_x=428)  Now, let $I=\overline{B M} \cap \overline{C N} \cap \overline{P Q}$ be the incenter of $\triangle P B C$. Then $I M \cdot I B=I P \cdot I Q=$ $I N \cdot I C$, so $B M N C$ is cyclic, meaning $\overline{M N}$ is antiparallel to $\overline{B C}$ through $\angle B I C$. Since $\overline{Q P I}$ passes through the circumcenter of $\triangle B I C$, it follows now $\overline{Q P I} \perp \overline{M N}$ as desired.


problem: Let $\mathbb{N}$ be the set of positive integers. Let $f: \mathbb{N} \rightarrow \mathbb{N}$ be a function satisfying the following two conditions: (a) $f(m)$ and $f(n)$ are relatively prime whenever $m$ and $n$ are relatively prime. (b) $n \leq f(n) \leq n+2012$ for all $n$.  Prove that for any natural number $n$ and any prime $p$, if $p$ divides $f(n)$ then $p$ divides $n$.

solution: 【 First short solution, by Jeffrey Kwan. Let $p_{0}, p_{1}, p_{2}, \ldots$ denote the sequence of all prime numbers, in any order. Pick any primes $q_{i}$ such that  $$ q_{0}\left|f\left(p_{0}\right), \quad q_{1}\right| f\left(p_{1}\right), \quad q_{2} \mid f\left(p_{2}\right), \text { etc. } $$  This is possible since each $f$ value above exceeds 1 . Also, since by hypothesis the $f\left(p_{i}\right)$ are pairwise coprime, the primes $q_{i}$ are all pairwise distinct.  Claim - We must have $q_{i}=p_{i}$ for each $i$. (Therefore, $f\left(p_{i}\right)$ is a power of $p_{i}$ for each $i$.)   $$ \begin{array}{rr} m+i & \equiv 0 \\ m & \left(\bmod q_{i}\right) \\ m & \equiv{ }^{\prime} \\ \left(\bmod p_{i}\right) \end{array} $$  for $0 \leq i \leq 2012$. But now $f(m)$ should be coprime to all $f\left(p_{i}\right)$, ergo coprime to $q_{0} q_{1} \ldots q_{2012}$, violating $m \leq f(m) \leq m+2012$.  All that is left to do is note that whenever $p \nmid n$, we have $\operatorname{gcd}(f(p), f(n))=1$, hence $p \nmid f(n)$. This is the contrapositive of the problem statement.


solution: 【 Second solution with a grid. Fix $n$ and $p$, and assume for contradiction $p \nmid n$. Claim - There exists a large integer $N$ with $f(N)=N$, that also satisfies $N \equiv 1$ $(\bmod n)$ and $N \equiv 0(\bmod p)$.  it to fill in the following table:  |  | $N+1$ | $N+2$ | $\ldots$ | $N+2012$ | | :---: | :---: | :---: | :---: | :---: | | $M$ | $q_{0,1}$ | $q_{0,2}$ | $\ldots$ | $q_{0,2012}$ | | $M+1$ | $q_{1,1}$ | $q_{1,2}$ | $\ldots$ | $q_{1,2012}$ | | $\vdots$ | $\vdots$ | $\vdots$ | $\ddots$ | $\vdots$ | | $M+2012$ | $q_{2012,1}$ | $q_{2012,2}$ | $\ldots$ | $q_{2012,2012}$ |.  By the Chinese Remainder Theorem, we can construct $N$ such that $N+1 \equiv 0\left(\bmod q_{i, 1}\right)$ for every $i$, and similarly for $N+2$, and so on. Moreover, we can also tack on the extra conditions $N \equiv 0(\bmod p)$ and $N \equiv 1(\bmod n)$ we wanted.  Notice that $N$ cannot be divisible by any of the $q_{i, j}$ 's, since the $q_{i, j}$ 's are greater than 2012.  After we've chosen $N$, we can pick $M$ such that $M \equiv 0\left(\bmod q_{0, j}\right)$ for every $j$, and similarly $M+1 \equiv 0\left(\bmod q_{1, j}\right)$, et cetera. Moreover, we can tack on the condition $M \equiv 1$ $(\bmod N)$, which ensures $\operatorname{gcd}(M, N)=1$.  What does this do? We claim that $f(N)=N$ now. Indeed $f(M)$ and $f(N)$ are relatively prime; but look at the table! The table tells us that $f(M)$ must have a common factor with each of $N+1, \ldots, N+2012$. So the only possibility is that $f(N)=N$.  Now we're basically done. Since $N \equiv 1(\bmod n)$, we have $\operatorname{gcd}(N, n)=1$ and hence $1=\operatorname{gcd}(f(N), f(n))=\operatorname{gcd}(N, f(n))$. But $p \mid N$ and $p \mid f(n)$, contradiction.


problem: In scalene triangle $A B C$, let the feet of the perpendiculars from $A$ to $\overline{B C}, B$ to $\overline{C A}$, $C$ to $\overline{A B}$ be $A_{1}, B_{1}, C_{1}$, respectively. Denote by $A_{2}$ the intersection of lines $B C$ and $B_{1} C_{1}$. Define $B_{2}$ and $C_{2}$ analogously. Let $D, E, F$ be the respective midpoints of sides $\overline{B C}, \overline{C A}, \overline{A B}$. Show that the perpendiculars from $D$ to $\overline{A A_{2}}, E$ to $\overline{B B_{2}}$ and $F$ to $\overline{C C_{2}}$ are concurrent.

solution: We claim that they pass through the orthocenter $H$. Indeed, consider the circle with diameter $\overline{B C}$, which circumscribes quadrilateral $B C B_{1} C_{1}$ and has center $D$. Then by Brokard theorem, $\overline{A A_{2}}$ is the polar of line $H$. Thus $\overline{D H} \perp \overline{A A_{2}}$.


problem: A rational number $x$ is given. Prove that there exists a sequence $x_{0}, x_{1}, x_{2}, \ldots$ of rational numbers with the following properties: (a) $x_{0}=x$; (b) for every $n \geq 1$, either $x_{n}=2 x_{n-1}$ or $x_{n}=2 x_{n-1}+\frac{1}{n}$; (c) $x_{n}$ is an integer for some $n$.

solution: Think of the sequence as a process over time. We'll show that: Claim - At any given time $t$, if the denominator of $x_{t}$ has some odd prime power $q=p^{e}$, then we can delete a factor of $p$ from the denominator, while only adding powers of two to the denominator. (Thus we can just delete off all the odd primes one by one and then double appropriately many times.)  Indeed, let $n$ be large, and suppose $t<2^{r+1} q<2^{r+2} q<\cdots<2^{r+m} q<n$. For some binary variables $\varepsilon_{i} \in\{0,1\}$ we can have  $$ x_{n}=2^{n-t} x_{t}+c_{1} \cdot \frac{\varepsilon_{1}}{q}+c_{2} \cdot \frac{\varepsilon_{2}}{q} \cdots+c_{s} \cdot \frac{\varepsilon_{m}}{q} $$  where $c_{i}$ is some power of 2 (to be exact, $c_{i}=\frac{2^{n-2^{r+i} q}}{2^{r+1}}$, but the exact value doesn't matter). If $m$ is large enough the set $\left\{0, c_{1}\right\}+\left\{0, c_{2}\right\}+\cdots+\left\{0, c_{m}\right\}$ spans everything modulo p. (Actually, Cauchy-Davenport implies $m=p$ is enough, but one can also just use Pigeonhole to notice some residue appears more than $p$ times, for $m=O\left(p^{2}\right)$.) Thus we can eliminate one factor of $p$ from the denominator, as desired.


problem: Positive real numbers $x, y, z$ satisfy $x y z+x y+y z+z x=x+y+z+1$. Prove that  $$ \frac{1}{3}\left(\sqrt{\frac{1+x^{2}}{1+x}}+\sqrt{\frac{1+y^{2}}{1+y}}+\sqrt{\frac{1+z^{2}}{1+z}}\right) \leq\left(\frac{x+y+z}{3}\right)^{5 / 8} . $$

solution: The key is the identity  $$ \begin{aligned} \frac{x^{2}+1}{x+1} & =\frac{\left(x^{2}+1\right)(y+1)(z+1)}{(x+1)(y+1)(z+1)} \\ & =\frac{x(x y z+x y+x z)+x^{2}+y z+y+z+1}{2(1+x+y+z)} \\ & =\frac{x(x+y+z+1-y z)+x^{2}+y z+y+z+1}{2(1+x+y+z)} \\ & =\frac{(x+y)(x+z)+x^{2}+(x-x y z+y+z+1)}{2(1+x+y+z)} \\ & =\frac{2(x+y)(x+z)}{2(1+x+y+z)} \\ & =\frac{(x+y)(x+z)}{1+x+y+z} . \end{aligned} $$  Remark. The "trick" can be rephrased as $\left(x^{2}+1\right)(y+1)(z+1)=2(x+y)(x+z)$. After this, straight Cauchy in the obvious way will do it (reducing everything to an inequality in $s=x+y+z$ ). One writes  $$ \begin{aligned} \left(\sum_{\mathrm{cyc}} \frac{\sqrt{(x+y)(x+z)}}{\sqrt{1+s}}\right)^{2} & \leq \frac{\left(\sum_{\mathrm{cyc}} x+y\right)\left(\sum_{\mathrm{cyc}} x+z\right)}{1+s} \\ & =\frac{4 s^{2}}{1+s} \end{aligned} $$  and so it suffices to check that $\frac{4 s^{2}}{1+s} \leq 9(s / 3)^{5 / 4}$, which is true because  $$ (s / 3)^{5} \cdot 9^{4} \cdot(1+s)^{4}-\left(4 s^{2}\right)^{4}=s^{5}(s-3)^{2}\left(27 s^{2}+14 s+3\right) \geq 0 $$


problem: Triangle $A B C$ is inscribed in circle $\Omega$. The interior angle bisector of angle $A$ intersects side $B C$ and $\Omega$ at $D$ and $L$ (other than $A$ ), respectively. Let $M$ be the midpoint of side $B C$. The circumcircle of triangle $A D M$ intersects sides $A B$ and $A C$ again at $Q$ and $P$ (other than $A$ ), respectively. Let $N$ be the midpoint of segment $P Q$, and let $H$ be the foot of the perpendicular from $L$ to line $N D$. Prove that line $M L$ is tangent to the circumcircle of triangle $H M N$.

solution: By angle chasing, equivalent to show $\overline{M N} \| \overline{A D}$, so discard the point $H$. We now present a three solutions. ब First solution using vectors. We first contend that: Claim - We have $Q B=P C$.   Now notice that the vector  $$ \overrightarrow{M N}=\frac{1}{2}(\overrightarrow{B Q}+\overrightarrow{C P}) $$  which must be parallel to the angle bisector since $\overrightarrow{B Q}$ and $\overrightarrow{C P}$ have the same magnitude.


solution: By angle chasing, equivalent to show $\overline{M N} \| \overline{A D}$, so discard the point $H$. We now present a three solutions. 『 Second solution using spiral similarity. let $X$ be the arc midpoint of $B A C$. Then $A D M X$ is cyclic with diameter $\overline{A M}$, and hence $X$ is the Miquel point $X$ of $Q B P C$ is the midpoint of arc $B A C$. Moreover $\overline{X N D}$ collinear (as $X P=X Q, D P=D Q)$ on $(A P Q)$. ![](https://cdn.mathpix.com/cropped/2024_11_19_b4303c9fa48a8c74b45cg-11.jpg?height=801&width=734&top_left_y=1827&top_left_x=661)  Then $\triangle X N M \sim \triangle X P C$ spirally, and  $$ \measuredangle X M N=\measuredangle X C P=\measuredangle X C A=\measuredangle X L A $$  thus done.


solution: By angle chasing, equivalent to show $\overline{M N} \| \overline{A D}$, so discard the point $H$. We now present a three solutions. 『 Third solution using barycentrics (mine). Once reduced to $\overline{M N} \| \overline{A B}$, straight bary will also work. By power of a point one obtains  $$ \begin{aligned} P & =\left(a^{2}: 0: 2 b(b+c)-a^{2}\right) \\ Q & =\left(a^{2}: 2 c(b+c)-a^{2}: 0\right) \\ \Longrightarrow N & =\left(a^{2}(b+c): 2 b c(b+c)-b a^{2}: 2 b c(b+c)-c a^{2}\right) . \end{aligned} $$  Now the point at infinity along $\overline{A D}$ is $(-(b+c): b: c)$ and so we need only verify  $$ \operatorname{det}\left[\begin{array}{ccc} a^{2}(b+c) & 2 b c(b+c)-b a^{2} & 2 b c(b+c)-c a^{2} \\ 0 & 1 & 1 \\ -(b+c) & b & c \end{array}\right]=0 $$  which follows since the first row is $-a^{2}$ times the third row plus $2 b c(b+c)$ times the second row.


problem: Let $n$ be a positive integer. Consider a triangular array of nonnegative integers as follows: ![](https://cdn.mathpix.com/cropped/2024_11_19_b4303c9fa48a8c74b45cg-03.jpg?height=244&width=809&top_left_y=238&top_left_x=675)  Call such a triangular array stable if for every $0 \leq i<j<k \leq n$ we have  $$ a_{i, j}+a_{j, k} \leq a_{i, k} \leq a_{i, j}+a_{j, k}+1 $$  For $s_{1}, \ldots, s_{n}$ any nondecreasing sequence of nonnegative integers, prove that there exists a unique stable triangular array such that the sum of all of the entries in row $k$ is equal to $s_{k}$.

solution: Let $n$ be a positive integer. Consider a triangular array of nonnegative integers as follows:  $$ \begin{array}{clllll} \text { Row 1: } & & & a_{0,1} \\ \text { Row 2: } & & a_{0,2} & a_{1,2} & \\ & \vdots & \vdots & & \ddots & \\ \text { Row } n-1: & a_{0, n-1} & a_{1, n-1} & \ldots & a_{n-2, n-1} \\ \text { Row } n \text { : } & a_{0, n} \quad a_{1, n} \quad a_{2, n} & & \ldots & a_{n-1, n} \end{array} $$  Call such a triangular array stable if for every $0 \leq i<j<k \leq n$ we have  $$ a_{i, j}+a_{j, k} \leq a_{i, k} \leq a_{i, j}+a_{j, k}+1 $$  For $s_{1}, \ldots, s_{n}$ any nondecreasing sequence of nonnegative integers, prove that there exists a unique stable triangular array such that the sum of all of the entries in row $k$ is equal to $s_{k}$.  Firstly, here are illustrative examples showing the arrays for $\left(s_{1}, s_{2}, s_{3}, s_{4}\right)=(2,5,9, x)$ where $9 \leq x \leq 14$. (The array has been left justified.)  $$ \begin{aligned} & {\left[\begin{array}{cccc} 2 & \swarrow & & \\ 4 & 1 & \swarrow & \\ 5 & 3 & 1 & \swarrow \\ 5 & 3 & 1 & 0 \end{array}\right]\left[\begin{array}{llll} 2 & \swarrow & & \\ 4 & 1 & \swarrow & \\ 5 & 3 & 1 & \swarrow \\ 6 & 3 & 1 & 0 \end{array}\right]\left[\begin{array}{llll} 2 & \swarrow & & \\ 4 & 1 & \swarrow & \\ 5 & 3 & 1 & \swarrow \\ 6 & 3 & 2 & 0 \end{array}\right]} \\ & {\left[\begin{array}{cccc} 2 & \swarrow & & \\ 4 & 1 & \swarrow & \swarrow \\ 5 & 3 & 1 & \swarrow \\ 6 & 4 & 2 & 0 \end{array}\right]\left[\begin{array}{llll} 2 & \swarrow & \\ 4 & 1 & \swarrow & \\ 5 & 3 & 1 & \swarrow \\ 6 & 4 & 2 & 1 \end{array}\right]\left[\begin{array}{cccc} 2 & \swarrow & \\ 4 & 1 & \swarrow & \\ 5 & 3 & 1 & \swarrow \\ 7 & 4 & 2 & 1 \end{array}\right]} \end{aligned} $$   The base case $N=s_{n-1}$ is done by copying the $n-1$ st row and adding a zero at the end. This is also unique, since $a_{i, n} \geq a_{i-1, n}+a_{n-1, n}$ for all $i=0, \ldots, n-2$, whence $\sum a_{i, n} \geq s_{n-1}$ follows.  Now the inductive step is based on the following lemma, which illustrates the idea of a "unique increasable entry".  ## Lemma  Fix a stable array Construct a tournament on the $n$ entries of the last row as follows: for $i<j$,  - $a_{i, n} \rightarrow a_{j, n}$ if $a_{i, n}=a_{i, j}+a_{j, n}$, and - $a_{j, n} \rightarrow a_{i, n}$ if $a_{i, n}=a_{i, j}+a_{j, n}+1$.  Then this tournament is transitive. Also, except for $N=s_{n-1}$, a 0 entry is never a source.  Intuitively, $a_{i, n} \rightarrow a_{j, n}$ if $a_{i, n}$ blocks $a_{j, n}$ from increasing. For instance, in the example  $$ \left[\begin{array}{rrrr} 2 & \swarrow & & \\ 4 & 1 & \swarrow & \\ 5 & 3 & 1 & \swarrow \\ \mathbf{6} & 3 & 1 & 0 \end{array}\right] $$  the tournament is $1 \rightarrow 3 \rightarrow 0 \rightarrow 6$.  $$ \left[\begin{array}{ccc} p & \swarrow & \\ s & q & \swarrow \\ x & y & z \end{array}\right] $$  If $x \rightarrow y \rightarrow z \rightarrow x$ happens, that means $x=y+p, y=q+z, x=s+z+1$, which gives $s=p+q-1$, contradiction. Similarly if $x \leftarrow y \leftarrow z \leftarrow x$ then $x=y+p+1, y=q+z+1$, $x=s+z$, which gives $s=p+q+2$, also contradiction.  Now this allows us to perform our induction. Indeed, to show existence from $N$ to $N+1$ we take a source of the tournament above and increase it. Conversely, to show uniqueness for $N$, note that we can take the (nonzero) sink of the tournament and decrement it, which gives $N-1$; our uniqueness inductive hypothesis now finishes.   $$ s_{k}+\sum_{i=1}^{k-1} a_{0, i} \leq k a_{0, k} \leq s_{k}+\sum_{i=1}\left(a_{0, i}+1\right) $$  and similarly for other entries.


problem: Given a set $S$ of $n$ variables, a binary operation $\times$ on $S$ is called simple if it satisfies $(x \times y) \times z=x \times(y \times z)$ for all $x, y, z \in S$ and $x \times y \in\{x, y\}$ for all $x, y \in S$. Given a simple operation $\times$ on $S$, any string of elements in $S$ can be reduced to a single element, such as $x y z \rightarrow x \times(y \times z)$. A string of variables in $S$ is called full if it contains each variable in $S$ at least once, and two strings are equivalent if they evaluate to the same variable regardless of which simple $\times$ is chosen. For example $x x x, x x$, and $x$ are equivalent, but these are only full if $n=1$. Suppose $T$ is a set of full strings such that any full string is equivalent to exactly one element of $T$. Determine the number of elements of $T$.

solution: The answer is $(n!)^{2}$. In fact it is possible to essentially find all $x$ : one assigns a real number to each variable in $S$. Then $x \times y$ takes the larger of $\{x, y\}$, and in the event of a tie picks either "left" or "right", where the choice of side is fixed among elements of each size. 【 First solution (Steven Hao). The main trick is the two lemmas, which are not hard to show (and are motivated by our conjecture).  $$ \begin{aligned} x x & =x \\ x y x z x & =x y z x . \end{aligned} $$  Consequently, define a double rainbow to be the concatenation of two full strings of length $n$, of which there are $(n!)^{2}$. We claim that these form equivalence classes for $T$.  To see that any string $s$ is equivalent to a double rainbow, note that $s=s s$, and hence using the second identity above repeatedly lets us reduce ss to a double rainbow.  To see two distinct double rainbows $R_{1}$ and $R_{2}$ aren't equivalent, one can use the construction mentioned in the beginning. Specifically, take two variables $a$ and $b$ which do not appear in the same order in $R_{1}$ and $R_{2}$. Then it's not hard to see that $a b a b, a b b a$, $b a a b, b a b a$ are pairwise non-equivalent by choosing "left" or "right" appropriately. Now construct $\times$ on the whole set by having $a$ and $b$ be the largest variables, so the rest of the variables don't matter in the evaluation of the string.


solution: The answer is $(n!)^{2}$. In fact it is possible to essentially find all $x$ : one assigns a real number to each variable in $S$. Then $x \times y$ takes the larger of $\{x, y\}$, and in the event of a tie picks either "left" or "right", where the choice of side is fixed among elements of each size. 【 Second solution outline (Ankan Bhattacharya). We outline a proof of the characterization claimed earlier, which will also give the answer $(n!)^{2}$. We say $a \sim b$ if $a b \neq b a$. Also, say $a>b$ if $a b=b a=a$. The following are proved by finite casework, using the fact that $\{a b, b c, c a\}$ always has exactly two distinct elements for any different $a, b, c$.  - If $a>b$ and $b>c$ then $a>c$. - If $a \sim b$ and $b \sim c$ then $a b=a$ if and only if $b c=b$. - If $a \sim b$ and $b \sim c$ then $a \sim c$. - If $a \sim b$ and $a>c$ then $b>c$. - If $a \sim b$ and $c>a$ then $c>b$.  This gives us the total ordering on the elements and the equivalence classes by $\sim$. In this we way can check the claimed operations are the only ones.