id
int64 1.61k
3.1k
| subfield
stringclasses 4
values | context
null | solution
stringlengths 11
212
| final_answer
sequencelengths 1
1
| is_multiple_answer
bool 2
classes | unit
stringclasses 8
values | answer_type
stringclasses 4
values | error
stringclasses 1
value | problem
stringlengths 49
4.42k
| _provided_sol
sequencelengths 1
5
| answer
stringlengths 1
204
|
---|---|---|---|---|---|---|---|---|---|---|---|
1,606 | Combinatorics | null | $\boxed{2}$ | [
"2"
] | false | null | Numerical | null | Xenia and Sergey play the following game. Xenia thinks of a positive integer $N$ not exceeding 5000. Then she fixes 20 distinct positive integers $a_{1}, a_{2}, \ldots, a_{20}$ such that, for each $k=1,2, \ldots, 20$, the numbers $N$ and $a_{k}$ are congruent modulo $k$. By a move, Sergey tells Xenia a set $S$ of positive integers not exceeding 20 , and she tells him back the set $\left\{a_{k}: k \in S\right\}$ without spelling out which number corresponds to which index. How many moves does Sergey need to determine for sure the number Xenia thought of? | [
"Sergey can determine Xenia's number in 2 but not fewer moves.\n\n\n\nWe first show that 2 moves are sufficient. Let Sergey provide the set $\\{17,18\\}$ on his first move, and the set $\\{18,19\\}$ on the second move. In Xenia's two responses, exactly one number occurs twice, namely, $a_{18}$. Thus, Sergey is able to identify $a_{17}, a_{18}$, and $a_{19}$, and thence the residue of $N$ modulo $17 \\cdot 18 \\cdot 19=5814>5000$, by the Chinese Remainder Theorem. This means that the given range contains a single number satisfying all congruences, and Sergey achieves his goal.\n\n\n\nTo show that 1 move is not sufficient, let $M=\\operatorname{lcm}(1,2, \\ldots, 10)=2^{3} \\cdot 3^{2} \\cdot 5 \\cdot 7=2520$. Notice that $M$ is divisible by the greatest common divisor of every pair of distinct positive integers not exceeding 20. Let Sergey provide the set $S=\\left\\{s_{1}, s_{2}, \\ldots, s_{k}\\right\\}$. We show that there exist pairwise distinct positive integers $b_{1}, b_{2}, \\ldots, b_{k}$ such that $1 \\equiv b_{i}\\left(\\bmod s_{i}\\right)$ and $M+1 \\equiv b_{i-1}\\left(\\bmod s_{i}\\right)$ (indices are reduced modulo $k$ ). Thus, if in response Xenia provides the set $\\left\\{b_{1}, b_{2}, \\ldots, b_{k}\\right\\}$, then Sergey will be unable to distinguish 1 from $M+1$, as desired.\n\n\n\nTo this end, notice that, for each $i$, the numbers of the form $1+m s_{i}, m \\in \\mathbb{Z}$, cover all residues modulo $s_{i+1}$ which are congruent to $1(\\equiv M+1)$ modulo $\\operatorname{gcd}\\left(s_{i}, s_{i+1}\\right) \\mid M$. Xenia can therefore choose a positive integer $b_{i}$ such that $b_{i} \\equiv 1\\left(\\bmod s_{i}\\right)$ and $b_{i} \\equiv M+1\\left(\\bmod s_{i+1}\\right)$. Clearly, such choices can be performed so as to make the $b_{i}$ pairwise distinct, as required."
] | 2 |
1,610 | Algebra | null | $\boxed{\frac{1}{2 n+2}}$ | [
"$\\frac{1}{2 n+2}$"
] | false | null | Expression | null | Given a positive integer $n$, determine the largest real number $\mu$ satisfying the following condition: for every $4 n$-point configuration $C$ in an open unit square $U$, there exists an open rectangle in $U$, whose sides are parallel to those of $U$, which contains exactly one point of $C$, and has an area greater than or equal to $\mu$. | [
"The required maximum is $\\frac{1}{2 n+2}$. To show that the condition in the statement is not met if $\\mu>\\frac{1}{2 n+2}$, let $U=(0,1) \\times(0,1)$, choose a small enough positive $\\epsilon$, and consider the configuration $C$ consisting of the $n$ four-element clusters of points $\\left(\\frac{i}{n+1} \\pm \\epsilon\\right) \\times\\left(\\frac{1}{2} \\pm \\epsilon\\right), i=1, \\ldots, n$, the four possible sign combinations being considered for each $i$. Clearly, every open rectangle in $U$, whose sides are parallel to those of $U$, which contains exactly one point of $C$, has area at $\\operatorname{most}\\left(\\frac{1}{n+1}+\\epsilon\\right) \\cdot\\left(\\frac{1}{2}+\\epsilon\\right)<\\mu$ if $\\epsilon$ is small enough.\n\n\n\nWe now show that, given a finite configuration $C$ of points in an open unit square $U$, there always exists an open rectangle in $U$, whose sides are parallel to those of $U$, which contains exactly one point of $C$, and has an area greater than or equal to $\\mu_{0}=\\frac{2}{|C|+4}$.\n\n\n\nTo prove this, usage will be made of the following two lemmas whose proofs are left at the end of the solution.\n\n\n\nLemma 1. Let $k$ be a positive integer, and let $\\lambda<\\frac{1}{\\lfloor k / 2\\rfloor+1}$ be a positive real number. If $t_{1}, \\ldots, t_{k}$ are pairwise distinct points in the open unit interval $(0,1)$, then some $t_{i}$ is isolated from the other $t_{j}$ by an open subinterval of $(0,1)$ whose length is greater than or equal to $\\lambda$.\n\n\n\nLemma 2. Given an integer $k \\geq 2$ and positive integers $m_{1}, \\ldots, m_{k}$,\n\n\n\n$$\n\n\\left\\lfloor\\frac{m_{1}}{2}\\right\\rfloor+\\sum_{i=1}^{k}\\left\\lfloor\\frac{m_{i}}{2}\\right\\rfloor+\\left\\lfloor\\frac{m_{k}}{2}\\right\\rfloor \\leq \\sum_{i=1}^{k} m_{i}-k+2\n\n$$\n\n\n\nBack to the problem, let $U=(0,1) \\times(0,1)$, project $C$ orthogonally on the $x$-axis to obtain the points $x_{1}<\\cdots<x_{k}$ in the open unit interval $(0,1)$, let $\\ell_{i}$ be the vertical through $x_{i}$, and let $m_{i}=\\left|C \\cap \\ell_{i}\\right|, i=1, \\ldots, k$.\n\n\n\nSetting $x_{0}=0$ and $x_{k+1}=1$, assume that $x_{i+1}-x_{i-1}>\\left(\\left\\lfloor m_{i} / 2\\right\\rfloor+1\\right) \\mu_{0}$ for some index $i$, and apply Lemma 1 to isolate one of the points in $C \\cap \\ell_{i}$ from the other ones by an open subinterval $x_{i} \\times J$ of $x_{i} \\times(0,1)$ whose length is greater than or equal to $\\mu_{0} /\\left(x_{i+1}-x_{i-1}\\right)$. Consequently, $\\left(x_{i-1}, x_{i+1}\\right) \\times J$ is an open rectangle in $U$, whose sides are parallel to those of $U$, which contains exactly one point of $C$ and has an area greater than or equal to $\\mu_{0}$.\n\n\n\nNext, we rule out the case $x_{i+1}-x_{i-1} \\leq\\left(\\left\\lfloor m_{i} / 2\\right\\rfloor+1\\right) \\mu_{0}$ for all indices $i$. If this were the case, notice that necessarily $k>1$; also, $x_{1}-x_{0}<x_{2}-x_{0} \\leq\\left(\\left\\lfloor m_{1} / 2\\right\\rfloor+1\\right) \\mu_{0}$ and $x_{k+1}-x_{k}<$ $x_{k+1}-x_{k-1} \\leq\\left(\\left\\lfloor m_{k} / 2\\right\\rfloor+1\\right) \\mu_{0}$. With reference to Lemma 2 , write\n\n\n\n$$\n\n\\begin{aligned}\n\n2=2\\left(x_{k+1}-x_{0}\\right) & =\\left(x_{1}-x_{0}\\right)+\\sum_{i=1}^{k}\\left(x_{i+1}-x_{i-1}\\right)+\\left(x_{k+1}-x_{k}\\right) \\\\\n\n& <\\left(\\left(\\left\\lfloor\\frac{m_{1}}{2}\\right\\rfloor+1\\right)+\\sum_{i=1}^{k}\\left(\\left\\lfloor\\frac{m_{i}}{2}\\right\\rfloor+1\\right)+\\left(\\left\\lfloor\\frac{m_{k}}{2}\\right\\rfloor+1\\right)\\right) \\cdot \\mu_{0} \\\\\n\n& \\leq\\left(\\sum_{i=1}^{k} m_{i}+4\\right) \\mu_{0}=(|C|+4) \\mu_{0}=2,\n\n\\end{aligned}\n\n$$\n\n\n\nand thereby reach a contradiction.\n\n\n\n\n\n\n\nFinally, we prove the two lemmas.\n\n\n\nProof of Lemma 1. Suppose, if possible, that no $t_{i}$ is isolated from the other $t_{j}$ by an open subinterval of $(0,1)$ whose length is greater than or equal to $\\lambda$. Without loss of generality, we may (and will) assume that $0=t_{0}<t_{1}<\\cdots<t_{k}<t_{k+1}=1$. Since the open interval $\\left(t_{i-1}, t_{i+1}\\right)$ isolates $t_{i}$ from the other $t_{j}$, its length, $t_{i+1}-t_{i-1}$, is less than $\\lambda$. Consequently, if $k$ is odd we have $1=\\sum_{i=0}^{(k-1) / 2}\\left(t_{2 i+2}-t_{2 i}\\right)<\\lambda\\left(1+\\frac{k-1}{2}\\right)<1$; if $k$ is even, we have $1<1+t_{k}-t_{k-1}=$ $\\sum_{i=0}^{k / 2-1}\\left(t_{2 i+2}-t_{2 i}\\right)+\\left(t_{k+1}-t_{k-1}\\right)<\\lambda\\left(1+\\frac{k}{2}\\right)<1$. A contradiction in either case.\n\n\n\nProof of Lemma 2. Let $I_{0}$, respectively $I_{1}$, be the set of all indices $i$ in the range $2, \\ldots, k-1$ such that $m_{i}$ is even, respectively odd. Clearly, $I_{0}$ and $I_{1}$ form a partition of that range. Since $m_{i} \\geq 2$ if $i$ is in $I_{0}$, and $m_{i} \\geq 1$ if $i$ is in $I_{1}$ (recall that the $m_{i}$ are positive integers),\n\n\n\n$$\n\n\\sum_{i=2}^{k-1} m_{i}=\\sum_{i \\in I_{0}} m_{i}+\\sum_{i \\in I_{1}} m_{i} \\geq 2\\left|I_{0}\\right|+\\left|I_{1}\\right|=2(k-2)-\\left|I_{1}\\right|, \\quad \\text { or } \\quad\\left|I_{1}\\right| \\geq 2(k-2)-\\sum_{i=2}^{k-1} m_{i}\n\n$$\n\n\n\nTherefore,\n\n\n\n$$\n\n\\begin{aligned}\n\n\\left\\lfloor\\frac{m_{1}}{2}\\right\\rfloor+\\sum_{i=1}^{k}\\left\\lfloor\\frac{m_{i}}{2}\\right\\rfloor+\\left\\lfloor\\frac{m_{k}}{2}\\right\\rfloor & \\leq m_{1}+\\left(\\sum_{i=2}^{k-1} \\frac{m_{i}}{2}-\\frac{\\left|I_{1}\\right|}{2}\\right)+m_{k} \\\\\n\n& \\leq m_{1}+\\left(\\frac{1}{2} \\sum_{i=2}^{k-1} m_{i}-(k-2)+\\frac{1}{2} \\sum_{i=2}^{k-1} m_{i}\\right)+m_{k} \\\\\n\n& =\\sum_{i=1}^{k} m_{i}-k+2 .\n\n\\end{aligned}\n\n$$"
] | $\frac{1}{2 n+2}$ |
1,612 | Number Theory | null | $\boxed{2^{1009}}$ | [
"$2^{1009}$"
] | false | null | Numerical | null |
Find (in closed form) the difference between the number of positive integers at most $2^{2017}$ with even weight and the number of positive integers at most $2^{2017}$ with odd weight. | [
"For every integer $M \\geq 0$, let $A_{M}=\\sum_{n=-2^{M}+1}^{0}(-1)^{w(n)}$ and let $B_{M}=$ $\\sum_{n=1}^{2^{M}}(-1)^{w(n)}$; thus, $B_{M}$ evaluates the difference of the number of even weight integers in the range 1 through $2^{M}$ and the number of odd weight integers in that range.\n\n\n\nNotice that\n\n\n\n$$\n\nw(n)= \\begin{cases}w\\left(n+2^{M}\\right)+1 & \\text { if }-2^{M}+1 \\leq n \\leq-2^{M-1} \\\\ w\\left(n-2^{M}\\right) & \\text { if } 2^{M-1}+1 \\leq n \\leq 2^{M}\\end{cases}\n\n$$\n\n\n\n\n\n\n\nto get\n\n\n\n$$\n\n\\begin{aligned}\n\n& A_{M}=-\\sum_{n=-2^{M}+1}^{-2^{M-1}}(-1)^{w\\left(n+2^{M}\\right)}+\\sum_{n=-2^{M-1}+1}^{0}(-1)^{w(n)}=-B_{M-1}+A_{M-1}, \\\\\n\n& B_{M}=\\sum_{n=1}^{2^{M-1}}(-1)^{w(n)}+\\sum_{n=2^{M-1}+1}^{2^{M}}(-1)^{w\\left(n-2^{M}\\right)}=B_{M-1}+A_{M-1} .\n\n\\end{aligned}\n\n$$\n\n\n\nIteration yields\n\n\n\n$$\n\n\\begin{aligned}\n\nB_{M} & =A_{M-1}+B_{M-1}=\\left(A_{M-2}-B_{M-2}\\right)+\\left(A_{M-2}+B_{M-2}\\right)=2 A_{M-2} \\\\\n\n& =2 A_{M-3}-2 B_{M-3}=2\\left(A_{M-4}-B_{M-4}\\right)-2\\left(A_{M-4}+B_{M-4}\\right)=-4 B_{M-4}\n\n\\end{aligned}\n\n$$\n\n\n\nThus, $B_{2017}=(-4)^{504} B_{1}=2^{1008} B_{1}$; since $B_{1}=(-1)^{w(1)}+(-1)^{w(2)}=2$, it follows that $B_{2017}=$ $2^{1009}$"
] | $2^{1009}$ |
1,613 | Algebra | null | $\boxed{2}$ | [
"2"
] | false | null | Numerical | null | Determine all positive integers $n$ satisfying the following condition: for every monic polynomial $P$ of degree at most $n$ with integer coefficients, there exists a positive integer $k \leq n$, and $k+1$ distinct integers $x_{1}, x_{2}, \ldots, x_{k+1}$ such that
$$
P\left(x_{1}\right)+P\left(x_{2}\right)+\cdots+P\left(x_{k}\right)=P\left(x_{k+1}\right) .
$$
Note. A polynomial is monic if the coefficient of the highest power is one. | [
"There is only one such integer, namely, $n=2$. In this case, if $P$ is a constant polynomial, the required condition is clearly satisfied; if $P=X+c$, then $P(c-1)+P(c+1)=$ $P(3 c)$; and if $P=X^{2}+q X+r$, then $P(X)=P(-X-q)$.\n\n\n\nTo rule out all other values of $n$, it is sufficient to exhibit a monic polynomial $P$ of degree at most $n$ with integer coefficients, whose restriction to the integers is injective, and $P(x) \\equiv 1$ $(\\bmod\\ n)$ for all integers $x$. This is easily seen by reading the relation in the statement modulo $n$, to deduce that $k \\equiv 1(\\bmod\\ n)$, so $k=1$, since $1 \\leq k \\leq n$; hence $P\\left(x_{1}\\right)=P\\left(x_{2}\\right)$ for some distinct integers $x_{1}$ and $x_{2}$, which contradicts injectivity.\n\n\n\nIf $n=1$, let $P=X$, and if $n=4$, let $P=X^{4}+7 X^{2}+4 X+1$. In the latter case, clearly, $P(x) \\equiv 1(\\bmod\\ 4)$ for all integers $x$; and $P$ is injective on the integers, since $P(x)-P(y)=$ $(x-y)\\left((x+y)\\left(x^{2}+y^{2}+7\\right)+4\\right)$, and the absolute value of $(x+y)\\left(x^{2}+y^{2}+7\\right)$ is either 0 or at least 7 for integral $x$ and $y$.\n\n\n\nAssume henceforth $n \\geq 3, n \\neq 4$, and let $f_{n}=(X-1)(X-2) \\cdots(X-n)$. Clearly, $f_{n}(x) \\equiv$ $0(\\bmod n)$ for all integers $x$. If $n$ is odd, then $f_{n}$ is non-decreasing on the integers; and if, in addition, $n>3$, then $f_{n}(x) \\equiv 0(\\bmod n+1)$ for all integers $x$, since $f_{n}(0)=-n !=-1 \\cdot 2 \\cdot \\cdots$. $\\frac{n+1}{2} \\cdot \\cdots \\cdot n \\equiv 0(\\bmod\\ n+1)$.\n\n\n\nFinally, let $P=f_{n}+n X+1$ if $n$ is odd, and let $P=f_{n-1}+n X+1$ if $n$ is even. In either case, $P$ is strictly increasing, hence injective, on the integers, and $P(x) \\equiv 1(\\bmod n)$ for all integers $x$."
] | 2 |
1,614 | Combinatorics | null | $\boxed{2n-2}$ | [
"$2n-2$"
] | false | null | Expression | null | Let $n$ be an integer greater than 1 and let $X$ be an $n$-element set. A non-empty collection of subsets $A_{1}, \ldots, A_{k}$ of $X$ is tight if the union $A_{1} \cup \cdots \cup A_{k}$ is a proper subset of $X$ and no element of $X$ lies in exactly one of the $A_{i}$ s. Find the largest cardinality of a collection of proper non-empty subsets of $X$, no non-empty subcollection of which is tight.
Note. A subset $A$ of $X$ is proper if $A \neq X$. The sets in a collection are assumed to be distinct. The whole collection is assumed to be a subcollection. | [
"The required maximum is $2 n-2$. To describe a $(2 n-2)$-element collection satisfying the required conditions, write $X=\\{1,2, \\ldots, n\\}$ and set $B_{k}=\\{1,2, \\ldots, k\\}$, $k=1,2, \\ldots, n-1$, and $B_{k}=\\{k-n+2, k-n+3, \\ldots, n\\}, k=n, n+1, \\ldots, 2 n-2$. To show that no subcollection of the $B_{k}$ is tight, consider a subcollection $\\mathcal{C}$ whose union $U$ is a proper subset of $X$, let $m$ be an element in $X \\backslash U$, and notice that $\\mathcal{C}$ is a subcollection of $\\left\\{B_{1}, \\ldots, B_{m-1}, B_{m+n-1}, \\ldots, B_{2 n-2}\\right\\}$, since the other $B$ 's are precisely those containing $m$. If $U$ contains elements less than $m$, let $k$ be the greatest such and notice that $B_{k}$ is the only member of $\\mathcal{C}$ containing $k$; and if $U$ contains elements greater than $m$, let $k$ be the least such and notice that $B_{k+n-2}$ is the only member of $\\mathcal{C}$ containing $k$. Consequently, $\\mathcal{C}$ is not tight.\n\n\n\nWe now proceed to show by induction on $n \\geq 2$ that the cardinality of a collection of proper non-empty subsets of $X$, no subcollection of which is tight, does not exceed $2 n-2$. The base case $n=2$ is clear, so let $n>2$ and suppose, if possible, that $\\mathcal{B}$ is a collection of $2 n-1$ proper non-empty subsets of $X$ containing no tight subcollection.\n\n\n\nTo begin, notice that $\\mathcal{B}$ has an empty intersection: if the members of $\\mathcal{B}$ shared an element $x$, then $\\mathcal{B}^{\\prime}=\\{B \\backslash\\{x\\}: B \\in \\mathcal{B}, B \\neq\\{x\\}\\}$ would be a collection of at least $2 n-2$ proper non-empty subsets of $X \\backslash\\{x\\}$ containing no tight subcollection, and the induction hypothesis would be contradicted.\n\n\n\nNow, for every $x$ in $X$, let $\\mathcal{B}_{x}$ be the (non-empty) collection of all members of $\\mathcal{B}$ not containing $x$. Since no subcollection of $\\mathcal{B}$ is tight, $\\mathcal{B}_{x}$ is not tight, and since the union of $\\mathcal{B}_{x}$ does not contain $x$, some $x^{\\prime}$ in $X$ is covered by a single member of $\\mathcal{B}_{x}$. In other words, there is a single set in $\\mathcal{B}$ covering $x^{\\prime}$ but not $x$. In this case, draw an arrow from $x$ to $x^{\\prime}$. Since there is at least one arrow from each $x$ in $X$, some of these arrows form a (minimal) cycle $x_{1} \\rightarrow x_{2} \\rightarrow \\cdots \\rightarrow x_{k} \\rightarrow x_{k+1}=x_{1}$ for some suitable integer $k \\geq 2$. Let $A_{i}$ be the unique member of $\\mathcal{B}$ containing $x_{i+1}$ but not $x_{i}$, and let $X^{\\prime}=\\left\\{x_{1}, x_{2}, \\ldots, x_{k}\\right\\}$.\n\n\n\nRemove $A_{1}, A_{2}, \\ldots, A_{k}$ from $\\mathcal{B}$ to obtain a collection $\\mathcal{B}^{\\prime}$ each member of which either contains or is disjoint from $X^{\\prime}$ : for if a member $B$ of $\\mathcal{B}^{\\prime}$ contained some but not all elements of $X^{\\prime}$, then $B$ should contain $x_{i+1}$ but not $x_{i}$ for some $i$, and $B=A_{i}$, a contradiction. This rules out the case $k=n$, for otherwise $\\mathcal{B}=\\left\\{A_{1}, A_{2}, \\ldots, A_{n}\\right\\}$, so $|\\mathcal{B}|<2 n-1$.\n\n\n\nTo rule out the case $k<n$, consider an extra element $x^{*}$ outside $X$ and let\n\n\n\n$$\n\n\\mathcal{B}^{*}=\\left\\{B: B \\in \\mathcal{B}^{\\prime}, B \\cap X^{\\prime}=\\varnothing\\right\\} \\cup\\left\\{\\left(B \\backslash X^{\\prime}\\right) \\cup\\left\\{x^{*}\\right\\}: B \\in \\mathcal{B}^{\\prime}, X^{\\prime} \\subseteq B\\right\\}\n\n$$\n\n\n\nthus, in each member of $\\mathcal{B}^{\\prime}$ containing $X^{\\prime}$, the latter is collapsed to $\\operatorname{singleton} x^{*}$. Notice that $\\mathcal{B}^{*}$ is a collection of proper non-empty subsets of $X^{*}=\\left(X \\backslash X^{\\prime}\\right) \\cup\\left\\{x^{*}\\right\\}$, no subcollection of which is tight. By the induction hypothesis, $\\left|\\mathcal{B}^{\\prime}\\right|=\\left|\\mathcal{B}^{*}\\right| \\leq 2\\left|X^{*}\\right|-2=2(n-k)$, so $|\\mathcal{B}| \\leq 2(n-k)+k=$ $2 n-k<2 n-1$, a final contradiction.",
"Proceed again by induction on $n$ to show that the cardinality of a collection of proper non-empty subsets of $X$, no subcollection of which is tight, does not exceed $2 n-2$.\n\n\n\nConsider any collection $\\mathcal{B}$ of proper non-empty subsets of $X$ with no tight subcollection (we call such collection good). Assume that there exist $M, N \\in \\mathcal{B}$ such that $M \\cup N$ is distinct from $M, N$, and $X$. In this case, we will show how to modify $\\mathcal{B}$ so that it remains good, contains the same number of sets, but the total number of elements in the sets of $\\mathcal{B}$ increases.\n\n\n\n\n\n\n\nConsider a maximal (relative to set-theoretic inclusion) subcollection $\\mathcal{C} \\subseteq \\mathcal{B}$ such that the set $C=\\bigcup_{A \\in \\mathcal{C}} A$ is distinct from $X$ and from all members of $\\mathcal{C}$. Notice here that the union of any subcollection $\\mathcal{D} \\subset \\mathcal{B}$ cannot coincide with any $K \\in \\mathcal{B} \\backslash \\mathcal{D}$, otherwise $\\{K\\} \\cup \\mathcal{D}$ would be tight. Surely, $\\mathcal{C}$ exists (since $\\{M, N\\}$ is an example of a collection satisfying the requirements on $\\mathcal{C}$, except for maximality); moreover, $C \\notin \\mathcal{B}$ by the above remark.\n\n\n\nSince $C \\neq X$, there exists an $L \\in \\mathcal{C}$ and $x \\in L$ such that $L$ is the unique set in $\\mathcal{C}$ containing $x$. Now replace in $\\mathcal{B}$ the set $L$ by $C$ in order to obtain a new collection $\\mathcal{B}^{\\prime}$ (then $\\left|\\mathcal{B}^{\\prime}\\right|=|\\mathcal{B}|$ ). We claim that $\\mathcal{B}^{\\prime}$ is good.\n\n\n\nAssume, to the contrary, that $\\mathcal{B}^{\\prime}$ contained a tight subcollection $\\mathcal{T}$; clearly, $C \\in \\mathcal{T}$, otherwise $\\mathcal{B}$ is not good. If $\\mathcal{T} \\subseteq \\mathcal{C} \\cup\\{C\\}$, then $C$ is the unique set in $\\mathcal{T}$ containing $x$ which is impossible. Therefore, there exists $P \\in \\mathcal{T} \\backslash(\\mathcal{C} \\cup\\{C\\})$. By maximality of $\\mathcal{C}$, the collection $\\mathcal{C} \\cup\\{P\\}$ does not satisfy the requirements imposed on $\\mathcal{C}$; since $P \\cup C \\neq X$, this may happen only if $C \\cup P=P$, i.e., if $C \\subset P$. But then $\\mathcal{G}=(\\mathcal{T} \\backslash\\{C\\}) \\cup \\mathcal{C}$ is a tight subcollection in $\\mathcal{B}$ : all elements of $C$ are covered by $\\mathcal{G}$ at least twice (by $P$ and an element of $\\mathcal{C}$ ), and all the rest elements are covered by $\\mathcal{G}$ the same number of times as by $\\mathcal{T}$. A contradiction. Thus $\\mathcal{B}^{\\prime}$ is good.\n\n\n\nSuch modifications may be performed finitely many times, since the total number of elements of sets in $\\mathcal{B}$ increases. Thus, at some moment we arrive at a good collection $\\mathcal{B}$ for which the procedure no longer applies. This means that for every $M, N \\in \\mathcal{B}$, either $M \\cup N=X$ or one of them is contained in the other.\n\n\n\nNow let $M$ be a minimal (with respect to inclusion) set in $\\mathcal{B}$. Then each set in $\\mathcal{B}$ either contains $M$ or forms $X$ in union with $M$ (i.e., contains $X \\backslash M$ ). Now one may easily see that the two collections\n\n\n\n$$\n\n\\mathcal{B}_{+}=\\{A \\backslash M: A \\in \\mathcal{B}, M \\subset A, A \\neq M\\}, \\quad \\mathcal{B}_{-}=\\{A \\cap M: A \\in \\mathcal{B}, X \\backslash M \\subset A, A \\neq X \\backslash M\\}\n\n$$\n\n\n\nare good as collections of subsets of $X \\backslash M$ and $M$, respectively; thus, by the induction hypothesis, we have $\\left|\\mathcal{B}_{+}\\right|+\\left|\\mathcal{B}_{-}\\right| \\leq 2 n-4$.\n\n\n\nFinally, each set $A \\in \\mathcal{B}$ either produces a set in one of the two new collections, or coincides with $M$ or $X \\backslash M$. Thus $|\\mathcal{B}| \\leq\\left|\\mathcal{B}_{+}\\right|+\\left|\\mathcal{B}_{-}\\right|+2 \\leq 2 n-2$, as required.",
"We provide yet another proof of the estimate $|\\mathcal{B}| \\leq 2 n-2$. Consider any collection $\\mathcal{B}$ of proper non-empty subsets of $X$ with no tight subcollection (we call such collection good). Arguing indirectly, we assume that there exists a good collection $\\mathcal{B}$ with $|\\mathcal{B}| \\geq 2 n-1$, and choose one such for the minimal possible value of $n$. Clearly, $n>2$.\n\n\n\nFirstly, we perform a different modification of $\\mathcal{B}$. Choose any $x \\in X$, and consider the subcollection $\\mathcal{B}_{x}=\\{B: B \\in \\mathcal{B}, x \\notin B\\}$. By our assumption, $\\mathcal{B}_{x}$ is not tight. As the union of sets in $\\mathcal{B}_{x}$ is distinct from $X$, either this collection is empty, or there exists an element $y \\in X$ contained in a unique member $A_{x}$ of $\\mathcal{B}_{x}$. In the former case, we add the set $B_{x}=X \\backslash\\{x\\}$ to $\\mathcal{B}$, and in the latter we replace $A_{x}$ by $B_{x}$, to form a new collection $\\mathcal{B}^{\\prime}$. (Notice that if $B_{x} \\in \\mathcal{B}$, then $B_{x} \\in \\mathcal{B}_{x}$ and $y \\in B_{x}$, so $B_{x}=A_{x}$.)\n\n\n\nWe claim that the collection $\\mathcal{B}^{\\prime}$ is also good. Indeed, if $\\mathcal{B}^{\\prime}$ has a tight subcollection $\\mathcal{T}$, then $B_{x}$ should lie in $\\mathcal{T}$. Then, as the union of the sets in $\\mathcal{T}$ is distinct from $X$, we should have $\\mathcal{T} \\subseteq \\mathcal{B}_{x} \\cup\\left\\{B_{x}\\right\\}$. But in this case an element $y$ is contained in a unique member of $\\mathcal{T}$, namely $B_{x}$, so $\\mathcal{T}$ is not tight - a contradiction.\n\n\n\nPerform this procedure for every $x \\in X$, to get a good collection $\\mathcal{B}$ containing the sets $B_{x}=X \\backslash\\{x\\}$ for all $x \\in X$. Consider now an element $x \\in X$ such that $\\left|\\mathcal{B}_{x}\\right|$ is maximal. As we have mentioned before, there exists an element $y \\in X$ belonging to a unique member (namely, $B_{x}$ ) of $\\mathcal{B}_{x}$. Thus, $\\mathcal{B}_{x} \\backslash\\left\\{B_{x}\\right\\} \\subset \\mathcal{B}_{y}$; also, $B_{y} \\in \\mathcal{B}_{y} \\backslash \\mathcal{B}_{x}$. Thus we get $\\left|\\mathcal{B}_{y}\\right| \\geq\\left|\\mathcal{B}_{x}\\right|$, which by the maximality assumption yields the equality, which in turn means that $\\mathcal{B}_{y}=\\left(\\mathcal{B}_{x} \\backslash\\left\\{B_{x}\\right\\}\\right) \\cup\\left\\{B_{y}\\right\\}$.\n\n\n\nTherefore, each set in $\\mathcal{B} \\backslash\\left\\{B_{x}, B_{y}\\right\\}$ contains either both $x$ and $y$, or none of them. Collapsing $\\{x, y\\}$ to singleton $x^{*}$, we get a new collection of $|\\mathcal{B}|-2$ subsets of $(X \\backslash\\{x, y\\}) \\cup\\left\\{x^{*}\\right\\}$ containing no tight subcollection. This contradicts minimality of $n$."
] | $2n-2$ |
1,618 | Number Theory | null | $\boxed{(1,8,19), (2,7,13), (4,5,7)}$ | [
"$(1,8,19), (2,7,13), (4,5,7)$"
] | true | null | Tuple | null | Determine all prime numbers $p$ and all positive integers $x$ and $y$ satisfying $x^{3}+y^{3}=$ $p(x y+p)$. | [
"Up to a swap of the first two entries, the only solutions are $(x, y, p)=(1,8,19)$, $(x, y, p)=(2,7,13)$ and $(x, y, p)=(4,5,7)$. The verification is routine.\n\n\n\nSet $s=x+y$. Rewrite the equation in the form $s\\left(s^{2}-3 x y\\right)=p(p+x y)$, and express $x y$ :\n\n\n\n$$\n\nx y=\\frac{s^{3}-p^{2}}{3 s+p} \\tag{*}\n\n$$\n\n\n\nIn particular,\n\n\n\n$$\n\ns^{2} \\geq 4 x y=\\frac{4\\left(s^{3}-p^{2}\\right)}{3 s+p}\n\n$$\n\n\n\nor\n\n\n\n$$\n\n(s-2 p)\\left(s^{2}+s p+2 p^{2}\\right) \\leq p^{2}-p^{3}<0\n\n$$\n\n\n\nso $s<2 p$.\n\n\n\nIf $p \\mid s$, then $s=p$ and $x y=p(p-1) / 4$ which is impossible for $x+y=p$ (the equation $t^{2}-p t+p(p-1) / 4=0$ has no integer solutions).\n\n\n\nIf $p \\nmid s$, rewrite $(*)$ in the form\n\n\n\n$$\n\n27 x y=\\left(9 s^{2}-3 s p+p^{2}\\right)-\\frac{p^{2}(p+27)}{3 s+p} .\n\n$$\n\n\n\nSince $p \\nmid s$, this could be integer only if $3 s+p \\mid$ $p+27$, and hence $3 s+p \\mid 27-s$.\n\n\n\nIf $s \\neq 9$, then $|3 s-27| \\geq 3 s+p$, so $27-3 s \\geq$ $3 s+p$, or $27-p \\geq 6 s$, whence $s \\leq 4$. These cases are ruled out by hand.\n\n\n\nIf $s=x+y=9$, then $(*)$ yields $x y=27-p$. Up to a swap of $x$ and $y$, all such triples $(x, y, p)$ are $(1,8,19),(2,7,13)$, and $(4,5,7)$.",
"Set again $s=x+y$. It is readily checked that $s \\leq 8$ provides no solutions, so assume $s \\geq 9$. Notice that $x^{3}+y^{3}=s\\left(x^{2}-x y+y^{2}\\right) \\geq$ $\\frac{1}{4} s^{3}$ and $x y \\leq \\frac{1}{4} s^{2}$. The condition in the statement then implies $s^{2}(s-p) \\leq 4 p^{2}$, so $s<p+4$.\n\n\n\nNotice that $p$ divides one of $s$ and $x^{2}-x y+y^{2}$. The case $p \\mid s$ is easily ruled out by the condition $s<p+4$ : The latter forces $s=p$, so $x^{2}-x y+y^{2}=x y+p$, i. e., $(x-y)^{2}=p$, which is impossible.\n\n\n\nHence $p \\mid x^{2}-x y+y^{2}$, so $x^{2}-x y+y^{2}=k p$ and $x y+p=k s$ for some positive integer $k$, implying\n\n\n\n$$\n\ns^{2}+3 p=k(3 s+p) \\tag{**}\n\n$$\n\n\n\nRecall that $p \\nmid s$ to infer that $3 k \\equiv s(\\bmod p)$. We now present two approaches.\n\n\n\n1st Approach. Write $3 k=s+m p$ for some integer $m$ and plug $k=\\frac{1}{3}(s+m p)$ into $(* *)$ to get $s=(9-m p) /(3 m+1)$. The condition $s \\geq 9$ then forces $m=0$, so $s=9$, in which case, up to a swap of the first two entries, the solutions turn out to be $(x, y, p)=(1,8,19),(x, y, p)=(2,7,13)$ and $(x, y, p)=(4,5,7)$.\n\n\n\n2nd Approach. Notice that $k=\\frac{s^{2}+3 p}{3 s+p}=3+$ $\\frac{s(s-9)}{3 s+p} \\leq 3+\\frac{1}{3}(s-9)=\\frac{1}{3} s \\leq \\frac{1}{3}(p+3)$, since $s<p+4$. Hence $3 k \\leq p+3$, and the congruence $3 k \\equiv s$ $(\\bmod p)$ then forces either $3 k=s-p$ or $3 k=s$.\n\n\n\nThe case $3 k=s-p$ is easily ruled out: Otherwise, $(* *)$ boils down to $2 s+p+9=0$, which is clearly impossible.\n\n\n\nFinally, if $3 k=s$, then $(* *)$ reduces to $s=9$. In this case, up to a swap of the first two entries, the only solutions are $(x, y, p)=(1,8,19)$, $(x, y, p)=(2,7,13)$ and $(x, y, p)=(4,5,7)$."
] | $(1,8,19), (2,7,13), (4,5,7)$ |
1,620 | Algebra | null | $\boxed{2n}$ | [
"$2n$"
] | false | null | Expression | null | Let $n \geqslant 2$ be an integer, and let $f$ be a $4 n$-variable polynomial with real coefficients. Assume that, for any $2 n$ points $\left(x_{1}, y_{1}\right), \ldots,\left(x_{2 n}, y_{2 n}\right)$ in the plane, $f\left(x_{1}, y_{1}, \ldots, x_{2 n}, y_{2 n}\right)=0$ if and only if the points form the vertices of a regular $2 n$-gon in some order, or are all equal.
Determine the smallest possible degree of $f$. | [
"The smallest possible degree is $2 n$. In what follows, we will frequently write $A_{i}=$ $\\left(x_{i}, y_{i}\\right)$, and abbreviate $P\\left(x_{1}, y_{1}, \\ldots, x_{2 n}, y_{2 n}\\right)$ to $P\\left(A_{1}, \\ldots, A_{2 n}\\right)$ or as a function of any $2 n$ points.\n\n\n\nSuppose that $f$ is valid. First, we note a key property:\n\n\n\nClaim (Sign of $f$ ). $f$ attains wither only nonnegative values, or only nonpositive values.\n\n\n\nProof. This follows from the fact that the zero-set of $f$ is very sparse: if $f$ takes on a positive and a negative value, we can move $A_{1}, \\ldots, A_{2 n}$ from the negative value to the positive value without ever having them form a regular $2 n$-gon - a contradiction.\n\n\n\nThe strategy for showing $\\operatorname{deg} f \\geq 2 n$ is the following. We will animate the points $A_{1}, \\ldots, A_{2 n}$ linearly in a variable $t$; then $g(t)=f\\left(A_{1}, \\ldots, A_{2 n}\\right)$ will have degree at most $\\operatorname{deg} f$ (assuming it is not zero). The claim above then establishes that any root of $g$ must be a multiple root, so if we can show that there are at least $n$ roots, we will have shown $\\operatorname{deg} g \\geq 2 n$, and so $\\operatorname{deg} f \\geq 2 n$.\n\n\n\nGeometrically, our goal is to exhibit $2 n$ linearly moving points so that they form a regular $2 n$-gon a total of $n$ times, but not always form one.\n\n\n\nWe will do this as follows. Draw $n$ mirrors through the origin, as lines making angles of $\\frac{\\pi}{n}$ with each other. Then, any point $P$ has a total of $2 n$ reflections in the mirrors, as shown below for $n=5$. (Some of these reflections may overlap.)\n\n\n\nDraw the $n$ angle bisectors of adjacent mirrors. Observe that the reflections of $P$ form a regular $2 n$ gon if and only if $P$ lies on one of the bisectors.\n\n\n\nWe will animate $P$ on any line $\\ell$ which intersects all $n$ bisectors (but does not pass through the origin), and let $P_{1}, \\ldots, P_{2 n}$ be its reflections. Clearly, these are also all linearly animated, and because of the reasons above, they will form a regular $2 n$-gon exactly $n$ times, when $\\ell$ meets each bisector. So this establishes $\\operatorname{deg} f \\geq 2 n$ for the reasons described previously.\n\n\n\nNow we pass to constructing a polynomial $f$ of degree $2 n$ having the desired property. First of all, we will instead find a polynomial $g$ which has this property, but only when points with sum zero are input. This still solves the problem, because then we can choose\n\n\n\n$$\nf\\left(A_{1}, A_{2}, \\ldots, A_{2 n}\\right)=g\\left(A_{1}-\\bar{A}, \\ldots, A_{2 n}-\\bar{A}\\right)\n$$\n\n\n\nwhere $\\bar{A}$ is the centroid of $A_{1}, \\ldots, A_{2 n}$. This has the upshot that we can now always assume $A_{1}+\\cdots+A_{2 n}=0$, which will simplify the ensuing discussion.\n\n\n\n<img_3624>\n\n\n\nWe will now construct a suitable $g$ as a sum of squares. This means that, if we write $g=g_{1}^{2}+g_{2}^{2}+$ $\\cdots+g_{m}^{2}$, then $g=0$ if and only if $g_{1}=\\cdots=g_{m}=0$, and that if their degrees are $d_{1}, \\ldots, d_{m}$, then $g$ has degree at most $2 \\max \\left(d_{1}, \\ldots, d_{m}\\right)$.\n\n\n\nThus, it is sufficient to exhibit several polynomials, all of degree at most $n$, such that $2 n$ points with zero sum are the vertices of a regular $2 n$-gon if and only if the polynomials are all zero at those points.\n\n\n\n\n\n\n\nFirst, we will impose the constraints that all $\\left|A_{i}\\right|^{2}=x_{i}^{2}+y_{i}^{2}$ are equal. This uses multiple degree 2 constraints.\n\n\n\nNow, we may assume that the points $A_{1}, \\ldots, A_{2 n}$ all lie on a circle with centre 0 , and $A_{1}+\\cdots+A_{2 n}=0$. If this circle has radius 0 , then all $A_{i}$ coincide, and we may ignore this case.\n\n\n\nOtherwise, the circle has positive radius. We will use the following lemma.\n\n\n\nLemma. Suppose that $a_{1}, \\ldots, a_{2 n}$ are complex numbers of the same non-zero magnitude, and suppose that $a_{1}^{k}+\\cdots+a_{2 n}^{k}=0, k=1, \\ldots, n$. Then $a_{1}, \\ldots, a_{2 n}$ form a regular $2 n$-gon centred at the origin. (Conversely, this is easily seen to be sufficient.)\n\n\n\nProof. Since all the hypotheses are homogenous, we may assume (mostly for convenience) that $a_{1}, \\ldots, a_{2 n}$ lie on the unit circle. By Newton's sums, the $k$-th symmetric sums of $a_{1}, \\ldots, a_{2 n}$ are all zero for $k$ in the range $1, \\ldots, n$.\n\n\n\nTaking conjugates yields $a_{1}^{-k}+\\cdots+a_{2 n}^{-k}=0$, $k=1, \\ldots, n$. Thus, we can repeat the above logic to obtain that the $k$-th symmetric sums of $a_{1}^{-1}, \\ldots, a_{2 n}^{-1}$ are also all zero for $k=1, \\ldots, n$. However, these are simply the $(2 n-k)$-th symmetric sums of $a_{1}, \\ldots, a_{2 n}$ (divided by $a_{1} \\cdots a_{2 n}$ ), so the first $2 n-1$ symmetric sums of $a_{1}, \\ldots, a_{2 n}$ are all zero. This implies that $a_{1}, \\ldots, a_{2 n}$ form a regular $2 n$-gon centred at the origin.\n\n\n\nWe will encode all of these constraints into our polynomial. More explicitly, write $a_{r}=x_{r}+y_{r} i$; then the constraint $a_{1}^{k}+\\cdots+a_{2 n}^{k}=0$ can be expressed as $p_{k}+q_{k} i=0$, where $p_{k}$ and $q_{k}$ are real polynomials in the coordinates. To incorporate this, simply impose the constraints $p_{k}=0$ and $q_{k}=0$; these are conditions of degree $k \\leq n$, so their squares are all of degree at most $2 n$.\n\n\n\nTo recap, taking the sum of squares of all of these constraints gives a polynomial $f$ of degree at most $2 n$ which works whenever $A_{1}+\\cdots+A_{2 n}=0$. Finally, the centroid-shifting trick gives a polynomial which works in general, as wanted."
] | $2n$ |
1,631 | Algebra | null | $\boxed{2}$ | [
"2"
] | false | null | Numerical | null | For a positive integer $a$, define a sequence of integers $x_{1}, x_{2}, \ldots$ by letting $x_{1}=a$ and $x_{n+1}=2 x_{n}+1$ for $n \geq 1$. Let $y_{n}=2^{x_{n}}-1$. Determine the largest possible $k$ such that, for some positive integer $a$, the numbers $y_{1}, \ldots, y_{k}$ are all prime. | [
"The largest such is $k=2$. Notice first that if $y_{i}$ is prime, then $x_{i}$ is prime as well. Actually, if $x_{i}=1$ then $y_{i}=1$ which is not prime, and if $x_{i}=m n$ for integer $m, n>1$ then $2^{m}-1 \\mid 2^{x_{i}}-1=y_{i}$, so $y_{i}$ is composite. In particular, if $y_{1}, y_{2}, \\ldots, y_{k}$ are primes for some $k \\geq 1$ then $a=x_{1}$ is also prime.\n\n\n\nNow we claim that for every odd prime $a$ at least one of the numbers $y_{1}, y_{2}, y_{3}$ is composite (and thus $k<3$ ). Assume, to the contrary, that $y_{1}, y_{2}$, and $y_{3}$ are primes; then $x_{1}, x_{2}, x_{3}$ are primes as well. Since $x_{1} \\geq 3$ is odd, we have $x_{2}>3$ and $x_{2} \\equiv 3(\\bmod 4)$; consequently, $x_{3} \\equiv 7$ $(\\bmod 8)$. This implies that 2 is a quadratic residue modulo $p=x_{3}$, so $2 \\equiv s^{2}(\\bmod p)$ for some integer $s$, and hence $2^{x_{2}}=2^{(p-1) / 2} \\equiv s^{p-1} \\equiv 1(\\bmod p)$. This means that $p \\mid y_{2}$, thus $2^{x_{2}}-1=x_{3}=2 x_{2}+1$. But it is easy to show that $2^{t}-1>2 t+1$ for all integer $t>3$. A contradiction.\n\n\n\nFinally, if $a=2$, then the numbers $y_{1}=3$ and $y_{2}=31$ are primes, while $y_{3}=2^{11}-1$ is divisible by 23 ; in this case we may choose $k=2$ but not $k=3$."
] | 2 |
1,641 | Combinatorics | null | $\boxed{\binom{2n}{n}}$ | [
"$\\binom{2n}{n}$"
] | false | null | Expression | null | Let $n$ be a positive integer and fix $2 n$ distinct points on a circumference. Split these points into $n$ pairs and join the points in each pair by an arrow (i.e., an oriented line segment). The resulting configuration is good if no two arrows cross, and there are no arrows $\overrightarrow{A B}$ and $\overrightarrow{C D}$ such that $A B C D$ is a convex quadrangle oriented clockwise. Determine the number of good configurations. | [
"The required number is $\\left(\\begin{array}{c}2 n \\\\ n\\end{array}\\right)$. To prove this, trace the circumference counterclockwise to label the points $a_{1}, a_{2}, \\ldots, a_{2 n}$.\n\nLet $\\mathcal{C}$ be any good configuration and let $O(\\mathcal{C})$ be the set of all points from which arrows emerge. We claim that every $n$-element subset $S$ of $\\left\\{a_{1}, \\ldots, a_{2 n}\\right\\}$ is an $O$-image of a unique good configuration; clearly, this provides the answer.\n\nTo prove the claim induct on $n$. The base case $n=1$ is clear. For the induction step, consider any $n$-element subset $S$ of $\\left\\{a_{1}, \\ldots, a_{2 n}\\right\\}$, and assume that $S=O(\\mathcal{C})$ for some good configuration $\\mathcal{C}$. Take any index $k$ such that $a_{k} \\in S$ and $a_{k+1} \\notin S$ (assume throughout that indices are cyclic modulo $2 n$, i.e., $a_{2 n+1}=a_{1}$ etc.).\n\nIf the arrow from $a_{k}$ points to some $a_{\\ell}, k+1<\\ell(<2 n+k)$, then the arrow pointing to $a_{k+1}$ emerges from some $a_{m}, m$ in the range $k+2$ through $\\ell-1$, since these two arrows do not cross. Then the arrows $a_{k} \\rightarrow a_{\\ell}$ and $a_{m} \\rightarrow a_{k+1}$ form a prohibited quadrangle. Hence, $\\mathcal{C}$ contains an arrow $a_{k} \\rightarrow a_{k+1}$.\n\nOn the other hand, if any configuration $\\mathcal{C}$ contains the arrow $a_{k} \\rightarrow a_{k+1}$, then this arrow cannot cross other arrows, neither can it occur in prohibited quadrangles.\n\nThus, removing the points $a_{k}, a_{k+1}$ from $\\left\\{a_{1}, \\ldots, a_{2 n}\\right\\}$ and the point $a_{k}$ from $S$, we may apply the induction hypothesis to find a unique good configuration $\\mathcal{C}^{\\prime}$ on $2 n-2$ points compatible with the new set of sources (i.e., points from which arrows emerge). Adjunction of the arrow $a_{k} \\rightarrow a_{k+1}$ to $\\mathcal{C}^{\\prime}$ yields a unique good configuration on $2 n$ points, as required.",
"Use the counterclockwise labelling $a_{1}, a_{2}, \\ldots, a_{2 n}$ in the solution above.\n\nLetting $D_{n}$ be the number of good configurations on $2 n$ points, we establish a recurrence relation for the $D_{n}$. To this end, let $C_{n}=\\frac{(2 n) !}{n !(n+1) !}$ the $n$th Catalan number; it is well-known that $C_{n}$ is the number of ways to connect $2 n$ given points on the circumference by $n$ pairwise disjoint chords.\n\nSince no two arrows cross, in any good configuration the vertex $a_{1}$ is connected to some $a_{2 k}$. Fix $k$ in the range 1 through $n$ and count the number of good configurations containing the arrow $a_{1} \\rightarrow a_{2 k}$. Let $\\mathcal{C}$ be any such configuration.\n\nIn $\\mathcal{C}$, the vertices $a_{2}, \\ldots, a_{2 k-1}$ are paired off with one other, each arrow pointing from the smaller to the larger index, for otherwise it would form a prohibited quadrangle with $a_{1} \\rightarrow a_{2 k}$. Consequently, there are $C_{k-1}$ ways of drawing such arrows between $a_{2}, \\ldots, a_{2 k-1}$.\n\nOn the other hand, the arrows between $a_{2 k+1}, \\ldots, a_{2 n}$ also form a good configuration, which can be chosen in $D_{n-k}$ ways. Finally, it is easily seen that any configuration of the first kind and any configuration of the second kind combine together to yield an overall good configuration.\n\nThus the number of good configurations containing the arrow $a_{1} \\rightarrow a_{2 k}$ is $C_{k-1} D_{n-k}$. Clearly, this is also the number of good configurations containing the arrow $a_{2(n-k+1)} \\rightarrow a_{1}$, so\n\n$$\nD_{n}=2 \\sum_{k=1}^{n} C_{k-1} D_{n-k} \\tag{*}\n$$\n\nTo find an explicit formula for $D_{n}$, let $d(x)=\\sum_{n=0}^{\\infty} D_{n} x^{n}$ and let $c(x)=\\sum_{n=0}^{\\infty} C_{n} x^{n}=$ $\\frac{1-\\sqrt{1-4 x}}{2 x}$ be the generating functions of the $D_{n}$ and the $C_{n}$, respectively. Since $D_{0}=1$, relation $(*)$\n\n\n\nyields $d(x)=2 x c(x) d(x)+1$, so\n\n$$\n\\begin{aligned}\nd(x)=\\frac{1}{1-2 x c(x)}=(1-4 x)^{-1 / 2} & =\\sum_{n \\geq 0}\\left(-\\frac{1}{2}\\right)\\left(-\\frac{3}{2}\\right) \\ldots\\left(-\\frac{2 n-1}{2}\\right) \\frac{(-4 x)^{n}}{n !} \\\\\n& =\\sum_{n \\geq 0} \\frac{2^{n}(2 n-1) ! !}{n !} x^{n}=\\sum_{n \\geq 0}\\left(\\begin{array}{c}\n2 n \\\\\nn\n\\end{array}\\right) x^{n} .\n\\end{aligned}\n$$\n\nConsequently, $D_{n}=\\left(\\begin{array}{c}2 n \\\\ n\\end{array}\\right)$.\n\n### solution_2\nLet $C_{n}=\\frac{1}{n+1}\\left(\\begin{array}{c}2 n \\\\ n\\end{array}\\right)$ denote the $n$th Catalan number and recall that there are exactly $C_{n}$ ways to join $2 n$ distinct points on a circumference by $n$ pairwise disjoint chords. Such a configuration of chords will be referred to as a Catalan n-configuration. An orientation of the chords in a Catalan configuration $\\mathcal{C}$ making it into a good configuration (in the sense defined in the statement of the problem) will be referred to as a good orientation for $\\mathcal{C}$.\n\nWe show by induction on $n$ that there are exactly $n+1$ good orientations for any Catalan $n$-configuration, so there are exactly $(n+1) C_{n}=\\left(\\begin{array}{c}2 n \\\\ n\\end{array}\\right)$ good configurations on $2 n$ points. The base case $n=1$ is clear.\n\nFor the induction step, let $n>1$, let $\\mathcal{C}$ be a Catalan $n$-configuration, and let $a b$ be a chord of minimal length in $\\mathcal{C}$. By minimality, the endpoints of the other chords in $\\mathcal{C}$ all lie on the major arc $a b$ of the circumference.\n\nLabel the $2 n$ endpoints $1,2, \\ldots, 2 n$ counterclockwise so that $\\{a, b\\}=\\{1,2\\}$, and notice that the good orientations for $\\mathcal{C}$ fall into two disjoint classes: Those containing the arrow $1 \\rightarrow 2$, and those containing the opposite arrow.\n\nSince the arrow $1 \\rightarrow 2$ cannot be involved in a prohibited quadrangle, the induction hypothesis applies to the Catalan $(n-1)$-configuration formed by the other chords to show that the first class contains exactly $n$ good orientations.\n\nFinally, the second class consists of a single orientation, namely, $2 \\rightarrow 1$, every other arrow emerging from the smaller endpoint of the respective chord; a routine verification shows that this is indeed a good orientation. This completes the induction step and ends the proof.\n\n### solution_3\nWe intend to count the number of good orientations of a Catalan $n$-configuration.\n\nFor each such configuration, we consider its dual graph $T$ whose vertices are finite regions bounded by chords and the circle, and an edge connects two regions sharing a boundary segment. This graph $T$ is a plane tree with $n$ edges and $n+1$ vertices.\n\nThere is a canonical bijection between orientations of chords and orientations of edges of $T$ in such a way that each chord crosses an edge of $T$ from the right to the left of the arrow on that edge. A good orientation of chords corresponds to an orientation of the tree containing no two edges oriented towards each other. Such an orientation is defined uniquely by its source vertex, i.e., the unique vertex having no in-arrows.\n\nTherefore, for each tree $T$ on $n+1$ vertices, there are exactly $n+1$ ways to orient it so that the source vertex is unique - one for each choice of the source. Thus, the answer is obtained in the same way as above."
] | $\binom{2n}{n}$ |
1,644 | Combinatorics | null | $\boxed{m n-\lfloor m / 2\rfloor}$ | [
"$m n-\\lfloor m / 2\\rfloor$"
] | false | null | Expression | null | Given positive integers $m$ and $n \geq m$, determine the largest number of dominoes $(1 \times 2$ or $2 \times 1$ rectangles) that can be placed on a rectangular board with $m$ rows and $2 n$ columns consisting of cells $(1 \times 1$ squares $)$ so that:
(i) each domino covers exactly two adjacent cells of the board;
(ii) no two dominoes overlap;
(iii) no two form a $2 \times 2$ square; and
(iv) the bottom row of the board is completely covered by $n$ dominoes. | [
"The required maximum is $m n-\\lfloor m / 2\\rfloor$ and is achieved by the brick-like vertically symmetric arrangement of blocks of $n$ and $n-1$ horizontal dominoes placed on alternate rows, so that the bottom row of the board is completely covered by $n$ dominoes.\n\n\n\nTo show that the number of dominoes in an arrangement satisfying the conditions in the statement does not exceed $m n-\\lfloor m / 2\\rfloor$, label the rows upwards $0,1, \\ldots, m-1$, and, for each $i$ in this range, draw a vertically symmetric block of $n-i$ fictitious horizontal dominoes in the $i$-th row (so the block on the $i$-th row leaves out $i$ cells on either side) - Figure 4 illustrates the case $m=n=6$. A fictitious domino is good if it is completely covered by a domino in the arrangement; otherwise, it is bad.\n\n\n\nIf the fictitious dominoes are all good, then the dominoes in the arrangement that cover no fictitious domino, if any, all lie in two triangular regions of side-length $m-1$ at the upper-left and upper-right corners of the board. Colour the cells of the board chess-like and notice that in each of the two triangular regions the number of black cells and the number of white cells differ by $\\lfloor m / 2\\rfloor$. Since each domino covers two cells of different colours, at least $\\lfloor m / 2\\rfloor$ cells are not covered in each of these regions, and the conclusion follows.\n\n\n\n<img_3888>\n\n\n\nFig. 4\n\n<img_3590>\n\n\n\nFig. 5\n\n\n\nTo deal with the remaining case where bad fictitious dominoes are present, we show that an arrangement satisfying the conditions in the statement can be transformed into another such with at least as many dominoes, but fewer bad fictitious dominoes. A finite number of such transformations eventually leads to an arrangement of at least as many dominoes all of whose fictitious dominoes are good, and the conclusion follows by the preceding.\n\n\n\nConsider the row of minimal rank containing bad fictitious dominoes - this is certainly not the bottom row - and let $D$ be one such. Let $\\ell$, respectively $r$, be the left, respectively right, cell of $D$ and notice that the cell below $\\ell$, respectively $r$, is the right, respectively left, cell of a domino $D_{1}$, respectively $D_{2}$, in the arrangement.\n\n\n\nIf $\\ell$ is covered by a domino $D_{\\ell}$ in the arrangement, since $D$ is bad and no two dominoes in the arrangement form a square, it follows that $D_{\\ell}$ is vertical. If $r$ were also covered by a domino $D_{r}$ in the arrangement, then $D_{r}$ would also be vertical, and would therefore form a square with $D_{\\ell}-$ a contradiction. Hence $r$ is not covered, and there is room for $D_{\\ell}$ to be placed so as to cover $D$, to obtain a new arrangement satisfying the conditions in the statement; the latter has as many dominoes as the former, but fewer bad fictitious dominoes. The case where $r$ is covered is dealt with similarly.\n\n\n\nFinally, if neither cell of $D$ is covered, addition of an extra domino to cover $D$ and, if necessary, removal of the domino above $D$ to avoid formation of a square, yields a new arrangement satisfying the conditions in the statement; the latter has at least as many dominoes as the former, but fewer bad fictitious dominoes. (Figure 5 illustrates the two cases.)",
"We present an alternative proof of the bound.\n\n\n\nLabel the rows upwards $0,1, \\ldots, m-1$, and the columns from the left to the right by $0,1, \\ldots, 2 n-1$; label each cell by the pair of its column's and row's numbers, so that $(1,0)$ is the second left cell in the bottom row. Colour the cells chess-like so that $(0,0)$ is white. For $0 \\leq i \\leq n-1$, we say that the $i$ th white diagonal is the set of cells of the form $(2 i+k, k)$, where $k$ ranges over all appropriate indices. Similarly, the ith black diagonal is the set of cells of the form $(2 i+1-k, k)$. (Notice that the white cells in the upper-left corner and the black cells in the upper-right corner are not covered by these diagonals.)\n\n\n\nClaim. Assume that $K$ lowest cells of some white diagonal are all covered by dominoes. Then all these $K$ dominoes face right or up from the diagonal. (In other words, the black cell of any such\n\n\n\n\n\n\n\ndomino is to the right or to the top of its white cell.) Similarly, if $K$ lowest cells of some black diagonal are covered by dominoes, then all these dominoes face left or up from the diagonal.\n\n\n\nProof. By symmetry, it suffices to prove the first statement. Assume that $K$ lowest cells of the $i$ th white diagonal is completely covered. We prove by induction on $k<K$ that the required claim holds for the domino covering $(2 i+k, k)$. The base case $k=0$ holds due to the problem condition. To establish the step, one observes that if $(2 i+k, k)$ is covered by a domino facing up of right, while $(2 i+k+1, k+1)$ is covered by a domino facing down or left, then these two dominoes form a square.\n\n\n\nWe turn to the solution. We will prove that there are at least $d=\\lfloor m / 2\\rfloor$ empty white cells. Since each domino covers exactly one white cell, the required bound follows.\n\n\n\nIf each of the first $d$ white diagonals contains an empty cell, the result is clear. Otherwise, let $i<d$ be the least index of a completely covered white diagonal. We say that the dominoes covering our diagonal are distinguished. After removing the distinguished dominoes, the board splits into two parts; the left part $L$ contains $i$ empty white cells on the previous diagonals. So, it suffices to prove that the right part $R$ contains at least $d-i$ empty white cells.\n\n\n\nLet $j$ be the number of distinguished dominoes facing up. Then at least $j-i$ of these dominoes cover some cells of (distinct) black diagonals (the relation $m \\leq n$ is used). Each such domino faces down from the corresponding black diagonal - so, by the Claim, each such black diagonal contains an empty cell in $R$. Thus, $R$ contains at least $j-i$ empty black cells.\n\n\n\nNow, let $w$ be the number of white cells in $R$. Then the number of black cells in $R$ is $w-d+j$, and at least $i-j$ of those are empty. Thus, the number of dominoes in $R$ is at most $(w-d+j)-(j-i)=w-(d-i)$, so $R$ contains at least $d-i$ empty white cells, as we wanted to show."
] | $m n-\lfloor m / 2\rfloor$ |
1,645 | Algebra | null | $\boxed{0}$ | [
"0"
] | false | null | Numerical | null | A cubic sequence is a sequence of integers given by $a_{n}=n^{3}+b n^{2}+c n+d$, where $b, c$ and $d$ are integer constants and $n$ ranges over all integers, including negative integers.
Determine the possible values of $a_{2015} \cdot a_{2016}$ for a cubic sequence satisfying the condition in part (a). | [
"The only possible value of $a_{2015} \\cdot a_{2016}$ is 0 . For simplicity, by performing a translation of the sequence (which may change the defining constants $b, c$ and $d$ ), we may instead concern ourselves with the values $a_{0}$ and $a_{1}$, rather than $a_{2015}$ and $a_{2016}$.\n\n\n\nSuppose now that we have a cubic sequence $a_{n}$ with $a_{0}=p^{2}$ and $a_{1}=q^{2}$ square numbers. We will show that $p=0$ or $q=0$. Consider the line $y=(q-p) x+p$ passing through $(0, p)$ and $(1, q)$; the latter are two points the line under consideration and the cubic $y^{2}=x^{3}+b x^{2}+c x+d$ share. Hence the two must share a third point whose $x$-coordinate is the third root of the polynomial $t^{3}+\\left(b-(q-p)^{2}\\right) t^{2}+(c-2(q-p) p) t+\\left(d-p^{2}\\right)$ (it may well happen that this third point coincide with one of the other two points the line and the cubic share).\n\n\n\nNotice that the sum of the three roots is $(q-p)^{2}-b$, so the third intersection has integral $x$-coordinate $X=(q-p)^{2}-b-1$. Its $y$-coordinate $Y=(q-p) X+p$ is also an integer, and hence $a_{X}=X^{3}+b X^{2}+c X+d=Y^{2}$ is a square. This contradicts our assumption on the sequence unless $X=0$ or $X=1$, i.e. unless $(q-p)^{2}=b+1$ or $(q-p)^{2}=b+2$.\n\n\n\n\n\n\n\nApplying the same argument to the line through $(0,-p)$ and $(1, q)$, we find that $(q+p)^{2}=b+1$ or $b+2$ also. Since $(q-p)^{2}$ and $(q+p)^{2}$ have the same parity, they must be equal, and hence $p q=0$, as desired.\n\n\n\nIt remains to show that such sequences exist, say when $p=0$. Consider the sequence $a_{n}=$ $n^{3}+\\left(q^{2}-2\\right) n^{2}+n$, chosen to satisfy $a_{0}=0$ and $a_{1}=q^{2}$. We will show that when $q=1$, the only square terms of the sequence are $a_{0}=0$ and $a_{1}=1$. Indeed, suppose that $a_{n}=n\\left(n^{2}-n+1\\right)$ is square. Since the second factor is positive, and the two factors are coprime, both must be squares; in particular, $n \\geq 0$. The case $n=0$ is clear, so let $n \\geq 1$. Finally, if $n>1$, then $(n-1)^{2}<n^{2}-n+1<n^{2}$, so $n^{2}-n+1$ is not a square. Consequently, $n=0$ or $n=1$, and the conclusion follows."
] | 0 |
1,659 | Algebra | null | $\boxed{f(x)=2 x}$ | [
"$f(x)=2 x$"
] | false | null | Expression | null | Find all functions $f: \mathbb{R}^{+} \rightarrow \mathbb{R}^{+}$ such that
$$
f(x+f(y))=f(x+y)+f(y)\tag{1}
$$
for all $x, y \in \mathbb{R}^{+}$. (Symbol $\mathbb{R}^{+}$denotes the set of all positive real numbers.) | [
"First we show that $f(y)>y$ for all $y \\in \\mathbb{R}^{+}$. Functional equation (1) yields $f(x+f(y))>f(x+y)$ and hence $f(y) \\neq y$ immediately. If $f(y)<y$ for some $y$, then setting $x=y-f(y)$ we get\n\n$$\nf(y)=f((y-f(y))+f(y))=f((y-f(y))+y)+f(y)>f(y),\n$$\n\ncontradiction. Therefore $f(y)>y$ for all $y \\in \\mathbb{R}^{+}$.\n\nFor $x \\in \\mathbb{R}^{+}$define $g(x)=f(x)-x$; then $f(x)=g(x)+x$ and, as we have seen, $g(x)>0$. Transforming (1) for function $g(x)$ and setting $t=x+y$,\n\n$$\n\\begin{aligned}\nf(t+g(y)) & =f(t)+f(y) \\\\\ng(t+g(y))+t+g(y) & =(g(t)+t)+(g(y)+y)\n\\end{aligned}\n$$\n\nand therefore\n\n$$\ng(t+g(y))=g(t)+y \\quad \\text { for all } t>y>0 \\tag{2}\n$$\n\nNext we prove that function $g(x)$ is injective. Suppose that $g\\left(y_{1}\\right)=g\\left(y_{2}\\right)$ for some numbers $y_{1}, y_{2} \\in \\mathbb{R}^{+}$. Then by $(2)$,\n\n$$\ng(t)+y_{1}=g\\left(t+g\\left(y_{1}\\right)\\right)=g\\left(t+g\\left(y_{2}\\right)\\right)=g(t)+y_{2}\n$$\n\nfor all $t>\\max \\left\\{y_{1}, y_{2}\\right\\}$. Hence, $g\\left(y_{1}\\right)=g\\left(y_{2}\\right)$ is possible only if $y_{1}=y_{2}$.\n\nNow let $u, v$ be arbitrary positive numbers and $t>u+v$. Applying (2) three times,\n\n$$\ng(t+g(u)+g(v))=g(t+g(u))+v=g(t)+u+v=g(t+g(u+v)) \\text {. }\n$$\n\nBy the injective property we conclude that $t+g(u)+g(v)=t+g(u+v)$, hence\n\n$$\ng(u)+g(v)=g(u+v)\\tag{3}\n$$\n\nSince function $g(v)$ is positive, equation (3) also shows that $g$ is an increasing function.\n\nFinally we prove that $g(x)=x$. Combining (2) and (3), we obtain\n\n$$\ng(t)+y=g(t+g(y))=g(t)+g(g(y))\n$$\n\nand hence\n\n$$\ng(g(y))=y\n$$\n\nSuppose that there exists an $x \\in \\mathbb{R}^{+}$such that $g(x) \\neq x$. By the monotonicity of $g$, if $x>g(x)$ then $g(x)>g(g(x))=x$. Similarly, if $x<g(x)$ then $g(x)<g(g(x))=x$. Both cases lead to contradiction, so there exists no such $x$.\n\nWe have proved that $g(x)=x$ and therefore $f(x)=g(x)+x=2 x$ for all $x \\in \\mathbb{R}^{+}$. This function indeed satisfies the functional equation (1).",
"We prove that $f(y)>y$ and introduce function $g(x)=f(x)-x>0$ in the same way as in Solution 1.\n\nFor arbitrary $t>y>0$, substitute $x=t-y$ into (1) to obtain\n\n$$\nf(t+g(y))=f(t)+f(y)\n$$\n\nwhich, by induction, implies\n\n$$\nf(t+n g(y))=f(t)+n f(y) \\quad \\text { for all } t>y>0, n \\in \\mathbb{N} \\tag{4}\n$$\n\nTake two arbitrary positive reals $y$ and $z$ and a third fixed number $t>\\max \\{y, z\\}$. For each positive integer $k$, let $\\ell_{k}=\\left\\lfloor k \\frac{g(y)}{g(z)}\\right\\rfloor$. Then $t+k g(y)-\\ell_{k} g(z) \\geq t>z$ and, applying (4) twice,\n\n$$\n\\begin{gathered}\nf\\left(t+k g(y)-\\ell_{k} g(z)\\right)+\\ell_{k} f(z)=f(t+k g(y))=f(t)+k f(y), \\\\\n0<\\frac{1}{k} f\\left(t+k g(y)-\\ell_{k} g(z)\\right)=\\frac{f(t)}{k}+f(y)-\\frac{\\ell_{k}}{k} f(z) .\n\\end{gathered}\n$$\n\nAs $k \\rightarrow \\infty$ we get\n\n$$\n0 \\leq \\lim _{k \\rightarrow \\infty}\\left(\\frac{f(t)}{k}+f(y)-\\frac{\\ell_{k}}{k} f(z)\\right)=f(y)-\\frac{g(y)}{g(z)} f(z)=f(y)-\\frac{f(y)-y}{f(z)-z} f(z)\n$$\n\nand therefore\n\n$$\n\\frac{f(y)}{y} \\leq \\frac{f(z)}{z}\n$$\n\nExchanging variables $y$ and $z$, we obtain the reverse inequality. Hence, $\\frac{f(y)}{y}=\\frac{f(z)}{z}$ for arbitrary $y$ and $z$; so function $\\frac{f(x)}{x}$ is constant, $f(x)=c x$.\n\nSubstituting back into (1), we find that $f(x)=c x$ is a solution if and only if $c=2$. So the only solution for the problem is $f(x)=2 x$."
] | $f(x)=2 x$ |
1,662 | Combinatorics | null | $\boxed{3 n}$ | [
"$3 n$"
] | false | null | Expression | null | Let $n>1$ be an integer. In the space, consider the set
$$
S=\{(x, y, z) \mid x, y, z \in\{0,1, \ldots, n\}, x+y+z>0\}
$$
Find the smallest number of planes that jointly contain all $(n+1)^{3}-1$ points of $S$ but none of them passes through the origin. | [
"It is easy to find $3 n$ such planes. For example, planes $x=i, y=i$ or $z=i$ $(i=1,2, \\ldots, n)$ cover the set $S$ but none of them contains the origin. Another such collection consists of all planes $x+y+z=k$ for $k=1,2, \\ldots, 3 n$.\n\nWe show that $3 n$ is the smallest possible number.\n\nLemma 1. Consider a nonzero polynomial $P\\left(x_{1}, \\ldots, x_{k}\\right)$ in $k$ variables. Suppose that $P$ vanishes at all points $\\left(x_{1}, \\ldots, x_{k}\\right)$ such that $x_{1}, \\ldots, x_{k} \\in\\{0,1, \\ldots, n\\}$ and $x_{1}+\\cdots+x_{k}>0$, while $P(0,0, \\ldots, 0) \\neq 0$. Then $\\operatorname{deg} P \\geq k n$.\n\nProof. We use induction on $k$. The base case $k=0$ is clear since $P \\neq 0$. Denote for clarity $y=x_{k}$.\n\nLet $R\\left(x_{1}, \\ldots, x_{k-1}, y\\right)$ be the residue of $P$ modulo $Q(y)=y(y-1) \\ldots(y-n)$. Polynomial $Q(y)$ vanishes at each $y=0,1, \\ldots, n$, hence $P\\left(x_{1}, \\ldots, x_{k-1}, y\\right)=R\\left(x_{1}, \\ldots, x_{k-1}, y\\right)$ for all $x_{1}, \\ldots, x_{k-1}, y \\in\\{0,1, \\ldots, n\\}$. Therefore, $R$ also satisfies the condition of the Lemma; moreover, $\\operatorname{deg}_{y} R \\leq n$. Clearly, $\\operatorname{deg} R \\leq \\operatorname{deg} P$, so it suffices to prove that $\\operatorname{deg} R \\geq n k$.\n\nNow, expand polynomial $R$ in the powers of $y$ :\n$$\nR\\left(x_{1}, \\ldots, x_{k-1}, y\\right)=R_{n}\\left(x_{1}, \\ldots, x_{k-1}\\right) y^{n}+R_{n-1}\\left(x_{1}, \\ldots, x_{k-1}\\right) y^{n-1}+\\cdots+R_{0}\\left(x_{1}, \\ldots, x_{k-1}\\right)\n$$\nWe show that polynomial $R_{n}\\left(x_{1}, \\ldots, x_{k-1}\\right)$ satisfies the condition of the induction hypothesis.\n\nConsider the polynomial $T(y)=R(0, \\ldots, 0, y)$ of degree $\\leq n$. This polynomial has $n$ roots $y=1, \\ldots, n$; on the other hand, $T(y) \\not \\equiv 0$ since $T(0) \\neq 0$. Hence $\\operatorname{deg} T=n$, and its leading coefficient is $R_{n}(0,0, \\ldots, 0) \\neq 0$. In particular, in the case $k=1$ we obtain that coefficient $R_{n}$ is nonzero.\n\nSimilarly, take any numbers $a_{1}, \\ldots, a_{k-1} \\in\\{0,1, \\ldots, n\\}$ with $a_{1}+\\cdots+a_{k-1}>0$. Substituting $x_{i}=a_{i}$ into $R\\left(x_{1}, \\ldots, x_{k-1}, y\\right)$, we get a polynomial in $y$ which vanishes at all points $y=0, \\ldots, n$ and has degree $\\leq n$. Therefore, this polynomial is null, hence $R_{i}\\left(a_{1}, \\ldots, a_{k-1}\\right)=0$ for all $i=0,1, \\ldots, n$. In particular, $R_{n}\\left(a_{1}, \\ldots, a_{k-1}\\right)=0$.\n\nThus, the polynomial $R_{n}\\left(x_{1}, \\ldots, x_{k-1}\\right)$ satisfies the condition of the induction hypothesis. So, we have $\\operatorname{deg} R_{n} \\geq(k-1) n$ and $\\operatorname{deg} P \\geq \\operatorname{deg} R \\geq \\operatorname{deg} R_{n}+n \\geq k n$.\n\nNow we can finish the solution. Suppose that there are $N$ planes covering all the points of $S$ but not containing the origin. Let their equations be $a_{i} x+b_{i} y+c_{i} z+d_{i}=0$. Consider the polynomial\n$$\nP(x, y, z)=\\prod_{i=1}^{N}\\left(a_{i} x+b_{i} y+c_{i} z+d_{i}\\right)\n$$\nIt has total degree $N$. This polynomial has the property that $P\\left(x_{0}, y_{0}, z_{0}\\right)=0$ for any $\\left(x_{0}, y_{0}, z_{0}\\right) \\in S$, while $P(0,0,0) \\neq 0$. Hence by Lemma 1 we get $N=\\operatorname{deg} P \\geq 3 n$, as desired.",
"We present a different proof of the main Lemma 1. Here we confine ourselves to the case $k=3$, which is applied in the solution, and denote the variables by $x, y$ and $z$. (The same proof works for the general statement as well.)\n\nThe following fact is known with various proofs; we provide one possible proof for the completeness.\n\nLemma 2. For arbitrary integers $0 \\leq m<n$ and for an arbitrary polynomial $P(x)$ of degree $m$,\n$$\n\\sum_{k=0}^{n}(-1)^{k}\\left(\\begin{array}{l}\nn \\\\\nk\n\\end{array}\\right) P(k)=0\\tag{1}\n$$\nProof. We use an induction on $n$. If $n=1$, then $P(x)$ is a constant polynomial, hence $P(1)-P(0)=0$, and the base is proved.\n\nFor the induction step, define $P_{1}(x)=P(x+1)-P(x)$. Then clearly $\\operatorname{deg} P_{1}=\\operatorname{deg} P-1=$ $m-1<n-1$, hence by the induction hypothesis we get\n$$\n\\begin{aligned}\n0 & =-\\sum_{k=0}^{n-1}(-1)^{k}\\left(\\begin{array}{c}\nn-1 \\\\\nk\n\\end{array}\\right) P_{1}(k)=\\sum_{k=0}^{n-1}(-1)^{k}\\left(\\begin{array}{c}\nn-1 \\\\\nk\n\\end{array}\\right)(P(k)-P(k+1)) \\\\\n& =\\sum_{k=0}^{n-1}(-1)^{k}\\left(\\begin{array}{c}\nn-1 \\\\\nk\n\\end{array}\\right) P(k)-\\sum_{k=0}^{n-1}(-1)^{k}\\left(\\begin{array}{c}\nn-1 \\\\\nk\n\\end{array}\\right) P(k+1) \\\\\n& =\\sum_{k=0}^{n-1}(-1)^{k}\\left(\\begin{array}{c}\nn-1 \\\\\nk\n\\end{array}\\right) P(k)+\\sum_{k=1}^{n}(-1)^{k}\\left(\\begin{array}{c}\nn-1 \\\\\nk-1\n\\end{array}\\right) P(k) \\\\\n& =P(0)+\\sum_{k=1}^{n-1}(-1)^{k}\\left(\\left(\\begin{array}{c}\nn-1 \\\\\nk-1\n\\end{array}\\right)+\\left(\\begin{array}{c}\nn-1 \\\\\nk\n\\end{array}\\right)\\right) P(k)+(-1)^{n} P(n)=\\sum_{k=0}^{n}(-1)^{k}\\left(\\begin{array}{c}\nn \\\\\nk\n\\end{array}\\right) P(k) .\n\\end{aligned}\n$$\nNow return to the proof of Lemma 1. Suppose, to the contrary, that $\\operatorname{deg} P=N<3 n$. Consider the sum\n$$\n\\Sigma=\\sum_{i=0}^{n} \\sum_{j=0}^{n} \\sum_{k=0}^{n}(-1)^{i+j+k}\\left(\\begin{array}{c}\nn \\\\\ni\n\\end{array}\\right)\\left(\\begin{array}{l}\nn \\\\\nj\n\\end{array}\\right)\\left(\\begin{array}{l}\nn \\\\\nk\n\\end{array}\\right) P(i, j, k)\n$$\nThe only nonzero term in this sum is $P(0,0,0)$ and its coefficient is $\\left(\\begin{array}{l}n \\\\ 0\\end{array}\\right)^{3}=1$; therefore $\\Sigma=P(0,0,0) \\neq 0$.\n\nOn the other hand, if $P(x, y, z)=\\sum_{\\alpha+\\beta+\\gamma \\leq N} p_{\\alpha, \\beta, \\gamma} x^{\\alpha} y^{\\beta} z^{\\gamma}$, then\n$$\n\\begin{aligned}\n\\Sigma & =\\sum_{i=0}^{n} \\sum_{j=0}^{n} \\sum_{k=0}^{n}(-1)^{i+j+k}\\left(\\begin{array}{c}\nn \\\\\ni\n\\end{array}\\right)\\left(\\begin{array}{l}\nn \\\\\nj\n\\end{array}\\right)\\left(\\begin{array}{l}\nn \\\\\nk\n\\end{array}\\right) \\sum_{\\alpha+\\beta+\\gamma \\leq N} p_{\\alpha, \\beta, \\gamma} i^{\\alpha} j^{\\beta} k^{\\gamma} \\\\\n& =\\sum_{\\alpha+\\beta+\\gamma \\leq N} p_{\\alpha, \\beta, \\gamma}\\left(\\sum_{i=0}^{n}(-1)^{i}\\left(\\begin{array}{c}\nn \\\\\ni\n\\end{array}\\right) i^{\\alpha}\\right)\\left(\\sum_{j=0}^{n}(-1)^{j}\\left(\\begin{array}{c}\nn \\\\\nj\n\\end{array}\\right) j^{\\beta}\\right)\\left(\\sum_{k=0}^{n}(-1)^{k}\\left(\\begin{array}{l}\nn \\\\\nk\n\\end{array}\\right) k^{\\gamma}\\right) .\n\\end{aligned}\n$$\nConsider an arbitrary term in this sum. We claim that it is zero. Since $N<3 n$, one of three inequalities $\\alpha<n, \\beta<n$ or $\\gamma<n$ is valid. For the convenience, suppose that $\\alpha<n$. Applying Lemma 2 to polynomial $x^{\\alpha}$, we get $\\sum_{i=0}^{n}(-1)^{i}\\left(\\begin{array}{c}n \\\\ i\\end{array}\\right) i^{\\alpha}=0$, hence the term is zero as required.\n\nThis yields $\\Sigma=0$ which is a contradiction. Therefore, $\\operatorname{deg} P \\geq 3 n$."
] | $3 n$ |
1,664 | Combinatorics | null | $\boxed{69$,$84}$ | [
"$69$,$84$"
] | true | null | Numerical | null | Find all positive integers $n$, for which the numbers in the set $S=\{1,2, \ldots, n\}$ can be colored red and blue, with the following condition being satisfied: the set $S \times S \times S$ contains exactly 2007 ordered triples $(x, y, z)$ such that (i) $x, y, z$ are of the same color and (ii) $x+y+z$ is divisible by $n$. | [
"Suppose that the numbers $1,2, \\ldots, n$ are colored red and blue. Denote by $R$ and $B$ the sets of red and blue numbers, respectively; let $|R|=r$ and $|B|=b=n-r$. Call a triple $(x, y, z) \\in S \\times S \\times S$ monochromatic if $x, y, z$ have the same color, and bichromatic otherwise. Call a triple $(x, y, z)$ divisible if $x+y+z$ is divisible by $n$. We claim that there are exactly $r^{2}-r b+b^{2}$ divisible monochromatic triples.\n\nFor any pair $(x, y) \\in S \\times S$ there exists a unique $z_{x, y} \\in S$ such that the triple $\\left(x, y, z_{x, y}\\right)$ is divisible; so there are exactly $n^{2}$ divisible triples. Furthermore, if a divisible triple $(x, y, z)$ is bichromatic, then among $x, y, z$ there are either one blue and two red numbers, or vice versa. In both cases, exactly one of the pairs $(x, y),(y, z)$ and $(z, x)$ belongs to the set $R \\times B$. Assign such pair to the triple $(x, y, z)$.\n\nConversely, consider any pair $(x, y) \\in R \\times B$, and denote $z=z_{x, y}$. Since $x \\neq y$, the triples $(x, y, z),(y, z, x)$ and $(z, x, y)$ are distinct, and $(x, y)$ is assigned to each of them. On the other hand, if $(x, y)$ is assigned to some triple, then this triple is clearly one of those mentioned above. So each pair in $R \\times B$ is assigned exactly three times.\n\nThus, the number of bichromatic divisible triples is three times the number of elements in $R \\times B$, and the number of monochromatic ones is $n^{2}-3 r b=(r+b)^{2}-3 r b=r^{2}-r b+b^{2}$, as claimed.\n\nSo, to find all values of $n$ for which the desired coloring is possible, we have to find all $n$, for which there exists a decomposition $n=r+b$ with $r^{2}-r b+b^{2}=2007$. Therefore, $9 \\mid r^{2}-r b+b^{2}=(r+b)^{2}-3 r b$. From this it consequently follows that $3|r+b, 3| r b$, and then $3|r, 3| b$. Set $r=3 s, b=3 c$. We can assume that $s \\geq c$. We have $s^{2}-s c+c^{2}=223$.\n\nFurthermore,\n$$\n892=4\\left(s^{2}-s c+c^{2}\\right)=(2 c-s)^{2}+3 s^{2} \\geq 3 s^{2} \\geq 3 s^{2}-3 c(s-c)=3\\left(s^{2}-s c+c^{2}\\right)=669\n$$\nso $297 \\geq s^{2} \\geq 223$ and $17 \\geq s \\geq 15$. If $s=15$ then\n$$\nc(15-c)=c(s-c)=s^{2}-\\left(s^{2}-s c+c^{2}\\right)=15^{2}-223=2\n$$\nwhich is impossible for an integer $c$. In a similar way, if $s=16$ then $c(16-c)=33$, which is also impossible. Finally, if $s=17$ then $c(17-c)=66$, and the solutions are $c=6$ and $c=11$. Hence, $(r, b)=(51,18)$ or $(r, b)=(51,33)$, and the possible values of $n$ are $n=51+18=69$ and $n=51+33=84$."
] | $69$,$84$ |
1,675 | Geometry | null | $\boxed{k=1}$ | [
"$k=1$"
] | false | null | Numerical | null | Determine the smallest positive real number $k$ with the following property.
Let $A B C D$ be a convex quadrilateral, and let points $A_{1}, B_{1}, C_{1}$ and $D_{1}$ lie on sides $A B, B C$, $C D$ and $D A$, respectively. Consider the areas of triangles $A A_{1} D_{1}, B B_{1} A_{1}, C C_{1} B_{1}$, and $D D_{1} C_{1}$; let $S$ be the sum of the two smallest ones, and let $S_{1}$ be the area of quadrilateral $A_{1} B_{1} C_{1} D_{1}$. Then we always have $k S_{1} \geq S$. | [
"Throughout the solution, triangles $A A_{1} D_{1}, B B_{1} A_{1}, C C_{1} B_{1}$, and $D D_{1} C_{1}$ will be referred to as border triangles. We will denote by $[\\mathcal{R}]$ the area of a region $\\mathcal{R}$.\n\nFirst, we show that $k \\geq 1$. Consider a triangle $A B C$ with unit area; let $A_{1}, B_{1}, K$ be the midpoints of its sides $A B, B C, A C$, respectively. Choose a point $D$ on the extension of $B K$, close to $K$. Take points $C_{1}$ and $D_{1}$ on sides $C D$ and $D A$ close to $D$ (see Figure 1). We have $\\left[B B_{1} A_{1}\\right]=\\frac{1}{4}$. Moreover, as $C_{1}, D_{1}, D \\rightarrow K$, we get $\\left[A_{1} B_{1} C_{1} D_{1}\\right] \\rightarrow\\left[A_{1} B_{1} K\\right]=\\frac{1}{4}$, $\\left[A A_{1} D_{1}\\right] \\rightarrow\\left[A A_{1} K\\right]=\\frac{1}{4},\\left[C C_{1} B_{1}\\right] \\rightarrow\\left[C K B_{1}\\right]=\\frac{1}{4}$ and $\\left[D D_{1} C_{1}\\right] \\rightarrow 0$. Hence, the sum of the two smallest areas of border triangles tends to $\\frac{1}{4}$, as well as $\\left[A_{1} B_{1} C_{1} D_{1}\\right]$; therefore, their ratio tends to 1 , and $k \\geq 1$.\n\nWe are left to prove that $k=1$ satisfies the desired property.\n\n<img_3730>\n\nFigure 1\n\n<img_3171>\n\nFigure 2\n\n<img_4006>\n\nFigure 3\n\nLemma. Let points $A_{1}, B_{1}, C_{1}$ lie respectively on sides $B C, C A, A B$ of a triangle $A B C$. Then $\\left[A_{1} B_{1} C_{1}\\right] \\geq \\min \\left\\{\\left[A C_{1} B_{1}\\right],\\left[B A_{1} C_{1}\\right],\\left[C B_{1} A_{1}\\right]\\right\\}$.\n\nProof. Let $A^{\\prime}, B^{\\prime}, C^{\\prime}$ be the midpoints of sides $B C, C A$ and $A B$, respectively.\n\nSuppose that two of points $A_{1}, B_{1}, C_{1}$ lie in one of triangles $A C^{\\prime} B^{\\prime}, B A^{\\prime} C^{\\prime}$ and $C B^{\\prime} A^{\\prime}$ (for convenience, let points $B_{1}$ and $C_{1}$ lie in triangle $A C^{\\prime} B^{\\prime}$; see Figure 2). Let segments $B_{1} C_{1}$ and $A A_{1}$ intersect at point $X$. Then $X$ also lies in triangle $A C^{\\prime} B^{\\prime}$. Hence $A_{1} X \\geq A X$, and we have\n$$\n\\frac{\\left[A_{1} B_{1} C_{1}\\right]}{\\left[A C_{1} B_{1}\\right]}=\\frac{\\frac{1}{2} A_{1} X \\cdot B_{1} C_{1} \\cdot \\sin \\angle A_{1} X C_{1}}{\\frac{1}{2} A X \\cdot B_{1} C_{1} \\cdot \\sin \\angle A X B_{1}}=\\frac{A_{1} X}{A X} \\geq 1\n$$\nas required.\n\nOtherwise, each one of triangles $A C^{\\prime} B^{\\prime}, B A^{\\prime} C^{\\prime}, C B^{\\prime} A^{\\prime}$ contains exactly one of points $A_{1}$, $B_{1}, C_{1}$, and we can assume that $B A_{1}<B A^{\\prime}, C B_{1}<C B^{\\prime}, A C_{1}<A C^{\\prime}$ (see Figure 3). Then lines $B_{1} A_{1}$ and $A B$ intersect at a point $Y$ on the extension of $A B$ beyond point $B$, hence $\\frac{\\left[A_{1} B_{1} C_{1}\\right]}{\\left[A_{1} B_{1} C^{\\prime}\\right]}=\\frac{C_{1} Y}{C^{\\prime} Y}>1$; also, lines $A_{1} C^{\\prime}$ and $C A$ intersect at a point $Z$ on the extension of $C A$ beyond point $A$, hence $\\frac{\\left[A_{1} B_{1} C^{\\prime}\\right]}{\\left[A_{1} B^{\\prime} C^{\\prime}\\right]}=\\frac{B_{1} Z}{B^{\\prime} Z}>1$. Finally, since $A_{1} A^{\\prime} \\| B^{\\prime} C^{\\prime}$, we have $\\left[A_{1} B_{1} C_{1}\\right]>\\left[A_{1} B_{1} C^{\\prime}\\right]>\\left[A_{1} B^{\\prime} C^{\\prime}\\right]=\\left[A^{\\prime} B^{\\prime} C^{\\prime}\\right]=\\frac{1}{4}[A B C]$.\n\n\n\nNow, from $\\left[A_{1} B_{1} C_{1}\\right]+\\left[A C_{1} B_{1}\\right]+\\left[B A_{1} C_{1}\\right]+\\left[C B_{1} A_{1}\\right]=[A B C]$ we obtain that one of the remaining triangles $A C_{1} B_{1}, B A_{1} C_{1}, C B_{1} A_{1}$ has an area less than $\\frac{1}{4}[A B C]$, so it is less than $\\left[A_{1} B_{1} C_{1}\\right]$.\n\nNow we return to the problem. We say that triangle $A_{1} B_{1} C_{1}$ is small if $\\left[A_{1} B_{1} C_{1}\\right]$ is less than each of $\\left[B B_{1} A_{1}\\right]$ and $\\left[C C_{1} B_{1}\\right]$; otherwise this triangle is big (the similar notion is introduced for triangles $B_{1} C_{1} D_{1}, C_{1} D_{1} A_{1}, D_{1} A_{1} B_{1}$ ). If both triangles $A_{1} B_{1} C_{1}$ and $C_{1} D_{1} A_{1}$ are big, then $\\left[A_{1} B_{1} C_{1}\\right]$ is not less than the area of some border triangle, and $\\left[C_{1} D_{1} A_{1}\\right]$ is not less than the area of another one; hence, $S_{1}=\\left[A_{1} B_{1} C_{1}\\right]+\\left[C_{1} D_{1} A_{1}\\right] \\geq S$. The same is valid for the pair of $B_{1} C_{1} D_{1}$ and $D_{1} A_{1} B_{1}$. So it is sufficient to prove that in one of these pairs both triangles are big.\n\nSuppose the contrary. Then there is a small triangle in each pair. Without loss of generality, assume that triangles $A_{1} B_{1} C_{1}$ and $D_{1} A_{1} B_{1}$ are small. We can assume also that $\\left[A_{1} B_{1} C_{1}\\right] \\leq$ $\\left[D_{1} A_{1} B_{1}\\right]$. Note that in this case ray $D_{1} C_{1}$ intersects line $B C$.\n\nConsider two cases.\n\n<img_3464>\n\nFigure 4\n\n<img_3580>\n\nFigure 5\n\nCase 1. Ray $C_{1} D_{1}$ intersects line $A B$ at some point $K$. Let ray $D_{1} C_{1}$ intersect line $B C$ at point $L$ (see Figure 4). Then we have $\\left[A_{1} B_{1} C_{1}\\right]<\\left[C C_{1} B_{1}\\right]<\\left[L C_{1} B_{1}\\right],\\left[A_{1} B_{1} C_{1}\\right]<\\left[B B_{1} A_{1}\\right]$ (both - since $\\left[A_{1} B_{1} C_{1}\\right]$ is small), and $\\left[A_{1} B_{1} C_{1}\\right] \\leq\\left[D_{1} A_{1} B_{1}\\right]<\\left[A A_{1} D_{1}\\right]<\\left[K A_{1} D_{1}\\right]<\\left[K A_{1} C_{1}\\right]$ (since triangle $D_{1} A_{1} B_{1}$ is small). This contradicts the Lemma, applied for triangle $A_{1} B_{1} C_{1}$ inside $L K B$.\n\nCase 2. Ray $C_{1} D_{1}$ does not intersect $A B$. Then choose a \"sufficiently far\" point $K$ on ray $B A$ such that $\\left[K A_{1} C_{1}\\right]>\\left[A_{1} B_{1} C_{1}\\right]$, and that ray $K C_{1}$ intersects line $B C$ at some point $L$ (see Figure 5). Since ray $C_{1} D_{1}$ does not intersect line $A B$, the points $A$ and $D_{1}$ are on different sides of $K L$; then $A$ and $D$ are also on different sides, and $C$ is on the same side as $A$ and $B$. Then analogously we have $\\left[A_{1} B_{1} C_{1}\\right]<\\left[C C_{1} B_{1}\\right]<\\left[L C_{1} B_{1}\\right]$ and $\\left[A_{1} B_{1} C_{1}\\right]<\\left[B B_{1} A_{1}\\right]$ since triangle $A_{1} B_{1} C_{1}$ is small. This (together with $\\left[A_{1} B_{1} C_{1}\\right]<\\left[K A_{1} C_{1}\\right]$ ) contradicts the Lemma again."
] | $k=1$ |
1,678 | Number Theory | null | $\boxed{(2,4)}$ | [
"$(2,4)$"
] | false | null | Tuple | null | Find all pairs $(k, n)$ of positive integers for which $7^{k}-3^{n}$ divides $k^{4}+n^{2}$. | [
"Suppose that a pair $(k, n)$ satisfies the condition of the problem. Since $7^{k}-3^{n}$ is even, $k^{4}+n^{2}$ is also even, hence $k$ and $n$ have the same parity. If $k$ and $n$ are odd, then $k^{4}+n^{2} \\equiv 1+1=2(\\bmod 4)$, while $7^{k}-3^{n} \\equiv 7-3 \\equiv 0(\\bmod 4)$, so $k^{4}+n^{2}$ cannot be divisible by $7^{k}-3^{n}$. Hence, both $k$ and $n$ must be even.\n\nWrite $k=2 a, n=2 b$. Then $7^{k}-3^{n}=7^{2 a}-3^{2 b}=\\frac{7^{a}-3^{b}}{2} \\cdot 2\\left(7^{a}+3^{b}\\right)$, and both factors are integers. So $2\\left(7^{a}+3^{b}\\right) \\mid 7^{k}-3^{n}$ and $7^{k}-3^{n} \\mid k^{4}+n^{2}=2\\left(8 a^{4}+2 b^{2}\\right)$, hence\n$$\n7^{a}+3^{b} \\leq 8 a^{4}+2 b^{2}\n$$\nWe prove by induction that $8 a^{4}<7^{a}$ for $a \\geq 4,2 b^{2}<3^{b}$ for $b \\geq 1$ and $2 b^{2}+9 \\leq 3^{b}$ for $b \\geq 3$. In the initial cases $a=4, b=1, b=2$ and $b=3$ we have $8 \\cdot 4^{4}=2048<7^{4}=2401,2<3$, $2 \\cdot 2^{2}=8<3^{2}=9$ and $2 \\cdot 3^{2}+9=3^{3}=27$, respectively.\n\nIf $8 a^{4}<7^{a}(a \\geq 4)$ and $2 b^{2}+9 \\leq 3^{b}(b \\geq 3)$, then\n$$\n\\begin{aligned}\n8(a+1)^{4} & =8 a^{4}\\left(\\frac{a+1}{a}\\right)^{4}<7^{a}\\left(\\frac{5}{4}\\right)^{4}=7^{a} \\frac{625}{256}<7^{a+1} \\quad \\text { and } \\\\\n2(b+1)^{2}+9 & <\\left(2 b^{2}+9\\right)\\left(\\frac{b+1}{b}\\right)^{2} \\leq 3^{b}\\left(\\frac{4}{3}\\right)^{2}=3^{b} \\frac{16}{9}<3^{b+1},\n\\end{aligned}\n$$\nas desired.\n\nFor $a \\geq 4$ we obtain $7^{a}+3^{b}>8 a^{4}+2 b^{2}$ and inequality (1) cannot hold. Hence $a \\leq 3$, and three cases are possible.\n\nCase 1: $a=1$. Then $k=2$ and $8+2 b^{2} \\geq 7+3^{b}$, thus $2 b^{2}+1 \\geq 3^{b}$. This is possible only if $b \\leq 2$. If $b=1$ then $n=2$ and $\\frac{k^{4}+n^{2}}{7^{k}-3^{n}}=\\frac{2^{4}+2^{2}}{7^{2}-3^{2}}=\\frac{1}{2}$, which is not an integer. If $b=2$ then $n=4$ and $\\frac{k^{4}+n^{2}}{7^{k}-3^{n}}=\\frac{2^{4}+4^{2}}{7^{2}-3^{4}}=-1$, so $(k, n)=(2,4)$ is a solution.\n\nCase 2: $a=2$. Then $k=4$ and $k^{4}+n^{2}=256+4 b^{2} \\geq\\left|7^{4}-3^{n}\\right|=\\left|49-3^{b}\\right| \\cdot\\left(49+3^{b}\\right)$. The smallest value of the first factor is 22 , attained at $b=3$, so $128+2 b^{2} \\geq 11\\left(49+3^{b}\\right)$, which is impossible since $3^{b}>2 b^{2}$.\n\nCase 3: $a=3$. Then $k=6$ and $k^{4}+n^{2}=1296+4 b^{2} \\geq\\left|7^{6}-3^{n}\\right|=\\left|343-3^{b}\\right| \\cdot\\left(343+3^{b}\\right)$. Analogously, $\\left|343-3^{b}\\right| \\geq 100$ and we have $324+b^{2} \\geq 25\\left(343+3^{b}\\right)$, which is impossible again.\n\nWe find that there exists a unique solution $(k, n)=(2,4)$."
] | $(2,4)$ |
1,681 | Number Theory | null | $\boxed{f(n)=n}$ | [
"$f(n)=n$"
] | false | null | Expression | null | Find all surjective functions $f: \mathbb{N} \rightarrow \mathbb{N}$ such that for every $m, n \in \mathbb{N}$ and every prime $p$, the number $f(m+n)$ is divisible by $p$ if and only if $f(m)+f(n)$ is divisible by $p$.
( $\mathbb{N}$ is the set of all positive integers.) | [
"Suppose that function $f: \\mathbb{N} \\rightarrow \\mathbb{N}$ satisfies the problem conditions.\n\nLemma. For any prime $p$ and any $x, y \\in \\mathbb{N}$, we have $x \\equiv y(\\bmod p)$ if and only if $f(x) \\equiv f(y)$ $(\\bmod p)$. Moreover, $p \\mid f(x)$ if and only if $p \\mid x$.\n\nProof. Consider an arbitrary prime $p$. Since $f$ is surjective, there exists some $x \\in \\mathbb{N}$ such that $p \\mid f(x)$. Let\n$$\nd=\\min \\{x \\in \\mathbb{N}: p \\mid f(x)\\}\n$$\nBy induction on $k$, we obtain that $p \\mid f(k d)$ for all $k \\in \\mathbb{N}$. The base is true since $p \\mid f(d)$. Moreover, if $p \\mid f(k d)$ and $p \\mid f(d)$ then, by the problem condition, $p \\mid f(k d+d)=f((k+1) d)$ as required.\n\nSuppose that there exists an $x \\in \\mathbb{N}$ such that $d \\not x$ but $p \\mid f(x)$. Let\n$$\ny=\\min \\{x \\in \\mathbb{N}: d \\nmid x, p \\mid f(x)\\} .\n$$\nBy the choice of $d$, we have $y>d$, and $y-d$ is a positive integer not divisible by $d$. Then $p \\nmid f(y-d)$, while $p \\mid f(d)$ and $p \\mid f(d+(y-d))=f(y)$. This contradicts the problem condition. Hence, there is no such $x$, and\n$$\np|f(x) \\Longleftrightarrow d| x .\\tag{1}\n$$\nTake arbitrary $x, y \\in \\mathbb{N}$ such that $x \\equiv y(\\bmod d)$. We have $p \\mid f(x+(2 x d-x))=f(2 x d)$; moreover, since $d \\mid 2 x d+(y-x)=y+(2 x d-x)$, we get $p \\mid f(y+(2 x d-x))$. Then by the problem condition $p|f(x)+f(2 x d-x), p| f(y)+f(2 x d-x)$, and hence $f(x) \\equiv-f(2 x d-x) \\equiv f(y)$ $(\\bmod p)$.\n\nOn the other hand, assume that $f(x) \\equiv f(y)(\\bmod p)$. Again we have $p \\mid f(x)+f(2 x d-x)$ which by our assumption implies that $p \\mid f(x)+f(2 x d-x)+(f(y)-f(x))=f(y)+f(2 x d-x)$. Hence by the problem condition $p \\mid f(y+(2 x d-x))$. Using (1) we get $0 \\equiv y+(2 x d-x) \\equiv y-x$ $(\\bmod d)$.\n\nThus, we have proved that\n$$\nx \\equiv y \\quad(\\bmod d) \\Longleftrightarrow f(x) \\equiv f(y) \\quad(\\bmod p)\\tag{2}\n$$\nWe are left to show that $p=d$ : in this case (1) and (2) provide the desired statements.\n\nThe numbers $1,2, \\ldots, d$ have distinct residues modulo $d$. By (2), numbers $f(1), f(2), \\ldots$, $f(d)$ have distinct residues modulo $p$; hence there are at least $d$ distinct residues, and $p \\geq d$. On the other hand, by the surjectivity of $f$, there exist $x_{1}, \\ldots, x_{p} \\in \\mathbb{N}$ such that $f\\left(x_{i}\\right)=i$ for any $i=1,2, \\ldots, p$. By (2), all these $x_{i}$ 's have distinct residues modulo $d$. For the same reasons, $d \\geq p$. Hence, $d=p$.\n\nNow we prove that $f(n)=n$ by induction on $n$. If $n=1$ then, by the Lemma, $p \\nmid f(1)$ for any prime $p$, so $f(1)=1$, and the base is established. Suppose that $n>1$ and denote $k=f(n)$. Note that there exists a prime $q \\mid n$, so by the Lemma $q \\mid k$ and $k>1$.\n\nIf $k>n$ then $k-n+1>1$, and there exists a prime $p \\mid k-n+1$; we have $k \\equiv n-1$ $(\\bmod p)$. By the induction hypothesis we have $f(n-1)=n-1 \\equiv k=f(n)(\\bmod p)$. Now, by the Lemma we obtain $n-1 \\equiv n(\\bmod p)$ which cannot be true.\n\n\n\nAnalogously, if $k<n$, then $f(k-1)=k-1$ by induction hypothesis. Moreover, $n-k+1>1$, so there exists a prime $p \\mid n-k+1$ and $n \\equiv k-1(\\bmod p)$. By the Lemma again, $k=f(n) \\equiv$ $f(k-1)=k-1(\\bmod p)$, which is also false. The only remaining case is $k=n$, so $f(n)=n$.\n\nFinally, the function $f(n)=n$ obviously satisfies the condition."
] | $f(n)=n$ |
1,687 | Algebra | null | $\boxed{f(n)=n$, $g(n)=1}$ | [
"$f(n)=n$, $g(n)=1$"
] | false | null | Expression | null | Determine all pairs $(f, g)$ of functions from the set of positive integers to itself that satisfy
$$
f^{g(n)+1}(n)+g^{f(n)}(n)=f(n+1)-g(n+1)+1
$$
for every positive integer $n$. Here, $f^{k}(n)$ means $\underbrace{f(f(\ldots f}_{k}(n) \ldots))$. | [
"The given relation implies\n\n$$\nf\\left(f^{g(n)}(n)\\right)<f(n+1) \\quad \\text { for all } n\n\\tag{1}\n$$\n\nwhich will turn out to be sufficient to determine $f$.\n\nLet $y_{1}<y_{2}<\\ldots$ be all the values attained by $f$ (this sequence might be either finite or infinite). We will prove that for every positive $n$ the function $f$ attains at least $n$ values, and we have (i) $)_{n}: f(x)=y_{n}$ if and only if $x=n$, and $(\\mathrm{ii})_{n}: y_{n}=n$. The proof will follow the scheme\n\n$$\n(\\mathrm{i})_{1},(\\mathrm{ii})_{1},(\\mathrm{i})_{2},(\\mathrm{ii})_{2}, \\ldots,(\\mathrm{i})_{n},(\\mathrm{ii})_{n}, \\ldots\n\\tag{2}\n$$\n\nTo start, consider any $x$ such that $f(x)=y_{1}$. If $x>1$, then (1) reads $f\\left(f^{g(x-1)}(x-1)\\right)<y_{1}$, contradicting the minimality of $y_{1}$. So we have that $f(x)=y_{1}$ is equivalent to $x=1$, establishing $(\\mathrm{i})_{1}$.\n\nNext, assume that for some $n$ statement $(\\mathrm{i})_{n}$ is established, as well as all the previous statements in (2). Note that these statements imply that for all $k \\geq 1$ and $a<n$ we have $f^{k}(x)=a$ if and only if $x=a$.\n\nNow, each value $y_{i}$ with $1 \\leq i \\leq n$ is attained at the unique integer $i$, so $y_{n+1}$ exists. Choose an arbitrary $x$ such that $f(x)=y_{n+1}$; we necessarily have $x>n$. Substituting $x-1$ into (1) we have $f\\left(f^{g(x-1)}(x-1)\\right)<y_{n+1}$, which implies\n\n$$\nf^{g(x-1)}(x-1) \\in\\{1, \\ldots, n\\}\n\\tag{3}\n$$\n\nSet $b=f^{g(x-1)}(x-1)$. If $b<n$ then we would have $x-1=b$ which contradicts $x>n$. So $b=n$, and hence $y_{n}=n$, which proves (ii) ${ }_{n}$. Next, from (i) ${ }_{n}$ we now get $f(k)=n \\Longleftrightarrow k=n$, so removing all the iterations of $f$ in (3) we obtain $x-1=b=n$, which proves $(\\mathrm{i})_{n+1}$.\n\nSo, all the statements in (2) are valid and hence $f(n)=n$ for all $n$. The given relation between $f$ and $g$ now reads $n+g^{n}(n)=n+1-g(n+1)+1$ or $g^{n}(n)+g(n+1)=2$, from which it immediately follows that we have $g(n)=1$ for all $n$.\n\n"
] | $f(n)=n$, $g(n)=1$ |
1,694 | Combinatorics | null | $\boxed{3}$ | [
"3"
] | false | null | Numerical | null | Determine the greatest positive integer $k$ that satisfies the following property: The set of positive integers can be partitioned into $k$ subsets $A_{1}, A_{2}, \ldots, A_{k}$ such that for all integers $n \geq 15$ and all $i \in\{1,2, \ldots, k\}$ there exist two distinct elements of $A_{i}$ whose sum is $n$. | [
"There are various examples showing that $k=3$ does indeed have the property under consideration. E.g. one can take\n\n$$\n\\begin{gathered}\nA_{1}=\\{1,2,3\\} \\cup\\{3 m \\mid m \\geq 4\\} \\\\\nA_{2}=\\{4,5,6\\} \\cup\\{3 m-1 \\mid m \\geq 4\\} \\\\\nA_{3}=\\{7,8,9\\} \\cup\\{3 m-2 \\mid m \\geq 4\\}\n\\end{gathered}\n$$\n\nTo check that this partition fits, we notice first that the sums of two distinct elements of $A_{i}$ obviously represent all numbers $n \\geq 1+12=13$ for $i=1$, all numbers $n \\geq 4+11=15$ for $i=2$, and all numbers $n \\geq 7+10=17$ for $i=3$. So, we are left to find representations of the numbers 15 and 16 as sums of two distinct elements of $A_{3}$. These are $15=7+8$ and $16=7+9$.\n\nLet us now suppose that for some $k \\geq 4$ there exist sets $A_{1}, A_{2}, \\ldots, A_{k}$ satisfying the given property. Obviously, the sets $A_{1}, A_{2}, A_{3}, A_{4} \\cup \\cdots \\cup A_{k}$ also satisfy the same property, so one may assume $k=4$.\n\nPut $B_{i}=A_{i} \\cap\\{1,2, \\ldots, 23\\}$ for $i=1,2,3,4$. Now for any index $i$ each of the ten numbers $15,16, \\ldots, 24$ can be written as sum of two distinct elements of $B_{i}$. Therefore this set needs to contain at least five elements. As we also have $\\left|B_{1}\\right|+\\left|B_{2}\\right|+\\left|B_{3}\\right|+\\left|B_{4}\\right|=23$, there has to be some index $j$ for which $\\left|B_{j}\\right|=5$. Let $B_{j}=\\left\\{x_{1}, x_{2}, x_{3}, x_{4}, x_{5}\\right\\}$. Finally, now the sums of two distinct elements of $A_{j}$ representing the numbers $15,16, \\ldots, 24$ should be exactly all the pairwise sums of the elements of $B_{j}$. Calculating the sum of these numbers in two different ways, we reach\n\n$$\n4\\left(x_{1}+x_{2}+x_{3}+x_{4}+x_{5}\\right)=15+16+\\ldots+24=195\n$$\n\nThus the number 195 should be divisible by 4, which is false. This contradiction completes our solution.",
"Again we only prove that $k \\leq 3$. Assume that $A_{1}, A_{2}, \\ldots, A_{k}$ is a partition satisfying the given property. We construct a graph $\\mathcal{G}$ on the set $V=\\{1,2, \\ldots, 18\\}$ of vertices as follows. For each $i \\in\\{1,2, \\ldots, k\\}$ and each $d \\in\\{15,16,17,19\\}$ we choose one pair of distinct elements $a, b \\in A_{i}$ with $a+b=d$, and we draw an $e d g e$ in the $i^{\\text {th }}$ color connecting $a$ with $b$. By hypothesis, $\\mathcal{G}$ has exactly 4 edges of each color.\n\nClaim. The graph $\\mathcal{G}$ contains at most one circuit.\n\nProof. Note that all the connected components of $\\mathcal{G}$ are monochromatic and hence contain at most four edges. Thus also all circuits of $\\mathcal{G}$ are monochromatic and have length at most four. Moreover, each component contains at most one circuit since otherwise it should contain at least five edges.\n\nSuppose that there is a 4-cycle in $\\mathcal{G}$, say with vertices $a, b, c$, and $d$ in order. Then $\\{a+b, b+$ $c, c+d, d+a\\}=\\{15,16,17,19\\}$. Taking sums we get $2(a+b+c+d)=15+16+17+19$ which is impossible for parity reasons. Thus all circuits of $\\mathcal{G}$ are triangles.\n\nNow if the vertices $a, b$, and $c$ form such a triangle, then by a similar reasoning the set $\\{a+b, b+$ $c, c+a\\}$ coincides with either $\\{15,16,17\\}$, or $\\{15,16,19\\}$, or $\\{16,17,19\\}$, or $\\{15,17,19\\}$. The last of these alternatives can be excluded for parity reasons again, whilst in the first three cases the set $\\{a, b, c\\}$ appears to be either $\\{7,8,9\\}$, or $\\{6,9,10\\}$, or $\\{7,9,10\\}$, respectively. Thus, a component containing a circuit should contain 9 as a vertex. Therefore there is at most one such component and hence at most one circuit.\n\nBy now we know that $\\mathcal{G}$ is a graph with $4 k$ edges, at least $k$ components and at most one circuit. Consequently, $\\mathcal{G}$ must have at least $4 k+k-1$ vertices. Thus $5 k-1 \\leq 18$, and $k \\leq 3$."
] | 3 |
1,695 | Combinatorics | null | $\boxed{\frac{3 m}{2}-1}$ | [
"$\\frac{3 m}{2}-1$"
] | false | null | Expression | null | Let $m$ be a positive integer and consider a checkerboard consisting of $m$ by $m$ unit squares. At the midpoints of some of these unit squares there is an ant. At time 0, each ant starts moving with speed 1 parallel to some edge of the checkerboard. When two ants moving in opposite directions meet, they both turn $90^{\circ}$ clockwise and continue moving with speed 1 . When more than two ants meet, or when two ants moving in perpendicular directions meet, the ants continue moving in the same direction as before they met. When an ant reaches one of the edges of the checkerboard, it falls off and will not re-appear.
Considering all possible starting positions, determine the latest possible moment at which the last ant falls off the checkerboard or prove that such a moment does not necessarily exist. | [
"For $m=1$ the answer is clearly correct, so assume $m>1$. In the sequel, the word collision will be used to denote meeting of exactly two ants, moving in opposite directions.\n\nIf at the beginning we place an ant on the southwest corner square facing east and an ant on the southeast corner square facing west, then they will meet in the middle of the bottom row at time $\\frac{m-1}{2}$. After the collision, the ant that moves to the north will stay on the board for another $m-\\frac{1}{2}$ time units and thus we have established an example in which the last ant falls off at time $\\frac{m-1}{2}+m-\\frac{1}{2}=\\frac{3 m}{2}-1$. So, we are left to prove that this is the latest possible moment.\n\nConsider any collision of two ants $a$ and $a^{\\prime}$. Let us change the rule for this collision, and enforce these two ants to turn anticlockwise. Then the succeeding behavior of all the ants does not change; the only difference is that $a$ and $a^{\\prime}$ swap their positions. These arguments may be applied to any collision separately, so we may assume that at any collision, either both ants rotate clockwise or both of them rotate anticlockwise by our own choice.\n\nFor instance, we may assume that there are only two types of ants, depending on their initial direction: NE-ants, which move only north or east, and $S W$-ants, moving only south and west. Then we immediately obtain that all ants will have fallen off the board after $2 m-1$ time units. However, we can get a better bound by considering the last moment at which a given ant collides with another ant.\n\nChoose a coordinate system such that the corners of the checkerboard are $(0,0),(m, 0),(m, m)$ and $(0, m)$. At time $t$, there will be no NE-ants in the region $\\{(x, y): x+y<t+1\\}$ and no SW-ants in the region $\\{(x, y): x+y>2 m-t-1\\}$. So if two ants collide at $(x, y)$ at time $t$, we have\n\n$$\nt+1 \\leq x+y \\leq 2 m-t-1\n\\tag{1}\n$$\n\n\n\nAnalogously, we may change the rules so that each ant would move either alternatingly north and west, or alternatingly south and east. By doing so, we find that apart from (11) we also have $|x-y| \\leq m-t-1$ for each collision at point $(x, y)$ and time $t$.\n\nTo visualize this, put\n\n$$\nB(t)=\\left\\{(x, y) \\in[0, m]^{2}: t+1 \\leq x+y \\leq 2 m-t-1 \\text { and }|x-y| \\leq m-t-1\\right\\}\n$$\n\nAn ant can thus only collide with another ant at time $t$ if it happens to be in the region $B(t)$. The following figure displays $B(t)$ for $t=\\frac{1}{2}$ and $t=\\frac{7}{2}$ in the case $m=6$ :\n\n<img_3463>\n\nNow suppose that an NE-ant has its last collision at time $t$ and that it does so at the point $(x, y)$ (if the ant does not collide at all, it will fall off the board within $m-\\frac{1}{2}<\\frac{3 m}{2}-1$ time units, so this case can be ignored). Then we have $(x, y) \\in B(t)$ and thus $x+y \\geq t+1$ and $x-y \\geq-(m-t-1)$. So we get\n\n$$\nx \\geq \\frac{(t+1)-(m-t-1)}{2}=t+1-\\frac{m}{2}\n$$\n\nBy symmetry we also have $y \\geq t+1-\\frac{m}{2}$, and hence $\\min \\{x, y\\} \\geq t+1-\\frac{m}{2}$. After this collision, the ant will move directly to an edge, which will take at $\\operatorname{most} m-\\min \\{x, y\\}$ units of time. In sum, the total amount of time the ant stays on the board is at most\n\n$$\nt+(m-\\min \\{x, y\\}) \\leq t+m-\\left(t+1-\\frac{m}{2}\\right)=\\frac{3 m}{2}-1\n$$\n\nBy symmetry, the same bound holds for SW-ants as well."
] | $\frac{3 m}{2}-1$ |
1,697 | Combinatorics | null | $\boxed{3986729}$ | [
"3986729"
] | false | null | Numerical | null | On a square table of 2011 by 2011 cells we place a finite number of napkins that each cover a square of 52 by 52 cells. In each cell we write the number of napkins covering it, and we record the maximal number $k$ of cells that all contain the same nonzero number. Considering all possible napkin configurations, what is the largest value of $k$ ? | [
"Let $m=39$, then $2011=52 m-17$. We begin with an example showing that there can exist 3986729 cells carrying the same positive number.\n\n<img_3188>\n\nTo describe it, we number the columns from the left to the right and the rows from the bottom to the top by $1,2, \\ldots, 2011$. We will denote each napkin by the coordinates of its lowerleft cell. There are four kinds of napkins: first, we take all napkins $(52 i+36,52 j+1)$ with $0 \\leq j \\leq i \\leq m-2$; second, we use all napkins $(52 i+1,52 j+36)$ with $0 \\leq i \\leq j \\leq m-2$; third, we use all napkins $(52 i+36,52 i+36)$ with $0 \\leq i \\leq m-2$; and finally the napkin $(1,1)$. Different groups of napkins are shown by different types of hatchings in the picture.\n\nNow except for those squares that carry two or more different hatchings, all squares have the number 1 written into them. The number of these exceptional cells is easily computed to be $\\left(52^{2}-35^{2}\\right) m-17^{2}=57392$.\n\nWe are left to prove that 3986729 is an upper bound for the number of cells containing the same number. Consider any configuration of napkins and any positive integer $M$. Suppose there are $g$ cells with a number different from $M$. Then it suffices to show $g \\geq 57392$. Throughout the solution, a line will mean either a row or a column.\n\nConsider any line $\\ell$. Let $a_{1}, \\ldots, a_{52 m-17}$ be the numbers written into its consecutive cells. For $i=1,2, \\ldots, 52$, let $s_{i}=\\sum_{t \\equiv i(\\bmod 52)} a_{t}$. Note that $s_{1}, \\ldots, s_{35}$ have $m$ terms each, while $s_{36}, \\ldots, s_{52}$ have $m-1$ terms each. Every napkin intersecting $\\ell$ contributes exactly 1 to each $s_{i}$;\n\n\n\nhence the number $s$ of all those napkins satisfies $s_{1}=\\cdots=s_{52}=s$. Call the line $\\ell$ rich if $s>(m-1) M$ and poor otherwise.\n\nSuppose now that $\\ell$ is rich. Then in each of the sums $s_{36}, \\ldots, s_{52}$ there exists a term greater than $M$; consider all these terms and call the corresponding cells the rich bad cells for this line. So, each rich line contains at least 17 cells that are bad for this line.\n\nIf, on the other hand, $\\ell$ is poor, then certainly $s<m M$ so in each of the sums $s_{1}, \\ldots, s_{35}$ there exists a term less than $M$; consider all these terms and call the corresponding cells the poor bad cells for this line. So, each poor line contains at least 35 cells that are bad for this line.\n\nLet us call all indices congruent to $1,2, \\ldots$, or 35 modulo 52 small, and all other indices, i.e. those congruent to $36,37, \\ldots$, or 52 modulo 52 , big. Recall that we have numbered the columns from the left to the right and the rows from the bottom to the top using the numbers $1,2, \\ldots, 52 m-17$; we say that a line is big or small depending on whether its index is big or small. By definition, all rich bad cells for the rows belong to the big columns, while the poor ones belong to the small columns, and vice versa.\n\nIn each line, we put a strawberry on each cell that is bad for this line. In addition, for each small rich line we put an extra strawberry on each of its (rich) bad cells. A cell gets the strawberries from its row and its column independently.\n\nNotice now that a cell with a strawberry on it contains a number different from $M$. If this cell gets a strawberry by the extra rule, then it contains a number greater than $M$. Moreover, it is either in a small row and in a big column, or vice versa. Suppose that it is in a small row, then it is not bad for its column. So it has not more than two strawberries in this case. On the other hand, if the extra rule is not applied to some cell, then it also has not more than two strawberries. So, the total number $N$ of strawberries is at most $2 g$.\n\nWe shall now estimate $N$ in a different way. For each of the $2 \\cdot 35 \\mathrm{~m}$ small lines, we have introduced at least 34 strawberries if it is rich and at least 35 strawberries if it is poor, so at least 34 strawberries in any case. Similarly, for each of the $2 \\cdot 17(m-1)$ big lines, we put at least $\\min (17,35)=17$ strawberries. Summing over all lines we obtain\n\n$$\n2 g \\geq N \\geq 2(35 m \\cdot 34+17(m-1) \\cdot 17)=2(1479 m-289)=2 \\cdot 57392\n$$\n\nas desired.",
"We present a different proof of the estimate which is the hard part of the problem. Let $S=35, H=17, m=39$; so the table size is $2011=S m+H(m-1)$, and the napkin size is $52=S+H$. Fix any positive integer $M$ and call a cell vicious if it contains a number distinct\n\n\n\nfrom $M$. We will prove that there are at least $H^{2}(m-1)+2 S H m$ vicious cells.\n\nFirstly, we introduce some terminology. As in the previous solution, we number rows and columns and we use the same notions of small and big indices and lines; so, an index is small if it is congruent to one of the numbers $1,2, \\ldots, S$ modulo $(S+H)$. The numbers $1,2, \\ldots, S+H$ will be known as residues. For two residues $i$ and $j$, we say that a cell is of type $(i, j)$ if the index of its row is congruent to $i$ and the index of its column to $j$ modulo $(S+H)$. The number of vicious cells of this type is denoted by $v_{i j}$.\n\nLet $s, s^{\\prime}$ be two variables ranging over small residues and let $h, h^{\\prime}$ be two variables ranging over big residues. A cell is said to be of class $A, B, C$, or $D$ if its type is of shape $\\left(s, s^{\\prime}\\right),(s, h),(h, s)$, or $\\left(h, h^{\\prime}\\right)$, respectively. The numbers of vicious cells belonging to these classes are denoted in this order by $a, b, c$, and $d$. Observe that each cell belongs to exactly one class.\n\nClaim 1. We have\n\n$$\nm \\leq \\frac{a}{S^{2}}+\\frac{b+c}{2 S H}\n\\tag{1}\n$$\n\nProof. Consider an arbitrary small row $r$. Denote the numbers of vicious cells on $r$ belonging to the classes $A$ and $B$ by $\\alpha$ and $\\beta$, respectively. As in the previous solution, we obtain that $\\alpha \\geq S$ or $\\beta \\geq H$. So in each case we have $\\frac{\\alpha}{S}+\\frac{\\beta}{H} \\geq 1$.\n\nPerforming this argument separately for each small row and adding up all the obtained inequalities, we get $\\frac{a}{S}+\\frac{b}{H} \\geq m S$. Interchanging rows and columns we similarly get $\\frac{a}{S}+\\frac{c}{H} \\geq m S$. Summing these inequalities and dividing by $2 S$ we get what we have claimed.\n\nClaim 2. Fix two small residue $s, s^{\\prime}$ and two big residues $h, h^{\\prime}$. Then $2 m-1 \\leq v_{s s^{\\prime}}+v_{s h^{\\prime}}+v_{h h^{\\prime}}$. Proof. Each napkin covers exactly one cell of type $\\left(s, s^{\\prime}\\right)$. Removing all napkins covering a vicious cell of this type, we get another collection of napkins, which covers each cell of type $\\left(s, s^{\\prime}\\right)$ either 0 or $M$ times depending on whether the cell is vicious or not. Hence $\\left(m^{2}-v_{s s^{\\prime}}\\right) M$ napkins are left and throughout the proof of Claim 2 we will consider only these remaining napkins. Now, using a red pen, write in each cell the number of napkins covering it. Notice that a cell containing a red number greater than $M$ is surely vicious.\n\nWe call two cells neighbors if they can be simultaneously covered by some napkin. So, each cell of type $\\left(h, h^{\\prime}\\right)$ has not more than four neighbors of type $\\left(s, s^{\\prime}\\right)$, while each cell of type $\\left(s, h^{\\prime}\\right)$ has not more than two neighbors of each of the types $\\left(s, s^{\\prime}\\right)$ and $\\left(h, h^{\\prime}\\right)$. Therefore, each red number at a cell of type $\\left(h, h^{\\prime}\\right)$ does not exceed $4 M$, while each red number at a cell of type $\\left(s, h^{\\prime}\\right)$ does not exceed $2 M$.\n\nLet $x, y$, and $z$ be the numbers of cells of type $\\left(h, h^{\\prime}\\right)$ whose red number belongs to $(M, 2 M]$, $(2 M, 3 M]$, and $(3 M, 4 M]$, respectively. All these cells are vicious, hence $x+y+z \\leq v_{h h^{\\prime}}$. The red numbers appearing in cells of type $\\left(h, h^{\\prime}\\right)$ clearly sum up to $\\left(m^{2}-v_{s s^{\\prime}}\\right) M$. Bounding each of these numbers by a multiple of $M$ we get\n\n$$\n\\left(m^{2}-v_{s s^{\\prime}}\\right) M \\leq\\left((m-1)^{2}-(x+y+z)\\right) M+2 x M+3 y M+4 z M\n$$\n\n\n\ni.e.\n\n$$\n2 m-1 \\leq v_{s s^{\\prime}}+x+2 y+3 z \\leq v_{s s^{\\prime}}+v_{h h^{\\prime}}+y+2 z\n$$\n\nSo, to prove the claim it suffices to prove that $y+2 z \\leq v_{s h^{\\prime}}$.\n\nFor a cell $\\delta$ of type $\\left(h, h^{\\prime}\\right)$ and a cell $\\beta$ of type $\\left(s, h^{\\prime}\\right)$ we say that $\\delta$ forces $\\beta$ if there are more than $M$ napkins covering both of them. Since each red number in a cell of type $\\left(s, h^{\\prime}\\right)$ does not exceed $2 M$, it cannot be forced by more than one cell.\n\nOn the other hand, if a red number in a $\\left(h, h^{\\prime}\\right)$-cell belongs to $(2 M, 3 M]$, then it forces at least one of its neighbors of type $\\left(s, h^{\\prime}\\right)$ (since the sum of red numbers in their cells is greater than $2 M)$. Analogously, an $\\left(h, h^{\\prime}\\right)$-cell with the red number in $(3 M, 4 M]$ forces both its neighbors of type $\\left(s, h^{\\prime}\\right)$, since their red numbers do not exceed $2 M$. Therefore there are at least $y+2 z$ forced cells and clearly all of them are vicious, as desired.\n\nClaim 3. We have\n\n$$\n2 m-1 \\leq \\frac{a}{S^{2}}+\\frac{b+c}{2 S H}+\\frac{d}{H^{2}}\n\\tag{2}\n$$\n\nProof. Averaging the previous result over all $S^{2} H^{2}$ possibilities for the quadruple $\\left(s, s^{\\prime}, h, h^{\\prime}\\right)$, we get $2 m-1 \\leq \\frac{a}{S^{2}}+\\frac{b}{S H}+\\frac{d}{H^{2}}$. Due to the symmetry between rows and columns, the same estimate holds with $b$ replaced by $c$. Averaging these two inequalities we arrive at our claim.\n\nNow let us multiply (2) by $H^{2}$, multiply (II) by $\\left(2 S H-H^{2}\\right)$ and add them; we get\n\n$H^{2}(2 m-1)+\\left(2 S H-H^{2}\\right) m \\leq a \\cdot \\frac{H^{2}+2 S H-H^{2}}{S^{2}}+(b+c) \\frac{H^{2}+2 S H-H^{2}}{2 S H}+d=a \\cdot \\frac{2 H}{S}+b+c+d$.\n\nThe left-hand side is exactly $H^{2}(m-1)+2 S H m$, while the right-hand side does not exceed $a+b+c+d$ since $2 H \\leq S$. Hence we come to the desired inequality."
] | 3986729 |
1,709 | Number Theory | null | $\boxed{1,3,5}$ | [
"1,3,5"
] | true | null | Numerical | null | For each positive integer $k$, let $t(k)$ be the largest odd divisor of $k$. Determine all positive integers $a$ for which there exists a positive integer $n$ such that all the differences
$$
t(n+a)-t(n), \quad t(n+a+1)-t(n+1), \quad \ldots, \quad t(n+2 a-1)-t(n+a-1)
$$
are divisible by 4 . | [
"A pair $(a, n)$ satisfying the condition of the problem will be called a winning pair. It is straightforward to check that the pairs $(1,1),(3,1)$, and $(5,4)$ are winning pairs.\n\nNow suppose that $a$ is a positive integer not equal to 1,3 , and 5 . We will show that there are no winning pairs $(a, n)$ by distinguishing three cases.\n\nCase 1: $a$ is even. In this case we have $a=2^{\\alpha} d$ for some positive integer $\\alpha$ and some odd $d$. Since $a \\geq 2^{\\alpha}$, for each positive integer $n$ there exists an $i \\in\\{0,1, \\ldots, a-1\\}$ such that $n+i=2^{\\alpha-1} e$, where $e$ is some odd integer. Then we have $t(n+i)=t\\left(2^{\\alpha-1} e\\right)=e$ and\n\n$$\nt(n+a+i)=t\\left(2^{\\alpha} d+2^{\\alpha-1} e\\right)=2 d+e \\equiv e+2 \\quad(\\bmod 4) .\n$$\n\nSo we get $t(n+i)-t(n+a+i) \\equiv 2(\\bmod 4)$, and $(a, n)$ is not a winning pair.\n\nCase 2: $a$ is odd and $a>8$. For each positive integer $n$, there exists an $i \\in\\{0,1, \\ldots, a-5\\}$ such that $n+i=2 d$ for some odd $d$. We get\n\n$$\nt(n+i)=d \\not \\equiv d+2=t(n+i+4) \\quad(\\bmod 4)\n$$\n\nand\n\n$$\nt(n+a+i)=n+a+i \\equiv n+a+i+4=t(n+a+i+4) \\quad(\\bmod 4)\n$$\n\nTherefore, the integers $t(n+a+i)-t(n+i)$ and $t(n+a+i+4)-t(n+i+4)$ cannot be both divisible by 4 , and therefore there are no winning pairs in this case.\n\nCase 3: $a=7$. For each positive integer $n$, there exists an $i \\in\\{0,1, \\ldots, 6\\}$ such that $n+i$ is either of the form $8 k+3$ or of the form $8 k+6$, where $k$ is a nonnegative integer. But we have\n\n$$\nt(8 k+3) \\equiv 3 \\not \\equiv 1 \\equiv 4 k+5=t(8 k+3+7) \\quad(\\bmod 4)\n$$\n\nand\n\n$$\nt(8 k+6)=4 k+3 \\equiv 3 \\not \\equiv 1 \\equiv t(8 k+6+7) \\quad(\\bmod 4)\n$$\n\nHence, there are no winning pairs of the form $(7, n)$."
] | 1,3,5 |
1,716 | Algebra | null | $\boxed{\frac{25}{2}}$ | [
"$\\frac{25}{2}$"
] | false | null | Numerical | null | Let $x_{1}, \ldots, x_{100}$ be nonnegative real numbers such that $x_{i}+x_{i+1}+x_{i+2} \leq 1$ for all $i=1, \ldots, 100$ (we put $x_{101}=x_{1}, x_{102}=x_{2}$ ). Find the maximal possible value of the sum
$$
S=\sum_{i=1}^{100} x_{i} x_{i+2}
$$ | [
"Let $x_{2 i}=0, x_{2 i-1}=\\frac{1}{2}$ for all $i=1, \\ldots, 50$. Then we have $S=50 \\cdot\\left(\\frac{1}{2}\\right)^{2}=\\frac{25}{2}$. So, we are left to show that $S \\leq \\frac{25}{2}$ for all values of $x_{i}$ 's satisfying the problem conditions.\n\nConsider any $1 \\leq i \\leq 50$. By the problem condition, we get $x_{2 i-1} \\leq 1-x_{2 i}-x_{2 i+1}$ and $x_{2 i+2} \\leq 1-x_{2 i}-x_{2 i+1}$. Hence by the AM-GM inequality we get\n\n$$\n\\begin{aligned}\nx_{2 i-1} x_{2 i+1} & +x_{2 i} x_{2 i+2} \\leq\\left(1-x_{2 i}-x_{2 i+1}\\right) x_{2 i+1}+x_{2 i}\\left(1-x_{2 i}-x_{2 i+1}\\right) \\\\\n& =\\left(x_{2 i}+x_{2 i+1}\\right)\\left(1-x_{2 i}-x_{2 i+1}\\right) \\leq\\left(\\frac{\\left(x_{2 i}+x_{2 i+1}\\right)+\\left(1-x_{2 i}-x_{2 i+1}\\right)}{2}\\right)^{2}=\\frac{1}{4} .\n\\end{aligned}\n$$\n\nSumming up these inequalities for $i=1,2, \\ldots, 50$, we get the desired inequality\n\n$$\n\\sum_{i=1}^{50}\\left(x_{2 i-1} x_{2 i+1}+x_{2 i} x_{2 i+2}\\right) \\leq 50 \\cdot \\frac{1}{4}=\\frac{25}{2}\n$$",
"We present another proof of the estimate. From the problem condition, we get\n\n$$\n\\begin{aligned}\nS=\\sum_{i=1}^{100} x_{i} x_{i+2} \\leq \\sum_{i=1}^{100} x_{i}\\left(1-x_{i}-x_{i+1}\\right) & =\\sum_{i=1}^{100} x_{i}-\\sum_{i=1}^{100} x_{i}^{2}-\\sum_{i=1}^{100} x_{i} x_{i+1} \\\\\n& =\\sum_{i=1}^{100} x_{i}-\\frac{1}{2} \\sum_{i=1}^{100}\\left(x_{i}+x_{i+1}\\right)^{2}\n\\end{aligned}\n$$\n\nBy the AM-QM inequality, we have $\\sum\\left(x_{i}+x_{i+1}\\right)^{2} \\geq \\frac{1}{100}\\left(\\sum\\left(x_{i}+x_{i+1}\\right)\\right)^{2}$, so\n\n$$\n\\begin{aligned}\nS \\leq \\sum_{i=1}^{100} x_{i}-\\frac{1}{200}\\left(\\sum_{i=1}^{100}\\left(x_{i}+x_{i+1}\\right)\\right)^{2} & =\\sum_{i=1}^{100} x_{i}-\\frac{2}{100}\\left(\\sum_{i=1}^{100} x_{i}\\right)^{2} \\\\\n& =\\frac{2}{100}\\left(\\sum_{i=1}^{100} x_{i}\\right)\\left(\\frac{100}{2}-\\sum_{i=1}^{100} x_{i}\\right) .\n\\end{aligned}\n$$\n\nAnd finally, by the AM-GM inequality\n\n$$\nS \\leq \\frac{2}{100} \\cdot\\left(\\frac{1}{2}\\left(\\sum_{i=1}^{100} x_{i}+\\frac{100}{2}-\\sum_{i=1}^{100} x_{i}\\right)\\right)^{2}=\\frac{2}{100} \\cdot\\left(\\frac{100}{4}\\right)^{2}=\\frac{25}{2}\n$$"
] | $\frac{25}{2}$ |
1,718 | Algebra | null | $\boxed{f(x)=\frac{1}{x}}$ | [
"$f(x)=\\frac{1}{x}$"
] | false | null | Expression | null | Denote by $\mathbb{Q}^{+}$the set of all positive rational numbers. Determine all functions $f: \mathbb{Q}^{+} \rightarrow \mathbb{Q}^{+}$ which satisfy the following equation for all $x, y \in \mathbb{Q}^{+}$:
$$
f\left(f(x)^{2} y\right)=x^{3} f(x y)
\tag{1}
$$ | [
"By substituting $y=1$, we get\n\n$$\nf\\left(f(x)^{2}\\right)=x^{3} f(x)\\tag{2}\n$$\n\nThen, whenever $f(x)=f(y)$, we have\n\n$$\nx^{3}=\\frac{f\\left(f(x)^{2}\\right)}{f(x)}=\\frac{f\\left(f(y)^{2}\\right)}{f(y)}=y^{3}\n$$\n\nwhich implies $x=y$, so the function $f$ is injective.\n\nNow replace $x$ by $x y$ in (2), and apply (1) twice, second time to $\\left(y, f(x)^{2}\\right)$ instead of $(x, y)$ :\n\n$$\nf\\left(f(x y)^{2}\\right)=(x y)^{3} f(x y)=y^{3} f\\left(f(x)^{2} y\\right)=f\\left(f(x)^{2} f(y)^{2}\\right)\n$$\n\nSince $f$ is injective, we get\n\n$$\n\\begin{aligned}\nf(x y)^{2} & =f(x)^{2} f(y)^{2} \\\\\nf(x y) & =f(x) f(y) .\n\\end{aligned}\n$$\n\nTherefore, $f$ is multiplicative. This also implies $f(1)=1$ and $f\\left(x^{n}\\right)=f(x)^{n}$ for all integers $n$.\n\nThen the function equation (1) can be re-written as\n\n$$\n\\begin{aligned}\nf(f(x))^{2} f(y) & =x^{3} f(x) f(y), \\\\\nf(f(x)) & =\\sqrt{x^{3} f(x)} .\n\\end{aligned}\n\\tag{3}\n$$\n\nLet $g(x)=x f(x)$. Then, by (3), we have\n\n$$\n\\begin{aligned}\ng(g(x)) & =g(x f(x))=x f(x) \\cdot f(x f(x))=x f(x)^{2} f(f(x))= \\\\\n& =x f(x)^{2} \\sqrt{x^{3} f(x)}=(x f(x))^{5 / 2}=(g(x))^{5 / 2},\n\\end{aligned}\n$$\n\nand, by induction,\n\n$$\n\\underbrace{g(g(\\ldots g}_{n+1}(x) \\ldots))=(g(x))^{(5 / 2)^{n}}\n\\tag{4}\n$$\n\nfor every positive integer $n$.\n\nConsider (4) for a fixed $x$. The left-hand side is always rational, so $(g(x))^{(5 / 2)^{n}}$ must be rational for every $n$. We show that this is possible only if $g(x)=1$. Suppose that $g(x) \\neq 1$, and let the prime factorization of $g(x)$ be $g(x)=p_{1}^{\\alpha_{1}} \\ldots p_{k}^{\\alpha_{k}}$ where $p_{1}, \\ldots, p_{k}$ are distinct primes and $\\alpha_{1}, \\ldots, \\alpha_{k}$ are nonzero integers. Then the unique prime factorization of (4) is\n\n$$\n\\underbrace{g(g(\\ldots g}_{n+1}(x) \\ldots))=(g(x))^{(5 / 2)^{n}}=p_{1}^{(5 / 2)^{n} \\alpha_{1}} \\ldots p_{k}^{(5 / 2)^{n} \\alpha_{k}}\n$$\n\n\n\nwhere the exponents should be integers. But this is not true for large values of $n$, for example $\\left(\\frac{5}{2}\\right)^{n} \\alpha_{1}$ cannot be a integer number when $2^{n} \\nmid \\alpha_{1}$. Therefore, $g(x) \\neq 1$ is impossible.\n\nHence, $g(x)=1$ and thus $f(x)=\\frac{1}{x}$ for all $x$.\n\nThe function $f(x)=\\frac{1}{x}$ satisfies the equation (1):\n\n$$\nf\\left(f(x)^{2} y\\right)=\\frac{1}{f(x)^{2} y}=\\frac{1}{\\left(\\frac{1}{x}\\right)^{2} y}=\\frac{x^{3}}{x y}=x^{3} f(x y)\n$$"
] | $f(x)=\frac{1}{x}$ |
1,723 | Combinatorics | null | $\boxed{M=2^{N-2}+1}$ | [
"$M=2^{N-2}+1$"
] | false | null | Expression | null | On some planet, there are $2^{N}$ countries $(N \geq 4)$. Each country has a flag $N$ units wide and one unit high composed of $N$ fields of size $1 \times 1$, each field being either yellow or blue. No two countries have the same flag.
We say that a set of $N$ flags is diverse if these flags can be arranged into an $N \times N$ square so that all $N$ fields on its main diagonal will have the same color. Determine the smallest positive integer $M$ such that among any $M$ distinct flags, there exist $N$ flags forming a diverse set. | [
"When speaking about the diagonal of a square, we will always mean the main diagonal.\n\nLet $M_{N}$ be the smallest positive integer satisfying the problem condition. First, we show that $M_{N}>2^{N-2}$. Consider the collection of all $2^{N-2}$ flags having yellow first squares and blue second ones. Obviously, both colors appear on the diagonal of each $N \\times N$ square formed by these flags.\n\nWe are left to show that $M_{N} \\leq 2^{N-2}+1$, thus obtaining the desired answer. We start with establishing this statement for $N=4$.\n\nSuppose that we have 5 flags of length 4 . We decompose each flag into two parts of 2 squares each; thereby, we denote each flag as $L R$, where the $2 \\times 1$ flags $L, R \\in \\mathcal{S}=\\{\\mathrm{BB}, \\mathrm{BY}, \\mathrm{YB}, \\mathrm{YY}\\}$ are its left and right parts, respectively. First, we make two easy observations on the flags $2 \\times 1$ which can be checked manually.\n\n(i) For each $A \\in \\mathcal{S}$, there exists only one $2 \\times 1$ flag $C \\in \\mathcal{S}$ (possibly $C=A$ ) such that $A$ and $C$ cannot form a $2 \\times 2$ square with monochrome diagonal (for part $\\mathrm{BB}$, that is $\\mathrm{YY}$, and for $\\mathrm{BY}$ that is $\\mathrm{YB)}$.\n\n(ii) Let $A_{1}, A_{2}, A_{3} \\in \\mathcal{S}$ be three distinct elements; then two of them can form a $2 \\times 2$ square with yellow diagonal, and two of them can form a $2 \\times 2$ square with blue diagonal (for all parts but $\\mathrm{BB}$, a pair (BY, YB) fits for both statements, while for all parts but BY, these pairs are $(\\mathrm{YB}, \\mathrm{YY})$ and $(\\mathrm{BB}, \\mathrm{YB}))$.\n\nNow, let $\\ell$ and $r$ be the numbers of distinct left and right parts of our 5 flags, respectively. The total number of flags is $5 \\leq r \\ell$, hence one of the factors (say, $r$ ) should be at least 3 . On the other hand, $\\ell, r \\leq 4$, so there are two flags with coinciding right part; let them be $L_{1} R_{1}$ and $L_{2} R_{1}\\left(L_{1} \\neq L_{2}\\right)$.\n\nNext, since $r \\geq 3$, there exist some flags $L_{3} R_{3}$ and $L_{4} R_{4}$ such that $R_{1}, R_{3}, R_{4}$ are distinct. Let $L^{\\prime} R^{\\prime}$ be the remaining flag. By (i), one of the pairs $\\left(L^{\\prime}, L_{1}\\right)$ and $\\left(L^{\\prime}, L_{2}\\right)$ can form a $2 \\times 2$ square with monochrome diagonal; we can assume that $L^{\\prime}, L_{2}$ form a square with a blue diagonal. Finally, the right parts of two of the flags $L_{1} R_{1}, L_{3} R_{3}, L_{4} R_{4}$ can also form a $2 \\times 2$ square with a blue diagonal by (ii). Putting these $2 \\times 2$ squares on the diagonal of a $4 \\times 4$ square, we find a desired arrangement of four flags.\n\nWe are ready to prove the problem statement by induction on $N$; actually, above we have proved the base case $N=4$. For the induction step, assume that $N>4$, consider any $2^{N-2}+1$ flags of length $N$, and arrange them into a large flag of size $\\left(2^{N-2}+1\\right) \\times N$. This flag contains a non-monochrome column since the flags are distinct; we may assume that this column is the first one. By the pigeonhole principle, this column contains at least $\\left\\lceil\\frac{2^{N-2}+1}{2}\\right\\rceil=2^{N-3}+1$ squares of one color (say, blue). We call the flags with a blue first square good.\n\nConsider all the good flags and remove the first square from each of them. We obtain at least $2^{N-3}+1 \\geq M_{N-1}$ flags of length $N-1$; by the induction hypothesis, $N-1$ of them\n\n\n\ncan form a square $Q$ with the monochrome diagonal. Now, returning the removed squares, we obtain a rectangle $(N-1) \\times N$, and our aim is to supplement it on the top by one more flag.\n\nIf $Q$ has a yellow diagonal, then we can take each flag with a yellow first square (it exists by a choice of the first column; moreover, it is not used in $Q$ ). Conversely, if the diagonal of $Q$ is blue then we can take any of the $\\geq 2^{N-3}+1-(N-1)>0$ remaining good flags. So, in both cases we get a desired $N \\times N$ square.",
"We present a different proof of the estimate $M_{N} \\leq 2^{N-2}+1$. We do not use the induction, involving Hall's lemma on matchings instead.\n\nConsider arbitrary $2^{N-2}+1$ distinct flags and arrange them into a large $\\left(2^{N-2}+1\\right) \\times N$ flag. Construct two bipartite graphs $G_{\\mathrm{y}}=\\left(V \\cup V^{\\prime}, E_{\\mathrm{y}}\\right)$ and $G_{\\mathrm{b}}=\\left(V \\cup V^{\\prime}, E_{\\mathrm{b}}\\right)$ with the common set of vertices as follows. Let $V$ and $V^{\\prime}$ be the set of columns and the set of flags under consideration, respectively. Next, let the edge $(c, f)$ appear in $E_{\\mathrm{y}}$ if the intersection of column $c$ and flag $f$ is yellow, and $(c, f) \\in E_{\\mathrm{b}}$ otherwise. Then we have to prove exactly that one of the graphs $G_{\\mathrm{y}}$ and $G_{\\mathrm{b}}$ contains a matching with all the vertices of $V$ involved.\n\nAssume that these matchings do not exist. By Hall's lemma, it means that there exist two sets of columns $S_{\\mathrm{y}}, S_{\\mathrm{b}} \\subset V$ such that $\\left|E_{\\mathrm{y}}\\left(S_{\\mathrm{y}}\\right)\\right| \\leq\\left|S_{\\mathrm{y}}\\right|-1$ and $\\left|E_{\\mathrm{b}}\\left(S_{\\mathrm{b}}\\right)\\right| \\leq\\left|S_{\\mathrm{b}}\\right|-1$ (in the left-hand sides, $E_{\\mathrm{y}}\\left(S_{\\mathrm{y}}\\right)$ and $E_{\\mathrm{b}}\\left(S_{\\mathrm{b}}\\right)$ denote respectively the sets of all vertices connected to $S_{\\mathrm{y}}$ and $S_{\\mathrm{b}}$ in the corresponding graphs). Our aim is to prove that this is impossible. Note that $S_{\\mathrm{y}}, S_{\\mathrm{b}} \\neq V$ since $N \\leq 2^{N-2}+1$.\n\nFirst, suppose that $S_{\\mathrm{y}} \\cap S_{\\mathrm{b}} \\neq \\varnothing$, so there exists some $c \\in S_{\\mathrm{y}} \\cap S_{\\mathrm{b}}$. Note that each flag is connected to $c$ either in $G_{\\mathrm{y}}$ or in $G_{\\mathrm{b}}$, hence $E_{\\mathrm{y}}\\left(S_{\\mathrm{y}}\\right) \\cup E_{\\mathrm{b}}\\left(S_{\\mathrm{b}}\\right)=V^{\\prime}$. Hence we have $2^{N-2}+1=\\left|V^{\\prime}\\right| \\leq\\left|E_{\\mathrm{y}}\\left(S_{\\mathrm{y}}\\right)\\right|+\\left|E_{\\mathrm{b}}\\left(S_{\\mathrm{b}}\\right)\\right| \\leq\\left|S_{\\mathrm{y}}\\right|+\\left|S_{\\mathrm{b}}\\right|-2 \\leq 2 N-4$; this is impossible for $N \\geq 4$.\n\nSo, we have $S_{\\mathrm{y}} \\cap S_{\\mathrm{b}}=\\varnothing$. Let $y=\\left|S_{\\mathrm{y}}\\right|, b=\\left|S_{\\mathrm{b}}\\right|$. From the construction of our graph, we have that all the flags in the set $V^{\\prime \\prime}=V^{\\prime} \\backslash\\left(E_{\\mathrm{y}}\\left(S_{\\mathrm{y}}\\right) \\cup E_{\\mathrm{b}}\\left(S_{\\mathrm{b}}\\right)\\right)$ have blue squares in the columns of $S_{\\mathrm{y}}$ and yellow squares in the columns of $S_{\\mathrm{b}}$. Hence the only undetermined positions in these flags are the remaining $N-y-b$ ones, so $2^{N-y-b} \\geq\\left|V^{\\prime \\prime}\\right| \\geq\\left|V^{\\prime}\\right|-\\left|E_{\\mathrm{y}}\\left(S_{\\mathrm{y}}\\right)\\right|-\\left|E_{\\mathrm{b}}\\left(S_{\\mathrm{b}}\\right)\\right| \\geq$ $2^{N-2}+1-(y-1)-(b-1)$, or, denoting $c=y+b, 2^{N-c}+c>2^{N-2}+2$. This is impossible since $N \\geq c \\geq 2$."
] | $M=2^{N-2}+1$ |
1,724 | Combinatorics | null | $\boxed{2}$ | [
"2"
] | false | null | Numerical | null | 2500 chess kings have to be placed on a $100 \times 100$ chessboard so that
(i) no king can capture any other one (i.e. no two kings are placed in two squares sharing a common vertex);
(ii) each row and each column contains exactly 25 kings.
Find the number of such arrangements. (Two arrangements differing by rotation or symmetry are supposed to be different.) | [
"Suppose that we have an arrangement satisfying the problem conditions. Divide the board into $2 \\times 2$ pieces; we call these pieces blocks. Each block can contain not more than one king (otherwise these two kings would attack each other); hence, by the pigeonhole principle each block must contain exactly one king.\n\nNow assign to each block a letter $\\mathrm{T}$ or $\\mathrm{B}$ if a king is placed in its top or bottom half, respectively. Similarly, assign to each block a letter $\\mathrm{L}$ or $\\mathrm{R}$ if a king stands in its left or right half. So we define T-blocks, B-blocks, L-blocks, and $R$-blocks. We also combine the letters; we call a block $a T L$-block if it is simultaneously T-block and L-block. Similarly we define TR-blocks, $B L$-blocks, and BR-blocks. The arrangement of blocks determines uniquely the arrangement of kings; so in the rest of the solution we consider the $50 \\times 50$ system of blocks (see Fig. 1). We identify the blocks by their coordinate pairs; the pair $(i, j)$, where $1 \\leq i, j \\leq 50$, refers to the $j$ th block in the $i$ th row (or the $i$ th block in the $j$ th column). The upper-left block is $(1,1)$.\n\nThe system of blocks has the following properties..\n\n$\\left(\\mathrm{i}^{\\prime}\\right)$ If $(i, j)$ is a B-block then $(i+1, j)$ is a B-block: otherwise the kings in these two blocks can take each other. Similarly: if $(i, j)$ is a T-block then $(i-1, j)$ is a T-block; if $(i, j)$ is an L-block then $(i, j-1)$ is an L-block; if $(i, j)$ is an R-block then $(i, j+1)$ is an R-block.\n\n(ii') Each column contains exactly 25 L-blocks and 25 R-blocks, and each row contains exactly 25 T-blocks and 25 B-blocks. In particular, the total number of L-blocks (or R-blocks, or T-blocks, or B-blocks) is equal to $25 \\cdot 50=1250$.\n\nConsider any B-block of the form $(1, j)$. By $\\left(\\mathrm{i}^{\\prime}\\right)$, all blocks in the $j$ th column are B-blocks; so we call such a column $B$-column. By (ii'), we have 25 B-blocks in the first row, so we obtain 25 B-columns. These $25 \\mathrm{~B}$-columns contain $1250 \\mathrm{~B}$-blocks, hence all blocks in the remaining columns are T-blocks, and we obtain 25 T-columns. Similarly, there are exactly 25 L-rows and exactly 25 -rows.\n\nNow consider an arbitrary pair of a T-column and a neighboring B-column (columns with numbers $j$ and $j+1$ ).\n\n<img_3973>\n\nFig. 1\n\n<img_3920>\n\nFig. 2\n\nCase 1. Suppose that the $j$ th column is a T-column, and the $(j+1)$ th column is a Bcolumn. Consider some index $i$ such that the $i$ th row is an L-row; then $(i, j+1)$ is a BL-block. Therefore, $(i+1, j)$ cannot be a TR-block (see Fig. 2), hence $(i+1, j)$ is a TL-block, thus the $(i+1)$ th row is an L-row. Now, choosing the $i$ th row to be the topmost L-row, we successively obtain that all rows from the $i$ th to the 50th are L-rows. Since we have exactly 25 L-rows, it follows that the rows from the 1st to the 25th are R-rows, and the rows from the 26th to the 50th are L-rows.\n\nNow consider the neighboring R-row and L-row (that are the rows with numbers 25 and 26). Replacing in the previous reasoning rows by columns and vice versa, the columns from the 1 st to the 25th are T-columns, and the columns from the 26th to the 50th are B-columns. So we have a unique arrangement of blocks that leads to the arrangement of kings satisfying the condition of the problem (see Fig. 3).\n\n<img_4043>\n\nFig. 3\n\n<img_3321>\n\nFig. 4\n\nCase 2. Suppose that the $j$ th column is a B-column, and the $(j+1)$ th column is a T-column. Repeating the arguments from Case 1, we obtain that the rows from the 1st to the 25th are L-rows (and all other rows are R-rows), the columns from the 1st to the 25th are B-columns (and all other columns are T-columns), so we find exactly one more arrangement of kings (see Fig. 4)."
] | 2 |
1,736 | Number Theory | null | $\boxed{39}$ | [
"39"
] | false | null | Numerical | null | Find the least positive integer $n$ for which there exists a set $\left\{s_{1}, s_{2}, \ldots, s_{n}\right\}$ consisting of $n$ distinct positive integers such that
$$
\left(1-\frac{1}{s_{1}}\right)\left(1-\frac{1}{s_{2}}\right) \ldots\left(1-\frac{1}{s_{n}}\right)=\frac{51}{2010}
$$ | [
"Suppose that for some $n$ there exist the desired numbers; we may assume that $s_{1}<s_{2}<\\cdots<s_{n}$. Surely $s_{1}>1$ since otherwise $1-\\frac{1}{s_{1}}=0$. So we have $2 \\leq s_{1} \\leq s_{2}-1 \\leq \\cdots \\leq s_{n}-(n-1)$, hence $s_{i} \\geq i+1$ for each $i=1, \\ldots, n$. Therefore\n\n$$\n\\begin{aligned}\n\\frac{51}{2010} & =\\left(1-\\frac{1}{s_{1}}\\right)\\left(1-\\frac{1}{s_{2}}\\right) \\ldots\\left(1-\\frac{1}{s_{n}}\\right) \\\\\n& \\geq\\left(1-\\frac{1}{2}\\right)\\left(1-\\frac{1}{3}\\right) \\ldots\\left(1-\\frac{1}{n+1}\\right)=\\frac{1}{2} \\cdot \\frac{2}{3} \\cdots \\frac{n}{n+1}=\\frac{1}{n+1}\n\\end{aligned}\n$$\n\nwhich implies\n\n$$\nn+1 \\geq \\frac{2010}{51}=\\frac{670}{17}>39\n$$\n\nso $n \\geq 39$.\n\nNow we are left to show that $n=39$ fits. Consider the set $\\{2,3, \\ldots, 33,35,36, \\ldots, 40,67\\}$ which contains exactly 39 numbers. We have\n\n$$\n\\frac{1}{2} \\cdot \\frac{2}{3} \\cdots \\frac{32}{33} \\cdot \\frac{34}{35} \\cdots \\frac{39}{40} \\cdot \\frac{66}{67}=\\frac{1}{33} \\cdot \\frac{34}{40} \\cdot \\frac{66}{67}=\\frac{17}{670}=\\frac{51}{2010}\n\\tag{1}\n$$\n\nhence for $n=39$ there exists a desired example."
] | 39 |
1,737 | Number Theory | null | $\boxed{(6,3),(9,3),(9,5),(54,5)}$ | [
"$(6,3),(9,3),(9,5),(54,5)$"
] | true | null | Tuple | null | Find all pairs $(m, n)$ of nonnegative integers for which
$$
m^{2}+2 \cdot 3^{n}=m\left(2^{n+1}-1\right)
\tag{1}
$$ | [
"For fixed values of $n$, the equation (1) is a simple quadratic equation in $m$. For $n \\leq 5$ the solutions are listed in the following table.\n\n| case | equation | discriminant | integer roots |\n| :--- | :--- | :--- | :--- |\n| $n=0$ | $m^{2}-m+2=0$ | -7 | none |\n| $n=1$ | $m^{2}-3 m+6=0$ | -15 | none |\n| $n=2$ | $m^{2}-7 m+18=0$ | -23 | none |\n| $n=3$ | $m^{2}-15 m+54=0$ | 9 | $m=6$ and $m=9$ |\n| $n=4$ | $m^{2}-31 m+162=0$ | 313 | none |\n| $n=5$ | $m^{2}-63 m+486=0$ | $2025=45^{2}$ | $m=9$ and $m=54$ |\n\nWe prove that there is no solution for $n \\geq 6$.\n\nSuppose that $(m, n)$ satisfies (1) and $n \\geq 6$. Since $m \\mid 2 \\cdot 3^{n}=m\\left(2^{n+1}-1\\right)-m^{2}$, we have $m=3^{p}$ with some $0 \\leq p \\leq n$ or $m=2 \\cdot 3^{q}$ with some $0 \\leq q \\leq n$.\n\nIn the first case, let $q=n-p$; then\n\n$$\n2^{n+1}-1=m+\\frac{2 \\cdot 3^{n}}{m}=3^{p}+2 \\cdot 3^{q}\n$$\n\nIn the second case let $p=n-q$. Then\n\n$$\n2^{n+1}-1=m+\\frac{2 \\cdot 3^{n}}{m}=2 \\cdot 3^{q}+3^{p}\n$$\n\nHence, in both cases we need to find the nonnegative integer solutions of\n\n$$\n3^{p}+2 \\cdot 3^{q}=2^{n+1}-1, \\quad p+q=n .\n\\tag{2}\n$$\n\nNext, we prove bounds for $p, q$. From (2) we get\n\n$$\n3^{p}<2^{n+1}=8^{\\frac{n+1}{3}}<9^{\\frac{n+1}{3}}=3^{\\frac{2(n+1)}{3}}\n$$\n\nand\n\n$$\n2 \\cdot 3^{q}<2^{n+1}=2 \\cdot 8^{\\frac{n}{3}}<2 \\cdot 9^{\\frac{n}{3}}=2 \\cdot 3^{\\frac{2 n}{3}}<2 \\cdot 3^{\\frac{2(n+1)}{3}}\n$$\n\nso $p, q<\\frac{2(n+1)}{3}$. Combining these inequalities with $p+q=n$, we obtain\n\n$$\n\\frac{n-2}{3}<p, q<\\frac{2(n+1)}{3}\n\\tag{3}\n$$\n\nNow let $h=\\min (p, q)$. By (3) we have $h>\\frac{n-2}{3}$; in particular, we have $h>1$. On the left-hand side of (2), both terms are divisible by $3^{h}$, therefore $9\\left|3^{h}\\right| 2^{n+1}-1$. It is easy check that $\\operatorname{ord}_{9}(2)=6$, so $9 \\mid 2^{n+1}-1$ if and only if $6 \\mid n+1$. Therefore, $n+1=6 r$ for some positive integer $r$, and we can write\n\n$$\n2^{n+1}-1=4^{3 r}-1=\\left(4^{2 r}+4^{r}+1\\right)\\left(2^{r}-1\\right)\\left(2^{r}+1\\right)\n\\tag{4}\n$$\n\n\n\nNotice that the factor $4^{2 r}+4^{r}+1=\\left(4^{r}-1\\right)^{2}+3 \\cdot 4^{r}$ is divisible by 3 , but it is never divisible by 9 . The other two factors in (4), $2^{r}-1$ and $2^{r}+1$ are coprime: both are odd and their difference is 2 . Since the whole product is divisible by $3^{h}$, we have either $3^{h-1} \\mid 2^{r}-1$ or $3^{h-1} \\mid 2^{r}+1$. In any case, we have $3^{h-1} \\leq 2^{r}+1$. Then\n\n$$\n\\begin{gathered}\n3^{h-1} \\leq 2^{r}+1 \\leq 3^{r}=3^{\\frac{n+1}{6}} \\\\\n\\frac{n-2}{3}-1<h-1 \\leq \\frac{n+1}{6} \\\\\nn<11 .\n\\end{gathered}\n$$\n\nBut this is impossible since we assumed $n \\geq 6$, and we proved $6 \\mid n+1$."
] | $(6,3),(9,3),(9,5),(54,5)$ |
1,738 | Number Theory | null | $\boxed{5}$ | [
"5"
] | false | null | Numerical | null | Find the smallest number $n$ such that there exist polynomials $f_{1}, f_{2}, \ldots, f_{n}$ with rational coefficients satisfying
$$
x^{2}+7=f_{1}(x)^{2}+f_{2}(x)^{2}+\cdots+f_{n}(x)^{2} .
$$ | [
"The equality $x^{2}+7=x^{2}+2^{2}+1^{2}+1^{2}+1^{2}$ shows that $n \\leq 5$. It remains to show that $x^{2}+7$ is not a sum of four (or less) squares of polynomials with rational coefficients.\n\nSuppose by way of contradiction that $x^{2}+7=f_{1}(x)^{2}+f_{2}(x)^{2}+f_{3}(x)^{2}+f_{4}(x)^{2}$, where the coefficients of polynomials $f_{1}, f_{2}, f_{3}$ and $f_{4}$ are rational (some of these polynomials may be zero).\n\nClearly, the degrees of $f_{1}, f_{2}, f_{3}$ and $f_{4}$ are at most 1 . Thus $f_{i}(x)=a_{i} x+b_{i}$ for $i=1,2,3,4$ and some rationals $a_{1}, b_{1}, a_{2}, b_{2}, a_{3}, b_{3}, a_{4}, b_{4}$. It follows that $x^{2}+7=\\sum_{i=1}^{4}\\left(a_{i} x+b_{i}\\right)^{2}$ and hence\n\n$$\n\\sum_{i=1}^{4} a_{i}^{2}=1, \\quad \\sum_{i=1}^{4} a_{i} b_{i}=0, \\quad \\sum_{i=1}^{4} b_{i}^{2}=7\n\\tag{1}\n$$\n\nLet $p_{i}=a_{i}+b_{i}$ and $q_{i}=a_{i}-b_{i}$ for $i=1,2,3,4$. Then\n\n$$\n\\begin{aligned}\n\\sum_{i=1}^{4} p_{i}^{2} & =\\sum_{i=1}^{4} a_{i}^{2}+2 \\sum_{i=1}^{4} a_{i} b_{i}+\\sum_{i=1}^{4} b_{i}^{2}=8, \\\\\n\\sum_{i=1}^{4} q_{i}^{2} & =\\sum_{i=1}^{4} a_{i}^{2}-2 \\sum_{i=1}^{4} a_{i} b_{i}+\\sum_{i=1}^{4} b_{i}^{2}=8 \\\\\n\\text { and } \\sum_{i=1}^{4} p_{i} q_{i} & =\\sum_{i=1}^{4} a_{i}^{2}-\\sum_{i=1}^{4} b_{i}^{2}=-6,\n\\end{aligned}\n$$\n\nwhich means that there exist a solution in integers $x_{1}, y_{1}, x_{2}, y_{2}, x_{3}, y_{3}, x_{4}, y_{4}$ and $m>0$ of the system of equations\n(i) $\\sum_{i=1}^{4} x_{i}^{2}=8 m^{2}$\n(ii) $\\sum_{i=1}^{4} y_{i}^{2}=8 m^{2}$\n(iii) $\\sum_{i=1}^{4} x_{i} y_{i}=-6 m^{2}$.\n\nWe will show that such a solution does not exist.\n\nAssume the contrary and consider a solution with minimal $m$. Note that if an integer $x$ is odd then $x^{2} \\equiv 1(\\bmod 8)$. Otherwise (i.e., if $x$ is even) we have $x^{2} \\equiv 0(\\bmod 8)$ or $x^{2} \\equiv 4$ $(\\bmod 8)$. Hence, by $(\\mathrm{i})$, we get that $x_{1}, x_{2}, x_{3}$ and $x_{4}$ are even. Similarly, by (ii), we get that $y_{1}, y_{2}, y_{3}$ and $y_{4}$ are even. Thus the LHS of (iii) is divisible by 4 and $m$ is also even. It follows that $\\left(\\frac{x_{1}}{2}, \\frac{y_{1}}{2}, \\frac{x_{2}}{2}, \\frac{y_{2}}{2}, \\frac{x_{3}}{2}, \\frac{y_{3}}{2}, \\frac{x_{4}}{2}, \\frac{y_{4}}{2}, \\frac{m}{2}\\right)$ is a solution of the system of equations (i), (ii) and (iii), which contradicts the minimality of $m$."
] | 5 |
1,747 | Algebra | null | $\boxed{M=\frac{9}{32} \sqrt{2}}$ | [
"$M=\\frac{9}{32} \\sqrt{2}$"
] | false | null | Numerical | null | Determine the smallest number $M$ such that the inequality
$$
\left|a b\left(a^{2}-b^{2}\right)+b c\left(b^{2}-c^{2}\right)+c a\left(c^{2}-a^{2}\right)\right| \leq M\left(a^{2}+b^{2}+c^{2}\right)^{2}
$$
holds for all real numbers $a, b, c$. | [
"We first consider the cubic polynomial\n\n$$\nP(t)=t b\\left(t^{2}-b^{2}\\right)+b c\\left(b^{2}-c^{2}\\right)+c t\\left(c^{2}-t^{2}\\right) .\n$$\n\nIt is easy to check that $P(b)=P(c)=P(-b-c)=0$, and therefore\n\n$$\nP(t)=(b-c)(t-b)(t-c)(t+b+c)\n$$\n\nsince the cubic coefficient is $b-c$. The left-hand side of the proposed inequality can therefore be written in the form\n\n$$\n\\left|a b\\left(a^{2}-b^{2}\\right)+b c\\left(b^{2}-c^{2}\\right)+c a\\left(c^{2}-a^{2}\\right)\\right|=|P(a)|=|(b-c)(a-b)(a-c)(a+b+c)| .\n$$\n\nThe problem comes down to finding the smallest number $M$ that satisfies the inequality\n\n$$\n|(b-c)(a-b)(a-c)(a+b+c)| \\leq M \\cdot\\left(a^{2}+b^{2}+c^{2}\\right)^{2} . \\tag{1}\n$$\n\nNote that this expression is symmetric, and we can therefore assume $a \\leq b \\leq c$ without loss of generality. With this assumption,\n\n$$\n|(a-b)(b-c)|=(b-a)(c-b) \\leq\\left(\\frac{(b-a)+(c-b)}{2}\\right)^{2}=\\frac{(c-a)^{2}}{4} \\tag{2}\n$$\n\nwith equality if and only if $b-a=c-b$, i.e. $2 b=a+c$. Also\n\n$$\n\\left(\\frac{(c-b)+(b-a)}{2}\\right)^{2} \\leq \\frac{(c-b)^{2}+(b-a)^{2}}{2} \\tag{3}\n$$\n\nor equivalently,\n\n$$\n3(c-a)^{2} \\leq 2 \\cdot\\left[(b-a)^{2}+(c-b)^{2}+(c-a)^{2}\\right]\n$$\n\nagain with equality only for $2 b=a+c$. From (2) and (3) we get\n\n$$\n\\begin{aligned}\n& |(b-c)(a-b)(a-c)(a+b+c)| \\\\\n\\leq & \\frac{1}{4} \\cdot\\left|(c-a)^{3}(a+b+c)\\right| \\\\\n= & \\frac{1}{4} \\cdot \\sqrt{(c-a)^{6}(a+b+c)^{2}} \\\\\n\\leq & \\frac{1}{4} \\cdot \\sqrt{\\left(\\frac{2 \\cdot\\left[(b-a)^{2}+(c-b)^{2}+(c-a)^{2}\\right]}{3}\\right)^{3} \\cdot(a+b+c)^{2}} \\\\\n= & \\frac{\\sqrt{2}}{2} \\cdot\\left(\\sqrt[4]{\\left(\\frac{(b-a)^{2}+(c-b)^{2}+(c-a)^{2}}{3}\\right)^{3} \\cdot(a+b+c)^{2}}\\right)^{2} .\n\\end{aligned}\n$$\n\n\n\nBy the weighted AM-GM inequality this estimate continues as follows:\n\n$$\n\\begin{aligned}\n& |(b-c)(a-b)(a-c)(a+b+c)| \\\\\n\\leq & \\frac{\\sqrt{2}}{2} \\cdot\\left(\\frac{(b-a)^{2}+(c-b)^{2}+(c-a)^{2}+(a+b+c)^{2}}{4}\\right)^{2} \\\\\n= & \\frac{9 \\sqrt{2}}{32} \\cdot\\left(a^{2}+b^{2}+c^{2}\\right)^{2} .\n\\end{aligned}\n$$\n\nWe see that the inequality (1) is satisfied for $M=\\frac{9}{32} \\sqrt{2}$, with equality if and only if $2 b=a+c$ and\n\n$$\n\\frac{(b-a)^{2}+(c-b)^{2}+(c-a)^{2}}{3}=(a+b+c)^{2}\n$$\n\nPlugging $b=(a+c) / 2$ into the last equation, we bring it to the equivalent form\n\n$$\n2(c-a)^{2}=9(a+c)^{2} .\n$$\n\nThe conditions for equality can now be restated as\n\n$$\n2 b=a+c \\quad \\text { and } \\quad(c-a)^{2}=18 b^{2} .\n$$\n\nSetting $b=1$ yields $a=1-\\frac{3}{2} \\sqrt{2}$ and $c=1+\\frac{3}{2} \\sqrt{2}$. We see that $M=\\frac{9}{32} \\sqrt{2}$ is indeed the smallest constant satisfying the inequality, with equality for any triple $(a, b, c)$ proportional to $\\left(1-\\frac{3}{2} \\sqrt{2}, 1,1+\\frac{3}{2} \\sqrt{2}\\right)$, up to permutation.\n\n"
] | $M=\frac{9}{32} \sqrt{2}$ |
1,750 | Combinatorics | null | $\boxed{1003}$ | [
"$1003$"
] | false | null | Numerical | null | A diagonal of a regular 2006-gon is called odd if its endpoints divide the boundary into two parts, each composed of an odd number of sides. Sides are also regarded as odd diagonals.
Suppose the 2006-gon has been dissected into triangles by 2003 nonintersecting diagonals. Find the maximum possible number of isosceles triangles with two odd sides. | [
"Call an isosceles triangle odd if it has two odd sides. Suppose we are given a dissection as in the problem statement. A triangle in the dissection which is odd and isosceles will be called iso-odd for brevity.\n\nLemma. Let $A B$ be one of dissecting diagonals and let $\\mathcal{L}$ be the shorter part of the boundary of the 2006-gon with endpoints $A, B$. Suppose that $\\mathcal{L}$ consists of $n$ segments. Then the number of iso-odd triangles with vertices on $\\mathcal{L}$ does not exceed $n / 2$.\n\nProof. This is obvious for $n=2$. Take $n$ with $2<n \\leq 1003$ and assume the claim to be true for every $\\mathcal{L}$ of length less than $n$. Let now $\\mathcal{L}$ (endpoints $A, B$ ) consist of $n$ segments. Let $P Q$ be the longest diagonal which is a side of an iso-odd triangle $P Q S$ with all vertices on $\\mathcal{L}$ (if there is no such triangle, there is nothing to prove). Every triangle whose vertices lie on $\\mathcal{L}$ is obtuse or right-angled; thus $S$ is the summit of $P Q S$. We may assume that the five points $A, P, S, Q, B$ lie on $\\mathcal{L}$ in this order and partition $\\mathcal{L}$ into four pieces $\\mathcal{L}_{A P}, \\mathcal{L}_{P S}, \\mathcal{L}_{S Q}, \\mathcal{L}_{Q B}$ (the outer ones possibly reducing to a point).\n\nBy the definition of $P Q$, an iso-odd triangle cannot have vertices on both $\\mathcal{L}_{A P}$ and $\\mathcal{L}_{Q B}$. Therefore every iso-odd triangle within $\\mathcal{L}$ has all its vertices on just one of the four pieces. Applying to each of these pieces the induction hypothesis and adding the four inequalities we get that the number of iso-odd triangles within $\\mathcal{L}$ other than $P Q S$ does not exceed $n / 2$. And since each of $\\mathcal{L}_{P S}, \\mathcal{L}_{S Q}$ consists of an odd number of sides, the inequalities for these two pieces are actually strict, leaving a $1 / 2+1 / 2$ in excess. Hence the triangle $P S Q$ is also covered by the estimate $n / 2$. This concludes the induction step and proves the lemma.\n\nThe remaining part of the solution in fact repeats the argument from the above proof. Consider the longest dissecting diagonal $X Y$. Let $\\mathcal{L}_{X Y}$ be the shorter of the two parts of the boundary with endpoints $X, Y$ and let $X Y Z$ be the triangle in the dissection with vertex $Z$ not on $\\mathcal{L}_{X Y}$. Notice that $X Y Z$ is acute or right-angled, otherwise one of the segments $X Z, Y Z$ would be longer than $X Y$. Denoting by $\\mathcal{L}_{X Z}, \\mathcal{L}_{Y Z}$ the two pieces defined by $Z$ and applying the lemma to each of $\\mathcal{L}_{X Y}, \\mathcal{L}_{X Z}, \\mathcal{L}_{Y Z}$ we infer that there are no more than 2006/2 iso-odd triangles in all, unless $X Y Z$ is one of them. But in that case $X Z$ and $Y Z$ are odd diagonals and the corresponding inequalities are strict. This shows that also in this case the total number of iso-odd triangles in the dissection, including $X Y Z$, is not greater than 1003.\n\nThis bound can be achieved. For this to happen, it just suffices to select a vertex of the 2006-gon and draw a broken line joining every second vertex, starting from the selected one. Since 2006 is even, the line closes. This already gives us the required 1003 iso-odd triangles. Then we can complete the triangulation in an arbitrary fashion.",
"Let the terms odd triangle and iso-odd triangle have the same meaning as in the first solution.\n\nLet $A B C$ be an iso-odd triangle, with $A B$ and $B C$ odd sides. This means that there are an odd number of sides of the 2006-gon between $A$ and $B$ and also between $B$ and $C$. We say that these sides belong to the iso-odd triangle $A B C$.\n\nAt least one side in each of these groups does not belong to any other iso-odd triangle. This is so because any odd triangle whose vertices are among the points between $A$ and $B$ has two sides of equal length and therefore has an even number of sides belonging to it in total. Eliminating all sides belonging to any other iso-odd triangle in this area must therefore leave one side that belongs to no other iso-odd triangle. Let us assign these two sides (one in each group) to the triangle $A B C$.\n\nTo each iso-odd triangle we have thus assigned a pair of sides, with no two triangles sharing an assigned side. It follows that at most 1003 iso-odd triangles can appear in the dissection.\n\nThis value can be attained, as shows the example from the first solution."
] | $1003$ |
1,760 | Geometry | null | $\boxed{\angle B E A_{1}=90$,$\angle A E B_{1}=90}$ | [
"$\\angle B E A_{1}=90$,$\\angle A E B_{1}=90$"
] | true | ^{\circ} | Numerical | null | In triangle $A B C$, let $J$ be the centre of the excircle tangent to side $B C$ at $A_{1}$ and to the extensions of sides $A C$ and $A B$ at $B_{1}$ and $C_{1}$, respectively. Suppose that the lines $A_{1} B_{1}$ and $A B$ are perpendicular and intersect at $D$. Let $E$ be the foot of the perpendicular from $C_{1}$ to line $D J$. Determine the angles $\angle B E A_{1}$ and $\angle A E B_{1}$. | [
"Let $K$ be the intersection point of lines $J C$ and $A_{1} B_{1}$. Obviously $J C \\perp A_{1} B_{1}$ and since $A_{1} B_{1} \\perp A B$, the lines $J K$ and $C_{1} D$ are parallel and equal. From the right triangle $B_{1} C J$ we obtain $J C_{1}^{2}=J B_{1}^{2}=J C \\cdot J K=J C \\cdot C_{1} D$ from which we infer that $D C_{1} / C_{1} J=C_{1} J / J C$ and the right triangles $D C_{1} J$ and $C_{1} J C$ are similar. Hence $\\angle C_{1} D J=\\angle J C_{1} C$, which implies that the lines $D J$ and $C_{1} C$ are perpendicular, i.e. the points $C_{1}, E, C$ are collinear.\n\n<img_3975>\n\nSince $\\angle C A_{1} J=\\angle C B_{1} J=\\angle C E J=90^{\\circ}$, points $A_{1}, B_{1}$ and $E$ lie on the circle of diameter $C J$. Then $\\angle D B A_{1}=\\angle A_{1} C J=\\angle D E A_{1}$, which implies that quadrilateral $B E A_{1} D$ is cyclic; therefore $\\angle A_{1} E B=90^{\\circ}$.\n\nQuadrilateral $A D E B_{1}$ is also cyclic because $\\angle E B_{1} A=\\angle E J C=\\angle E D C_{1}$, therefore we obtain $\\angle A E B_{1}=\\angle A D B=90^{\\circ}$.\n\n<img_3438>",
"Consider the circles $\\omega_{1}, \\omega_{2}$ and $\\omega_{3}$ of diameters $C_{1} D, A_{1} B$ and $A B_{1}$, respectively. Line segments $J C_{1}, J B_{1}$ and $J A_{1}$ are tangents to those circles and, due to the right angle at $D$, $\\omega_{2}$ and $\\omega_{3}$ pass through point $D$. Since $\\angle C_{1} E D$ is a right angle, point $E$ lies on circle $\\omega_{1}$, therefore\n\n$$\nJ C_{1}^{2}=J D \\cdot J E\n$$\n\nSince $J A_{1}=J B_{1}=J C_{1}$ are all radii of the excircle, we also have\n\n$$\nJ A_{1}^{2}=J D \\cdot J E \\quad \\text { and } \\quad J B_{1}^{2}=J D \\cdot J E .\n$$\n\nThese equalities show that $E$ lies on circles $\\omega_{2}$ and $\\omega_{3}$ as well, so $\\angle B E A_{1}=\\angle A E B_{1}=90^{\\circ}$.\n\n### solution_2\nFirst note that $A_{1} B_{1}$ is perpendicular to the external angle bisector $C J$ of $\\angle B C A$ and parallel to the internal angle bisector of that angle. Therefore, $A_{1} B_{1}$ is perpendicular to $A B$ if and only if triangle $A B C$ is isosceles, $A C=B C$. In that case the external bisector $C J$ is parallel to $A B$.\n\nTriangles $A B C$ and $B_{1} A_{1} J$ are similar, as their corresponding sides are perpendicular. In particular, we have $\\angle D A_{1} J=\\angle C_{1} B A_{1}$; moreover, from cyclic deltoid $J A_{1} B C_{1}$,\n\n$$\n\\angle C_{1} A_{1} J=\\angle C_{1} B J=\\frac{1}{2} \\angle C_{1} B A_{1}=\\frac{1}{2} \\angle D A_{1} J\n$$\n\nTherefore, $A_{1} C_{1}$ bisects angle $\\angle D A_{1} J$.\n\n<img_3155>\n\nIn triangle $B_{1} A_{1} J$, line $J C_{1}$ is the external bisector at vertex $J$. The point $C_{1}$ is the intersection of two external angle bisectors (at $A_{1}$ and $J$ ) so $C_{1}$ is the centre of the excircle $\\omega$, tangent to side $A_{1} J$, and to the extension of $B_{1} A_{1}$ at point $D$.\n\nNow consider the similarity transform $\\varphi$ which moves $B_{1}$ to $A, A_{1}$ to $B$ and $J$ to $C$. This similarity can be decomposed into a rotation by $90^{\\circ}$ around a certain point $O$ and a homothety from the same centre. This similarity moves point $C_{1}$ (the centre of excircle $\\omega$ ) to $J$ and moves $D$ (the point of tangency) to $C_{1}$.\n\nSince the rotation angle is $90^{\\circ}$, we have $\\angle X O \\varphi(X)=90^{\\circ}$ for an arbitrary point $X \\neq O$. For $X=D$ and $X=C_{1}$ we obtain $\\angle D O C_{1}=\\angle C_{1} O J=90^{\\circ}$. Therefore $O$ lies on line segment $D J$ and $C_{1} O$ is perpendicular to $D J$. This means that $O=E$.\n\nFor $X=A_{1}$ and $X=B_{1}$ we obtain $\\angle A_{1} O B=\\angle B_{1} O A=90^{\\circ}$, i.e.\n\n$$\n\\angle B E A_{1}=\\angle A E B_{1}=90^{\\circ} .\n$$"
] | $\angle B E A_{1}=90$,$\angle A E B_{1}=90$ |
1,766 | Number Theory | null | $\boxed{(0,2),(0,-2),(4,23),(4,-23)}$ | [
"$(0,2),(0,-2),(4,23),(4,-23)$"
] | true | null | Tuple | null | Determine all pairs $(x, y)$ of integers satisfying the equation
$$
1+2^{x}+2^{2 x+1}=y^{2}
$$ | [
"If $(x, y)$ is a solution then obviously $x \\geq 0$ and $(x,-y)$ is a solution too. For $x=0$ we get the two solutions $(0,2)$ and $(0,-2)$.\n\nNow let $(x, y)$ be a solution with $x>0$; without loss of generality confine attention to $y>0$. The equation rewritten as\n\n$$\n2^{x}\\left(1+2^{x+1}\\right)=(y-1)(y+1)\n$$\n\nshows that the factors $y-1$ and $y+1$ are even, exactly one of them divisible by 4 . Hence $x \\geq 3$ and one of these factors is divisible by $2^{x-1}$ but not by $2^{x}$. So\n\n$$\ny=2^{x-1} m+\\epsilon, \\quad m \\text { odd }, \\quad \\epsilon= \\pm 1\\tag{1}\n$$\n\nPlugging this into the original equation we obtain\n\n$$\n2^{x}\\left(1+2^{x+1}\\right)=\\left(2^{x-1} m+\\epsilon\\right)^{2}-1=2^{2 x-2} m^{2}+2^{x} m \\epsilon,\n$$\n\nor, equivalently\n\n$$\n1+2^{x+1}=2^{x-2} m^{2}+m \\epsilon .\n$$\n\nTherefore\n\n$$\n1-\\epsilon m=2^{x-2}\\left(m^{2}-8\\right) .\\tag{2}\n$$\n\nFor $\\epsilon=1$ this yields $m^{2}-8 \\leq 0$, i.e., $m=1$, which fails to satisfy (2).\n\nFor $\\epsilon=-1$ equation (2) gives us\n\n$$\n1+m=2^{x-2}\\left(m^{2}-8\\right) \\geq 2\\left(m^{2}-8\\right),\n$$\n\nimplying $2 m^{2}-m-17 \\leq 0$. Hence $m \\leq 3$; on the other hand $m$ cannot be 1 by $(2)$. Because $m$ is odd, we obtain $m=3$, leading to $x=4$. From (1) we get $y=23$. These values indeed satisfy the given equation. Recall that then $y=-23$ is also good. Thus we have the complete list of solutions $(x, y):(0,2),(0,-2),(4,23),(4,-23)$."
] | $(0,2),(0,-2),(4,23),(4,-23)$ |
1,775 | Algebra | null | $\boxed{\left\lfloor\log _{2} n\right\rfloor+1}$ | [
"$\\left\\lfloor\\log _{2} n\\right\\rfloor+1$"
] | false | null | Expression | null | Given a positive integer $n$, find the smallest value of $\left\lfloor\frac{a_{1}}{1}\right\rfloor+\left\lfloor\frac{a_{2}}{2}\right\rfloor+\cdots+\left\lfloor\frac{a_{n}}{n}\right\rfloor$ over all permutations $\left(a_{1}, a_{2}, \ldots, a_{n}\right)$ of $(1,2, \ldots, n)$. | [
"Suppose that $2^{k} \\leqslant n<2^{k+1}$ with some nonnegative integer $k$. First we show a permutation $\\left(a_{1}, a_{2}, \\ldots, a_{n}\\right)$ such that $\\left\\lfloor\\frac{a_{1}}{1}\\right\\rfloor+\\left\\lfloor\\frac{a_{2}}{2}\\right\\rfloor+\\cdots+\\left\\lfloor\\frac{a_{n}}{n}\\right\\rfloor=k+1$; then we will prove that $\\left\\lfloor\\frac{a_{1}}{1}\\right\\rfloor+\\left\\lfloor\\frac{a_{2}}{2}\\right\\rfloor+\\cdots+\\left\\lfloor\\frac{a_{n}}{n}\\right\\rfloor \\geqslant k+1$ for every permutation. Hence, the minimal possible value will be $k+1$.\n\nI. Consider the permutation\n\n$$\n\\begin{gathered}\n\\left(a_{1}\\right)=(1), \\quad\\left(a_{2}, a_{3}\\right)=(3,2), \\quad\\left(a_{4}, a_{5}, a_{6}, a_{7}\\right)=(7,4,5,6), \\\\\n\\left(a_{2^{k-1}}, \\ldots, a_{2^{k}-1}\\right)=\\left(2^{k}-1,2^{k-1}, 2^{k-1}+1, \\ldots, 2^{k}-2\\right), \\\\\n\\left(a_{2^{k}}, \\ldots, a_{n}\\right)=\\left(n, 2^{k}, 2^{k}+1, \\ldots, n-1\\right) .\n\\end{gathered}\n$$\n\nThis permutation consists of $k+1$ cycles. In every cycle $\\left(a_{p}, \\ldots, a_{q}\\right)=(q, p, p+1, \\ldots, q-1)$ we have $q<2 p$, so\n\n$$\n\\sum_{i=p}^{q}\\left\\lfloor\\frac{a_{i}}{i}\\right\\rfloor=\\left\\lfloor\\frac{q}{p}\\right\\rfloor+\\sum_{i=p+1}^{q}\\left\\lfloor\\frac{i-1}{i}\\right\\rfloor=1\n$$\n\nThe total sum over all cycles is precisely $k+1$.\n\nII. In order to establish the lower bound, we prove a more general statement.\n\nClaim. If $b_{1}, \\ldots, b_{2^{k}}$ are distinct positive integers then\n\n$$\n\\sum_{i=1}^{2^{k}}\\left\\lfloor\\frac{b_{i}}{i}\\right\\rfloor \\geqslant k+1\n$$\n\nFrom the Claim it follows immediately that $\\sum_{i=1}^{n}\\left\\lfloor\\frac{a_{i}}{i}\\right\\rfloor \\geqslant \\sum_{i=1}^{2^{k}}\\left\\lfloor\\frac{a_{i}}{i}\\right\\rfloor \\geqslant k+1$.\n\nProof of the Claim. Apply induction on $k$. For $k=1$ the claim is trivial, $\\left\\lfloor\\frac{b_{1}}{1}\\right\\rfloor \\geqslant 1$. Suppose the Claim holds true for some positive integer $k$, and consider $k+1$.\n\nIf there exists an index $j$ such that $2^{k}<j \\leqslant 2^{k+1}$ and $b_{j} \\geqslant j$ then\n\n$$\n\\sum_{i=1}^{2^{k+1}}\\left\\lfloor\\frac{b_{i}}{i}\\right\\rfloor \\geqslant \\sum_{i=1}^{2^{k}}\\left\\lfloor\\frac{b_{i}}{i}\\right\\rfloor+\\left\\lfloor\\frac{b_{j}}{j}\\right\\rfloor \\geqslant(k+1)+1\n$$\n\nby the induction hypothesis, so the Claim is satisfied.\n\nOtherwise we have $b_{j}<j \\leqslant 2^{k+1}$ for every $2^{k}<j \\leqslant 2^{k+1}$. Among the $2^{k+1}$ distinct numbers $b_{1}, \\ldots, b_{2^{k+1}}$ there is some $b_{m}$ which is at least $2^{k+1}$; that number must be among $b_{1} \\ldots, b_{2^{k}}$. Hence, $1 \\leqslant m \\leqslant 2^{k}$ and $b_{m} \\geqslant 2^{k+1}$.\n\nWe will apply the induction hypothesis to the numbers\n\n$$\nc_{1}=b_{1}, \\ldots, c_{m-1}=b_{m-1}, \\quad c_{m}=b_{2^{k}+1}, \\quad c_{m+1}=b_{m+1}, \\ldots, c_{2^{k}}=b_{2^{k}}\n$$\n\nso take the first $2^{k}$ numbers but replace $b_{m}$ with $b_{2^{k}+1}$. Notice that\n\n$$\n\\left\\lfloor\\frac{b_{m}}{m}\\right\\rfloor \\geqslant\\left\\lfloor\\frac{2^{k+1}}{m}\\right\\rfloor=\\left\\lfloor\\frac{2^{k}+2^{k}}{m}\\right\\rfloor \\geqslant\\left\\lfloor\\frac{b_{2^{k}+1}+m}{m}\\right\\rfloor=\\left\\lfloor\\frac{c_{m}}{m}\\right\\rfloor+1\n$$\n\n\n\nFor the other indices $i$ with $1 \\leqslant i \\leqslant 2^{k}, i \\neq m$ we have $\\left\\lfloor\\frac{b_{i}}{i}\\right\\rfloor=\\left\\lfloor\\frac{c_{i}}{i}\\right\\rfloor$, so\n\n$$\n\\sum_{i=1}^{2^{k+1}}\\left\\lfloor\\frac{b_{i}}{i}\\right\\rfloor=\\sum_{i=1}^{2^{k}}\\left\\lfloor\\frac{b_{i}}{i}\\right\\rfloor \\geqslant \\sum_{i=1}^{2^{k}}\\left\\lfloor\\frac{c_{i}}{i}\\right\\rfloor+1 \\geqslant(k+1)+1\n$$\n\nThat proves the Claim and hence completes the solution.",
"Assume $2^{k} \\leqslant n<2^{k+1}$, and let $P=\\left\\{2^{0}, 2^{1}, \\ldots, 2^{k}\\right\\}$ be the set of powers of 2 among $1,2, \\ldots, n$. Call an integer $i \\in\\{1,2, \\ldots, n\\}$ and the interval $\\left[i, a_{i}\\right]$ good if $a_{i} \\geqslant i$.\n\nLemma 1. The good intervals cover the integers $1,2, \\ldots, n$.\n\nProof. Consider an arbitrary $x \\in\\{1,2 \\ldots, n\\}$; we want to find a good interval $\\left[i, a_{i}\\right]$ that covers $x$; i.e., $i \\leqslant x \\leqslant a_{i}$. Take the cycle of the permutation that contains $x$, that is $\\left(x, a_{x}, a_{a_{x}}, \\ldots\\right)$. In this cycle, let $i$ be the first element with $a_{i} \\geqslant x$; then $i \\leqslant x \\leqslant a_{i}$.\n\nLemma 2. If a good interval $\\left[i, a_{i}\\right]$ covers $p$ distinct powers of 2 then $\\left\\lfloor\\frac{a_{i}}{i}\\right\\rfloor \\geqslant p$; more formally, $\\left\\lfloor\\frac{a_{i}}{i}\\right\\rfloor \\geqslant\\left|\\left[i, a_{i}\\right] \\cap P\\right|$.\n\nProof. The ratio of the smallest and largest powers of 2 in the interval is at least $2^{p-1}$. By Bernoulli's inequality, $\\frac{a_{i}}{i} \\geqslant 2^{p-1} \\geqslant p$; that proves the lemma.\n\nNow, by Lemma 1, the good intervals cover $P$. By applying Lemma 2 as well, we obtain that\n\n$$\n\\sum_{i=1}^{n}\\left\\lfloor\\frac{a_{i}}{i}\\right\\rfloor=\\sum_{i \\text { is good }}^{n}\\left\\lfloor\\frac{a_{i}}{i}\\right\\rfloor \\geqslant \\sum_{i \\text { is good }}^{n}\\left|\\left[i, a_{i}\\right] \\cap P\\right| \\geqslant|P|=k+1\n$$",
"We show proof based on the following inequality.\n\nLemma 3. \n\n$$\n\\left\\lfloor\\frac{a}{b}\\right\\rfloor \\geqslant \\log _{2} \\frac{a+1}{b}\n$$\n\nfor every pair $a, b$ of positive integers.\n\nProof. Let $t=\\left\\lfloor\\frac{a}{b}\\right\\rfloor$, so $t \\leqslant \\frac{a}{b}$ and $\\frac{a+1}{b} \\leqslant t+1$. By applying the inequality $2^{t} \\geqslant t+1$, we obtain\n\n$$\n\\left\\lfloor\\frac{a}{b}\\right\\rfloor=t \\geqslant \\log _{2}(t+1) \\geqslant \\log _{2} \\frac{a+1}{b}\n$$\n\nBy applying the lemma to each term, we get\n\n$$\n\\sum_{i=1}^{n}\\left\\lfloor\\frac{a_{i}}{i}\\right\\rfloor \\geqslant \\sum_{i=1}^{n} \\log _{2} \\frac{a_{i}+1}{i}=\\sum_{i=1}^{n} \\log _{2}\\left(a_{i}+1\\right)-\\sum_{i=1}^{n} \\log _{2} i\n$$\n\nNotice that the numbers $a_{1}+1, a_{2}+1, \\ldots, a_{n}+1$ form a permutation of $2,3, \\ldots, n+1$. Hence, in the last two sums all terms cancel out, except for $\\log _{2}(n+1)$ in the first sum and $\\log _{2} 1=0$ in the second sum. Therefore,\n\n$$\n\\sum_{i=1}^{n}\\left\\lfloor\\frac{a_{i}}{i}\\right\\rfloor \\geqslant \\log _{2}(n+1)>k\n$$\n\nAs the left-hand side is an integer, it must be at least $k+1$."
] | $\left\lfloor\log _{2} n\right\rfloor+1$ |
1,782 | Combinatorics | null | $\boxed{m_{\max }=n^{2}-n-1}$ | [
"$m_{\\max }=n^{2}-n-1$"
] | false | null | Expression | null | Let $n \geqslant 3$ be an integer. An integer $m \geqslant n+1$ is called $n$-colourful if, given infinitely many marbles in each of $n$ colours $C_{1}, C_{2}, \ldots, C_{n}$, it is possible to place $m$ of them around a circle so that in any group of $n+1$ consecutive marbles there is at least one marble of colour $C_{i}$ for each $i=1, \ldots, n$.
Prove that there are only finitely many positive integers which are not $n$-colourful. Find the largest among them. | [
"First suppose that there are $n(n-1)-1$ marbles. Then for one of the colours, say blue, there are at most $n-2$ marbles, which partition the non-blue marbles into at most $n-2$ groups with at least $(n-1)^{2}>n(n-2)$ marbles in total. Thus one of these groups contains at least $n+1$ marbles and this group does not contain any blue marble.\n\nNow suppose that the total number of marbles is at least $n(n-1)$. Then we may write this total number as $n k+j$ with some $k \\geqslant n-1$ and with $0 \\leqslant j \\leqslant n-1$. We place around a circle $k-j$ copies of the colour sequence $[1,2,3, \\ldots, n]$ followed by $j$ copies of the colour sequence $[1,1,2,3, \\ldots, n]$."
] | $m_{\max }=n^{2}-n-1$ |
1,789 | Combinatorics | null | $\boxed{\frac{100!}{2^{50}}}$ | [
"$\\frac{100!}{2^{50}}$"
] | false | null | Expression | null | Determine the largest $N$ for which there exists a table $T$ of integers with $N$ rows and 100 columns that has the following properties:
(i) Every row contains the numbers 1,2, ., 100 in some order.
(ii) For any two distinct rows $r$ and $s$, there is a column $c$ such that $|T(r, c)-T(s, c)| \geqslant 2$.
Here $T(r, c)$ means the number at the intersection of the row $r$ and the column $c$. | [
"Non-existence of a larger table. Let us consider some fixed row in the table, and let us replace (for $k=1,2, \\ldots, 50$ ) each of two numbers $2 k-1$ and $2 k$ respectively by the symbol $x_{k}$. The resulting pattern is an arrangement of 50 symbols $x_{1}, x_{2}, \\ldots, x_{50}$, where every symbol occurs exactly twice. Note that there are $N=100 ! / 2^{50}$ distinct patterns $P_{1}, \\ldots, P_{N}$.\n\nIf two rows $r \\neq s$ in the table have the same pattern $P_{i}$, then $|T(r, c)-T(s, c)| \\leqslant 1$ holds for all columns $c$. As this violates property (ii) in the problem statement, different rows have different patterns. Hence there are at most $N=100 ! / 2^{50}$ rows.\n\nExistence of a table with $N$ rows. We construct the table by translating every pattern $P_{i}$ into a corresponding row with the numbers $1,2, \\ldots, 100$. We present a procedure that inductively replaces the symbols by numbers. The translation goes through steps $k=1,2, \\ldots, 50$ in increasing order and at step $k$ replaces the two occurrences of symbol $x_{k}$ by $2 k-1$ and $2 k$.\n\n- The left occurrence of $x_{1}$ is replaced by 1 , and its right occurrence is replaced by 2 .\n- For $k \\geqslant 2$, we already have the number $2 k-2$ somewhere in the row, and now we are looking for the places for $2 k-1$ and $2 k$. We make the three numbers $2 k-2,2 k-1,2 k$ show up (ordered from left to right) either in the order $2 k-2,2 k-1,2 k$, or as $2 k, 2 k-2,2 k-1$, or as $2 k-1,2 k, 2 k-2$. This is possible, since the number $2 k-2$ has been placed in the preceding step, and shows up before / between / after the two occurrences of the symbol $x_{k}$.\n\nWe claim that the $N$ rows that result from the $N$ patterns yield a table with the desired property (ii). Indeed, consider the $r$-th and the $s$-th row $(r \\neq s)$, which by construction result from patterns $P_{r}$ and $P_{s}$. Call a symbol $x_{i}$ aligned, if it occurs in the same two columns in $P_{r}$ and in $P_{s}$. Let $k$ be the largest index, for which symbol $x_{k}$ is not aligned. Note that $k \\geqslant 2$. Consider the column $c^{\\prime}$ with $T\\left(r, c^{\\prime}\\right)=2 k$ and the column $c^{\\prime \\prime}$ with $T\\left(s, c^{\\prime \\prime}\\right)=2 k$. Then $T\\left(r, c^{\\prime \\prime}\\right) \\leqslant 2 k$ and $T\\left(s, c^{\\prime}\\right) \\leqslant 2 k$, as all symbols $x_{i}$ with $i \\geqslant k+1$ are aligned.\n\n- If $T\\left(r, c^{\\prime \\prime}\\right) \\leqslant 2 k-2$, then $\\left|T\\left(r, c^{\\prime \\prime}\\right)-T\\left(s, c^{\\prime \\prime}\\right)\\right| \\geqslant 2$ as desired.\n- If $T\\left(s, c^{\\prime}\\right) \\leqslant 2 k-2$, then $\\left|T\\left(r, c^{\\prime}\\right)-T\\left(s, c^{\\prime}\\right)\\right| \\geqslant 2$ as desired.\n- If $T\\left(r, c^{\\prime \\prime}\\right)=2 k-1$ and $T\\left(s, c^{\\prime}\\right)=2 k-1$, then the symbol $x_{k}$ is aligned; contradiction.\n\nIn the only remaining case we have $c^{\\prime}=c^{\\prime \\prime}$, so that $T\\left(r, c^{\\prime}\\right)=T\\left(s, c^{\\prime}\\right)=2 k$ holds. Now let us consider the columns $d^{\\prime}$ and $d^{\\prime \\prime}$ with $T\\left(r, d^{\\prime}\\right)=2 k-1$ and $T\\left(s, d^{\\prime \\prime}\\right)=2 k-1$. Then $d \\neq d^{\\prime \\prime}$ (as the symbol $x_{k}$ is not aligned), and $T\\left(r, d^{\\prime \\prime}\\right) \\leqslant 2 k-2$ and $T\\left(s, d^{\\prime}\\right) \\leqslant 2 k-2$ (as all symbols $x_{i}$ with $i \\geqslant k+1$ are aligned).\n\n- If $T\\left(r, d^{\\prime \\prime}\\right) \\leqslant 2 k-3$, then $\\left|T\\left(r, d^{\\prime \\prime}\\right)-T\\left(s, d^{\\prime \\prime}\\right)\\right| \\geqslant 2$ as desired.\n- If $T\\left(s, c^{\\prime}\\right) \\leqslant 2 k-3$, then $\\left|T\\left(r, d^{\\prime}\\right)-T\\left(s, d^{\\prime}\\right)\\right| \\geqslant 2$ as desired.\n\nIn the only remaining case we have $T\\left(r, d^{\\prime \\prime}\\right)=2 k-2$ and $T\\left(s, d^{\\prime}\\right)=2 k-2$. Now the row $r$ has the numbers $2 k-2,2 k-1,2 k$ in the three columns $d^{\\prime}, d^{\\prime \\prime}, c^{\\prime}$. As one of these triples violates the ordering property of $2 k-2,2 k-1,2 k$, we have the final contradiction."
] | $\frac{100!}{2^{50}}$ |
1,798 | Number Theory | null | $\boxed{2}$ | [
"2"
] | false | null | Numerical | null | Determine all integers $n \geqslant 1$ for which there exists a pair of positive integers $(a, b)$ such that no cube of a prime divides $a^{2}+b+3$ and
$$
\frac{a b+3 b+8}{a^{2}+b+3}=n
$$ | [
"As $b \\equiv-a^{2}-3\\left(\\bmod a^{2}+b+3\\right)$, the numerator of the given fraction satisfies\n\n$$\na b+3 b+8 \\equiv a\\left(-a^{2}-3\\right)+3\\left(-a^{2}-3\\right)+8 \\equiv-(a+1)^{3} \\quad\\left(\\bmod a^{2}+b+3\\right)\n$$\n\nAs $a^{2}+b+3$ is not divisible by $p^{3}$ for any prime $p$, if $a^{2}+b+3$ divides $(a+1)^{3}$ then it does also divide $(a+1)^{2}$. Since\n\n$$\n0<(a+1)^{2}<2\\left(a^{2}+b+3\\right)\n$$\n\nwe conclude $(a+1)^{2}=a^{2}+b+3$. This yields $b=2(a-1)$ and $n=2$. The choice $(a, b)=(2,2)$ with $a^{2}+b+3=9$ shows that $n=2$ indeed is a solution."
] | 2 |
1,800 | Number Theory | null | $\boxed{1,3}$ | [
"1,3"
] | true | null | Numerical | null | Find all positive integers $n$ with the following property: the $k$ positive divisors of $n$ have a permutation $\left(d_{1}, d_{2}, \ldots, d_{k}\right)$ such that for every $i=1,2, \ldots, k$, the number $d_{1}+\cdots+d_{i}$ is a perfect square. | [
"For $i=1,2, \\ldots, k$ let $d_{1}+\\ldots+d_{i}=s_{i}^{2}$, and define $s_{0}=0$ as well. Obviously $0=s_{0}<s_{1}<s_{2}<\\ldots<s_{k}$, so\n\n$$\ns_{i} \\geqslant i \\quad \\text { and } \\quad d_{i}=s_{i}^{2}-s_{i-1}^{2}=\\left(s_{i}+s_{i-1}\\right)\\left(s_{i}-s_{i-1}\\right) \\geqslant s_{i}+s_{i-1} \\geqslant 2 i-1\n\\tag{1}\n$$\n\nThe number 1 is one of the divisors $d_{1}, \\ldots, d_{k}$ but, due to $d_{i} \\geqslant 2 i-1$, the only possibility is $d_{1}=1$.\n\nNow consider $d_{2}$ and $s_{2} \\geqslant 2$. By definition, $d_{2}=s_{2}^{2}-1=\\left(s_{2}-1\\right)\\left(s_{2}+1\\right)$, so the numbers $s_{2}-1$ and $s_{2}+1$ are divisors of $n$. In particular, there is some index $j$ such that $d_{j}=s_{2}+1$.\n\nNotice that\n\n$$\ns_{2}+s_{1}=s_{2}+1=d_{j} \\geqslant s_{j}+s_{j-1} ;\n\\tag{2}\n$$\n\nsince the sequence $s_{0}<s_{1}<\\ldots<s_{k}$ increases, the index $j$ cannot be greater than 2. Hence, the divisors $s_{2}-1$ and $s_{2}+1$ are listed among $d_{1}$ and $d_{2}$. That means $s_{2}-1=d_{1}=1$ and $s_{2}+1=d_{2} ;$ therefore $s_{2}=2$ and $d_{2}=3$.\n\nWe can repeat the above process in general.\n\nClaim. $d_{i}=2 i-1$ and $s_{i}=i$ for $i=1,2, \\ldots, k$.\n\nProof. Apply induction on $i$. The Claim has been proved for $i=1,2$. Suppose that we have already proved $d=1, d_{2}=3, \\ldots, d_{i}=2 i-1$, and consider the next divisor $d_{i+1}$ :\n\n$$\nd_{i+1}=s_{i+1}^{2}-s_{i}^{2}=s_{i+1}^{2}-i^{2}=\\left(s_{i+1}-i\\right)\\left(s_{i+1}+i\\right)\n$$\n\nThe number $s_{i+1}+i$ is a divisor of $n$, so there is some index $j$ such that $d_{j}=s_{i+1}+i$.\n\nSimilarly to (2), by (1) we have\n\n$$\ns_{i+1}+s_{i}=s_{i+1}+i=d_{j} \\geqslant s_{j}+s_{j-1}\n\\tag{3}\n$$\n\nsince the sequence $s_{0}<s_{1}<\\ldots<s_{k}$ increases, (3) forces $j \\leqslant i+1$. On the other hand, $d_{j}=s_{i+1}+i>2 i>d_{i}>d_{i-1}>\\ldots>d_{1}$, so $j \\leqslant i$ is not possible. The only possibility is $j=i+1$.\n\nHence,\n\n$$\n\\begin{gathered}\ns_{i+1}+i=d_{i+1}=s_{i+1}^{2}-s_{i}^{2}=s_{i+1}^{2}-i^{2} \\\\\ns_{i+1}^{2}-s_{i+1}=i(i+1) .\n\\end{gathered}\n$$\n\nBy solving this equation we get $s_{i+1}=i+1$ and $d_{i+1}=2 i+1$, that finishes the proof.\n\nNow we know that the positive divisors of the number $n$ are $1,3,5, \\ldots, n-2, n$. The greatest divisor is $d_{k}=2 k-1=n$ itself, so $n$ must be odd. The second greatest divisor is $d_{k-1}=n-2$; then $n-2$ divides $n=(n-2)+2$, so $n-2$ divides 2 . Therefore, $n$ must be 1 or 3 .\n\nThe numbers $n=1$ and $n=3$ obviously satisfy the requirements: for $n=1$ we have $k=1$ and $d_{1}=1^{2}$; for $n=3$ we have $k=2, d_{1}=1^{2}$ and $d_{1}+d_{2}=1+3=2^{2}$."
] | 1,3 |
1,807 | Algebra | null | $\boxed{-2,0,2}$ | [
"$-2,0,2$"
] | true | null | Numerical | null | Let $q$ be a real number. Gugu has a napkin with ten distinct real numbers written on it, and he writes the following three lines of real numbers on the blackboard:
- In the first line, Gugu writes down every number of the form $a-b$, where $a$ and $b$ are two (not necessarily distinct) numbers on his napkin.
- In the second line, Gugu writes down every number of the form $q a b$, where $a$ and $b$ are two (not necessarily distinct) numbers from the first line.
- In the third line, Gugu writes down every number of the form $a^{2}+b^{2}-c^{2}-d^{2}$, where $a, b, c, d$ are four (not necessarily distinct) numbers from the first line.
Determine all values of $q$ such that, regardless of the numbers on Gugu's napkin, every number in the second line is also a number in the third line. | [
"Call a number $q$ good if every number in the second line appears in the third line unconditionally. We first show that the numbers 0 and \\pm 2 are good. The third line necessarily contains 0 , so 0 is good. For any two numbers $a, b$ in the first line, write $a=x-y$ and $b=u-v$, where $x, y, u, v$ are (not necessarily distinct) numbers on the napkin. We may now write\n\n$$\n2 a b=2(x-y)(u-v)=(x-v)^{2}+(y-u)^{2}-(x-u)^{2}-(y-v)^{2},\n$$\n\nwhich shows that 2 is good. By negating both sides of the above equation, we also see that -2 is good.\n\nWe now show that $-2,0$, and 2 are the only good numbers. Assume for sake of contradiction that $q$ is a good number, where $q \\notin\\{-2,0,2\\}$. We now consider some particular choices of numbers on Gugu's napkin to arrive at a contradiction.\n\nAssume that the napkin contains the integers $1,2, \\ldots, 10$. Then, the first line contains the integers $-9,-8, \\ldots, 9$. The second line then contains $q$ and $81 q$, so the third line must also contain both of them. But the third line only contains integers, so $q$ must be an integer. Furthermore, the third line contains no number greater than $162=9^{2}+9^{2}-0^{2}-0^{2}$ or less than -162 , so we must have $-162 \\leqslant 81 q \\leqslant 162$. This shows that the only possibilities for $q$ are \\pm 1 .\n\nNow assume that $q= \\pm 1$. Let the napkin contain $0,1,4,8,12,16,20,24,28,32$. The first line contains \\pm 1 and \\pm 4 , so the second line contains \\pm 4 . However, for every number $a$ in the first line, $a \\not \\equiv 2(\\bmod 4)$, so we may conclude that $a^{2} \\equiv 0,1(\\bmod 8)$. Consequently, every number in the third line must be congruent to $-2,-1,0,1,2(\\bmod 8)$; in particular, \\pm 4 cannot be in the third line, which is a contradiction.",
"Let $q$ be a good number, as defined in the first solution, and define the polynomial $P\\left(x_{1}, \\ldots, x_{10}\\right)$ as\n\n$$\n\\prod_{i<j}\\left(x_{i}-x_{j}\\right) \\prod_{a_{i} \\in S}\\left(q\\left(x_{1}-x_{2}\\right)\\left(x_{3}-x_{4}\\right)-\\left(a_{1}-a_{2}\\right)^{2}-\\left(a_{3}-a_{4}\\right)^{2}+\\left(a_{5}-a_{6}\\right)^{2}+\\left(a_{7}-a_{8}\\right)^{2}\\right)\n$$\n\nwhere $S=\\left\\{x_{1}, \\ldots, x_{10}\\right\\}$.\n\nWe claim that $P\\left(x_{1}, \\ldots, x_{10}\\right)=0$ for every choice of real numbers $\\left(x_{1}, \\ldots, x_{10}\\right)$. If any two of the $x_{i}$ are equal, then $P\\left(x_{1}, \\ldots, x_{10}\\right)=0$ trivially. If no two are equal, assume that Gugu has those ten numbers $x_{1}, \\ldots, x_{10}$ on his napkin. Then, the number $q\\left(x_{1}-x_{2}\\right)\\left(x_{3}-x_{4}\\right)$ is in the second line, so we must have some $a_{1}, \\ldots, a_{8}$ so that\n\n$$\nq\\left(x_{1}-x_{2}\\right)\\left(x_{3}-x_{4}\\right)-\\left(a_{1}-a_{2}\\right)^{2}-\\left(a_{3}-a_{4}\\right)^{2}+\\left(a_{5}-a_{6}\\right)^{2}+\\left(a_{7}-a_{8}\\right)^{2}=0\n$$\n\n\n\nand hence $P\\left(x_{1}, \\ldots, x_{10}\\right)=0$.\n\nSince every polynomial that evaluates to zero everywhere is the zero polynomial, and the product of two nonzero polynomials is necessarily nonzero, we may define $F$ such that\n\n$$\nF\\left(x_{1}, \\ldots, x_{10}\\right) \\equiv q\\left(x_{1}-x_{2}\\right)\\left(x_{3}-x_{4}\\right)-\\left(a_{1}-a_{2}\\right)^{2}-\\left(a_{3}-a_{4}\\right)^{2}+\\left(a_{5}-a_{6}\\right)^{2}+\\left(a_{7}-a_{8}\\right)^{2} \\equiv 0\n$$\n\nfor some particular choice $a_{i} \\in S$.\n\nEach of the sets $\\left\\{a_{1}, a_{2}\\right\\},\\left\\{a_{3}, a_{4}\\right\\},\\left\\{a_{5}, a_{6}\\right\\}$, and $\\left\\{a_{7}, a_{8}\\right\\}$ is equal to at most one of the four sets $\\left\\{x_{1}, x_{3}\\right\\},\\left\\{x_{2}, x_{3}\\right\\},\\left\\{x_{1}, x_{4}\\right\\}$, and $\\left\\{x_{2}, x_{4}\\right\\}$. Thus, without loss of generality, we may assume that at most one of the sets $\\left\\{a_{1}, a_{2}\\right\\},\\left\\{a_{3}, a_{4}\\right\\},\\left\\{a_{5}, a_{6}\\right\\}$, and $\\left\\{a_{7}, a_{8}\\right\\}$ is equal to $\\left\\{x_{1}, x_{3}\\right\\}$. Let $u_{1}, u_{3}, u_{5}, u_{7}$ be the indicator functions for this equality of sets: that is, $u_{i}=1$ if and only if $\\left\\{a_{i}, a_{i+1}\\right\\}=\\left\\{x_{1}, x_{3}\\right\\}$. By assumption, at least three of the $u_{i}$ are equal to 0 .\n\nWe now compute the coefficient of $x_{1} x_{3}$ in $F$. It is equal to $q+2\\left(u_{1}+u_{3}-u_{5}-u_{7}\\right)=0$, and since at least three of the $u_{i}$ are zero, we must have that $q \\in\\{-2,0,2\\}$, as desired."
] | $-2,0,2$ |
1,810 | Algebra | null | $\boxed{-(n-1) / 2}$ | [
"$-(n-1) / 2$"
] | false | null | Expression | null | An integer $n \geqslant 3$ is given. We call an $n$-tuple of real numbers $\left(x_{1}, x_{2}, \ldots, x_{n}\right)$ Shiny if for each permutation $y_{1}, y_{2}, \ldots, y_{n}$ of these numbers we have
$$
\sum_{i=1}^{n-1} y_{i} y_{i+1}=y_{1} y_{2}+y_{2} y_{3}+y_{3} y_{4}+\cdots+y_{n-1} y_{n} \geqslant-1
$$
Find the largest constant $K=K(n)$ such that
$$
\sum_{1 \leqslant i<j \leqslant n} x_{i} x_{j} \geqslant K
$$
holds for every Shiny $n$-tuple $\left(x_{1}, x_{2}, \ldots, x_{n}\right)$. | [
"First of all, we show that we may not take a larger constant $K$. Let $t$ be a positive number, and take $x_{2}=x_{3}=\\cdots=t$ and $x_{1}=-1 /(2 t)$. Then, every product $x_{i} x_{j}(i \\neq j)$ is equal to either $t^{2}$ or $-1 / 2$. Hence, for every permutation $y_{i}$ of the $x_{i}$, we have\n\n$$\ny_{1} y_{2}+\\cdots+y_{n-1} y_{n} \\geqslant(n-3) t^{2}-1 \\geqslant-1\n$$\n\nThis justifies that the $n$-tuple $\\left(x_{1}, \\ldots, x_{n}\\right)$ is Shiny. Now, we have\n\n$$\n\\sum_{i<j} x_{i} x_{j}=-\\frac{n-1}{2}+\\frac{(n-1)(n-2)}{2} t^{2}\n$$\n\nThus, as $t$ approaches 0 from above, $\\sum_{i<j} x_{i} x_{j}$ gets arbitrarily close to $-(n-1) / 2$. This shows that we may not take $K$ any larger than $-(n-1) / 2$. It remains to show that $\\sum_{i<j} x_{i} x_{j} \\geqslant$ $-(n-1) / 2$ for any Shiny choice of the $x_{i}$.\n\nFrom now onward, assume that $\\left(x_{1}, \\ldots, x_{n}\\right)$ is a Shiny $n$-tuple. Let the $z_{i}(1 \\leqslant i \\leqslant n)$ be some permutation of the $x_{i}$ to be chosen later. The indices for $z_{i}$ will always be taken modulo $n$. We will first split up the sum $\\sum_{i<j} x_{i} x_{j}=\\sum_{i<j} z_{i} z_{j}$ into $\\lfloor(n-1) / 2\\rfloor$ expressions, each of the form $y_{1} y_{2}+\\cdots+y_{n-1} y_{n}$ for some permutation $y_{i}$ of the $z_{i}$, and some leftover terms. More specifically, write\n\n$$\n\\sum_{i<j} z_{i} z_{j}=\\sum_{q=0}^{n-1} \\sum_{\\substack{i+j \\equiv q \\\\ i \\neq j}} z_{i} z_{j}=\\sum_{\\substack{(\\bmod n)}}^{\\left\\lfloor\\frac{n-1}{2}\\right\\rfloor} \\sum_{\\substack{i+j \\equiv 2 p-1,2 p(\\bmod n) \\\\ i \\neq j}} z_{i} z_{j}+L\n\\tag{1}\n$$\n\nwhere $L=z_{1} z_{-1}+z_{2} z_{-2}+\\cdots+z_{(n-1) / 2} z_{-(n-1) / 2}$ if $n$ is odd, and $L=z_{1} z_{-1}+z_{1} z_{-2}+z_{2} z_{-2}+$ $\\cdots+z_{(n-2) / 2} z_{-n / 2}$ if $n$ is even. We note that for each $p=1,2, \\ldots,\\lfloor(n-1) / 2\\rfloor$, there is some permutation $y_{i}$ of the $z_{i}$ such that\n\n$$\n\\sum_{\\substack{i+j \\equiv 2 p-1,2 p(\\bmod n) \\\\ i \\neq j}} z_{i} z_{j}=\\sum_{k=1}^{n-1} y_{k} y_{k+1}\n$$\n\nbecause we may choose $y_{2 i-1}=z_{i+p-1}$ for $1 \\leqslant i \\leqslant(n+1) / 2$ and $y_{2 i}=z_{p-i}$ for $1 \\leqslant i \\leqslant n / 2$.\n\nWe show (1) graphically for $n=6,7$ in the diagrams below. The edges of the graphs each represent a product $z_{i} z_{j}$, and the dashed and dotted series of lines represents the sum of the edges, which is of the form $y_{1} y_{2}+\\cdots+y_{n-1} y_{n}$ for some permutation $y_{i}$ of the $z_{i}$ precisely when the series of lines is a Hamiltonian path. The filled edges represent the summands of $L$.\n\n\n\n<img_3150>\n\nNow, because the $z_{i}$ are Shiny, we have that (1) yields the following bound:\n\n$$\n\\sum_{i<j} z_{i} z_{j} \\geqslant-\\left\\lfloor\\frac{n-1}{2}\\right\\rfloor+L\n$$\n\nIt remains to show that, for each $n$, there exists some permutation $z_{i}$ of the $x_{i}$ such that $L \\geqslant 0$ when $n$ is odd, and $L \\geqslant-1 / 2$ when $n$ is even. We now split into cases based on the parity of $n$ and provide constructions of the permutations $z_{i}$.\n\nSince we have not made any assumptions yet about the $x_{i}$, we may now assume without loss of generality that\n\n$$\nx_{1} \\leqslant x_{2} \\leqslant \\cdots \\leqslant x_{k} \\leqslant 0 \\leqslant x_{k+1} \\leqslant \\cdots \\leqslant x_{n}\n\\tag{2}\n$$\n\nCase 1: $n$ is odd.\n\nWithout loss of generality, assume that $k$ (from (2)) is even, because we may negate all the $x_{i}$ if $k$ is odd. We then have $x_{1} x_{2}, x_{3} x_{4}, \\ldots, x_{n-2} x_{n-1} \\geqslant 0$ because the factors are of the same sign. Let $L=x_{1} x_{2}+x_{3} x_{4}+\\cdots+x_{n-2} x_{n-1} \\geqslant 0$. We choose our $z_{i}$ so that this definition of $L$ agrees with the sum of the leftover terms in (1). Relabel the $x_{i}$ as $z_{i}$ such that\n\n$$\n\\left\\{z_{1}, z_{n-1}\\right\\},\\left\\{z_{2}, z_{n-2}\\right\\}, \\ldots,\\left\\{z_{(n-1) / 2}, z_{(n+1) / 2}\\right\\}\n$$\n\nare some permutation of\n\n$$\n\\left\\{x_{1}, x_{2}\\right\\},\\left\\{x_{3}, x_{4}\\right\\}, \\ldots,\\left\\{x_{n-2}, x_{n-1}\\right\\}\n$$\n\nand $z_{n}=x_{n}$. Then, we have $L=z_{1} z_{n-1}+\\cdots+z_{(n-1) / 2} z_{(n+1) / 2}$, as desired.\n\nCase 2: $n$ is even.\n\nLet $L=x_{1} x_{2}+x_{2} x_{3}+\\cdots+x_{n-1} x_{n}$. Assume without loss of generality $k \\neq 1$. Now, we have\n\n$$\n\\begin{gathered}\n2 L=\\left(x_{1} x_{2}+\\cdots+x_{n-1} x_{n}\\right)+\\left(x_{1} x_{2}+\\cdots+x_{n-1} x_{n}\\right) \\geqslant\\left(x_{2} x_{3}+\\cdots+x_{n-1} x_{n}\\right)+x_{k} x_{k+1} \\\\\n\\geqslant x_{2} x_{3}+\\cdots+x_{n-1} x_{n}+x_{n} x_{1} \\geqslant-1\n\\end{gathered}\n$$\n\nwhere the first inequality holds because the only negative term in $L$ is $x_{k} x_{k+1}$, the second inequality holds because $x_{1} \\leqslant x_{k} \\leqslant 0 \\leqslant x_{k+1} \\leqslant x_{n}$, and the third inequality holds because the $x_{i}$ are assumed to be Shiny. We thus have that $L \\geqslant-1 / 2$. We now choose a suitable $z_{i}$ such that the definition of $L$ matches the leftover terms in (1).\n\n\n\nRelabel the $x_{i}$ with $z_{i}$ in the following manner: $x_{2 i-1}=z_{-i}, x_{2 i}=z_{i}$ (again taking indices modulo $n$ ). We have that\n\n$$\nL=\\sum_{\\substack{i+j \\equiv 0,-1(\\bmod n) \\\\ i \\neq j j}} z_{i} z_{j}\n$$\n\nas desired.",
"We present another proof that $\\sum_{i<j} x_{i} x_{j} \\geqslant-(n-1) / 2$ for any Shiny $n$-tuple $\\left(x_{1}, \\ldots, x_{n}\\right)$. Assume an ordering of the $x_{i}$ as in (2), and let $\\ell=n-k$. Assume without loss of generality that $k \\geqslant \\ell$. Also assume $k \\neq n$, (as otherwise, all of the $x_{i}$ are nonpositive, and so the inequality is trivial). Define the sets of indices $S=\\{1,2, \\ldots, k\\}$ and $T=\\{k+1, \\ldots, n\\}$. Define the following sums:\n\n$$\nK=\\sum_{\\substack{i<j \\\\ i, j \\in S}} x_{i} x_{j}, \\quad M=\\sum_{\\substack{i \\in S \\\\ j \\in T}} x_{i} x_{j}, \\quad \\text { and } \\quad L=\\sum_{\\substack{i<j \\\\ i, j \\in T}} x_{i} x_{j}\n$$\n\nBy definition, $K, L \\geqslant 0$ and $M \\leqslant 0$. We aim to show that $K+L+M \\geqslant-(n-1) / 2$.\n\nWe split into cases based on whether $k=\\ell$ or $k>\\ell$.\n\nCase 1: $k>\\ell$.\n\nConsider all permutations $\\phi:\\{1,2, \\ldots, n\\} \\rightarrow\\{1,2, \\ldots, n\\}$ such that $\\phi^{-1}(T)=\\{2,4, \\ldots, 2 \\ell\\}$. Note that there are $k ! \\ell$ ! such permutations $\\phi$. Define\n\n$$\nf(\\phi)=\\sum_{i=1}^{n-1} x_{\\phi(i)} x_{\\phi(i+1)}\n$$\n\nWe know that $f(\\phi) \\geqslant-1$ for every permutation $\\phi$ with the above property. Averaging $f(\\phi)$ over all $\\phi$ gives\n\n$$\n-1 \\leqslant \\frac{1}{k ! \\ell !} \\sum_{\\phi} f(\\phi)=\\frac{2 \\ell}{k \\ell} M+\\frac{2(k-\\ell-1)}{k(k-1)} K\n$$\n\nwhere the equality holds because there are $k \\ell$ products in $M$, of which $2 \\ell$ are selected for each $\\phi$, and there are $k(k-1) / 2$ products in $K$, of which $k-\\ell-1$ are selected for each $\\phi$. We now have\n\n$$\nK+L+M \\geqslant K+L+\\left(-\\frac{k}{2}-\\frac{k-\\ell-1}{k-1} K\\right)=-\\frac{k}{2}+\\frac{\\ell}{k-1} K+L .\n$$\n\nSince $k \\leqslant n-1$ and $K, L \\geqslant 0$, we get the desired inequality.\n\nCase 2: $k=\\ell=n / 2$.\n\nWe do a similar approach, considering all $\\phi:\\{1,2, \\ldots, n\\} \\rightarrow\\{1,2, \\ldots, n\\}$ such that $\\phi^{-1}(T)=$ $\\{2,4, \\ldots, 2 \\ell\\}$, and defining $f$ the same way. Analogously to Case 1 , we have\n\n$$\n-1 \\leqslant \\frac{1}{k ! \\ell !} \\sum_{\\phi} f(\\phi)=\\frac{2 \\ell-1}{k \\ell} M\n$$\n\nbecause there are $k \\ell$ products in $M$, of which $2 \\ell-1$ are selected for each $\\phi$. Now, we have that\n\n$$\nK+L+M \\geqslant M \\geqslant-\\frac{n^{2}}{4(n-1)} \\geqslant-\\frac{n-1}{2}\n$$\n\nwhere the last inequality holds because $n \\geqslant 4$."
] | $-(n-1) / 2$ |
1,818 | Combinatorics | null | $\boxed{\frac{n(n+1)(2 n+1)}{6}}$ | [
"$\\frac{n(n+1)(2 n+1)}{6}$"
] | false | null | Expression | null | Let $n>1$ be an integer. An $n \times n \times n$ cube is composed of $n^{3}$ unit cubes. Each unit cube is painted with one color. For each $n \times n \times 1$ box consisting of $n^{2}$ unit cubes (of any of the three possible orientations), we consider the set of the colors present in that box (each color is listed only once). This way, we get $3 n$ sets of colors, split into three groups according to the orientation. It happens that for every set in any group, the same set appears in both of the other groups. Determine, in terms of $n$, the maximal possible number of colors that are present. | [
"Call a $n \\times n \\times 1$ box an $x$-box, a $y$-box, or a $z$-box, according to the direction of its short side. Let $C$ be the number of colors in a valid configuration. We start with the upper bound for $C$.\n\nLet $\\mathcal{C}_{1}, \\mathcal{C}_{2}$, and $\\mathcal{C}_{3}$ be the sets of colors which appear in the big cube exactly once, exactly twice, and at least thrice, respectively. Let $M_{i}$ be the set of unit cubes whose colors are in $\\mathcal{C}_{i}$, and denote $n_{i}=\\left|M_{i}\\right|$.\n\nConsider any $x$-box $X$, and let $Y$ and $Z$ be a $y$ - and a $z$-box containing the same set of colors as $X$ does.\n\nClaim. $4\\left|X \\cap M_{1}\\right|+\\left|X \\cap M_{2}\\right| \\leqslant 3 n+1$.\n\nProof. We distinguish two cases.\n\nCase 1: $X \\cap M_{1} \\neq \\varnothing$.\n\nA cube from $X \\cap M_{1}$ should appear in all three boxes $X, Y$, and $Z$, so it should lie in $X \\cap Y \\cap Z$. Thus $X \\cap M_{1}=X \\cap Y \\cap Z$ and $\\left|X \\cap M_{1}\\right|=1$.\n\nConsider now the cubes in $X \\cap M_{2}$. There are at most $2(n-1)$ of them lying in $X \\cap Y$ or $X \\cap Z$ (because the cube from $X \\cap Y \\cap Z$ is in $M_{1}$ ). Let $a$ be some other cube from $X \\cap M_{2}$. Recall that there is just one other cube $a^{\\prime}$ sharing a color with $a$. But both $Y$ and $Z$ should contain such cube, so $a^{\\prime} \\in Y \\cap Z$ (but $a^{\\prime} \\notin X \\cap Y \\cap Z$ ). The map $a \\mapsto a^{\\prime}$ is clearly injective, so the number of cubes $a$ we are interested in does not exceed $|(Y \\cap Z) \\backslash X|=n-1$. Thus $\\left|X \\cap M_{2}\\right| \\leqslant 2(n-1)+(n-1)=3(n-1)$, and hence $4\\left|X \\cap M_{1}\\right|+\\left|X \\cap M_{2}\\right| \\leqslant 4+3(n-1)=3 n+1$.\n\nCase 2: $X \\cap M_{1}=\\varnothing$.\n\nIn this case, the same argument applies with several changes. Indeed, $X \\cap M_{2}$ contains at most $2 n-1$ cubes from $X \\cap Y$ or $X \\cap Z$. Any other cube $a$ in $X \\cap M_{2}$ corresponds to some $a^{\\prime} \\in Y \\cap Z$ (possibly with $a^{\\prime} \\in X$ ), so there are at most $n$ of them. All this results in $\\left|X \\cap M_{2}\\right| \\leqslant(2 n-1)+n=3 n-1$, which is even better than we need (by the assumptions of our case).\n\nSumming up the inequalities from the Claim over all $x$-boxes $X$, we obtain\n\n$$\n4 n_{1}+n_{2} \\leqslant n(3 n+1) .\n$$\n\nObviously, we also have $n_{1}+n_{2}+n_{3}=n^{3}$.\n\nNow we are prepared to estimate $C$. Due to the definition of the $M_{i}$, we have $n_{i} \\geqslant i\\left|\\mathcal{C}_{i}\\right|$, so\n\n$$\nC \\leqslant n_{1}+\\frac{n_{2}}{2}+\\frac{n_{3}}{3}=\\frac{n_{1}+n_{2}+n_{3}}{3}+\\frac{4 n_{1}+n_{2}}{6} \\leqslant \\frac{n^{3}}{3}+\\frac{3 n^{2}+n}{6}=\\frac{n(n+1)(2 n+1)}{6} .\n$$\n\nIt remains to present an example of an appropriate coloring in the above-mentioned number of colors. For each color, we present the set of all cubes of this color. These sets are:\n\n1. $n$ singletons of the form $S_{i}=\\{(i, i, i)\\}$ (with $1 \\leqslant i \\leqslant n$ );\n2. $3\\left(\\begin{array}{c}n \\\\ 2\\end{array}\\right)$ doubletons of the forms $D_{i, j}^{1}=\\{(i, j, j),(j, i, i)\\}, D_{i, j}^{2}=\\{(j, i, j),(i, j, i)\\}$, and $D_{i, j}^{3}=$ $\\{(j, j, i),(i, i, j)\\}$ (with $1 \\leqslant i<j \\leqslant n)$;\n\n\n3. $2\\left(\\begin{array}{l}n \\\\ 3\\end{array}\\right)$ triplets of the form $T_{i, j, k}=\\{(i, j, k),(j, k, i),(k, i, j)\\}$ (with $1 \\leqslant i<j<k \\leqslant n$ or $1 \\leqslant i<k<j \\leqslant n)$.\n\nOne may easily see that the $i^{\\text {th }}$ boxes of each orientation contain the same set of colors, and that\n\n$$\nn+\\frac{3 n(n-1)}{2}+\\frac{n(n-1)(n-2)}{3}=\\frac{n(n+1)(2 n+1)}{6}\n$$\n\ncolors are used, as required.",
"We will approach a new version of the original problem. In this new version, each cube may have a color, or be invisible (not both). Now we make sets of colors for each $n \\times n \\times 1$ box as before (where \"invisible\" is not considered a color) and group them by orientation, also as before. Finally, we require that, for every non-empty set in any group, the same set must appear in the other 2 groups. What is the maximum number of colors present with these new requirements?\n\nLet us call strange a big $n \\times n \\times n$ cube whose painting scheme satisfies the new requirements, and let $D$ be the number of colors in a strange cube. Note that any cube that satisfies the original requirements is also strange, so $\\max (D)$ is an upper bound for the original answer.\n\nClaim. $D \\leqslant \\frac{n(n+1)(2 n+1)}{6}$.\n\nProof. The proof is by induction on $n$. If $n=1$, we must paint the cube with at most 1 color.\n\nNow, pick a $n \\times n \\times n$ strange cube $A$, where $n \\geqslant 2$. If $A$ is completely invisible, $D=0$ and we are done. Otherwise, pick a non-empty set of colors $\\mathcal{S}$ which corresponds to, say, the boxes $X, Y$ and $Z$ of different orientations.\n\nNow find all cubes in $A$ whose colors are in $\\mathcal{S}$ and make them invisible. Since $X, Y$ and $Z$ are now completely invisible, we can throw them away and focus on the remaining $(n-1) \\times(n-1) \\times(n-1)$ cube $B$. The sets of colors in all the groups for $B$ are the same as the sets for $A$, removing exactly the colors in $\\mathcal{S}$, and no others! Therefore, every nonempty set that appears in one group for $B$ still shows up in all possible orientations (it is possible that an empty set of colors in $B$ only matched $X, Y$ or $Z$ before these were thrown away, but remember we do not require empty sets to match anyway). In summary, $B$ is also strange.\n\nBy the induction hypothesis, we may assume that $B$ has at most $\\frac{(n-1) n(2 n-1)}{6}$ colors. Since there were at most $n^{2}$ different colors in $\\mathcal{S}$, we have that $A$ has at most $\\frac{(n-1) n(2 n-1)}{6}+n^{2}=$ $\\frac{n(n+1)(2 n+1)}{6}$ colors.\n\nFinally, the construction in the previous solution shows a painting scheme (with no invisible cubes) that reaches this maximum, so we are done."
] | $\frac{n(n+1)(2 n+1)}{6}$ |
1,820 | Combinatorics | null | $\boxed{n^{2}+1}$ | [
"$n^{2}+1$"
] | false | null | Expression | null | Let $n$ be a given positive integer. In the Cartesian plane, each lattice point with nonnegative coordinates initially contains a butterfly, and there are no other butterflies. The neighborhood of a lattice point $c$ consists of all lattice points within the axis-aligned $(2 n+1) \times$ $(2 n+1)$ square centered at $c$, apart from $c$ itself. We call a butterfly lonely, crowded, or comfortable, depending on whether the number of butterflies in its neighborhood $N$ is respectively less than, greater than, or equal to half of the number of lattice points in $N$.
Every minute, all lonely butterflies fly away simultaneously. This process goes on for as long as there are any lonely butterflies. Assuming that the process eventually stops, determine the number of comfortable butterflies at the final state. | [
"We always identify a butterfly with the lattice point it is situated at. For two points $p$ and $q$, we write $p \\geqslant q$ if each coordinate of $p$ is at least the corresponding coordinate of $q$. Let $O$ be the origin, and let $\\mathcal{Q}$ be the set of initially occupied points, i.e., of all lattice points with nonnegative coordinates. Let $\\mathcal{R}_{\\mathrm{H}}=\\{(x, 0): x \\geqslant 0\\}$ and $\\mathcal{R}_{\\mathrm{V}}=\\{(0, y): y \\geqslant 0\\}$ be the sets of the lattice points lying on the horizontal and vertical boundary rays of $\\mathcal{Q}$. Denote by $N(a)$ the neighborhood of a lattice point $a$.\n\n1. Initial observations. We call a set of lattice points up-right closed if its points stay in the set after being shifted by any lattice vector $(i, j)$ with $i, j \\geqslant 0$. Whenever the butterflies form a up-right closed set $\\mathcal{S}$, we have $|N(p) \\cap \\mathcal{S}| \\geqslant|N(q) \\cap \\mathcal{S}|$ for any two points $p, q \\in \\mathcal{S}$ with $p \\geqslant q$. So, since $\\mathcal{Q}$ is up-right closed, the set of butterflies at any moment also preserves this property. We assume all forthcoming sets of lattice points to be up-right closed.\n\nWhen speaking of some set $\\mathcal{S}$ of lattice points, we call its points lonely, comfortable, or crowded with respect to this set (i.e., as if the butterflies were exactly at all points of $\\mathcal{S}$ ). We call a set $\\mathcal{S} \\subset \\mathcal{Q}$ stable if it contains no lonely points. In what follows, we are interested only in those stable sets whose complements in $\\mathcal{Q}$ are finite, because one can easily see that only a finite number of butterflies can fly away on each minute.\n\nIf the initial set $\\mathcal{Q}$ of butterflies contains some stable set $\\mathcal{S}$, then, clearly no butterfly of this set will fly away. On the other hand, the set $\\mathcal{F}$ of all butterflies in the end of the process is stable. This means that $\\mathcal{F}$ is the largest (with respect to inclusion) stable set within $\\mathcal{Q}$, and we are about to describe this set.\n\n2. A description of a final set. The following notion will be useful. Let $\\mathcal{U}=\\left\\{\\vec{u}_{1}, \\vec{u}_{2}, \\ldots, \\vec{u}_{d}\\right\\}$ be a set of $d$ pairwise non-parallel lattice vectors, each having a positive $x$ - and a negative $y$-coordinate. Assume that they are numbered in increasing order according to slope. We now define a $\\mathcal{U}$-curve to be the broken line $p_{0} p_{1} \\ldots p_{d}$ such that $p_{0} \\in \\mathcal{R}_{\\mathrm{V}}, p_{d} \\in \\mathcal{R}_{\\mathrm{H}}$, and $\\vec{p}_{i-1} \\vec{p}_{i}=\\vec{u}_{i}$ for all $i=1,2, \\ldots, m$ (see the Figure below to the left).\n\n<img_3839>\n\nConstruction of $\\mathcal{U}$-curve\n\n<img_4021>\n\n<img_3612>\n\nConstruction of $\\mathcal{D}$\n\n\n\nNow, let $\\mathcal{K}_{n}=\\{(i, j): 1 \\leqslant i \\leqslant n,-n \\leqslant j \\leqslant-1\\}$. Consider all the rays emerging at $O$ and passing through a point from $\\mathcal{K}_{n}$; number them as $r_{1}, \\ldots, r_{m}$ in increasing order according to slope. Let $A_{i}$ be the farthest from $O$ lattice point in $r_{i} \\cap \\mathcal{K}_{n}$, set $k_{i}=\\left|r_{i} \\cap \\mathcal{K}_{n}\\right|$, let $\\vec{v}_{i}=\\overrightarrow{O A_{i}}$, and finally denote $\\mathcal{V}=\\left\\{\\vec{v}_{i}: 1 \\leqslant i \\leqslant m\\right\\}$; see the Figure above to the right. We will concentrate on the $\\mathcal{V}$-curve $d_{0} d_{1} \\ldots d_{m}$; let $\\mathcal{D}$ be the set of all lattice points $p$ such that $p \\geqslant p^{\\prime}$ for some (not necessarily lattice) point $p^{\\prime}$ on the $\\mathcal{V}$-curve. In fact, we will show that $\\mathcal{D}=\\mathcal{F}$.\n\nClearly, the $\\mathcal{V}$-curve is symmetric in the line $y=x$. Denote by $D$ the convex hull of $\\mathcal{D}$.\n\n3. We prove that the set $\\mathcal{D}$ contains all stable sets. Let $\\mathcal{S} \\subset \\mathcal{Q}$ be a stable set (recall that it is assumed to be up-right closed and to have a finite complement in $\\mathcal{Q}$ ). Denote by $S$ its convex hull; clearly, the vertices of $S$ are lattice points. The boundary of $S$ consists of two rays (horizontal and vertical ones) along with some $\\mathcal{V}_{*}$-curve for some set of lattice vectors $\\mathcal{V}_{*}$.\n\nClaim 1. For every $\\vec{v}_{i} \\in \\mathcal{V}$, there is a $\\vec{v}_{i}^{*} \\in \\mathcal{V}_{*}$ co-directed with $\\vec{v}$ with $\\left|\\vec{v}_{i}^{*}\\right| \\geqslant|\\vec{v}|$.\n\nProof. Let $\\ell$ be the supporting line of $S$ parallel to $\\vec{v}_{i}$ (i.e., $\\ell$ contains some point of $S$, and the set $S$ lies on one side of $\\ell$ ). Take any point $b \\in \\ell \\cap \\mathcal{S}$ and consider $N(b)$. The line $\\ell$ splits the set $N(b) \\backslash \\ell$ into two congruent parts, one having an empty intersection with $\\mathcal{S}$. Hence, in order for $b$ not to be lonely, at least half of the set $\\ell \\cap N(b)$ (which contains $2 k_{i}$ points) should lie in $S$. Thus, the boundary of $S$ contains a segment $\\ell \\cap S$ with at least $k_{i}+1$ lattice points (including $b$ ) on it; this segment corresponds to the required vector $\\vec{v}_{i}^{*} \\in \\mathcal{V}_{*}$.\n\n<img_3156>\n\nProof of Claim 1\n\n<img_3490>\n\nProof of Claim 2\n\nClaim 2. Each stable set $\\mathcal{S} \\subseteq \\mathcal{Q}$ lies in $\\mathcal{D}$.\n\nProof. To show this, it suffices to prove that the $\\mathcal{V}_{*}$-curve lies in $D$, i.e., that all its vertices do so. Let $p^{\\prime}$ be an arbitrary vertex of the $\\mathcal{V}_{*}$-curve; $p^{\\prime}$ partitions this curve into two parts, $\\mathcal{X}$ (being down-right of $p$ ) and $\\mathcal{Y}$ (being up-left of $p$ ). The set $\\mathcal{V}$ is split now into two parts: $\\mathcal{V}_{\\mathcal{X}}$ consisting of those $\\vec{v}_{i} \\in \\mathcal{V}$ for which $\\vec{v}_{i}^{*}$ corresponds to a segment in $\\mathcal{X}$, and a similar part $\\mathcal{V}_{\\mathcal{Y}}$. Notice that the $\\mathcal{V}$-curve consists of several segments corresponding to $\\mathcal{V}_{\\mathcal{X}}$, followed by those corresponding to $\\mathcal{V}_{\\mathcal{Y}}$. Hence there is a vertex $p$ of the $\\mathcal{V}$-curve separating $\\mathcal{V}_{\\mathcal{X}}$ from $\\mathcal{V}_{\\mathcal{Y}}$. Claim 1 now yields that $p^{\\prime} \\geqslant p$, so $p^{\\prime} \\in \\mathcal{D}$, as required.\n\nClaim 2 implies that the final set $\\mathcal{F}$ is contained in $\\mathcal{D}$.\n\n4. $\\mathcal{D}$ is stable, and its comfortable points are known. Recall the definitions of $r_{i}$; let $r_{i}^{\\prime}$ be the ray complementary to $r_{i}$. By our definitions, the set $N(O)$ contains no points between the rays $r_{i}$ and $r_{i+1}$, as well as between $r_{i}^{\\prime}$ and $r_{i+1}^{\\prime}$.\n\nClaim 3. In the set $\\mathcal{D}$, all lattice points of the $\\mathcal{V}$-curve are comfortable.\n\nProof. Let $p$ be any lattice point of the $\\mathcal{V}$-curve, belonging to some segment $d_{i} d_{i+1}$. Draw the line $\\ell$ containing this segment. Then $\\ell \\cap \\mathcal{D}$ contains exactly $k_{i}+1$ lattice points, all of which lie in $N(p)$ except for $p$. Thus, exactly half of the points in $N(p) \\cap \\ell$ lie in $\\mathcal{D}$. It remains to show that all points of $N(p)$ above $\\ell$ lie in $\\mathcal{D}$ (recall that all the points below $\\ell$ lack this property).\n\n\n\nNotice that each vector in $\\mathcal{V}$ has one coordinate greater than $n / 2$; thus the neighborhood of $p$ contains parts of at most two segments of the $\\mathcal{V}$-curve succeeding $d_{i} d_{i+1}$, as well as at most two of those preceding it.\n\nThe angles formed by these consecutive segments are obtained from those formed by $r_{j}$ and $r_{j-1}^{\\prime}$ (with $i-1 \\leqslant j \\leqslant i+2$ ) by shifts; see the Figure below. All the points in $N(p)$ above $\\ell$ which could lie outside $\\mathcal{D}$ lie in shifted angles between $r_{j}, r_{j+1}$ or $r_{j}^{\\prime}, r_{j-1}^{\\prime}$. But those angles, restricted to $N(p)$, have no lattice points due to the above remark. The claim is proved.\n<img_3487>\n\nProof of Claim 3\n\nClaim 4. All the points of $\\mathcal{D}$ which are not on the boundary of $D$ are crowded.\n\nProof. Let $p \\in \\mathcal{D}$ be such a point. If it is to the up-right of some point $p^{\\prime}$ on the curve, then the claim is easy: the shift of $N\\left(p^{\\prime}\\right) \\cap \\mathcal{D}$ by $\\overrightarrow{p^{\\prime} p}$ is still in $\\mathcal{D}$, and $N(p)$ contains at least one more point of $\\mathcal{D}$ - either below or to the left of $p$. So, we may assume that $p$ lies in a right triangle constructed on some hypothenuse $d_{i} d_{i+1}$. Notice here that $d_{i}, d_{i+1} \\in N(p)$.\n\nDraw a line $\\ell \\| d_{i} d_{i+1}$ through $p$, and draw a vertical line $h$ through $d_{i}$; see Figure below. Let $\\mathcal{D}_{\\mathrm{L}}$ and $\\mathcal{D}_{\\mathrm{R}}$ be the parts of $\\mathcal{D}$ lying to the left and to the right of $h$, respectively (points of $\\mathcal{D} \\cap h$ lie in both parts).\n\n<img_3424>\n\nNotice that the vectors $\\overrightarrow{d_{i} p}, \\overrightarrow{d_{i+1} d_{i+2}}, \\overrightarrow{d_{i} d_{i+1}}, \\overrightarrow{d_{i-1} d_{i}}$, and $\\overrightarrow{p d_{i+1}}$ are arranged in non-increasing order by slope. This means that $\\mathcal{D}_{\\mathrm{L}}$ shifted by $\\overrightarrow{d_{i} p}$ still lies in $\\mathcal{D}$, as well as $\\mathcal{D}_{\\mathrm{R}}$ shifted by $\\overrightarrow{d_{i+1} p}$. As we have seen in the proof of Claim 3, these two shifts cover all points of $N(p)$ above $\\ell$, along with those on $\\ell$ to the left of $p$. Since $N(p)$ contains also $d_{i}$ and $d_{i+1}$, the point $p$ is crowded.\n\nThus, we have proved that $\\mathcal{D}=\\mathcal{F}$, and have shown that the lattice points on the $\\mathcal{V}$-curve are exactly the comfortable points of $\\mathcal{D}$. It remains to find their number.\n\nRecall the definition of $\\mathcal{K}_{n}$ (see Figure on the first page of the solution). Each segment $d_{i} d_{i+1}$ contains $k_{i}$ lattice points different from $d_{i}$. Taken over all $i$, these points exhaust all the lattice points in the $\\mathcal{V}$-curve, except for $d_{1}$, and thus the number of lattice points on the $\\mathcal{V}$-curve is $1+\\sum_{i=1}^{m} k_{i}$. On the other hand, $\\sum_{i=1}^{m} k_{i}$ is just the number of points in $\\mathcal{K}_{n}$, so it equals $n^{2}$. Hence the answer to the problem is $n^{2}+1$."
] | $n^{2}+1$ |
1,828 | Geometry | null | $\boxed{6048}$ | [
"6048"
] | false | null | Numerical | null | There are 2017 mutually external circles drawn on a blackboard, such that no two are tangent and no three share a common tangent. A tangent segment is a line segment that is a common tangent to two circles, starting at one tangent point and ending at the other one. Luciano is drawing tangent segments on the blackboard, one at a time, so that no tangent segment intersects any other circles or previously drawn tangent segments. Luciano keeps drawing tangent segments until no more can be drawn. Find all possible numbers of tangent segments when he stops drawing. | [
"First, consider a particular arrangement of circles $C_{1}, C_{2}, \\ldots, C_{n}$ where all the centers are aligned and each $C_{i}$ is eclipsed from the other circles by its neighbors - for example, taking $C_{i}$ with center $\\left(i^{2}, 0\\right)$ and radius $i / 2$ works. Then the only tangent segments that can be drawn are between adjacent circles $C_{i}$ and $C_{i+1}$, and exactly three segments can be drawn for each pair. So Luciano will draw exactly $3(n-1)$ segments in this case.\n\n<img_3497>\n\nFor the general case, start from a final configuration (that is, an arrangement of circles and segments in which no further segments can be drawn). The idea of the solution is to continuously resize and move the circles around the plane, one by one (in particular, making sure we never have 4 circles with a common tangent line), and show that the number of segments drawn remains constant as the picture changes. This way, we can reduce any circle/segment configuration to the particular one mentioned above, and the final number of segments must remain at $3 n-3$.\n\nSome preliminary considerations: look at all possible tangent segments joining any two circles. A segment that is tangent to a circle $A$ can do so in two possible orientations - it may come out of $A$ in clockwise or counterclockwise orientation. Two segments touching the same circle with the same orientation will never intersect each other. Each pair $(A, B)$ of circles has 4 choices of tangent segments, which can be identified by their orientations - for example, $(A+, B-)$ would be the segment which comes out of $A$ in clockwise orientation and comes out of $B$ in counterclockwise orientation. In total, we have $2 n(n-1)$ possible segments, disregarding intersections.\n\nNow we pick a circle $C$ and start to continuously move and resize it, maintaining all existing tangent segments according to their identifications, including those involving $C$. We can keep our choice of tangent segments until the configuration reaches a transition. We lose nothing if we assume that $C$ is kept at least $\\varepsilon$ units away from any other circle, where $\\varepsilon$ is a positive, fixed constant; therefore at a transition either: (1) a currently drawn tangent segment $t$ suddenly becomes obstructed; or (2) a currently absent tangent segment $t$ suddenly becomes unobstructed and available.\n\nClaim. A transition can only occur when three circles $C_{1}, C_{2}, C_{3}$ are tangent to a common line $\\ell$ containing $t$, in a way such that the three tangent segments lying on $\\ell$ (joining the three circles pairwise) are not obstructed by any other circles or tangent segments (other than $C_{1}, C_{2}, C_{3}$ ). Proof. Since (2) is effectively the reverse of (1), it suffices to prove the claim for (1). Suppose $t$ has suddenly become obstructed, and let us consider two cases.\n\n\n\nCase 1: $t$ becomes obstructed by a circle\n\n<img_3256>\n\nThen the new circle becomes the third circle tangent to $\\ell$, and no other circles or tangent segments are obstructing $t$.\n\nCase 2: $t$ becomes obstructed by another tangent segment $t^{\\prime}$ \n\nWhen two segments $t$ and $t^{\\prime}$ first intersect each other, they must do so at a vertex of one of them. But if a vertex of $t^{\\prime}$ first crossed an interior point of $t$, the circle associated to this vertex was already blocking $t$ (absurd), or is about to (we already took care of this in case 1). So we only have to analyze the possibility of $t$ and $t^{\\prime}$ suddenly having a common vertex. However, if that happens, this vertex must belong to a single circle (remember we are keeping different circles at least $\\varepsilon$ units apart from each other throughout the moving/resizing process), and therefore they must have different orientations with respect to that circle.\n<img_4010>\n\nThus, at the transition moment, both $t$ and $t^{\\prime}$ are tangent to the same circle at a common point, that is, they must be on the same line $\\ell$ and hence we again have three circles simultaneously tangent to $\\ell$. Also no other circles or tangent segments are obstructing $t$ or $t^{\\prime}$ (otherwise, they would have disappeared before this transition).\n\nNext, we focus on the maximality of a configuration immediately before and after a transition, where three circles share a common tangent line $\\ell$. Let the three circles be $C_{1}, C_{2}, C_{3}$, ordered by their tangent points. The only possibly affected segments are the ones lying on $\\ell$, namely $t_{12}, t_{23}$ and $t_{13}$. Since $C_{2}$ is in the middle, $t_{12}$ and $t_{23}$ must have different orientations with respect to $C_{2}$. For $C_{1}, t_{12}$ and $t_{13}$ must have the same orientation, while for $C_{3}, t_{13}$ and $t_{23}$ must have the same orientation. The figure below summarizes the situation, showing alternative positions for $C_{1}$ (namely, $C_{1}$ and $C_{1}^{\\prime}$ ) and for $C_{3}\\left(C_{3}\\right.$ and $C_{3}^{\\prime}$ ).\n\n<img_3756>\n\n\n\nNow perturb the diagram slightly so the three circles no longer have a common tangent, while preserving the definition of $t_{12}, t_{23}$ and $t_{13}$ according to their identifications. First note that no other circles or tangent segments can obstruct any of these segments. Also recall that tangent segments joining the same circle at the same orientation will never obstruct each other.\n\nThe availability of the tangent segments can now be checked using simple diagrams.\n\nCase 1: $t_{13}$ passes through $C_{2}$\n\n<img_3220>\n\nIn this case, $t_{13}$ is not available, but both $t_{12}$ and $t_{23}$ are.\n\nCase 2: $t_{13}$ does not pass through $C_{2}$\n\n<img_3461>\n\nNow $t_{13}$ is available, but $t_{12}$ and $t_{23}$ obstruct each other, so only one can be drawn.\n\nIn any case, exactly 2 out of these 3 segments can be drawn. Thus the maximal number of segments remains constant as we move or resize the circles, and we are done.",
"First note that all tangent segments lying on the boundary of the convex hull of the circles are always drawn since they do not intersect anything else. Now in the final picture, aside from the $n$ circles, the blackboard is divided into regions. We can consider the picture as a plane (multi-)graph $G$ in which the circles are the vertices and the tangent segments are the edges. The idea of this solution is to find a relation between the number of edges and the number of regions in $G$; then, once we prove that $G$ is connected, we can use Euler's formula to finish the problem.\n\nThe boundary of each region consists of 1 or more (for now) simple closed curves, each made of arcs and tangent segments. The segment and the arc might meet smoothly (as in $S_{i}$, $i=1,2, \\ldots, 6$ in the figure below) or not (as in $P_{1}, P_{2}, P_{3}, P_{4}$; call such points sharp corners of the boundary). In other words, if a person walks along the border, her direction would suddenly turn an angle of $\\pi$ at a sharp corner.\n\n\n\n<img_3559>\n\nClaim 1. The outer boundary $B_{1}$ of any internal region has at least 3 sharp corners.\n\nProof. Let a person walk one lap along $B_{1}$ in the counterclockwise orientation. As she does so, she will turn clockwise as she moves along the circle arcs, and not turn at all when moving along the lines. On the other hand, her total rotation after one lap is $2 \\pi$ in the counterclockwise direction! Where could she be turning counterclockwise? She can only do so at sharp corners, and, even then, she turns only an angle of $\\pi$ there. But two sharp corners are not enough, since at least one arc must be present - so she must have gone through at least 3 sharp corners.\n\nClaim 2. Each internal region is simply connected, that is, has only one boundary curve.\n\nProof. Suppose, by contradiction, that some region has an outer boundary $B_{1}$ and inner boundaries $B_{2}, B_{3}, \\ldots, B_{m}(m \\geqslant 2)$. Let $P_{1}$ be one of the sharp corners of $B_{1}$.\n\nNow consider a car starting at $P_{1}$ and traveling counterclockwise along $B_{1}$. It starts in reverse, i.e., it is initially facing the corner $P_{1}$. Due to the tangent conditions, the car may travel in a way so that its orientation only changes when it is moving along an arc. In particular, this means the car will sometimes travel forward. For example, if the car approaches a sharp corner when driving in reverse, it would continue travel forward after the corner, instead of making an immediate half-turn. This way, the orientation of the car only changes in a clockwise direction since the car always travels clockwise around each arc.\n\nNow imagine there is a laser pointer at the front of the car, pointing directly ahead. Initially, the laser endpoint hits $P_{1}$, but, as soon as the car hits an arc, the endpoint moves clockwise around $B_{1}$. In fact, the laser endpoint must move continuously along $B_{1}$ ! Indeed, if the endpoint ever jumped (within $B_{1}$, or from $B_{1}$ to one of the inner boundaries), at the moment of the jump the interrupted laser would be a drawable tangent segment that Luciano missed (see figure below for an example).\n\n<img_3484>\n\n\n\nNow, let $P_{2}$ and $P_{3}$ be the next two sharp corners the car goes through, after $P_{1}$ (the previous lemma assures their existence). At $P_{2}$ the car starts moving forward, and at $P_{3}$ it will start to move in reverse again. So, at $P_{3}$, the laser endpoint is at $P_{3}$ itself. So while the car moved counterclockwise between $P_{1}$ and $P_{3}$, the laser endpoint moved clockwise between $P_{1}$ and $P_{3}$. That means the laser beam itself scanned the whole region within $B_{1}$, and it should have crossed some of the inner boundaries.\n\nClaim 3. Each region has exactly 3 sharp corners.\n\nProof. Consider again the car of the previous claim, with its laser still firmly attached to its front, traveling the same way as before and going through the same consecutive sharp corners $P_{1}, P_{2}$ and $P_{3}$. As we have seen, as the car goes counterclockwise from $P_{1}$ to $P_{3}$, the laser endpoint goes clockwise from $P_{1}$ to $P_{3}$, so together they cover the whole boundary. If there were a fourth sharp corner $P_{4}$, at some moment the laser endpoint would pass through it. But, since $P_{4}$ is a sharp corner, this means the car must be on the extension of a tangent segment going through $P_{4}$. Since the car is not on that segment itself (the car never goes through $P_{4}$ ), we would have 3 circles with a common tangent line, which is not allowed.\n\n<img_3207>\n\nWe are now ready to finish the solution. Let $r$ be the number of internal regions, and $s$ be the number of tangent segments. Since each tangent segment contributes exactly 2 sharp corners to the diagram, and each region has exactly 3 sharp corners, we must have $2 s=3 r$. Since the graph corresponding to the diagram is connected, we can use Euler's formula $n-s+r=1$ and find $s=3 n-3$ and $r=2 n-2$."
] | 6048 |
1,832 | Number Theory | null | $\boxed{807}$ | [
"807"
] | false | null | Numerical | null | Call a rational number short if it has finitely many digits in its decimal expansion. For a positive integer $m$, we say that a positive integer $t$ is $m$-tastic if there exists a number $c \in\{1,2,3, \ldots, 2017\}$ such that $\frac{10^{t}-1}{c \cdot m}$ is short, and such that $\frac{10^{k}-1}{c \cdot m}$ is not short for any $1 \leqslant k<t$. Let $S(m)$ be the set of $m$-tastic numbers. Consider $S(m)$ for $m=1,2, \ldots$ What is the maximum number of elements in $S(m)$ ? | [
"First notice that $x \\in \\mathbb{Q}$ is short if and only if there are exponents $a, b \\geqslant 0$ such that $2^{a} \\cdot 5^{b} \\cdot x \\in \\mathbb{Z}$. In fact, if $x$ is short, then $x=\\frac{n}{10^{k}}$ for some $k$ and we can take $a=b=k$; on the other hand, if $2^{a} \\cdot 5^{b} \\cdot x=q \\in \\mathbb{Z}$ then $x=\\frac{2^{b} \\cdot 5^{a} q}{10^{a+b}}$, so $x$ is short.\n\nIf $m=2^{a} \\cdot 5^{b} \\cdot s$, with $\\operatorname{gcd}(s, 10)=1$, then $\\frac{10^{t}-1}{m}$ is short if and only if $s$ divides $10^{t}-1$. So we may (and will) suppose without loss of generality that $\\operatorname{gcd}(m, 10)=1$. Define\n\n$$\nC=\\{1 \\leqslant c \\leqslant 2017: \\operatorname{gcd}(c, 10)=1\\} \\text {. }\n$$\n\nThe $m$-tastic numbers are then precisely the smallest exponents $t>0$ such that $10^{t} \\equiv 1$ $(\\bmod \\mathrm{cm})$ for some integer $c \\in C$, that is, the set of orders of 10 modulo $\\mathrm{cm}$. In other words,\n\n$$\nS(m)=\\left\\{\\operatorname{ord}_{c m}(10): c \\in C\\right\\}\n$$\n\nSince there are $4 \\cdot 201+3=807$ numbers $c$ with $1 \\leqslant c \\leqslant 2017$ and $\\operatorname{gcd}(c, 10)=1$, namely those such that $c \\equiv 1,3,7,9(\\bmod 10)$,\n\n$$\n|S(m)| \\leqslant|C|=807\n$$\n\nNow we find $m$ such that $|S(m)|=807$. Let\n\n$$\nP=\\{1<p \\leqslant 2017: p \\text { is prime, } p \\neq 2,5\\}\n$$\n\nand choose a positive integer $\\alpha$ such that every $p \\in P$ divides $10^{\\alpha}-1$ (e.g. $\\alpha=\\varphi(T), T$ being the product of all primes in $P$ ), and let $m=10^{\\alpha}-1$.\n\nClaim. For every $c \\in C$, we have\n\n$$\n\\operatorname{ord}_{c m}(10)=c \\alpha \\text {. }\n$$\n\nAs an immediate consequence, this implies $|S(m)|=|C|=807$, finishing the problem. Proof. Obviously $\\operatorname{ord}_{m}(10)=\\alpha$. Let $t=\\operatorname{ord}_{c m}(10)$. Then\n\n$$\nc m\\left|10^{t}-1 \\Longrightarrow m\\right| 10^{t}-1 \\Longrightarrow \\alpha \\mid t \\text {. }\n$$\n\nHence $t=k \\alpha$ for some $k \\in \\mathbb{Z}_{>0}$. We will show that $k=c$.\n\nDenote by $\\nu_{p}(n)$ the number of prime factors $p$ in $n$, that is, the maximum exponent $\\beta$ for which $p^{\\beta} \\mid n$. For every $\\ell \\geqslant 1$ and $p \\in P$, the Lifting the Exponent Lemma provides\n\n$$\n\\nu_{p}\\left(10^{\\ell \\alpha}-1\\right)=\\nu_{p}\\left(\\left(10^{\\alpha}\\right)^{\\ell}-1\\right)=\\nu_{p}\\left(10^{\\alpha}-1\\right)+\\nu_{p}(\\ell)=\\nu_{p}(m)+\\nu_{p}(\\ell)\n$$\n\nso\n\n$$\n\\begin{aligned}\nc m \\mid 10^{k \\alpha}-1 & \\Longleftrightarrow \\forall p \\in P ; \\nu_{p}(\\mathrm{~cm}) \\leqslant \\nu_{p}\\left(10^{k \\alpha}-1\\right) \\\\\n& \\Longleftrightarrow \\forall p \\in P ; \\nu_{p}(m)+\\nu_{p}(c) \\leqslant \\nu_{p}(m)+\\nu_{p}(k) \\\\\n& \\Longleftrightarrow \\forall p \\in P ; \\nu_{p}(c) \\leqslant \\nu_{p}(k) \\\\\n& \\Longleftrightarrow c \\mid k .\n\\end{aligned}\n$$\n\nThe first such $k$ is $k=c$, so $\\operatorname{ord}_{c m}(10)=c \\alpha$."
] | 807 |
1,833 | Number Theory | null | $\boxed{(3,2)}$ | [
"$(3,2)$"
] | false | null | Tuple | null | Find all pairs $(p, q)$ of prime numbers with $p>q$ for which the number
$$
\frac{(p+q)^{p+q}(p-q)^{p-q}-1}{(p+q)^{p-q}(p-q)^{p+q}-1}
$$
is an integer. | [
"Let $M=(p+q)^{p-q}(p-q)^{p+q}-1$, which is relatively prime with both $p+q$ and $p-q$. Denote by $(p-q)^{-1}$ the multiplicative inverse of $(p-q)$ modulo $M$.\n\nBy eliminating the term -1 in the numerator,\n\n$$\n(p+q)^{p+q}(p-q)^{p-q}-1 \\equiv(p+q)^{p-q}(p-q)^{p+q}-1 \\quad(\\bmod M)\\\\\n(p+q)^{2 q} \\equiv(p-q)^{2 q} \\quad(\\bmod M)\\tag{1}\n$$\n$$\n\\left((p+q) \\cdot(p-q)^{-1}\\right)^{2 q} \\equiv 1 \\quad(\\bmod M) .\n\\tag{2}\n$$\n\nCase 1: $q \\geqslant 5$.\n\nConsider an arbitrary prime divisor $r$ of $M$. Notice that $M$ is odd, so $r \\geqslant 3$. By (2), the multiplicative order of $\\left((p+q) \\cdot(p-q)^{-1}\\right)$ modulo $r$ is a divisor of the exponent $2 q$ in $(2)$, so it can be 1,2 , $q$ or $2 q$.\n\nBy Fermat's theorem, the order divides $r-1$. So, if the order is $q$ or $2 q$ then $r \\equiv 1(\\bmod q)$. If the order is 1 or 2 then $r \\mid(p+q)^{2}-(p-q)^{2}=4 p q$, so $r=p$ or $r=q$. The case $r=p$ is not possible, because, by applying Fermat's theorem,\n\n$M=(p+q)^{p-q}(p-q)^{p+q}-1 \\equiv q^{p-q}(-q)^{p+q}-1=\\left(q^{2}\\right)^{p}-1 \\equiv q^{2}-1=(q+1)(q-1) \\quad(\\bmod p)$\n\nand the last factors $q-1$ and $q+1$ are less than $p$ and thus $p \\nmid M$. Hence, all prime divisors of $M$ are either $q$ or of the form $k q+1$; it follows that all positive divisors of $M$ are congruent to 0 or 1 modulo $q$.\n\nNow notice that\n\n$$\nM=\\left((p+q)^{\\frac{p-q}{2}}(p-q)^{\\frac{p+q}{2}}-1\\right)\\left((p+q)^{\\frac{p-q}{2}}(p-q)^{\\frac{p+q}{2}}+1\\right)\n$$\n\nis the product of two consecutive positive odd numbers; both should be congruent to 0 or 1 modulo $q$. But this is impossible by the assumption $q \\geqslant 5$. So, there is no solution in Case 1 .\n\nCase 2: $q=2$.\n\nBy (1), we have $M \\mid(p+q)^{2 q}-(p-q)^{2 q}=(p+2)^{4}-(p-2)^{4}$, so\n\n$$\n\\begin{gathered}\n(p+2)^{p-2}(p-2)^{p+2}-1=M \\leqslant(p+2)^{4}-(p-2)^{4} \\leqslant(p+2)^{4}-1, \\\\\n(p+2)^{p-6}(p-2)^{p+2} \\leqslant 1 .\n\\end{gathered}\n$$\n\nIf $p \\geqslant 7$ then the left-hand side is obviously greater than 1 . For $p=5$ we have $(p+2)^{p-6}(p-2)^{p+2}=7^{-1} \\cdot 3^{7}$ which is also too large.\n\nThere remains only one candidate, $p=3$, which provides a solution:\n\n$$\n\\frac{(p+q)^{p+q}(p-q)^{p-q}-1}{(p+q)^{p-q}(p-q)^{p+q}-1}=\\frac{5^{5} \\cdot 1^{1}-1}{5^{1} \\cdot 1^{5}-1}=\\frac{3124}{4}=781\n$$\n\nSo in Case 2 the only solution is $(p, q)=(3,2)$.\n\n\n\nCase 3: $q=3$.\n\nSimilarly to Case 2, we have\n\n$$\nM \\mid(p+q)^{2 q}-(p-q)^{2 q}=64 \\cdot\\left(\\left(\\frac{p+3}{2}\\right)^{6}-\\left(\\frac{p-3}{2}\\right)^{6}\\right)\n$$\n\nSince $M$ is odd, we conclude that\n\n$$\nM \\mid\\left(\\frac{p+3}{2}\\right)^{6}-\\left(\\frac{p-3}{2}\\right)^{6}\n$$\n\nand\n\n$$\n\\begin{gathered}\n(p+3)^{p-3}(p-3)^{p+3}-1=M \\leqslant\\left(\\frac{p+3}{2}\\right)^{6}-\\left(\\frac{p-3}{2}\\right)^{6} \\leqslant\\left(\\frac{p+3}{2}\\right)^{6}-1 \\\\\n64(p+3)^{p-9}(p-3)^{p+3} \\leqslant 1\n\\end{gathered}\n$$\n\nIf $p \\geqslant 11$ then the left-hand side is obviously greater than 1 . If $p=7$ then the left-hand side is $64 \\cdot 10^{-2} \\cdot 4^{10}>1$. If $p=5$ then the left-hand side is $64 \\cdot 8^{-4} \\cdot 2^{8}=2^{2}>1$. Therefore, there is no solution in Case 3."
] | $(3,2)$ |
1,834 | Number Theory | null | $\boxed{3}$ | [
"3"
] | false | null | Numerical | null | Find the smallest positive integer $n$, or show that no such $n$ exists, with the following property: there are infinitely many distinct $n$-tuples of positive rational numbers $\left(a_{1}, a_{2}, \ldots, a_{n}\right)$ such that both
$$
a_{1}+a_{2}+\cdots+a_{n} \quad \text { and } \quad \frac{1}{a_{1}}+\frac{1}{a_{2}}+\cdots+\frac{1}{a_{n}}
$$
are integers. | [
"For $n=1, a_{1} \\in \\mathbb{Z}_{>0}$ and $\\frac{1}{a_{1}} \\in \\mathbb{Z}_{>0}$ if and only if $a_{1}=1$. Next we show that\n\n(i) There are finitely many $(x, y) \\in \\mathbb{Q}_{>0}^{2}$ satisfying $x+y \\in \\mathbb{Z}$ and $\\frac{1}{x}+\\frac{1}{y} \\in \\mathbb{Z}$\n\nWrite $x=\\frac{a}{b}$ and $y=\\frac{c}{d}$ with $a, b, c, d \\in \\mathbb{Z}_{>0}$ and $\\operatorname{gcd}(a, b)=\\operatorname{gcd}(c, d)=1$. Then $x+y \\in \\mathbb{Z}$ and $\\frac{1}{x}+\\frac{1}{y} \\in \\mathbb{Z}$ is equivalent to the two divisibility conditions\n\n$$\nb d \\mid a d+b c \\text { (1) and } \\quad a c \\mid a d+b c\n$$\n\nCondition (1) implies that $d|a d+b c \\Longleftrightarrow d| b c \\Longleftrightarrow d \\mid b$ since $\\operatorname{gcd}(c, d)=1$. Still from (1) we get $b|a d+b c \\Longleftrightarrow b| a d \\Longleftrightarrow b \\mid d$ since $\\operatorname{gcd}(a, b)=1$. From $b \\mid d$ and $d \\mid b$ we have $b=d$.\n\nAn analogous reasoning with condition (2) shows that $a=c$. Hence $x=\\frac{a}{b}=\\frac{c}{d}=y$, i.e., the problem amounts to finding all $x \\in \\mathbb{Q}_{>0}$ such that $2 x \\in \\mathbb{Z}_{>0}$ and $\\frac{2}{x} \\in \\mathbb{Z}_{>0}$. Letting $n=2 x \\in \\mathbb{Z}_{>0}$, we have that $\\frac{2}{x} \\in \\mathbb{Z}_{>0} \\Longleftrightarrow \\frac{4}{n} \\in \\mathbb{Z}_{>0} \\Longleftrightarrow n=1,2$ or 4 , and there are finitely many solutions, namely $(x, y)=\\left(\\frac{1}{2}, \\frac{1}{2}\\right)^{n},(1,1)$ or $(2,2)$.\n\n(ii) There are infinitely many triples $(x, y, z) \\in \\mathbb{Q}_{>0}^{2}$ such that $x+y+z \\in \\mathbb{Z}$ and $\\frac{1}{x}+\\frac{1}{y}+\\frac{1}{z} \\in \\mathbb{Z}$. We will look for triples such that $x+y+z=1$, so we may write them in the form\n\n$$\n(x, y, z)=\\left(\\frac{a}{a+b+c}, \\frac{b}{a+b+c}, \\frac{c}{a+b+c}\\right) \\quad \\text { with } a, b, c \\in \\mathbb{Z}_{>0}\n$$\n\nWe want these to satisfy\n\n$$\n\\frac{1}{x}+\\frac{1}{y}+\\frac{1}{z}=\\frac{a+b+c}{a}+\\frac{a+b+c}{b}+\\frac{a+b+c}{c} \\in \\mathbb{Z} \\Longleftrightarrow \\frac{b+c}{a}+\\frac{a+c}{b}+\\frac{a+b}{c} \\in \\mathbb{Z}\n$$\n\nFixing $a=1$, it suffices to find infinitely many pairs $(b, c) \\in \\mathbb{Z}_{>0}^{2}$ such that\n\n$$\n\\frac{1}{b}+\\frac{1}{c}+\\frac{c}{b}+\\frac{b}{c}=3 \\Longleftrightarrow b^{2}+c^{2}-3 b c+b+c=0\n\\tag{*}\n$$\n\nTo show that equation (*) has infinitely many solutions, we use Vieta jumping (also known as root flipping): starting with $b=2, c=3$, the following algorithm generates infinitely many solutions. Let $c \\geqslant b$, and view $(*)$ as a quadratic equation in $b$ for $c$ fixed:\n\n$$\nb^{2}-(3 c-1) \\cdot b+\\left(c^{2}+c\\right)=0\n\\tag{**}\n$$\n\nThen there exists another root $b_{0} \\in \\mathbb{Z}$ of $(* *)$ which satisfies $b+b_{0}=3 c-1$ and $b \\cdot b_{0}=c^{2}+c$. Since $c \\geqslant b$ by assumption,\n\n$$\nb_{0}=\\frac{c^{2}+c}{b} \\geqslant \\frac{c^{2}+c}{c}>c\n$$\n\nHence from the solution $(b, c)$ we obtain another one $\\left(c, b_{0}\\right)$ with $b_{0}>c$, and we can then \"jump\" again, this time with $c$ as the \"variable\" in the quadratic (*). This algorithm will generate an infinite sequence of distinct solutions, whose first terms are\n\n$(2,3),(3,6),(6,14),(14,35),(35,90),(90,234),(234,611),(611,1598),(1598,4182), \\ldots$",
"Call the $n$-tuples $\\left(a_{1}, a_{2}, \\ldots, a_{n}\\right) \\in \\mathbb{Q}_{>0}^{n}$ satisfying the conditions of the problem statement good, and those for which\n\n$$\nf\\left(a_{1}, \\ldots, a_{n}\\right) \\stackrel{\\text { def }}{=}\\left(a_{1}+a_{2}+\\cdots+a_{n}\\right)\\left(\\frac{1}{a_{1}}+\\frac{1}{a_{2}}+\\cdots+\\frac{1}{a_{n}}\\right)\n$$\n\nis an integer pretty. Then good $n$-tuples are pretty, and if $\\left(b_{1}, \\ldots, b_{n}\\right)$ is pretty then\n\n$$\n\\left(\\frac{b_{1}}{b_{1}+b_{2}+\\cdots+b_{n}}, \\frac{b_{2}}{b_{1}+b_{2}+\\cdots+b_{n}}, \\ldots, \\frac{b_{n}}{b_{1}+b_{2}+\\cdots+b_{n}}\\right)\n$$\n\nis good since the sum of its components is 1 , and the sum of the reciprocals of its components equals $f\\left(b_{1}, \\ldots, b_{n}\\right)$. We declare pretty $n$-tuples proportional to each other equivalent since they are precisely those which give rise to the same good $n$-tuple. Clearly, each such equivalence class contains exactly one $n$-tuple of positive integers having no common prime divisors. Call such $n$-tuple a primitive pretty tuple. Our task is to find infinitely many primitive pretty $n$-tuples.\n\nFor $n=1$, there is clearly a single primitive 1-tuple. For $n=2$, we have $f(a, b)=\\frac{(a+b)^{2}}{a b}$, which can be integral (for coprime $a, b \\in \\mathbb{Z}_{>0}$ ) only if $a=b=1$ (see for instance (i) in the first solution).\n\nNow we construct infinitely many primitive pretty triples for $n=3$. Fix $b, c, k \\in \\mathbb{Z}_{>0}$; we will try to find sufficient conditions for the existence of an $a \\in \\mathbb{Q}_{>0}$ such that $f(a, b, c)=k$. Write $\\sigma=b+c, \\tau=b c$. From $f(a, b, c)=k$, we have that $a$ should satisfy the quadratic equation\n\n$$\na^{2} \\cdot \\sigma+a \\cdot\\left(\\sigma^{2}-(k-1) \\tau\\right)+\\sigma \\tau=0\n$$\n\nwhose discriminant is\n\n$$\n\\Delta=\\left(\\sigma^{2}-(k-1) \\tau\\right)^{2}-4 \\sigma^{2} \\tau=\\left((k+1) \\tau-\\sigma^{2}\\right)^{2}-4 k \\tau^{2}\n$$\n\nWe need it to be a square of an integer, say, $\\Delta=M^{2}$ for some $M \\in \\mathbb{Z}$, i.e., we want\n\n$$\n\\left((k+1) \\tau-\\sigma^{2}\\right)^{2}-M^{2}=2 k \\cdot 2 \\tau^{2}\n$$\n\nso that it suffices to set\n\n$$\n(k+1) \\tau-\\sigma^{2}=\\tau^{2}+k, \\quad M=\\tau^{2}-k .\n$$\n\nThe first relation reads $\\sigma^{2}=(\\tau-1)(k-\\tau)$, so if $b$ and $c$ satisfy\n\n$$\n\\tau-1 \\mid \\sigma^{2} \\quad \\text { i.e. } \\quad b c-1 \\mid(b+c)^{2}\n$$\n\nthen $k=\\frac{\\sigma^{2}}{\\tau-1}+\\tau$ will be integral, and we find rational solutions to (1), namely\n\n$$\na=\\frac{\\sigma}{\\tau-1}=\\frac{b+c}{b c-1} \\quad \\text { or } \\quad a=\\frac{\\tau^{2}-\\tau}{\\sigma}=\\frac{b c \\cdot(b c-1)}{b+c}\n$$\n\n\n\nWe can now find infinitely many pairs $(b, c)$ satisfying (2) by Vieta jumping. For example, if we impose\n\n$$\n(b+c)^{2}=5 \\cdot(b c-1)\n$$\n\nthen all pairs $(b, c)=\\left(v_{i}, v_{i+1}\\right)$ satisfy the above condition, where\n\n$$\nv_{1}=2, v_{2}=3, \\quad v_{i+2}=3 v_{i+1}-v_{i} \\quad \\text { for } i \\geqslant 0\n$$\n\nFor $(b, c)=\\left(v_{i}, v_{i+1}\\right)$, one of the solutions to (1) will be $a=(b+c) /(b c-1)=5 /(b+c)=$ $5 /\\left(v_{i}+v_{i+1}\\right)$. Then the pretty triple $(a, b, c)$ will be equivalent to the integral pretty triple\n\n$$\n\\left(5, v_{i}\\left(v_{i}+v_{i+1}\\right), v_{i+1}\\left(v_{i}+v_{i+1}\\right)\\right)\n$$\n\nAfter possibly dividing by 5 , we obtain infinitely many primitive pretty triples, as required."
] | 3 |
1,838 | Algebra | null | $\boxed{\frac{1}{2}}$ | [
"$\\frac{1}{2}$"
] | false | null | Numerical | null | Find the smallest real constant $C$ such that for any positive real numbers $a_{1}, a_{2}, a_{3}, a_{4}$ and $a_{5}$ (not necessarily distinct), one can always choose distinct subscripts $i, j, k$ and $l$ such that
$$
\left|\frac{a_{i}}{a_{j}}-\frac{a_{k}}{a_{l}}\right| \leqslant C .\tag{1}
$$ | [
"We first show that $C \\leqslant \\frac{1}{2}$. For any positive real numbers $a_{1} \\leqslant a_{2} \\leqslant a_{3} \\leqslant a_{4} \\leqslant a_{5}$, consider the five fractions\n\n$$\n\\frac{a_{1}}{a_{2}}, \\frac{a_{3}}{a_{4}}, \\frac{a_{1}}{a_{5}}, \\frac{a_{2}}{a_{3}}, \\frac{a_{4}}{a_{5}}\\tag{2}\n$$\n\nEach of them lies in the interval $(0,1]$. Therefore, by the Pigeonhole Principle, at least three of them must lie in $\\left(0, \\frac{1}{2}\\right]$ or lie in $\\left(\\frac{1}{2}, 1\\right]$ simultaneously. In particular, there must be two consecutive terms in (2) which belong to an interval of length $\\frac{1}{2}$ (here, we regard $\\frac{a_{1}}{a_{2}}$ and $\\frac{a_{4}}{a_{5}}$ as consecutive). In other words, the difference of these two fractions is less than $\\frac{1}{2}$. As the indices involved in these two fractions are distinct, we can choose them to be $i, j, k, l$ and conclude that $C \\leqslant \\frac{1}{2}$.\n\nNext, we show that $C=\\frac{1}{2}$ is best possible. Consider the numbers $1,2,2,2, n$ where $n$ is a large real number. The fractions formed by two of these numbers in ascending order are $\\frac{1}{n}, \\frac{2}{n}, \\frac{1}{2}, \\frac{2}{2}, \\frac{2}{1}, \\frac{n}{2}, \\frac{n}{1}$. Since the indices $i, j, k, l$ are distinct, $\\frac{1}{n}$ and $\\frac{2}{n}$ cannot be chosen simultaneously. Therefore the minimum value of the left-hand side of (1) is $\\frac{1}{2}-\\frac{2}{n}$. When $n$ tends to infinity, this value approaches $\\frac{1}{2}$, and so $C$ cannot be less than $\\frac{1}{2}$.\n\nThese conclude that $C=\\frac{1}{2}$ is the smallest possible choice."
] | $\frac{1}{2}$ |
1,843 | Algebra | null | $\boxed{2016}$ | [
"2016"
] | false | null | Numerical | null | The equation
$$
(x-1)(x-2) \cdots(x-2016)=(x-1)(x-2) \cdots(x-2016)
$$
is written on the board. One tries to erase some linear factors from both sides so that each side still has at least one factor, and the resulting equation has no real roots. Find the least number of linear factors one needs to erase to achieve this. | [
"Since there are 2016 common linear factors on both sides, we need to erase at least 2016 factors. We claim that the equation has no real roots if we erase all factors $(x-k)$ on the left-hand side with $k \\equiv 2,3(\\bmod 4)$, and all factors $(x-m)$ on the right-hand side with $m \\equiv 0,1(\\bmod 4)$. Therefore, it suffices to show that no real number $x$ satisfies\n\n$$\n\\prod_{j=0}^{503}(x-4 j-1)(x-4 j-4)=\\prod_{j=0}^{503}(x-4 j-2)(x-4 j-3) .\n\\tag{1}\n$$\n\n- Case 1. $x=1,2, \\ldots, 2016$.\n\nIn this case, one side of (1) is zero while the other side is not. This shows $x$ cannot satisfy (1).\n\n- Case 2. $4 k+1<x<4 k+2$ or $4 k+3<x<4 k+4$ for some $k=0,1, \\ldots, 503$.\n\nFor $j=0,1, \\ldots, 503$ with $j \\neq k$, the product $(x-4 j-1)(x-4 j-4)$ is positive. For $j=k$, the product $(x-4 k-1)(x-4 k-4)$ is negative. This shows the left-hand side of (1) is negative. On the other hand, each product $(x-4 j-2)(x-4 j-3)$ on the right-hand side of (1) is positive. This yields a contradiction.\n\n- Case 3. $x<1$ or $x>2016$ or $4 k<x<4 k+1$ for some $k=1,2, \\ldots, 503$.\n\nThe equation (1) can be rewritten as\n\n$$\n1=\\prod_{j=0}^{503} \\frac{(x-4 j-1)(x-4 j-4)}{(x-4 j-2)(x-4 j-3)}=\\prod_{j=0}^{503}\\left(1-\\frac{2}{(x-4 j-2)(x-4 j-3)}\\right) .\n$$\n\nNote that $(x-4 j-2)(x-4 j-3)>2$ for $0 \\leqslant j \\leqslant 503$ in this case. So each term in the product lies strictly between 0 and 1 , and the whole product must be less than 1 , which is impossible.\n\n- Case 4. $4 k+2<x<4 k+3$ for some $k=0,1, \\ldots, 503$.\n\nThis time we rewrite (1) as\n\n$$\n\\begin{aligned}\n1 & =\\frac{x-1}{x-2} \\cdot \\frac{x-2016}{x-2015} \\prod_{j=1}^{503} \\frac{(x-4 j)(x-4 j-1)}{(x-4 j+1)(x-4 j-2)} \\\\\n& =\\frac{x-1}{x-2} \\cdot \\frac{x-2016}{x-2015} \\prod_{j=1}^{503}\\left(1+\\frac{2}{(x-4 j+1)(x-4 j-2)}\\right) .\n\\end{aligned}\n$$\n\nClearly, $\\frac{x-1}{x-2}$ and $\\frac{x-2016}{x-2015}$ are both greater than 1 . For the range of $x$ in this case, each term in the product is also greater than 1 . Then the right-hand side must be greater than 1 and hence a contradiction arises.\n\n\n\nFrom the four cases, we conclude that (1) has no real roots. Hence, the minimum number of linear factors to be erased is 2016 ."
] | 2016 |
1,845 | Algebra | null | $\boxed{\frac{4}{9}}$ | [
"$\\frac{4}{9}$"
] | false | null | Numerical | null | Determine the largest real number $a$ such that for all $n \geqslant 1$ and for all real numbers $x_{0}, x_{1}, \ldots, x_{n}$ satisfying $0=x_{0}<x_{1}<x_{2}<\cdots<x_{n}$, we have
$$
\frac{1}{x_{1}-x_{0}}+\frac{1}{x_{2}-x_{1}}+\cdots+\frac{1}{x_{n}-x_{n-1}} \geqslant a\left(\frac{2}{x_{1}}+\frac{3}{x_{2}}+\cdots+\frac{n+1}{x_{n}}\right) .\tag{1}
$$ | [
"We first show that $a=\\frac{4}{9}$ is admissible. For each $2 \\leqslant k \\leqslant n$, by the CauchySchwarz Inequality, we have\n\n$$\n\\left(x_{k-1}+\\left(x_{k}-x_{k-1}\\right)\\right)\\left(\\frac{(k-1)^{2}}{x_{k-1}}+\\frac{3^{2}}{x_{k}-x_{k-1}}\\right) \\geqslant(k-1+3)^{2},\n$$\n\nwhich can be rewritten as\n\n$$\n\\frac{9}{x_{k}-x_{k-1}} \\geqslant \\frac{(k+2)^{2}}{x_{k}}-\\frac{(k-1)^{2}}{x_{k-1}}\\tag{2}\n$$\n\nSumming (2) over $k=2,3, \\ldots, n$ and adding $\\frac{9}{x_{1}}$ to both sides, we have\n\n$$\n9 \\sum_{k=1}^{n} \\frac{1}{x_{k}-x_{k-1}} \\geqslant 4 \\sum_{k=1}^{n} \\frac{k+1}{x_{k}}+\\frac{n^{2}}{x_{n}}>4 \\sum_{k=1}^{n} \\frac{k+1}{x_{k}}\n$$\n\nThis shows (1) holds for $a=\\frac{4}{9}$.\n\nNext, we show that $a=\\frac{4}{9}$ is the optimal choice. Consider the sequence defined by $x_{0}=0$ and $x_{k}=x_{k-1}+k(k+1)$ for $k \\geqslant 1$, that is, $x_{k}=\\frac{1}{3} k(k+1)(k+2)$. Then the left-hand side of (1) equals\n\n$$\n\\sum_{k=1}^{n} \\frac{1}{k(k+1)}=\\sum_{k=1}^{n}\\left(\\frac{1}{k}-\\frac{1}{k+1}\\right)=1-\\frac{1}{n+1}\n$$\n\nwhile the right-hand side equals\n\n$$\na \\sum_{k=1}^{n} \\frac{k+1}{x_{k}}=3 a \\sum_{k=1}^{n} \\frac{1}{k(k+2)}=\\frac{3}{2} a \\sum_{k=1}^{n}\\left(\\frac{1}{k}-\\frac{1}{k+2}\\right)=\\frac{3}{2}\\left(1+\\frac{1}{2}-\\frac{1}{n+1}-\\frac{1}{n+2}\\right) a .\n$$\n\nWhen $n$ tends to infinity, the left-hand side tends to 1 while the right-hand side tends to $\\frac{9}{4} a$. Therefore $a$ has to be at most $\\frac{4}{9}$.\n\nHence the largest value of $a$ is $\\frac{4}{9}$.",
"We shall give an alternative method to establish (1) with $a=\\frac{4}{9}$. We define $y_{k}=x_{k}-x_{k-1}>0$ for $1 \\leqslant k \\leqslant n$. By the Cauchy-Schwarz Inequality, for $1 \\leqslant k \\leqslant n$, we have\n\n$$\n\\left(y_{1}+y_{2}+\\cdots+y_{k}\\right)\\left(\\sum_{j=1}^{k} \\frac{1}{y_{j}}\\left(\\begin{array}{c}\nj+1 \\\\\n2\n\\end{array}\\right)^{2}\\right) \\geqslant\\left(\\left(\\begin{array}{l}\n2 \\\\\n2\n\\end{array}\\right)+\\left(\\begin{array}{l}\n3 \\\\\n2\n\\end{array}\\right)+\\cdots+\\left(\\begin{array}{c}\nk+1 \\\\\n2\n\\end{array}\\right)\\right)^{2}=\\left(\\begin{array}{c}\nk+2 \\\\\n3\n\\end{array}\\right)^{2} .\n$$\n\n\n\nThis can be rewritten as\n\n$$\n\\frac{k+1}{y_{1}+y_{2}+\\cdots+y_{k}} \\leqslant \\frac{36}{k^{2}(k+1)(k+2)^{2}}\\left(\\sum_{j=1}^{k} \\frac{1}{y_{j}}\\left(\\begin{array}{c}\nj+1 \\\\\n2\n\\end{array}\\right)^{2}\\right) .\n\\tag{3}\n$$\n\nSumming (3) over $k=1,2, \\ldots, n$, we get\n\n$$\n\\frac{2}{y_{1}}+\\frac{3}{y_{1}+y_{2}}+\\cdots+\\frac{n+1}{y_{1}+y_{2}+\\cdots+y_{n}} \\leqslant \\frac{c_{1}}{y_{1}}+\\frac{c_{2}}{y_{2}}+\\cdots+\\frac{c_{n}}{y_{n}}\n\\tag{4}\n$$\n\nwhere for $1 \\leqslant m \\leqslant n$,\n\n$$\n\\begin{aligned}\nc_{m} & =36\\left(\\begin{array}{c}\nm+1 \\\\\n2\n\\end{array}\\right)^{2} \\sum_{k=m}^{n} \\frac{1}{k^{2}(k+1)(k+2)^{2}} \\\\\n& =\\frac{9 m^{2}(m+1)^{2}}{4} \\sum_{k=m}^{n}\\left(\\frac{1}{k^{2}(k+1)^{2}}-\\frac{1}{(k+1)^{2}(k+2)^{2}}\\right) \\\\\n& =\\frac{9 m^{2}(m+1)^{2}}{4}\\left(\\frac{1}{m^{2}(m+1)^{2}}-\\frac{1}{(n+1)^{2}(n+2)^{2}}\\right)<\\frac{9}{4} .\n\\end{aligned}\n$$\n\nFrom (4), the inequality (1) holds for $a=\\frac{4}{9}$. This is also the upper bound as can be verified in the same way as"
] | $\frac{4}{9}$ |
1,847 | Combinatorics | null | $\boxed{1}$ | [
"1"
] | false | null | Numerical | null | Find all positive integers $n$ for which all positive divisors of $n$ can be put into the cells of a rectangular table under the following constraints:
- each cell contains a distinct divisor;
- the sums of all rows are equal; and
- the sums of all columns are equal. | [
"Suppose all positive divisors of $n$ can be arranged into a rectangular table of size $k \\times l$ where the number of rows $k$ does not exceed the number of columns $l$. Let the sum of numbers in each column be $s$. Since $n$ belongs to one of the columns, we have $s \\geqslant n$, where equality holds only when $n=1$.\n\nFor $j=1,2, \\ldots, l$, let $d_{j}$ be the largest number in the $j$-th column. Without loss of generality, assume $d_{1}>d_{2}>\\cdots>d_{l}$. Since these are divisors of $n$, we have\n\n$$\nd_{l} \\leqslant \\frac{n}{l}\\tag{1}\n$$\n\nAs $d_{l}$ is the maximum entry of the $l$-th column, we must have\n\n$$\nd_{l} \\geqslant \\frac{s}{k} \\geqslant \\frac{n}{k}\\tag{2}\n$$\n\nThe relations (1) and (2) combine to give $\\frac{n}{l} \\geqslant \\frac{n}{k}$, that is, $k \\geqslant l$. Together with $k \\leqslant l$, we conclude that $k=l$. Then all inequalities in (1) and (2) are equalities. In particular, $s=n$ and so $n=1$, in which case the conditions are clearly satisfied.",
"Clearly $n=1$ works. Then we assume $n>1$ and let its prime factorization be $n=p_{1}^{r_{1}} p_{2}^{r_{2}} \\cdots p_{t}^{r_{t}}$. Suppose the table has $k$ rows and $l$ columns with $1<k \\leqslant l$. Note that $k l$ is the number of positive divisors of $n$ and the sum of all entries is the sum of positive divisors of $n$, which we denote by $\\sigma(n)$. Consider the column containing $n$. Since the column sum is $\\frac{\\sigma(n)}{l}$, we must have $\\frac{\\sigma(n)}{l}>n$. Therefore, we have\n\n$$\n\\begin{aligned}\n\\left(r_{1}+1\\right)\\left(r_{2}+1\\right) \\cdots\\left(r_{t}+1\\right) & =k l \\leqslant l^{2}<\\left(\\frac{\\sigma(n)}{n}\\right)^{2} \\\\\n& =\\left(1+\\frac{1}{p_{1}}+\\cdots+\\frac{1}{p_{1}^{r_{1}}}\\right)^{2} \\cdots\\left(1+\\frac{1}{p_{t}}+\\cdots+\\frac{1}{p_{t}^{r_{t}}}\\right)^{2} .\n\\end{aligned}\n$$\n\nThis can be rewritten as\n\n$$\nf\\left(p_{1}, r_{1}\\right) f\\left(p_{2}, r_{2}\\right) \\cdots f\\left(p_{t}, r_{t}\\right)<1\n\\tag{3}\n$$\n\nwhere\n\n$$\nf(p, r)=\\frac{r+1}{\\left(1+\\frac{1}{p}+\\cdots+\\frac{1}{p^{r}}\\right)^{2}}=\\frac{(r+1)\\left(1-\\frac{1}{p}\\right)^{2}}{\\left(1-\\frac{1}{p^{r+1}}\\right)^{2}}\n$$\n\n\n\nDirect computation yields\n\n$$\nf(2,1)=\\frac{8}{9}, \\quad f(2,2)=\\frac{48}{49}, \\quad f(3,1)=\\frac{9}{8}\n$$\n\nAlso, we find that\n\n$$\n\\begin{aligned}\n& f(2, r) \\geqslant\\left(1-\\frac{1}{2^{r+1}}\\right)^{-2}>1 \\quad \\text { for } r \\geqslant 3, \\\\\n& f(3, r) \\geqslant \\frac{4}{3}\\left(1-\\frac{1}{3^{r+1}}\\right)^{-2}>\\frac{4}{3}>\\frac{9}{8} \\quad \\text { for } r \\geqslant 2, \\text { and } \\\\\n& f(p, r) \\geqslant \\frac{32}{25}\\left(1-\\frac{1}{p^{r+1}}\\right)^{-2}>\\frac{32}{25}>\\frac{9}{8} \\quad \\text { for } p \\geqslant 5 .\n\\end{aligned}\n$$\n\nFrom these values and bounds, it is clear that (3) holds only when $n=2$ or 4 . In both cases, it is easy to see that the conditions are not satisfied. Hence, the only possible $n$ is 1 ."
] | 1 |
1,854 | Combinatorics | null | $\boxed{2 n}$ | [
"$2 n$"
] | false | null | Expression | null | Let $n$ be a positive integer. Determine the smallest positive integer $k$ with the following property: it is possible to mark $k$ cells on a $2 n \times 2 n$ board so that there exists a unique partition of the board into $1 \times 2$ and $2 \times 1$ dominoes, none of which contains two marked cells. | [
"We first construct an example of marking $2 n$ cells satisfying the requirement. Label the rows and columns $1,2, \\ldots, 2 n$ and label the cell in the $i$-th row and the $j$-th column $(i, j)$.\n\nFor $i=1,2, \\ldots, n$, we mark the cells $(i, i)$ and $(i, i+1)$. We claim that the required partition exists and is unique. The two diagonals of the board divide the board into four regions. Note that the domino covering cell $(1,1)$ must be vertical. This in turn shows that each domino covering $(2,2),(3,3), \\ldots,(n, n)$ is vertical. By induction, the dominoes in the left region are all vertical. By rotational symmetry, the dominoes in the bottom region are horizontal, and so on. This shows that the partition exists and is unique.\n<img_3889>\n\nIt remains to show that this value of $k$ is the smallest possible. Assume that only $k<2 n$ cells are marked, and there exists a partition $P$ satisfying the requirement. It suffices to show there exists another desirable partition distinct from $P$. Let $d$ be the main diagonal of the board.\n\nConstruct the following graph with edges of two colours. Its vertices are the cells of the board. Connect two vertices with a red edge if they belong to the same domino of $P$. Connect two vertices with a blue edge if their reflections in $d$ are connected by a red edge. It is possible that two vertices are connected by edges of both colours. Clearly, each vertex has both red and blue degrees equal to 1 . Thus the graph splits into cycles where the colours of edges in each cycle alternate (a cycle may have length 2).\n\nConsider any cell $c$ lying on the diagonal $d$. Its two edges are symmetrical with respect to $d$. Thus they connect $c$ to different cells. This shows $c$ belongs to a cycle $C(c)$ of length at least 4. Consider a part of this cycle $c_{0}, c_{1}, \\ldots, c_{m}$ where $c_{0}=c$ and $m$ is the least positive integer such that $c_{m}$ lies on $d$. Clearly, $c_{m}$ is distinct from $c$. From the construction, the path symmetrical to this with respect to $d$ also lies in the graph, and so these paths together form $C(c)$. Hence, $C(c)$ contains exactly two cells from $d$. Then all $2 n$ cells in $d$ belong to $n$ cycles $C_{1}, C_{2}, \\ldots, C_{n}$, each has length at least 4.\n\nBy the Pigeonhole Principle, there exists a cycle $C_{i}$ containing at most one of the $k$ marked cells. We modify $P$ as follows. We remove all dominoes containing the vertices of $C_{i}$, which\n\n\n\ncorrespond to the red edges of $C_{i}$. Then we put the dominoes corresponding to the blue edges of $C_{i}$. Since $C_{i}$ has at least 4 vertices, the resultant partition $P^{\\prime}$ is different from $P$. Clearly, no domino in $P^{\\prime}$ contains two marked cells as $C_{i}$ contains at most one marked cell. This shows the partition is not unique and hence $k$ cannot be less than $2 n$."
] | $2 n$ |
1,866 | Number Theory | null | $\boxed{6}$ | [
"6"
] | false | null | Numerical | null | Define $P(n)=n^{2}+n+1$. For any positive integers $a$ and $b$, the set
$$
\{P(a), P(a+1), P(a+2), \ldots, P(a+b)\}
$$
is said to be fragrant if none of its elements is relatively prime to the product of the other elements. Determine the smallest size of a fragrant set. | [
"We have the following observations.\n\n(i) $(P(n), P(n+1))=1$ for any $n$.\n\nWe have $(P(n), P(n+1))=\\left(n^{2}+n+1, n^{2}+3 n+3\\right)=\\left(n^{2}+n+1,2 n+2\\right)$. Noting that $n^{2}+n+1$ is odd and $\\left(n^{2}+n+1, n+1\\right)=(1, n+1)=1$, the claim follows.\n\n(ii) $(P(n), P(n+2))=1$ for $n \\not \\equiv 2(\\bmod 7)$ and $(P(n), P(n+2))=7$ for $n \\equiv 2(\\bmod 7)$.\n\nFrom $(2 n+7) P(n)-(2 n-1) P(n+2)=14$ and the fact that $P(n)$ is odd, $(P(n), P(n+2))$ must be a divisor of 7 . The claim follows by checking $n \\equiv 0,1, \\ldots, 6(\\bmod 7)$ directly.\n\n(iii) $(P(n), P(n+3))=1$ for $n \\not \\equiv 1(\\bmod 3)$ and $3 \\mid(P(n), P(n+3))$ for $n \\equiv 1(\\bmod 3)$.\n\nFrom $(n+5) P(n)-(n-1) P(n+3)=18$ and the fact that $P(n)$ is odd, $(P(n), P(n+3))$ must be a divisor of 9 . The claim follows by checking $n \\equiv 0,1,2(\\bmod 3)$ directly.\n\nSuppose there exists a fragrant set with at most 5 elements. We may assume it contains exactly 5 elements $P(a), P(a+1), \\ldots, P(a+4)$ since the following argument also works with fewer elements. Consider $P(a+2)$. From (i), it is relatively prime to $P(a+1)$ and $P(a+3)$. Without loss of generality, assume $(P(a), P(a+2))>1$. From (ii), we have $a \\equiv 2(\\bmod 7)$. The same observation implies $(P(a+1), P(a+3))=1$. In order that the set is fragrant, $(P(a), P(a+3))$ and $(P(a+1), P(a+4))$ must both be greater than 1 . From (iii), this holds only when both $a$ and $a+1$ are congruent to $1 \\bmod 3$, which is a contradiction.\n\nIt now suffices to construct a fragrant set of size 6 . By the Chinese Remainder Theorem, we can take a positive integer $a$ such that\n\n$$\na \\equiv 7 \\quad(\\bmod 19), \\quad a+1 \\equiv 2 \\quad(\\bmod 7), \\quad a+2 \\equiv 1 \\quad(\\bmod 3)\n$$\n\nFor example, we may take $a=197$. From (ii), both $P(a+1)$ and $P(a+3)$ are divisible by 7. From (iii), both $P(a+2)$ and $P(a+5)$ are divisible by 3 . One also checks from $19 \\mid P(7)=57$ and $19 \\mid P(11)=133$ that $P(a)$ and $P(a+4)$ are divisible by 19 . Therefore, the set $\\{P(a), P(a+1), \\ldots, P(a+5)\\}$ is fragrant.\n\nTherefore, the smallest size of a fragrant set is 6 ."
] | 6 |
1,869 | Number Theory | null | $\boxed{f(n)=n^{2}}$ | [
"$f(n)=n^{2}$"
] | false | null | Expression | null | Denote by $\mathbb{N}$ the set of all positive integers. Find all functions $f: \mathbb{N} \rightarrow \mathbb{N}$ such that for all positive integers $m$ and $n$, the integer $f(m)+f(n)-m n$ is nonzero and divides $m f(m)+n f(n)$. | [
"It is given that\n\n$$\nf(m)+f(n)-m n \\mid m f(m)+n f(n) .\n\\tag{1}\n$$\n\nTaking $m=n=1$ in (1), we have $2 f(1)-1 \\mid 2 f(1)$. Then $2 f(1)-1 \\mid 2 f(1)-(2 f(1)-1)=1$ and hence $f(1)=1$.\n\nLet $p \\geqslant 7$ be a prime. Taking $m=p$ and $n=1$ in (1), we have $f(p)-p+1 \\mid p f(p)+1$ and hence\n\n$$\nf(p)-p+1 \\mid p f(p)+1-p(f(p)-p+1)=p^{2}-p+1 .\n$$\n\nIf $f(p)-p+1=p^{2}-p+1$, then $f(p)=p^{2}$. If $f(p)-p+1 \\neq p^{2}-p+1$, as $p^{2}-p+1$ is an odd positive integer, we have $p^{2}-p+1 \\geqslant 3(f(p)-p+1)$, that is,\n\n$$\nf(p) \\leqslant \\frac{1}{3}\\left(p^{2}+2 p-2\\right)\n\\tag{2}\n$$\n\nTaking $m=n=p$ in (1), we have $2 f(p)-p^{2} \\mid 2 p f(p)$. This implies\n\n$$\n2 f(p)-p^{2} \\mid 2 p f(p)-p\\left(2 f(p)-p^{2}\\right)=p^{3} .\n$$\n\nBy $(2)$ and $f(p) \\geqslant 1$, we get\n\n$$\n-p^{2}<2 f(p)-p^{2} \\leqslant \\frac{2}{3}\\left(p^{2}+2 p-2\\right)-p^{2}<-p\n$$\n\nsince $p \\geqslant 7$. This contradicts the fact that $2 f(p)-p^{2}$ is a factor of $p^{3}$. Thus we have proved that $f(p)=p^{2}$ for all primes $p \\geqslant 7$.\n\nLet $n$ be a fixed positive integer. Choose a sufficiently large prime $p$. Consider $m=p$ in (1). We obtain\n\n$$\nf(p)+f(n)-p n \\mid p f(p)+n f(n)-n(f(p)+f(n)-p n)=p f(p)-n f(p)+p n^{2} .\n$$\n\nAs $f(p)=p^{2}$, this implies $p^{2}-p n+f(n) \\mid p\\left(p^{2}-p n+n^{2}\\right)$. As $p$ is sufficiently large and $n$ is fixed, $p$ cannot divide $f(n)$, and so $\\left(p, p^{2}-p n+f(n)\\right)=1$. It follows that $p^{2}-p n+f(n) \\mid p^{2}-p n+n^{2}$ and hence\n\n$$\np^{2}-p n+f(n) \\mid\\left(p^{2}-p n+n^{2}\\right)-\\left(p^{2}-p n+f(n)\\right)=n^{2}-f(n) .\n$$\n\nNote that $n^{2}-f(n)$ is fixed while $p^{2}-p n+f(n)$ is chosen to be sufficiently large. Therefore, we must have $n^{2}-f(n)=0$ so that $f(n)=n^{2}$ for any positive integer $n$.\n\nFinally, we check that when $f(n)=n^{2}$ for any positive integer $n$, then\n\n$$\nf(m)+f(n)-m n=m^{2}+n^{2}-m n\n$$\n\nand\n\n$$\nm f(m)+n f(n)=m^{3}+n^{3}=(m+n)\\left(m^{2}+n^{2}-m n\\right) .\n$$\n\nThe latter expression is divisible by the former for any positive integers $m, n$. This shows $f(n)=n^{2}$ is the only solution."
] | $f(n)=n^{2}$ |
1,872 | Algebra | null | $\boxed{\frac{N}{2}}$ | [
"$\\frac{N}{2}$"
] | false | null | Expression | null | Let $n$ be a positive integer, and set $N=2^{n}$. Determine the smallest real number $a_{n}$ such that, for all real $x$,
$$
\sqrt[N]{\frac{x^{2 N}+1}{2}} \leqslant a_{n}(x-1)^{2}+x
$$ | [
"First of all, assume that $a_{n}<N / 2$ satisfies the condition. Take $x=1+t$ for $t>0$, we should have\n\n$$\n\\frac{(1+t)^{2 N}+1}{2} \\leqslant\\left(1+t+a_{n} t^{2}\\right)^{N}\n$$\n\nExpanding the brackets we get\n\n$$\n\\left(1+t+a_{n} t^{2}\\right)^{N}-\\frac{(1+t)^{2 N}+1}{2}=\\left(N a_{n}-\\frac{N^{2}}{2}\\right) t^{2}+c_{3} t^{3}+\\ldots+c_{2 N} t^{2 N}\n\\tag{1}\n$$\n\nwith some coefficients $c_{3}, \\ldots, c_{2 N}$. Since $a_{n}<N / 2$, the right hand side of (1) is negative for sufficiently small $t$. A contradiction.\n\nIt remains to prove the following inequality\n\n$$\n\\text{let }\\mathcal{I}(N, x)\\text{ be }\\sqrt[N]{\\frac{1+x^{2 N}}{2}} \\leqslant x+\\frac{N}{2}(x-1)^{2}\n$$\n\nwhere $N=2^{n}$.\n\nUse induction in $n$. The base case $n=0$ is trivial: $N=1$ and both sides of $\\mathcal{I}(N, x)$ are equal to $\\left(1+x^{2}\\right) / 2$. For completing the induction we prove $\\mathcal{I}(2 N, x)$ assuming that $\\mathcal{I}(N, y)$ is established for all real $y$. We have\n\n$$\n\\begin{aligned}\n\\left(x+N(x-1)^{2}\\right)^{2} & =x^{2}+N^{2}(x-1)^{4}+N(x-1)^{2} \\frac{(x+1)^{2}-(x-1)^{2}}{2} \\\\\n& =x^{2}+\\frac{N}{2}\\left(x^{2}-1\\right)^{2}+\\left(N^{2}-\\frac{N}{2}\\right)(x-1)^{4} \\geqslant x^{2}+\\frac{N}{2}\\left(x^{2}-1\\right)^{2} \\geqslant \\sqrt[N]{\\frac{1+x^{4 N}}{2}}\n\\end{aligned}\n$$\n\nwhere the last inequality is $\\mathcal{I}\\left(N, x^{2}\\right)$. Since\n\n$$\nx+N(x-1)^{2} \\geqslant x+\\frac{(x-1)^{2}}{2}=\\frac{x^{2}+1}{2} \\geqslant 0\n$$\n\ntaking square root we get $\\mathcal{I}(2 N, x)$. The inductive step is complete."
] | $\frac{N}{2}$ |
1,873 | Algebra | null | $\boxed{4}$ | [
"4"
] | false | null | Numerical | null | Let $\mathcal{A}$ denote the set of all polynomials in three variables $x, y, z$ with integer coefficients. Let $\mathcal{B}$ denote the subset of $\mathcal{A}$ formed by all polynomials which can be expressed as
$$
(x+y+z) P(x, y, z)+(x y+y z+z x) Q(x, y, z)+x y z R(x, y, z)
$$
with $P, Q, R \in \mathcal{A}$. Find the smallest non-negative integer $n$ such that $x^{i} y^{j} z^{k} \in \mathcal{B}$ for all nonnegative integers $i, j, k$ satisfying $i+j+k \geqslant n$. | [
"We start by showing that $n \\leqslant 4$, i.e., any monomial $f=x^{i} y^{j} z^{k}$ with $i+j+k \\geqslant 4$ belongs to $\\mathcal{B}$. Assume that $i \\geqslant j \\geqslant k$, the other cases are analogous.\n\nLet $x+y+z=p, x y+y z+z x=q$ and $x y z=r$. Then\n\n$$\n0=(x-x)(x-y)(x-z)=x^{3}-p x^{2}+q x-r\n$$\n\ntherefore $x^{3} \\in \\mathcal{B}$. Next, $x^{2} y^{2}=x y q-(x+y) r \\in \\mathcal{B}$.\n\nIf $k \\geqslant 1$, then $r$ divides $f$, thus $f \\in \\mathcal{B}$. If $k=0$ and $j \\geqslant 2$, then $x^{2} y^{2}$ divides $f$, thus we have $f \\in \\mathcal{B}$ again. Finally, if $k=0, j \\leqslant 1$, then $x^{3}$ divides $f$ and $f \\in \\mathcal{B}$ in this case also.\n\nIn order to prove that $n \\geqslant 4$, we show that the monomial $x^{2} y$ does not belong to $\\mathcal{B}$. Assume the contrary:\n\n$$\nx^{2} y=p P+q Q+r R\n\\tag{1}\n$$\n\nfor some polynomials $P, Q, R$. If polynomial $P$ contains the monomial $x^{2}$ (with nonzero coefficient), then $p P+q Q+r R$ contains the monomial $x^{3}$ with the same nonzero coefficient. So $P$ does not contain $x^{2}, y^{2}, z^{2}$ and we may write\n\n$$\nx^{2} y=(x+y+z)(a x y+b y z+c z x)+(x y+y z+z x)(d x+e y+f z)+g x y z\n$$\n\nwhere $a, b, c ; d, e, f ; g$ are the coefficients of $x y, y z, z x ; x, y, z ; x y z$ in the polynomials $P$; $Q ; R$, respectively (the remaining coefficients do not affect the monomials of degree 3 in $p P+q Q+r R$ ). By considering the coefficients of $x y^{2}$ we get $e=-a$, analogously $e=-b$, $f=-b, f=-c, d=-c$, thus $a=b=c$ and $f=e=d=-a$, but then the coefficient of $x^{2} y$ in the right hand side equals $a+d=0 \\neq 1$."
] | 4 |
1,874 | Algebra | null | $\boxed{8}$ | [
"8"
] | false | null | Numerical | null | Suppose that $a, b, c, d$ are positive real numbers satisfying $(a+c)(b+d)=a c+b d$. Find the smallest possible value of
$$
S=\frac{a}{b}+\frac{b}{c}+\frac{c}{d}+\frac{d}{a}
$$ | [
"To show that $S \\geqslant 8$, apply the AM-GM inequality twice as follows:\n\n$$\n\\left(\\frac{a}{b}+\\frac{c}{d}\\right)+\\left(\\frac{b}{c}+\\frac{d}{a}\\right) \\geqslant 2 \\sqrt{\\frac{a c}{b d}}+2 \\sqrt{\\frac{b d}{a c}}=\\frac{2(a c+b d)}{\\sqrt{a b c d}}=\\frac{2(a+c)(b+d)}{\\sqrt{a b c d}} \\geqslant 2 \\cdot \\frac{2 \\sqrt{a c} \\cdot 2 \\sqrt{b d}}{\\sqrt{a b c d}}=8 .\n$$\n\nThe above inequalities turn into equalities when $a=c$ and $b=d$. Then the condition $(a+c)(b+d)=a c+b d$ can be rewritten as $4 a b=a^{2}+b^{2}$. So it is satisfied when $a / b=2 \\pm \\sqrt{3}$. Hence, $S$ attains value 8 , e.g., when $a=c=1$ and $b=d=2+\\sqrt{3}$.",
"By homogeneity we may suppose that $a b c d=1$. Let $a b=C, b c=A$ and $c a=B$. Then $a, b, c$ can be reconstructed from $A, B$ and $C$ as $a=\\sqrt{B C / A}, b=\\sqrt{A C / B}$ and $c=\\sqrt{A B / C}$. Moreover, the condition $(a+c)(b+d)=a c+b d$ can be written in terms of $A, B, C$ as\n\n$$\nA+\\frac{1}{A}+C+\\frac{1}{C}=b c+a d+a b+c d=(a+c)(b+d)=a c+b d=B+\\frac{1}{B} .\n$$\n\nWe then need to minimize the expression\n\n$$\n\\begin{aligned}\nS & :=\\frac{a d+b c}{b d}+\\frac{a b+c d}{a c}=\\left(A+\\frac{1}{A}\\right) B+\\left(C+\\frac{1}{C}\\right) \\frac{1}{B} \\\\\n& =\\left(A+\\frac{1}{A}\\right)\\left(B-\\frac{1}{B}\\right)+\\left(A+\\frac{1}{A}+C+\\frac{1}{C}\\right) \\frac{1}{B} \\\\\n& =\\left(A+\\frac{1}{A}\\right)\\left(B-\\frac{1}{B}\\right)+\\left(B+\\frac{1}{B}\\right) \\frac{1}{B} .\n\\end{aligned}\n$$\n\nWithout loss of generality assume that $B \\geqslant 1$ (otherwise, we may replace $B$ by $1 / B$ and swap $A$ and $C$, this changes neither the relation nor the function to be maximized). Therefore, we can write\n\n$$\nS \\geqslant 2\\left(B-\\frac{1}{B}\\right)+\\left(B+\\frac{1}{B}\\right) \\frac{1}{B}=2 B+\\left(1-\\frac{1}{B}\\right)^{2}=: f(B)\n$$\n\nClearly, $f$ increases on $[1, \\infty)$. Since\n\n$$\nB+\\frac{1}{B}=A+\\frac{1}{A}+C+\\frac{1}{C} \\geqslant 4\n$$\n\nwe have $B \\geqslant B^{\\prime}$, where $B^{\\prime}=2+\\sqrt{3}$ is the unique root greater than 1 of the equation $B^{\\prime}+1 / B^{\\prime}=4$. Hence,\n\n$$\nS \\geqslant f(B) \\geqslant f\\left(B^{\\prime}\\right)=2\\left(B^{\\prime}-\\frac{1}{B^{\\prime}}\\right)+\\left(B^{\\prime}+\\frac{1}{B^{\\prime}}\\right) \\frac{1}{B^{\\prime}}=2 B^{\\prime}-\\frac{2}{B^{\\prime}}+\\frac{4}{B^{\\prime}}=8\n$$\n\nIt remains to note that when $A=C=1$ and $B=B^{\\prime}$ we have the equality $S=8$.",
"We present another proof of the inequality $S \\geqslant 8$. We start with the estimate\n\n$$\n\\left(\\frac{a}{b}+\\frac{c}{d}\\right)+\\left(\\frac{b}{c}+\\frac{d}{a}\\right) \\geqslant 2 \\sqrt{\\frac{a c}{b d}}+2 \\sqrt{\\frac{b d}{a c}}\n$$\n\nLet $y=\\sqrt{a c}$ and $z=\\sqrt{b d}$, and assume, without loss of generality, that $a c \\geqslant b d$. By the AM-GM inequality, we have\n\n$$\ny^{2}+z^{2}=a c+b d=(a+c)(b+d) \\geqslant 2 \\sqrt{a c} \\cdot 2 \\sqrt{b d}=4 y z .\n$$\n\nSubstituting $x=y / z$, we get $4 x \\leqslant x^{2}+1$. For $x \\geqslant 1$, this holds if and only if $x \\geqslant 2+\\sqrt{3}$.\n\nNow we have\n\n$$\n2 \\sqrt{\\frac{a c}{b d}}+2 \\sqrt{\\frac{b d}{a c}}=2\\left(x+\\frac{1}{x}\\right)\n$$\n\nClearly, this is minimized by setting $x(\\geqslant 1)$ as close to 1 as possible, i.e., by taking $x=2+\\sqrt{3}$. Then $2(x+1 / x)=2((2+\\sqrt{3})+(2-\\sqrt{3}))=8$, as required."
] | 8 |
1,879 | Algebra | null | $\boxed{f(x)=x+1}$ | [
"$f(x)=x+1$"
] | false | null | Expression | null | Let $\mathbb{R}^{+}$be the set of positive real numbers. Determine all functions $f: \mathbb{R}^{+} \rightarrow \mathbb{R}^{+}$ such that, for all positive real numbers $x$ and $y$,
$$
f(x+f(x y))+y=f(x) f(y)+1
\tag{*}
$$ | [
"A straightforward check shows that $f(x)=x+1$ satisfies (*). We divide the proof of the converse statement into a sequence of steps.\n\nStep 1: $f$ is injective.\n\nPut $x=1$ in (*) and rearrange the terms to get\n\n$$\ny=f(1) f(y)+1-f(1+f(y))\n$$\n\nTherefore, if $f\\left(y_{1}\\right)=f\\left(y_{2}\\right)$, then $y_{1}=y_{2}$.\n\nStep 2: $f$ is (strictly) monotone increasing.\n\nFor any fixed $y \\in \\mathbb{R}^{+}$, the function\n\n$$\ng(x):=f(x+f(x y))=f(x) f(y)+1-y\n$$\n\nis injective by Step 1. Therefore, $x_{1}+f\\left(x_{1} y\\right) \\neq x_{2}+f\\left(x_{2} y\\right)$ for all $y, x_{1}, x_{2} \\in \\mathbb{R}^{+}$with $x_{1} \\neq x_{2}$. Plugging in $z_{i}=x_{i} y$, we arrive at\n\n$$\n\\frac{z_{1}-z_{2}}{y} \\neq f\\left(z_{2}\\right)-f\\left(z_{1}\\right), \\quad \\text { or } \\quad \\frac{1}{y} \\neq \\frac{f\\left(z_{2}\\right)-f\\left(z_{1}\\right)}{z_{1}-z_{2}}\n$$\n\nfor all $y, z_{1}, z_{2} \\in \\mathbb{R}^{+}$with $z_{1} \\neq z_{2}$. This means that the right-hand side of the rightmost relation is always non-positive, i.e., $f$ is monotone non-decreasing. Since $f$ is injective, it is strictly monotone.\n\nStep 3: There exist constants $a$ and $b$ such that $f(y)=a y+b$ for all $y \\in \\mathbb{R}^{+}$.\n\nSince $f$ is monotone and bounded from below by 0 , for each $x_{0} \\geqslant 0$, there exists a right limit $\\lim _{x \\searrow x_{0}} f(x) \\geqslant 0$. Put $p=\\lim _{x \\searrow 0} f(x)$ and $q=\\lim _{x \\searrow p} f(x)$.\n\nFix an arbitrary $y$ and take the limit of $(*)$ as $x \\searrow 0$. We have $f(x y) \\searrow p$ and hence $f(x+f(x y)) \\searrow q$; therefore, we obtain\n\n$$\nq+y=p f(y)+1, \\quad \\text { or } \\quad f(y)=\\frac{q+y-1}{p}\n$$\n\n(Notice that $p \\neq 0$, otherwise $q+y=1$ for all $y$, which is absurd.) The claim is proved.\n\nStep 4: $f(x)=x+1$ for all $x \\in \\mathbb{R}^{+}$.\n\nBased on the previous step, write $f(x)=a x+b$. Putting this relation into (*) we get\n\n$$\na(x+a x y+b)+b+y=(a x+b)(a y+b)+1,\n$$\n\nwhich can be rewritten as\n\n$$\n(a-a b) x+(1-a b) y+a b+b-b^{2}-1=0 \\quad \\text { for all } x, y \\in \\mathbb{R}^{+}\n$$\n\nThis identity may hold only if all the coefficients are 0 , i.e.,\n\n$$\na-a b=1-a b=a b+b-b^{2}-1=0 .\n$$\n\nHence, $a=b=1$.",
"We provide another proof that $f(x)=x+1$ is the only function satisfying $(*)$.\n\nPut $a=f(1)$. Define the function $\\phi: \\mathbb{R}^{+} \\rightarrow \\mathbb{R}$ by\n\n$$\n\\phi(x)=f(x)-x-1\n$$\n\nThen equation $(*)$ reads as\n\n$$\n\\phi(x+f(x y))=f(x) f(y)-f(x y)-x-y .\n\\tag{1}\n$$\n\nSince the right-hand side of (1) is symmetric under swapping $x$ and $y$, we obtain\n\n$$\n\\phi(x+f(x y))=\\phi(y+f(x y))\n$$\n\nIn particular, substituting $(x, y)=(t, 1 / t)$ we get\n\n$$\n\\phi(a+t)=\\phi\\left(a+\\frac{1}{t}\\right), \\quad t \\in \\mathbb{R}^{+}\n\\tag{2}\n$$\n\nNotice that the function $f$ is bounded from below by a positive constant. Indeed, for each $y \\in \\mathbb{R}^{+}$, the relation $(*)$ yields $f(x) f(y)>y-1$, hence\n\n$$\nf(x)>\\frac{y-1}{f(y)} \\quad \\text { for all } x \\in \\mathbb{R}^{+}\n$$\n\nIf $y>1$, this provides a desired positive lower bound for $f(x)$.\n\nNow, let $M=\\inf _{x \\in \\mathbb{R}^{+}} f(x)>0$. Then, for all $y \\in \\mathbb{R}^{+}$,\n\n$$\nM \\geqslant \\frac{y-1}{f(y)}, \\quad \\text { or } \\quad f(y) \\geqslant \\frac{y-1}{M}\n\\tag{3}\n$$\n\nLemma 1. The function $f(x)$ (and hence $\\phi(x)$ ) is bounded on any segment $[p, q]$, where $0<p<q<+\\infty$.\n\nProof. $f$ is bounded from below by $M$. It remains to show that $f$ is bounded from above on $[p, q]$. Substituting $y=1$ into $(*)$, we get\n\n$$\nf(x+f(x))=a f(x)\n\\tag{4}\n$$\n\nTake $z \\in[p, q]$ and put $s=f(z)$. By (4), we have\n\n$$\nf(z+s)=a s \\quad \\text { and } \\quad f(z+s+a s)=f(z+s+f(z+s))=a^{2} s\n$$\n\nPlugging in $(x, y)=\\left(z, 1+\\frac{s}{z}\\right)$ to $(*)$ and using (3), we obtain\n\n$$\nf(z+a s)=f(z+f(z+s))=s f\\left(1+\\frac{s}{z}\\right)-\\frac{s}{z} \\geqslant \\frac{s^{2}}{M z}-\\frac{s}{z}\n$$\n\nNow, substituting $(x, y)=\\left(z+a s, \\frac{z}{z+a s}\\right)$ to $(*)$ and applying the above estimate and the estimate $f(y) \\geqslant M$, we obtain\n\n$$\n\\begin{aligned}\n& a^{2} s=f(z+s+a s)=f(z+a s+f(z))=f(z+a s) f\\left(\\frac{z}{z+a s}\\right)+1-\\frac{z}{z+a s} \\\\\n& \\geqslant M f(z+a s) \\geqslant \\frac{s^{2}}{z}-\\frac{M s}{z} \\geqslant \\frac{s^{2}}{q}-\\frac{M s}{p}\n\\end{aligned}\n$$\n\nThis yields $s \\leqslant q\\left(\\frac{M}{p}+a^{2}\\right)=: L$, and $f$ is bounded from above by $L$ on $[p, q]$.\n\n\n\nApplying Lemma 1 to the segment $[a, a+1]$, we see that $\\phi$ is bounded on it. By $(2)$ we get that $\\phi$ is also bounded on $[a+1,+\\infty)$, and hence on $[a,+\\infty)$. Put $C=\\max \\{a, 3\\}$.\n\nLemma 2. For all $x \\geqslant C$, we have $\\phi(x)=0$ (and hence $f(x)=x+1$ ).\n\nProof. Substituting $y=x$ to (1), we obtain\n\n$$\n\\phi\\left(x+f\\left(x^{2}\\right)\\right)=f(x)^{2}-f\\left(x^{2}\\right)-2 x\n$$\n\nhence,\n\n$$\n\\phi\\left(x+f\\left(x^{2}\\right)\\right)+\\phi\\left(x^{2}\\right)=f(x)^{2}-(x+1)^{2}=\\phi(x)(f(x)+x+1) .\n\\tag{5}\n$$\n\nSince $f(x)+x+1 \\geqslant C+1 \\geqslant 4$, we obtain that\n\n$$\n|\\phi(x)| \\leqslant \\frac{1}{4}\\left(\\left|\\phi\\left(x+f\\left(x^{2}\\right)\\right)\\right|+\\left|\\phi\\left(x^{2}\\right)\\right|\\right)\n\\tag{6}\n$$\n\nSince $C \\geqslant a$, there exists a finite supremum $S=\\sup _{x \\geqslant C}|\\phi(x)|$. For each $x \\in[C,+\\infty)$, both $x+f\\left(x^{2}\\right)$ and $x^{2}$ are greater than $x$; hence they also lie in $[C,+\\infty)$. Therefore, taking the supremum of the left-hand side of (6) over $x \\in[C,+\\infty)$, we obtain $S \\leqslant S / 2$ and hence $S=0$. Thus, $\\phi(x)=0$ for all $x \\geqslant C$.\n\nIt remains to show that $f(y)=y+1$ when $0<y<C$. For each $y$, choose $x>\\max \\left\\{C, \\frac{C}{y}\\right\\}$. Then all three numbers $x, x y$, and $x+f(x y)$ are greater than $C$, so $(*)$ reads as\n\n$$\n(x+x y+1)+1+y=(x+1) f(y)+1, \\text { hence } f(y)=y+1\n$$"
] | $f(x)=x+1$ |
1,882 | Combinatorics | null | $\boxed{n^{2}-n+1}$ | [
"$n^{2}-n+1$"
] | false | null | Expression | null | Let $n$ be an integer with $n \geqslant 2$. On a slope of a mountain, $n^{2}$ checkpoints are marked, numbered from 1 to $n^{2}$ from the bottom to the top. Each of two cable car companies, $A$ and $B$, operates $k$ cable cars numbered from 1 to $k$; each cable car provides a transfer from some checkpoint to a higher one. For each company, and for any $i$ and $j$ with $1 \leqslant i<j \leqslant k$, the starting point of car $j$ is higher than the starting point of car $i$; similarly, the finishing point of car $j$ is higher than the finishing point of car $i$. Say that two checkpoints are linked by some company if one can start from the lower checkpoint and reach the higher one by using one or more cars of that company (no movement on foot is allowed).
Determine the smallest $k$ for which one can guarantee that there are two checkpoints that are linked by each of the two companies. | [
"We start with showing that for any $k \\leqslant n^{2}-n$ there may be no pair of checkpoints linked by both companies. Clearly, it suffices to provide such an example for $k=n^{2}-n$.\n\nLet company $A$ connect the pairs of checkpoints of the form $(i, i+1)$, where $n \\nmid i$. Then all pairs of checkpoints $(i, j)$ linked by $A$ satisfy $\\lceil i / n\\rceil=\\lceil j / n\\rceil$.\n\nLet company $B$ connect the pairs of the form $(i, i+n)$, where $1 \\leqslant i \\leqslant n^{2}-n$. Then pairs of checkpoints $(i, j)$ linked by $B$ satisfy $i \\equiv j(\\bmod n)$. Clearly, no pair $(i, j)$ satisfies both conditions, so there is no pair linked by both companies.\n\nNow we show that for $k=n^{2}-n+1$ there always exist two required checkpoints. Define an $A$-chain as a sequence of checkpoints $a_{1}<a_{2}<\\ldots<a_{t}$ such that company $A$ connects $a_{i}$ with $a_{i+1}$ for all $1 \\leqslant i \\leqslant t-1$, but there is no $A$-car transferring from some checkpoint to $a_{1}$ and no $A$-car transferring from $a_{t}$ to any other checkpoint. Define $B$-chains similarly. Moving forth and back, one easily sees that any checkpoint is included in a unique $A$-chain (possibly consisting of that single checkpoint), as well as in a unique $B$-chain. Now, put each checkpoint into a correspondence to the pair of the $A$-chain and the $B$-chain it belongs to.\n\nAll finishing points of $A$-cars are distinct, so there are $n^{2}-k=n-1$ checkpoints that are not such finishing points. Each of them is a starting point of a unique $A$-chain, so the number of $A$-chains is $n-1$. Similarly, the number of $B$-chains also equals $n-1$. Hence, there are $(n-1)^{2}$ pairs consisting of an $A$ - and a $B$-chain. Therefore, two of the $n^{2}$ checkpoints correspond to the same pair, so that they belong to the same $A$-chain, as well as to the same $B$-chain. This means that they are linked by both companies, as required."
] | $n^{2}-n+1$ |
1,883 | Combinatorics | null | $\boxed{\lceil n / 2\rceil+1}$ | [
"$\\lceil n / 2\\rceil+1$"
] | false | null | Expression | null | The Fibonacci numbers $F_{0}, F_{1}, F_{2}, \ldots$ are defined inductively by $F_{0}=0, F_{1}=1$, and $F_{n+1}=F_{n}+F_{n-1}$ for $n \geqslant 1$. Given an integer $n \geqslant 2$, determine the smallest size of a set $S$ of integers such that for every $k=2,3, \ldots, n$ there exist some $x, y \in S$ such that $x-y=F_{k}$. | [
"First we show that if a set $S \\subset \\mathbb{Z}$ satisfies the conditions then $|S| \\geqslant \\frac{n}{2}+1$.\n\nLet $d=\\lceil n / 2\\rceil$, so $n \\leqslant 2 d \\leqslant n+1$. In order to prove that $|S| \\geqslant d+1$, construct a graph as follows. Let the vertices of the graph be the elements of $S$. For each $1 \\leqslant k \\leqslant d$, choose two elements $x, y \\in S$ such that $x-y=F_{2 k-1}$, and add the pair $(x, y)$ to the graph as edge. (Note that by the problem's constraints, there must be a pair $(x, y)$ with $x-y=F_{2 k-1}$ for every $3 \\leqslant 2 k-1 \\leqslant 2 d-1 \\leqslant n$; moreover, due to $F_{1}=F_{2}$ we have a pair with $x-y=F_{1}$ as well.) We will say that the length of the edge $(x, y)$ is $|x-y|$.\n\nWe claim that the graph contains no cycle. For the sake of contradiction, suppose that the graph contains a cycle $\\left(x_{1}, \\ldots, x_{\\ell}\\right)$, and let the longest edge in the cycle be $\\left(x_{1}, x_{\\ell}\\right)$ with length $F_{2 m+1}$. The other edges $\\left(x_{1}, x_{2}\\right), \\ldots,\\left(x_{\\ell-1}, x_{\\ell}\\right)$ in the cycle are shorter than $F_{2 m+1}$ and distinct, their lengths form a subset of $\\left\\{F_{1}, F_{3}, \\ldots, F_{2 m-1}\\right\\}$. But this is not possible because\n\n$$\n\\begin{aligned}\nF_{2 m+1} & =\\left|x_{\\ell}-x_{1}\\right| \\leqslant \\sum_{i=1}^{\\ell-1}\\left|x_{i+1}-x_{i}\\right| \\leqslant F_{1}+F_{3}+F_{5}+\\ldots+F_{2 m-1} \\\\\n& =F_{2}+\\left(F_{4}-F_{2}\\right)+\\left(F_{6}-F_{4}\\right)+\\ldots+\\left(F_{2 m}-F_{2 m-2}\\right)=F_{2 m}<F_{2 m+1} .\n\\end{aligned}\n$$\n\nHence, the graph has $d$ edges and cannot contain a cycle, therefore it must contain at least $d+1$ vertices, so $|S| \\geqslant d+1$.\n\nNow we show a suitable set with $d+1$ elements. Let\n\n$$\nS=\\left\\{F_{0}, F_{2}, F_{4}, F_{5}, \\ldots, F_{2 d}\\right\\}\n$$\n\nFor $1 \\leqslant k \\leqslant d$ we have $F_{0}, F_{2 k-2}, F_{2 k} \\in S$ with differences $F_{2 k}-F_{2 k-2}=F_{2 k-1}$ and $F_{2 k}-F_{0}=F_{2 k}$, so each of $F_{1}, F_{2}, \\ldots, F_{2 d}$ occurs as difference between two elements in $S$. So this set containing $d+1$ numbers is suitable.\n\n\n\nThis page is intentionally left blank"
] | $\lceil n / 2\rceil+1$ |
1,887 | Combinatorics | null | $\boxed{7}$ | [
"7"
] | false | null | Numerical | null | Players $A$ and $B$ play a game on a blackboard that initially contains 2020 copies of the number 1. In every round, player $A$ erases two numbers $x$ and $y$ from the blackboard, and then player $B$ writes one of the numbers $x+y$ and $|x-y|$ on the blackboard. The game terminates as soon as, at the end of some round, one of the following holds:
(1) one of the numbers on the blackboard is larger than the sum of all other numbers;
(2) there are only zeros on the blackboard.
Player $B$ must then give as many cookies to player $A$ as there are numbers on the blackboard. Player $A$ wants to get as many cookies as possible, whereas player $B$ wants to give as few as possible. Determine the number of cookies that $A$ receives if both players play optimally. | [
"For a positive integer $n$, we denote by $S_{2}(n)$ the sum of digits in its binary representation. We prove that, in fact, if a board initially contains an even number $n>1$ of ones, then $A$ can guarantee to obtain $S_{2}(n)$, but not more, cookies. The binary representation of 2020 is $2020=\\overline{11111100100}_{2}$, so $S_{2}(2020)=7$, and the answer follows.\n\nA strategy for A. At any round, while possible, A chooses two equal nonzero numbers on the board. Clearly, while $A$ can make such choice, the game does not terminate. On the other hand, $A$ can follow this strategy unless the game has already terminated. Indeed, if $A$ always chooses two equal numbers, then each number appearing on the board is either 0 or a power of 2 with non-negative integer exponent, this can be easily proved using induction on the number of rounds. At the moment when $A$ is unable to follow the strategy all nonzero numbers on the board are distinct powers of 2 . If the board contains at least one such power, then the largest of those powers is greater than the sum of the others. Otherwise there are only zeros on the blackboard, in both cases the game terminates.\n\nFor every number on the board, define its range to be the number of ones it is obtained from. We can prove by induction on the number of rounds that for any nonzero number $k$ written by $B$ its range is $k$, and for any zero written by $B$ its range is a power of 2 . Thus at the end of each round all the ranges are powers of two, and their sum is $n$. Since $S_{2}(a+b) \\leqslant S_{2}(a)+S_{2}(b)$ for any positive integers $a$ and $b$, the number $n$ cannot be represented as a sum of less than $S_{2}(n)$ powers of 2 . Thus at the end of each round the board contains at least $S_{2}(n)$ numbers, while $A$ follows the above strategy. So $A$ can guarantee at least $S_{2}(n)$ cookies for himself.\n\nA strategy for $B$. Denote $s=S_{2}(n)$.\n\nLet $x_{1}, \\ldots, x_{k}$ be the numbers on the board at some moment of the game after $B$ 's turn or at the beginning of the game. Say that a collection of $k \\operatorname{signs} \\varepsilon_{1}, \\ldots, \\varepsilon_{k} \\in\\{+1,-1\\}$ is balanced if\n\n$$\n\\sum_{i=1}^{k} \\varepsilon_{i} x_{i}=0\n$$\n\nWe say that a situation on the board is good if $2^{s+1}$ does not divide the number of balanced collections. An appropriate strategy for $B$ can be explained as follows: Perform a move so that the situation remains good, while it is possible. We intend to show that in this case $B$ will not lose more than $S_{2}(n)$ cookies. For this purpose, we prove several lemmas.\n\nFor a positive integer $k$, denote by $\\nu_{2}(k)$ the exponent of the largest power of 2 that divides $k$. Recall that, by Legendre's formula, $\\nu_{2}(n !)=n-S_{2}(n)$ for every positive integer $n$.\n\n\n\nLemma 1. The initial situation is good.\n\nProof. In the initial configuration, the number of balanced collections is equal to $\\left(\\begin{array}{c}n \\\\ n / 2\\end{array}\\right)$. We have\n\n$$\n\\nu_{2}\\left(\\left(\\begin{array}{c}\nn \\\\\nn / 2\n\\end{array}\\right)\\right)=\\nu_{2}(n !)-2 \\nu_{2}((n / 2) !)=\\left(n-S_{2}(n)\\right)-2\\left(\\frac{n}{2}-S_{2}(n / 2)\\right)=S_{2}(n)=s\n$$\n\nHence $2^{s+1}$ does not divide the number of balanced collections, as desired.\n\nLemma 2. B may play so that after each round the situation remains good.\n\nProof. Assume that the situation $\\left(x_{1}, \\ldots, x_{k}\\right)$ before a round is good, and that $A$ erases two numbers, $x_{p}$ and $x_{q}$.\n\nLet $N$ be the number of all balanced collections, $N_{+}$be the number of those having $\\varepsilon_{p}=\\varepsilon_{q}$, and $N_{-}$be the number of other balanced collections. Then $N=N_{+}+N_{-}$. Now, if $B$ replaces $x_{p}$ and $x_{q}$ by $x_{p}+x_{q}$, then the number of balanced collections will become $N_{+}$. If $B$ replaces $x_{p}$ and $x_{q}$ by $\\left|x_{p}-x_{q}\\right|$, then this number will become $N_{-}$. Since $2^{s+1}$ does not divide $N$, it does not divide one of the summands $N_{+}$and $N_{-}$, hence $B$ can reach a good situation after the round.\n\nLemma 3. Assume that the game terminates at a good situation. Then the board contains at most $s$ numbers.\n\nProof. Suppose, one of the numbers is greater than the sum of the other numbers. Then the number of balanced collections is 0 and hence divisible by $2^{s+1}$. Therefore, the situation is not good.\n\nThen we have only zeros on the blackboard at the moment when the game terminates. If there are $k$ of them, then the number of balanced collections is $2^{k}$. Since the situation is good, we have $k \\leqslant s$.\n\nBy Lemmas 1 and 2, $B$ may act in such way that they keep the situation good. By Lemma 3, when the game terminates, the board contains at most $s$ numbers. This is what we aimed to prove."
] | 7 |
1,914 | Combinatorics | null | $\boxed{\frac{1}{4} n(n+1)}$ | [
"$\\frac{1}{4} n(n+1)$"
] | false | null | Expression | null | Let $n$ be a positive integer. Harry has $n$ coins lined up on his desk, each showing heads or tails. He repeatedly does the following operation: if there are $k$ coins showing heads and $k>0$, then he flips the $k^{\text {th }}$ coin over; otherwise he stops the process. (For example, the process starting with THT would be THT $\rightarrow H H T \rightarrow H T T \rightarrow T T T$, which takes three steps.)
Letting $C$ denote the initial configuration (a sequence of $n H$ 's and $T$ 's), write $\ell(C)$ for the number of steps needed before all coins show $T$. Show that this number $\ell(C)$ is finite, and determine its average value over all $2^{n}$ possible initial configurations $C$. | [
"We represent the problem using a directed graph $G_{n}$ whose vertices are the length- $n$ strings of $H$ 's and $T$ 's. The graph features an edge from each string to its successor (except for $T T \\cdots T T$, which has no successor). We will also write $\\bar{H}=T$ and $\\bar{T}=H$.\n\nThe graph $G_{0}$ consists of a single vertex: the empty string. The main claim is that $G_{n}$ can be described explicitly in terms of $G_{n-1}$ :\n\n- We take two copies, $X$ and $Y$, of $G_{n-1}$.\n- In $X$, we take each string of $n-1$ coins and just append a $T$ to it. In symbols, we replace $s_{1} \\cdots s_{n-1}$ with $s_{1} \\cdots s_{n-1} T$.\n- In $Y$, we take each string of $n-1$ coins, flip every coin, reverse the order, and append an $H$ to it. In symbols, we replace $s_{1} \\cdots s_{n-1}$ with $\\bar{s}_{n-1} \\bar{s}_{n-2} \\cdots \\bar{s}_{1} H$.\n- Finally, we add one new edge from $Y$ to $X$, namely $H H \\cdots H H H \\rightarrow H H \\cdots H H T$.\n\nWe depict $G_{4}$ below, in a way which indicates this recursive construction:\n\n<img_3966>\n\nWe prove the claim inductively. Firstly, $X$ is correct as a subgraph of $G_{n}$, as the operation on coins is unchanged by an extra $T$ at the end: if $s_{1} \\cdots s_{n-1}$ is sent to $t_{1} \\cdots t_{n-1}$, then $s_{1} \\cdots s_{n-1} T$ is sent to $t_{1} \\cdots t_{n-1} T$.\n\nNext, $Y$ is also correct as a subgraph of $G_{n}$, as if $s_{1} \\cdots s_{n-1}$ has $k$ occurrences of $H$, then $\\bar{s}_{n-1} \\cdots \\bar{s}_{1} H$ has $(n-1-k)+1=n-k$ occurrences of $H$, and thus (provided that $k>0$ ), if $s_{1} \\cdots s_{n-1}$ is sent to $t_{1} \\cdots t_{n-1}$, then $\\bar{s}_{n-1} \\cdots \\bar{s}_{1} H$ is sent to $\\bar{t}_{n-1} \\cdots \\bar{t}_{1} H$.\n\nFinally, the one edge from $Y$ to $X$ is correct, as the operation does send $H H \\cdots H H H$ to HH $\\cdots H H T$.\n\n\n\nTo finish, note that the sequences in $X$ take an average of $E(n-1)$ steps to terminate, whereas the sequences in $Y$ take an average of $E(n-1)$ steps to reach $H H \\cdots H$ and then an additional $n$ steps to terminate. Therefore, we have\n\n$$\nE(n)=\\frac{1}{2}(E(n-1)+(E(n-1)+n))=E(n-1)+\\frac{n}{2}\n$$\n\nWe have $E(0)=0$ from our description of $G_{0}$. Thus, by induction, we have $E(n)=\\frac{1}{2}(1+\\cdots+$ $n)=\\frac{1}{4} n(n+1)$, which in particular is finite.",
"We consider what happens with configurations depending on the coins they start and end with.\n\n- If a configuration starts with $H$, the last $n-1$ coins follow the given rules, as if they were all the coins, until they are all $T$, then the first coin is turned over.\n- If a configuration ends with $T$, the last coin will never be turned over, and the first $n-1$ coins follow the given rules, as if they were all the coins.\n- If a configuration starts with $T$ and ends with $H$, the middle $n-2$ coins follow the given rules, as if they were all the coins, until they are all $T$. After that, there are $2 n-1$ more steps: first coins $1,2, \\ldots, n-1$ are turned over in that order, then coins $n, n-1, \\ldots, 1$ are turned over in that order.\n\nAs this covers all configurations, and the number of steps is clearly finite for 0 or 1 coins, it follows by induction on $n$ that the number of steps is always finite.\n\nWe define $E_{A B}(n)$, where $A$ and $B$ are each one of $H, T$ or *, to be the average number of steps over configurations of length $n$ restricted to those that start with $A$, if $A$ is not *, and that end with $B$, if $B$ is not * (so * represents \"either $H$ or $T$ \"). The above observations tell us that, for $n \\geqslant 2$ :\n\n- $E_{H *}(n)=E(n-1)+1$.\n- $E_{* T}(n)=E(n-1)$.\n- $E_{H T}(n)=E(n-2)+1$ (by using both the observations for $H *$ and for $* T$ ).\n- $E_{T H}(n)=E(n-2)+2 n-1$.\n\nNow $E_{H *}(n)=\\frac{1}{2}\\left(E_{H H}(n)+E_{H T}(n)\\right)$, so $E_{H H}(n)=2 E(n-1)-E(n-2)+1$. Similarly, $E_{T T}(n)=2 E(n-1)-E(n-2)-1$. So\n\n$$\nE(n)=\\frac{1}{4}\\left(E_{H T}(n)+E_{H H}(n)+E_{T T}(n)+E_{T H}(n)\\right)=E(n-1)+\\frac{n}{2}\n$$\n\nWe have $E(0)=0$ and $E(1)=\\frac{1}{2}$, so by induction on $n$ we have $E(n)=\\frac{1}{4} n(n+1)$.",
"Let $H_{i}$ be the number of heads in positions 1 to $i$ inclusive (so $H_{n}$ is the total number of heads), and let $I_{i}$ be 1 if the $i^{\\text {th }}$ coin is a head, 0 otherwise. Consider the function\n\n$$\nt(i)=I_{i}+2\\left(\\min \\left\\{i, H_{n}\\right\\}-H_{i}\\right)\n$$\n\nWe claim that $t(i)$ is the total number of times coin $i$ is turned over (which implies that the process terminates). Certainly $t(i)=0$ when all coins are tails, and $t(i)$ is always a nonnegative integer, so it suffices to show that when the $k^{\\text {th }}$ coin is turned over (where $k=H_{n}$ ), $t(k)$ goes down by 1 and all the other $t(i)$ are unchanged. We show this by splitting into cases:\n\n\n\n- If $i<k, I_{i}$ and $H_{i}$ are unchanged, and $\\min \\left\\{i, H_{n}\\right\\}=i$ both before and after the coin flip, so $t(i)$ is unchanged.\n- If $i>k, \\min \\left\\{i, H_{n}\\right\\}=H_{n}$ both before and after the coin flip, and both $H_{n}$ and $H_{i}$ change by the same amount, so $t(i)$ is unchanged.\n- If $i=k$ and the coin is heads, $I_{i}$ goes down by 1 , as do both $\\min \\left\\{i, H_{n}\\right\\}=H_{n}$ and $H_{i}$; so $t(i)$ goes down by 1 .\n- If $i=k$ and the coin is tails, $I_{i}$ goes up by $1, \\min \\left\\{i, H_{n}\\right\\}=i$ is unchanged and $H_{i}$ goes up by 1 ; so $t(i)$ goes down by 1 .\n\nWe now need to compute the average value of\n\n$$\n\\sum_{i=1}^{n} t(i)=\\sum_{i=1}^{n} I_{i}+2 \\sum_{i=1}^{n} \\min \\left\\{i, H_{n}\\right\\}-2 \\sum_{i=1}^{n} H_{i}\n$$\n\nThe average value of the first term is $\\frac{1}{2} n$, and that of the third term is $-\\frac{1}{2} n(n+1)$. To compute the second term, we sum over choices for the total number of heads, and then over the possible values of $i$, getting\n\n$$\n2^{1-n} \\sum_{j=0}^{n}\\left(\\begin{array}{c}\nn \\\\\nj\n\\end{array}\\right) \\sum_{i=1}^{n} \\min \\{i, j\\}=2^{1-n} \\sum_{j=0}^{n}\\left(\\begin{array}{c}\nn \\\\\nj\n\\end{array}\\right)\\left(n j-\\left(\\begin{array}{l}\nj \\\\\n2\n\\end{array}\\right)\\right)\n$$\n\nNow, in terms of trinomial coefficients,\n\n$$\n\\sum_{j=0}^{n} j\\left(\\begin{array}{l}\nn \\\\\nj\n\\end{array}\\right)=\\sum_{j=1}^{n}\\left(\\begin{array}{c}\nn \\\\\nn-j, j-1,1\n\\end{array}\\right)=n \\sum_{j=0}^{n-1}\\left(\\begin{array}{c}\nn-1 \\\\\nj\n\\end{array}\\right)=2^{n-1} n\n$$\n\nand\n\n$$\n\\sum_{j=0}^{n}\\left(\\begin{array}{l}\nj \\\\\n2\n\\end{array}\\right)\\left(\\begin{array}{l}\nn \\\\\nj\n\\end{array}\\right)=\\sum_{j=2}^{n}\\left(\\begin{array}{c}\nn \\\\\nn-j, j-2,2\n\\end{array}\\right)=\\left(\\begin{array}{l}\nn \\\\\n2\n\\end{array}\\right) \\sum_{j=0}^{n-2}\\left(\\begin{array}{c}\nn-2 \\\\\nj\n\\end{array}\\right)=2^{n-2}\\left(\\begin{array}{l}\nn \\\\\n2\n\\end{array}\\right)\n$$\n\nSo the second term above is\n\n$$\n2^{1-n}\\left(2^{n-1} n^{2}-2^{n-2}\\left(\\begin{array}{l}\nn \\\\\n2\n\\end{array}\\right)\\right)=n^{2}-\\frac{n(n-1)}{4}\n$$\n\nand the required average is\n\n$$\nE(n)=\\frac{1}{2} n+n^{2}-\\frac{n(n-1)}{4}-\\frac{1}{2} n(n+1)=\\frac{n(n+1)}{4} .\n$$",
"Harry has built a Turing machine to flip the coins for him. The machine is initially positioned at the $k^{\\text {th }}$ coin, where there are $k$ heads (and the position before the first coin is considered to be the $0^{\\text {th }}$ coin). The machine then moves according to the following rules, stopping when it reaches the position before the first coin: if the coin at its current position is $H$, it flips the coin and moves to the previous coin, while if the coin at its current position is $T$, it flips the coin and moves to the next position.\n\nConsider the maximal sequences of consecutive moves in the same direction. Suppose the machine has $a$ consecutive moves to the next coin, before a move to the previous coin. After those $a$ moves, the $a$ coins flipped in those moves are all heads, as is the coin the machine is now at, so at least the next $a+1$ moves will all be moves to the previous coin. Similarly, $a$ consecutive moves to the previous coin are followed by at least $a+1$ consecutive moves to\n\n\n\nthe next coin. There cannot be more than $n$ consecutive moves in the same direction, so this proves that the process terminates (with a move from the first coin to the position before the first coin).\n\nThus we have a (possibly empty) sequence $a_{1}<\\cdots<a_{t} \\leqslant n$ giving the lengths of maximal sequences of consecutive moves in the same direction, where the final $a_{t}$ moves must be moves to the previous coin, ending before the first coin. We claim there is a bijection between initial configurations of the coins and such sequences. This gives\n\n$$\nE(n)=\\frac{1}{2}(1+2+\\cdots+n)=\\frac{n(n+1)}{4}\n$$\n\nas required, since each $i$ with $1 \\leqslant i \\leqslant n$ will appear in half of the sequences, and will contribute $i$ to the number of moves when it does.\n\nTo see the bijection, consider following the sequence of moves backwards, starting with the machine just before the first coin and all coins showing tails. This certainly determines a unique configuration of coins that could possibly correspond to the given sequence. Furthermore, every coin flipped as part of the $a_{j}$ consecutive moves is also flipped as part of all subsequent sequences of $a_{k}$ consecutive moves, for all $k>j$, meaning that, as we follow the moves backwards, each coin is always in the correct state when flipped to result in a move in the required direction. (Alternatively, since there are $2^{n}$ possible configurations of coins and $2^{n}$ possible such ascending sequences, the fact that the sequence of moves determines at most one configuration of coins, and thus that there is an injection from configurations of coins to such ascending sequences, is sufficient for it to be a bijection, without needing to show that coins are in the right state as we move backwards.)",
"We explicitly describe what happens with an arbitrary sequence $C$ of $n$ coins. Suppose that $C$ contain $k$ heads at positions $1 \\leqslant c_{1}<c_{2}<\\cdots<c_{k} \\leqslant n$.\n\nLet $i$ be the minimal index such that $c_{i} \\geqslant k$. Then the first few steps will consist of turning over the $k^{\\text {th }},(k+1)^{\\text {th }}, \\ldots, c_{i}^{\\text {th }},\\left(c_{i}-1\\right)^{\\text {th }},\\left(c_{i}-2\\right)^{\\text {th }}, \\ldots, k^{\\text {th }}$ coins in this order. After that we get a configuration with $k-1$ heads at the same positions as in the initial one, except for $c_{i}$. This part of the process takes $2\\left(c_{i}-k\\right)+1$ steps.\n\nAfter that, the process acts similarly; by induction on the number of heads we deduce that the process ends. Moreover, if the $c_{i}$ disappear in order $c_{i_{1}}, \\ldots, c_{i_{k}}$, the whole process takes\n\n$$\n\\ell(C)=\\sum_{j=1}^{k}\\left(2\\left(c_{i_{j}}-(k+1-j)\\right)+1\\right)=2 \\sum_{j=1}^{k} c_{j}-2 \\sum_{j=1}^{k}(k+1-j)+k=2 \\sum_{j=1}^{k} c_{j}-k^{2}\n$$\n\nsteps.\n\nNow let us find the total value $S_{k}$ of $\\ell(C)$ over all $\\left(\\begin{array}{l}n \\\\ k\\end{array}\\right)$ configurations with exactly $k$ heads. To sum up the above expression over those, notice that each number $1 \\leqslant i \\leqslant n$ appears as $c_{j}$ exactly $\\left(\\begin{array}{c}n-1 \\\\ k-1\\end{array}\\right)$ times. Thus\n\n$$\n\\begin{array}{r}\nS_{k}=2\\left(\\begin{array}{l}\nn-1 \\\\\nk-1\n\\end{array}\\right) \\sum_{i=1}^{n} i-\\left(\\begin{array}{l}\nn \\\\\nk\n\\end{array}\\right) k^{2}=2 \\frac{(n-1) \\cdots(n-k+1)}{(k-1) !} \\cdot \\frac{n(n+1)}{2}-\\frac{n \\cdots(n-k+1)}{k !} k^{2} \\\\\n=\\frac{n(n-1) \\cdots(n-k+1)}{(k-1) !}((n+1)-k)=n(n-1)\\left(\\begin{array}{l}\nn-2 \\\\\nk-1\n\\end{array}\\right)+n\\left(\\begin{array}{l}\nn-1 \\\\\nk-1\n\\end{array}\\right) .\n\\end{array}\n$$\n\nTherefore, the total value of $\\ell(C)$ over all configurations is\n\n$$\n\\sum_{k=1}^{n} S_{k}=n(n-1) \\sum_{k=1}^{n}\\left(\\begin{array}{l}\nn-2 \\\\\nk-1\n\\end{array}\\right)+n \\sum_{k=1}^{n}\\left(\\begin{array}{l}\nn-1 \\\\\nk-1\n\\end{array}\\right)=n(n-1) 2^{n-2}+n 2^{n-1}=2^{n} \\frac{n(n+1)}{4}\n$$\n\nHence the required average is $E(n)=\\frac{n(n+1)}{4}$."
] | $\frac{1}{4} n(n+1)$ |
1,915 | Combinatorics | null | $\boxed{k=n+1}$ | [
"$k=n+1$"
] | false | null | Expression | null | On a flat plane in Camelot, King Arthur builds a labyrinth $\mathfrak{L}$ consisting of $n$ walls, each of which is an infinite straight line. No two walls are parallel, and no three walls have a common point. Merlin then paints one side of each wall entirely red and the other side entirely blue.
At the intersection of two walls there are four corners: two diagonally opposite corners where a red side and a blue side meet, one corner where two red sides meet, and one corner where two blue sides meet. At each such intersection, there is a two-way door connecting the two diagonally opposite corners at which sides of different colours meet.
After Merlin paints the walls, Morgana then places some knights in the labyrinth. The knights can walk through doors, but cannot walk through walls.
Let $k(\mathfrak{L})$ be the largest number $k$ such that, no matter how Merlin paints the labyrinth $\mathfrak{L}$, Morgana can always place at least $k$ knights such that no two of them can ever meet. For each $n$, what are all possible values for $k(\mathfrak{L})$, where $\mathfrak{L}$ is a labyrinth with $n$ walls? | [
"First we show by induction that the $n$ walls divide the plane into $\\left(\\begin{array}{c}n+1 \\\\ 2\\end{array}\\right)+1$ regions. The claim is true for $n=0$ as, when there are no walls, the plane forms a single region. When placing the $n^{\\text {th }}$ wall, it intersects each of the $n-1$ other walls exactly once and hence splits each of $n$ of the regions formed by those other walls into two regions. By the induction hypothesis, this yields $\\left(\\left(\\begin{array}{l}n \\\\ 2\\end{array}\\right)+1\\right)+n=\\left(\\begin{array}{c}n+1 \\\\ 2\\end{array}\\right)+1$ regions, proving the claim.\n\nNow let $G$ be the graph with vertices given by the $\\left(\\begin{array}{c}n+1 \\\\ 2\\end{array}\\right)+1$ regions, and with two regions connected by an edge if there is a door between them.\n\nWe now show that no matter how Merlin paints the $n$ walls, Morgana can place at least $n+1$ knights. No matter how the walls are painted, there are exactly $\\left(\\begin{array}{l}n \\\\ 2\\end{array}\\right)$ intersection points, each of which corresponds to a single edge in $G$. Consider adding the edges of $G$ sequentially and note that each edge reduces the number of connected components by at most one. Therefore the number of connected components of $\\mathrm{G}$ is at least $\\left(\\begin{array}{c}n+1 \\\\ 2\\end{array}\\right)+1-\\left(\\begin{array}{l}n \\\\ 2\\end{array}\\right)=n+1$. If Morgana places a knight in regions corresponding to different connected components of $G$, then no two knights can ever meet.\n\nNow we give a construction showing that, no matter what shape the labyrinth is, Merlin can colour it such that there are exactly $n+1$ connected components, allowing Morgana to place at most $n+1$ knights.\n\nFirst, we choose a coordinate system on the labyrinth so that none of the walls run due north-south, or due east-west. We then have Merlin paint the west face of each wall red, and the east face of each wall blue. We label the regions according to how many walls the region is on the east side of: the labels are integers between 0 and $n$.\n\nWe claim that, for each $i$, the regions labelled $i$ are connected by doors. First, we note that for each $i$ with $0 \\leqslant i \\leqslant n$ there is a unique region labelled $i$ which is unbounded to the north.\n\nNow, consider a knight placed in some region with label $i$, and ask them to walk north (moving east or west by following the walls on the northern sides of regions, as needed). This knight will never get stuck: each region is convex, and so, if it is bounded to the north, it has a single northernmost vertex with a door northwards to another region with label $i$.\n\nEventually it will reach a region which is unbounded to the north, which will be the unique such region with label $i$. Hence every region with label $i$ is connected to this particular region, and so all regions with label $i$ are connected to each other.\n\nAs a result, there are exactly $n+1$ connected components, and Morgana can place at most $n+1$ knights.",
"We give another description of a strategy for Merlin to paint the walls so that Morgana can place no more than $n+1$ knights.\n\nMerlin starts by building a labyrinth of $n$ walls of his own design. He places walls in turn with increasing positive gradients, placing each so far to the right that all intersection points of previously-placed lines lie to the left of it. He paints each in such a way that blue is on the left and red is on the right.\n\nFor example, here is a possible sequence of four such lines $\\ell_{1}, \\ell_{2}, \\ell_{3}, \\ell_{4}$ :\n\n<img_3427>\n\nWe say that a region is \"on the right\" if it has $x$-coordinate unbounded above (note that if we only have one wall, then both regions are on the right). We claim inductively that, after placing $n$ lines, there are $n+1$ connected components in the resulting labyrinth, each of which contains exactly one region on the right. This is certainly true after placing 0 lines, as then there is only one region (and hence one connected component) and it is on the right.\n\nWhen placing the $n^{\\text {th }}$ line, it then cuts every one of the $n-1$ previously placed lines, and since it is to the right of all intersection points, the regions it cuts are exactly the $n$ regions on the right.\n\n<img_3985>\n\nThe addition of this line leaves all previous connected components with exactly one region on the right, and creates a new connected component containing exactly one region, and that region is also on the right. As a result, by induction, this particular labyrinth will have $n+1$ connected components.\n\nHaving built this labyrinth, Merlin then moves the walls one-by-one (by a sequence of continuous translations and rotations of lines) into the proper position of the given labyrinth, in such a way that no two lines ever become parallel.\n\n\n\nThe only time the configuration is changed is when one wall is moved through an intersection point of two others:\n<img_3360>\n\nNote that all moves really do switch between two configurations like this: all sets of three lines have this colour configuration initially, and the rules on rotations mean they are preserved (in particular, we cannot create three lines creating a triangle with three red edges inwards, or three blue edges inwards).\n\nHowever, as can be seen, such a move preserves the number of connected components, so in the painting this provides for Arthur's actual labyrinth, Morgana can still only place at most $n+1$ knights."
] | $k=n+1$ |
1,918 | Combinatorics | null | $\boxed{960}$ | [
"960"
] | false | null | Numerical | null | There are 60 empty boxes $B_{1}, \ldots, B_{60}$ in a row on a table and an unlimited supply of pebbles. Given a positive integer $n$, Alice and Bob play the following game.
In the first round, Alice takes $n$ pebbles and distributes them into the 60 boxes as she wishes. Each subsequent round consists of two steps:
(a) Bob chooses an integer $k$ with $1 \leqslant k \leqslant 59$ and splits the boxes into the two groups $B_{1}, \ldots, B_{k}$ and $B_{k+1}, \ldots, B_{60}$.
(b) Alice picks one of these two groups, adds one pebble to each box in that group, and removes one pebble from each box in the other group.
Bob wins if, at the end of any round, some box contains no pebbles. Find the smallest $n$ such that Alice can prevent Bob from winning. | [
"We present solutions for the general case of $N>1$ boxes, and write $M=\\left\\lfloor\\frac{N}{2}+1\\right\\rfloor\\left\\lceil\\frac{N}{2}+1\\right\\rceil-1$ for the claimed answer. For $1 \\leqslant k<N$, say that Bob makes a $k$-move if he splits the boxes into a left group $\\left\\{B_{1}, \\ldots, B_{k}\\right\\}$ and a right group $\\left\\{B_{k+1}, \\ldots, B_{N}\\right\\}$. Say that one configuration dominates another if it has at least as many pebbles in each box, and say that it strictly dominates the other configuration if it also has more pebbles in at least one box. (Thus, if Bob wins in some configuration, he also wins in every configuration that it dominates.)\n\nIt is often convenient to consider ' $V$-shaped' configurations; for $1 \\leqslant i \\leqslant N$, let $V_{i}$ be the configuration where $B_{j}$ contains $1+|j-i|$ pebbles (i.e. where the $i^{\\text {th }}$ box has a single pebble and the numbers increase by one in both directions, so the first box has $i$ pebbles and the last box has $N+1-i$ pebbles). Note that $V_{i}$ contains $\\frac{1}{2} i(i+1)+\\frac{1}{2}(N+1-i)(N+2-i)-1$ pebbles. If $i=\\left\\lceil\\frac{N}{2}\\right\\rceil$, this number equals $M$.solution split naturally into a strategy for Alice (starting with $M$ pebbles and showing she can prevent Bob from winning) and a strategy for Bob (showing he can win for any starting configuration with at most $M-1$ pebbles). The following observation is also useful to simplify the analysis of strategies for Bob.\n\nObservation A. Consider two consecutive rounds. Suppose that in the first round Bob made a $k$-move and Alice picked the left group, and then in the second round Bob makes an $\\ell$-move, with $\\ell>k$. We may then assume, without loss of generality, that Alice again picks the left group.\n\nProof. Suppose Alice picks the right group in the second round. Then the combined effect of the two rounds is that each of the boxes $B_{k+1}, \\ldots, B_{\\ell}$ lost two pebbles (and the other boxes are unchanged). Hence this configuration is strictly dominated by that before the first round, and it suffices to consider only Alice's other response.\n\nFor Alice. Alice initially distributes pebbles according to $V_{\\left\\lceil\\frac{N}{2}\\right\\rceil}$. Suppose the current configuration of pebbles dominates $V_{i}$. If Bob makes a $k$-move with $k \\geqslant i$ then Alice picks the left group, which results in a configuration that dominates $V_{i+1}$. Likewise, if Bob makes a $k$-move with $k<i$ then Alice picks the right group, which results in a configuration that dominates $V_{i-1}$. Since none of $V_{1}, \\ldots, V_{N}$ contains an empty box, Alice can prevent Bob from ever winning.\n\nFor Bob. The key idea in this solution is the following claim.\n\nClaim. If there exist a positive integer $k$ such that there are at least $2 k$ boxes that have at most $k$ pebbles each then Bob can force a win.\n\nProof. We ignore the other boxes. First, Bob makes a $k$-move (splits the $2 k$ boxes into two groups of $k$ boxes each). Without loss of generality, Alice picks the left group. Then Bob makes a $(k+1)$-move, ... a $(2 k-1)$-move. By Observation A, we may suppose Alice always picks the left group. After Bob's $(2 k-1)$-move, the rightmost box becomes empty and Bob wins.\n\nNow, we claim that if $n<M$ then either there already exists an empty box, or there exist a positive integer $k$ and $2 k$ boxes with at most $k$ pebbles each (and thus Bob can force a win). Otherwise, assume each box contains at least 1 pebble, and for each $1 \\leqslant k \\leqslant\\left\\lfloor\\frac{N}{2}\\right\\rfloor$, at least $N-(2 k-1)=N+1-2 k$ boxes contain at least $k+1$ pebbles. Summing, there are at least as many pebbles in total as in $V_{\\left\\lceil\\frac{N}{2}\\right\\rceil}$; that is, at least $M$ pebbles, as desired.",
"We present solutions for the general case of $N>1$ boxes, and write $M=\\left\\lfloor\\frac{N}{2}+1\\right\\rfloor\\left\\lceil\\frac{N}{2}+1\\right\\rceil-1$ for the claimed answer. For $1 \\leqslant k<N$, say that Bob makes a $k$-move if he splits the boxes into a left group $\\left\\{B_{1}, \\ldots, B_{k}\\right\\}$ and a right group $\\left\\{B_{k+1}, \\ldots, B_{N}\\right\\}$. Say that one configuration dominates another if it has at least as many pebbles in each box, and say that it strictly dominates the other configuration if it also has more pebbles in at least one box. (Thus, if Bob wins in some configuration, he also wins in every configuration that it dominates.)\n\nIt is often convenient to consider ' $V$-shaped' configurations; for $1 \\leqslant i \\leqslant N$, let $V_{i}$ be the configuration where $B_{j}$ contains $1+|j-i|$ pebbles (i.e. where the $i^{\\text {th }}$ box has a single pebble and the numbers increase by one in both directions, so the first box has $i$ pebbles and the last box has $N+1-i$ pebbles). Note that $V_{i}$ contains $\\frac{1}{2} i(i+1)+\\frac{1}{2}(N+1-i)(N+2-i)-1$ pebbles. If $i=\\left\\lceil\\frac{N}{2}\\right\\rceil$, this number equals $M$.solution split naturally into a strategy for Alice (starting with $M$ pebbles and showing she can prevent Bob from winning) and a strategy for Bob (showing he can win for any starting configuration with at most $M-1$ pebbles). The following observation is also useful to simplify the analysis of strategies for Bob.\n\nObservation A. Consider two consecutive rounds. Suppose that in the first round Bob made a $k$-move and Alice picked the left group, and then in the second round Bob makes an $\\ell$-move, with $\\ell>k$. We may then assume, without loss of generality, that Alice again picks the left group.\n\nProof. Suppose Alice picks the right group in the second round. Then the combined effect of the two rounds is that each of the boxes $B_{k+1}, \\ldots, B_{\\ell}$ lost two pebbles (and the other boxes are unchanged). Hence this configuration is strictly dominated by that before the first round, and it suffices to consider only Alice's other response.\n\n\nFor Alice. Let $K=\\left\\lfloor\\frac{N}{2}+1\\right\\rfloor$. Alice starts with the boxes in the configuration $V_{K}$. For each of Bob's $N-1$ possible choices, consider the subset of rounds in which he makes that choice. In that subset of rounds, Alice alternates between picking the left group and picking the right group; the first time Bob makes that choice, Alice picks the group containing the $K^{\\text {th }}$ box. Thus, at any time during the game, the number of pebbles in each box depends only on which choices Bob has made an odd number of times. This means that the number of pebbles in a box could decrease by at most the number of choices for which Alice would have started by removing a pebble from the group containing that box. These numbers are, for each box,\n\n$$\n\\left\\lfloor\\frac{N}{2}\\right\\rfloor,\\left\\lfloor\\frac{N}{2}-1\\right\\rfloor, \\ldots, 1,0,1, \\ldots,\\left\\lceil\\frac{N}{2}-1\\right\\rceil\n$$\n\nThese are pointwise less than the numbers of pebbles the boxes started with, meaning that no box ever becomes empty with this strategy.\n\nSo the final answer is $n=960$. In general, if there are $N>1$ boxes, the answer is $n=\\left\\lfloor\\frac{N}{2}+1\\right\\rfloor\\left\\lceil\\frac{N}{2}+1\\right\\rceil-1$.\n\nCommon remarks. We present solutions for the general case of $N>1$ boxes, and write $M=\\left\\lfloor\\frac{N}{2}+1\\right\\rfloor\\left\\lceil\\frac{N}{2}+1\\right\\rceil-1$ for the claimed answer. For $1 \\leqslant k<N$, say that Bob makes a $k$-move if he splits the boxes into a left group $\\left\\{B_{1}, \\ldots, B_{k}\\right\\}$ and a right group $\\left\\{B_{k+1}, \\ldots, B_{N}\\right\\}$. Say that one configuration dominates another if it has at least as many pebbles in each box, and say that it strictly dominates the other configuration if it also has more pebbles in at least one box. (Thus, if Bob wins in some configuration, he also wins in every configuration that it dominates.)\n\nIt is often convenient to consider ' $V$-shaped' configurations; for $1 \\leqslant i \\leqslant N$, let $V_{i}$ be the configuration where $B_{j}$ contains $1+|j-i|$ pebbles (i.e. where the $i^{\\text {th }}$ box has a single pebble and the numbers increase by one in both directions, so the first box has $i$ pebbles and the last box has $N+1-i$ pebbles). Note that $V_{i}$ contains $\\frac{1}{2} i(i+1)+\\frac{1}{2}(N+1-i)(N+2-i)-1$ pebbles. If $i=\\left\\lceil\\frac{N}{2}\\right\\rceil$, this number equals $M$.\n\nFor Bob. Let $K=\\left\\lfloor\\frac{N}{2}+1\\right\\rfloor$. For Bob's strategy, we consider a configuration $X$ with at most $M-1$ pebbles, and we make use of Observation A. Consider two configurations with $M$ pebbles: $V_{K}$ and $V_{N+1-K}$ (if $n$ is odd, they are the same configuration; if $n$ is even, one is the reverse of the other). The configuration $X$ has fewer pebbles than $V_{K}$ in at least one box, and fewer pebbles than $V_{N+1-K}$ in at least one box.\n\nSuppose first that, with respect to one of those configurations (without loss of generality $V_{K}$ ), $X$ has fewer pebbles in one of the boxes in the half where they have $1,2, \\ldots,\\left\\lceil\\frac{N}{2}\\right\\rceil$ pebbles (the right half in $V_{K}$ if $N$ is even; if $N$ is odd, we can take it to be the right half, without loss of generality, as the configuration is symmetric). Note that the number cannot be fewer in the box with 1 pebble in $V_{K}$, because then it would have 0 pebbles. Bob then does a $K$-move. If Alice picks the right group, the total number of pebbles goes down and we restart Bob's strategy with a smaller number of pebbles. If Alice picks the left group, Bob follows with a $(K+1)$-move, a $(K+2)$-move, and so on; by Observation A we may assume Alice always picks the left group. But whichever box in the right half had fewer pebbles in $X$ than in $V_{K}$ ends up with 0 pebbles at some point in this sequence of moves.\n\nOtherwise, $N$ is even, and for both of those configurations, there are fewer pebbles in $X$ only on the $2,3, \\ldots, \\frac{N}{2}+1$ side. That is, the numbers of pebbles in $X$ are at least\n\n$$\n\\frac{N}{2}, \\frac{N}{2}-1, \\ldots, 1,1, \\ldots, \\frac{N}{2}\n\\tag{C}\n$$\n\nwith equality occurring at least once on each side. Bob does an $\\frac{N}{2}$-move. Whichever group Alice chooses, the total number of pebbles is unchanged, and the side from which pebbles are removed now has a box with fewer pebbles than in $(C)$, so the previous case of Bob's strategy can now be applied."
] | 960 |
1,920 | Combinatorics | null | $\boxed{2^{k}}$ | [
"$2^{k}$"
] | false | null | Expression | null | For any two different real numbers $x$ and $y$, we define $D(x, y)$ to be the unique integer $d$ satisfying $2^{d} \leqslant|x-y|<2^{d+1}$. Given a set of reals $\mathcal{F}$, and an element $x \in \mathcal{F}$, we say that the scales of $x$ in $\mathcal{F}$ are the values of $D(x, y)$ for $y \in \mathcal{F}$ with $x \neq y$.
Let $k$ be a given positive integer. Suppose that each member $x$ of $\mathcal{F}$ has at most $k$ different scales in $\mathcal{F}$ (note that these scales may depend on $x$ ). What is the maximum possible size of $\mathcal{F}$ ? | [
"We first construct a set $\\mathcal{F}$ with $2^{k}$ members, each member having at most $k$ different scales in $\\mathcal{F}$. Take $\\mathcal{F}=\\left\\{0,1,2, \\ldots, 2^{k}-1\\right\\}$. The scale between any two members of $\\mathcal{F}$ is in the set $\\{0,1, \\ldots, k-1\\}$.\n\nWe now show that $2^{k}$ is an upper bound on the size of $\\mathcal{F}$. For every finite set $\\mathcal{S}$ of real numbers, and every real $x$, let $r_{\\mathcal{S}}(x)$ denote the number of different scales of $x$ in $\\mathcal{S}$. That is, $r_{\\mathcal{S}}(x)=|\\{D(x, y): x \\neq y \\in \\mathcal{S}\\}|$. Thus, for every element $x$ of the set $\\mathcal{F}$ in the problem statement, we have $r_{\\mathcal{F}}(x) \\leqslant k$. The condition $|\\mathcal{F}| \\leqslant 2^{k}$ is an immediate consequence of the following lemma.\n\nLemma. Let $\\mathcal{S}$ be a finite set of real numbers, and define\n\n$$\nw(\\mathcal{S})=\\sum_{x \\in \\mathcal{S}} 2^{-r_{\\mathcal{S}}(x)}\n$$\n\nThen $w(\\mathcal{S}) \\leqslant 1$.\n\nProof. Induction on $n=|\\mathcal{S}|$. If $\\mathcal{S}=\\{x\\}$, then $r_{\\mathcal{S}}(x)=0$, so $w(\\mathcal{S})=1$.\n\nAssume now $n \\geqslant 2$, and let $x_{1}<\\cdots<x_{n}$ list the members of $\\mathcal{S}$. Let $d$ be the minimal scale between two distinct elements of $\\mathcal{S}$; then there exist neighbours $x_{t}$ and $x_{t+1}$ with $D\\left(x_{t}, x_{t+1}\\right)=d$. Notice that for any two indices $i$ and $j$ with $j-i>1$ we have $D\\left(x_{i}, x_{j}\\right)>d$, since\n\n$$\n\\left|x_{i}-x_{j}\\right|=\\left|x_{i+1}-x_{i}\\right|+\\left|x_{j}-x_{i+1}\\right| \\geqslant 2^{d}+2^{d}=2^{d+1}\n$$\n\nNow choose the minimal $i \\leqslant t$ and the maximal $j \\geqslant t+1$ such that $D\\left(x_{i}, x_{i+1}\\right)=$ $D\\left(x_{i+1}, x_{i+2}\\right)=\\cdots=D\\left(x_{j-1}, x_{j}\\right)=d$.\n\nLet $E$ be the set of all the $x_{s}$ with even indices $i \\leqslant s \\leqslant j, O$ be the set of those with odd indices $i \\leqslant s \\leqslant j$, and $R$ be the rest of the elements (so that $\\mathcal{S}$ is the disjoint union of $E, O$ and $R$ ). Set $\\mathcal{S}_{O}=R \\cup O$ and $\\mathcal{S}_{E}=R \\cup E$; we have $\\left|\\mathcal{S}_{O}\\right|<|\\mathcal{S}|$ and $\\left|\\mathcal{S}_{E}\\right|<|\\mathcal{S}|$, so $w\\left(\\mathcal{S}_{O}\\right), w\\left(\\mathcal{S}_{E}\\right) \\leqslant 1$ by the inductive hypothesis.\n\nClearly, $r_{\\mathcal{S}_{O}}(x) \\leqslant r_{\\mathcal{S}}(x)$ and $r_{\\mathcal{S}_{E}}(x) \\leqslant r_{\\mathcal{S}}(x)$ for any $x \\in R$, and thus\n\n$$\n\\begin{aligned}\n\\sum_{x \\in R} 2^{-r_{\\mathcal{S}}(x)} & =\\frac{1}{2} \\sum_{x \\in R}\\left(2^{-r_{\\mathcal{S}}(x)}+2^{-r_{\\mathcal{S}}(x)}\\right) \\\\\n& \\leqslant \\frac{1}{2} \\sum_{x \\in R}\\left(2^{-r_{\\mathcal{S}_{O}}(x)}+2^{-r_{\\mathcal{S}_{E}}(x)}\\right)\n\\end{aligned}\n$$\n\nOn the other hand, for every $x \\in O$, there is no $y \\in \\mathcal{S}_{O}$ such that $D_{\\mathcal{S}_{O}}(x, y)=d$ (as all candidates from $\\mathcal{S}$ were in $E$ ). Hence, we have $r_{\\mathcal{S}_{O}}(x) \\leqslant r_{\\mathcal{S}}(x)-1$, and thus\n\n$$\n\\sum_{x \\in O} 2^{-r_{\\mathcal{S}}(x)} \\leqslant \\frac{1}{2} \\sum_{x \\in O} 2^{-r_{\\mathcal{S}_{O}}(x)}\n$$\n\n\n\nSimilarly, for every $x \\in E$, we have\n\n$$\n\\sum_{x \\in E} 2^{-r_{\\mathcal{S}}(x)} \\leqslant \\frac{1}{2} \\sum_{x \\in E} 2^{-r_{\\mathcal{S}_{E}}(x)}\n$$\n\nWe can then combine these to give\n\n$$\n\\begin{aligned}\n& w(S)=\\sum_{x \\in R} 2^{-r_{\\mathcal{S}}(x)}+\\sum_{x \\in O} 2^{-r_{\\mathcal{S}}(x)}+\\sum_{x \\in E} 2^{-r_{\\mathcal{S}}(x)} \\\\\n& \\leqslant \\frac{1}{2} \\sum_{x \\in R}\\left(2^{-r_{\\mathcal{S}_{O}}(x)}+2^{-r_{\\mathcal{S}_{E}}(x)}\\right)+\\frac{1}{2} \\sum_{x \\in O} 2^{-r_{\\mathcal{S}_{O}}(x)}+\\frac{1}{2} \\sum_{x \\in E} 2^{-r_{\\mathcal{S}_{E}}(x)} \\\\\n& =\\frac{1}{2}\\left(\\sum_{x \\in \\mathcal{S}_{O}} 2^{-{ }^{-} \\mathcal{S}_{O}}(x)+\\sum_{x \\in \\mathcal{S}_{E}} 2^{-r_{\\mathcal{S}_{E}}(x)}\\right) \\quad\\left(\\text { since } \\mathcal{S}_{O}=O \\cup R \\text { and } \\mathcal{S}_{E}=E \\cup R\\right) \\\\\n& \\left.=\\frac{1}{2}\\left(w\\left(\\mathcal{S}_{O}\\right)+w\\left(\\mathcal{S}_{E}\\right)\\right)\\right) \\quad(\\text { by definition of } w(\\cdot)) \\\\\n& \\leqslant 1 \\quad \\text { (by the inductive hypothesis) }\n\\end{aligned}\n$$\n\nwhich completes the induction."
] | $2^{k}$ |
1,929 | Number Theory | null | $\boxed{(1,1), (3,2)}$ | [
"$(1,1), (3,2)$"
] | true | null | Tuple | null | Find all pairs $(m, n)$ of positive integers satisfying the equation
$$
\left(2^{n}-1\right)\left(2^{n}-2\right)\left(2^{n}-4\right) \cdots\left(2^{n}-2^{n-1}\right)=m !
\tag{1}
$$ | [
"For any prime $p$ and positive integer $N$, we will denote by $v_{p}(N)$ the exponent of the largest power of $p$ that divides $N$. The left-hand side of (1) will be denoted by $L_{n}$; that is, $L_{n}=\\left(2^{n}-1\\right)\\left(2^{n}-2\\right)\\left(2^{n}-4\\right) \\cdots\\left(2^{n}-2^{n-1}\\right)$.\n\nWe will get an upper bound on $n$ from the speed at which $v_{2}\\left(L_{n}\\right)$ grows.\n\nFrom\n\n$$\nL_{n}=\\left(2^{n}-1\\right)\\left(2^{n}-2\\right) \\cdots\\left(2^{n}-2^{n-1}\\right)=2^{1+2+\\cdots+(n-1)}\\left(2^{n}-1\\right)\\left(2^{n-1}-1\\right) \\cdots\\left(2^{1}-1\\right)\n$$\n\nwe read\n\n$$\nv_{2}\\left(L_{n}\\right)=1+2+\\cdots+(n-1)=\\frac{n(n-1)}{2}\n$$\n\nOn the other hand, $v_{2}(m !)$ is expressed by the Legendre formula as\n\n$$\nv_{2}(m !)=\\sum_{i=1}^{\\infty}\\left\\lfloor\\frac{m}{2^{i}}\\right\\rfloor\n$$\n\nAs usual, by omitting the floor functions,\n\n$$\nv_{2}(m !)<\\sum_{i=1}^{\\infty} \\frac{m}{2^{i}}=m\n$$\n\nThus, $L_{n}=m$ ! implies the inequality\n\n$$\n\\frac{n(n-1)}{2}<m\n\\tag{2}\n$$\n\nIn order to obtain an opposite estimate, observe that\n\n$$\nL_{n}=\\left(2^{n}-1\\right)\\left(2^{n}-2\\right) \\cdots\\left(2^{n}-2^{n-1}\\right)<\\left(2^{n}\\right)^{n}=2^{n^{2}}\n$$\n\nWe claim that\n\n$$\n2^{n^{2}}<\\left(\\frac{n(n-1)}{2}\\right) ! \\text { for } n \\geqslant 6\n\\tag{3}\n$$\n\nFor $n=6$ the estimate $(3)$ is true because $2^{6^{2}}<6.9 \\cdot 10^{10}$ and $\\left(\\frac{n(n-1)}{2}\\right) !=15 !>1.3 \\cdot 10^{12}$.\n\nFor $n \\geqslant 7$ we prove (3) by the following inequalities:\n\n$$\n\\begin{aligned}\n\\left(\\frac{n(n-1)}{2}\\right) ! & =15 ! \\cdot 16 \\cdot 17 \\cdots \\frac{n(n-1)}{2}>2^{36} \\cdot 16^{\\frac{n(n-1)}{2}-15} \\\\\n& =2^{2 n(n-1)-24}=2^{n^{2}} \\cdot 2^{n(n-2)-24}>2^{n^{2}}\n\\end{aligned}\n$$\n\n\n\nPutting together (2) and (3), for $n \\geqslant 6$ we get a contradiction, since\n\n$$\nL_{n}<2^{n^{2}}<\\left(\\frac{n(n-1)}{2}\\right) !<m !=L_{n}\n$$\n\nHence $n \\geqslant 6$ is not possible.\n\nChecking manually the cases $n \\leqslant 5$ we find\n\n$$\n\\begin{gathered}\nL_{1}=1=1 !, \\quad L_{2}=6=3 !, \\quad 5 !<L_{3}=168<6 ! \\\\\n7 !<L_{4}=20160<8 ! \\quad \\text { and } \\quad 10 !<L_{5}=9999360<11 !\n\\end{gathered}\n$$\n\nSo, there are two solutions:\n\n$$\n(m, n) \\in\\{(1,1),(3,2)\\}\n$$",
"For any prime $p$ and positive integer $N$, we will denote by $v_{p}(N)$ the exponent of the largest power of $p$ that divides $N$. The left-hand side of (1) will be denoted by $L_{n}$; that is, $L_{n}=\\left(2^{n}-1\\right)\\left(2^{n}-2\\right)\\left(2^{n}-4\\right) \\cdots\\left(2^{n}-2^{n-1}\\right)$.\n\n\nChecking manually the cases $n \\leqslant 5$ we find\n\n$$\n\\begin{gathered}\nL_{1}=1=1 !, \\quad L_{2}=6=3 !, \\quad 5 !<L_{3}=168<6 ! \\\\\n7 !<L_{4}=20160<8 ! \\quad \\text { and } \\quad 10 !<L_{5}=9999360<11 !\n\\end{gathered}\n$$\n\nWe will exclude $n \\geqslant 5$ by considering the exponents of 3 and 31 in (1).\n\nFor odd primes $p$ and distinct integers $a, b$, coprime to $p$, with $p \\mid a-b$, the Lifting The Exponent lemma asserts that\n\n$$\nv_{p}\\left(a^{k}-b^{k}\\right)=v_{p}(a-b)+v_{p}(k) .\n$$\n\nNotice that 3 divides $2^{k}-1$ if only if $k$ is even; moreover, by the Lifting The Exponent lemma we have\n\n$$\nv_{3}\\left(2^{2 k}-1\\right)=v_{3}\\left(4^{k}-1\\right)=1+v_{3}(k)=v_{3}(3 k)\n$$\n\nHence,\n\n$$\nv_{3}\\left(L_{n}\\right)=\\sum_{2 k \\leqslant n} v_{3}\\left(4^{k}-1\\right)=\\sum_{k \\leqslant\\left\\lfloor\\frac{n}{2}\\right\\rfloor} v_{3}(3 k)\n$$\n\nNotice that the last expression is precisely the exponent of 3 in the prime factorisation of $\\left(3\\left\\lfloor\\frac{n}{2}\\right\\rfloor\\right)$ !. Therefore\n\n$$\nv_{3}(m !)=v_{3}\\left(L_{n}\\right)=v_{3}\\left(\\left(3\\left\\lfloor\\frac{n}{2}\\right\\rfloor\\right) !\\right)\n$$\n$$\n3\\left\\lfloor\\frac{n}{2}\\right\\rfloor \\leqslant m \\leqslant 3\\left\\lfloor\\frac{n}{2}\\right\\rfloor+2 .\n\\tag{4}\n$$\n\nSuppose that $n \\geqslant 5$. Note that every fifth factor in $L_{n}$ is divisible by $31=2^{5}-1$, and hence we have $v_{31}\\left(L_{n}\\right) \\geqslant\\left\\lfloor\\frac{n}{5}\\right\\rfloor$. Then\n\n$$\n\\frac{n}{10} \\leqslant\\left\\lfloor\\frac{n}{5}\\right\\rfloor \\leqslant v_{31}\\left(L_{n}\\right)=v_{31}(m !)=\\sum_{k=1}^{\\infty}\\left\\lfloor\\frac{m}{31^{k}}\\right\\rfloor<\\sum_{k=1}^{\\infty} \\frac{m}{31^{k}}=\\frac{m}{30}\n\\tag{5}\n$$\n\nBy combining (4) and (5),\n\n$$\n3 n<m \\leqslant \\frac{3 n}{2}+2\n$$\n\nso $n<\\frac{4}{3}$ which is inconsistent with the inequality $n \\geqslant 5$."
] | $(1,1), (3,2)$ |
1,930 | Number Theory | null | $\boxed{(1,2,3),(1,3,2),(2,1,3),(2,3,1),(3,1,2),(3,2,1)}$ | [
"$(1,2,3),(1,3,2),(2,1,3),(2,3,1),(3,1,2),(3,2,1)$"
] | true | null | Tuple | null | Find all triples $(a, b, c)$ of positive integers such that $a^{3}+b^{3}+c^{3}=(a b c)^{2}$. | [
"Note that the equation is symmetric. We will assume without loss of generality that $a \\geqslant b \\geqslant c$, and prove that the only solution is $(a, b, c)=(3,2,1)$.\n\n\nWe will start by proving that $c=1$. Note that\n\n$$\n3 a^{3} \\geqslant a^{3}+b^{3}+c^{3}>a^{3} .\n$$\n\nSo $3 a^{3} \\geqslant(a b c)^{2}>a^{3}$ and hence $3 a \\geqslant b^{2} c^{2}>a$. Now $b^{3}+c^{3}=a^{2}\\left(b^{2} c^{2}-a\\right) \\geqslant a^{2}$, and so\n\n$$\n18 b^{3} \\geqslant 9\\left(b^{3}+c^{3}\\right) \\geqslant 9 a^{2} \\geqslant b^{4} c^{4} \\geqslant b^{3} c^{5},\n$$\n\nso $18 \\geqslant c^{5}$ which yields $c=1$.\n\nNow, note that we must have $a>b$, as otherwise we would have $2 b^{3}+1=b^{4}$ which has no positive integer solutions. So\n\n$$\na^{3}-b^{3} \\geqslant(b+1)^{3}-b^{3}>1\n$$\n\nand\n\n$$\n2 a^{3}>1+a^{3}+b^{3}>a^{3},\n$$\n\nwhich implies $2 a^{3}>a^{2} b^{2}>a^{3}$ and so $2 a>b^{2}>a$. Therefore\n\n$$\n4\\left(1+b^{3}\\right)=4 a^{2}\\left(b^{2}-a\\right) \\geqslant 4 a^{2}>b^{4},\n$$\n\nso $4>b^{3}(b-4)$; that is, $b \\leqslant 4$.\n\nNow, for each possible value of $b$ with $2 \\leqslant b \\leqslant 4$ we obtain a cubic equation for $a$ with constant coefficients. These are as follows:\n\n$$\n\\begin{aligned}\n& b=2: \\quad a^{3}-4 a^{2}+9=0 \\\\\n& b=3: \\quad a^{3}-9 a^{2}+28=0 \\\\\n& b=4: \\quad a^{3}-16 a^{2}+65=0\n\\end{aligned}\n$$\n\nThe only case with an integer solution for $a$ with $b \\leqslant a$ is $b=2$, leading to $(a, b, c)=(3,2,1)$.",
"Note that the equation is symmetric. We will assume without loss of generality that $a \\geqslant b \\geqslant c$, and prove that the only solution is $(a, b, c)=(3,2,1)$.\n\nAgain, we will start by proving that $c=1$. Suppose otherwise that $c \\geqslant 2$. We have $a^{3}+b^{3}+c^{3} \\leqslant 3 a^{3}$, so $b^{2} c^{2} \\leqslant 3 a$. Since $c \\geqslant 2$, this tells us that $b \\leqslant \\sqrt{3 a / 4}$. As the right-hand side of the original equation is a multiple of $a^{2}$, we have $a^{2} \\leqslant 2 b^{3} \\leqslant 2(3 a / 4)^{3 / 2}$. In other words, $a \\leqslant \\frac{27}{16}<2$, which contradicts the assertion that $a \\geqslant c \\geqslant 2$. So there are no solutions in this case, and so we must have $c=1$.\n\nNow, the original equation becomes $a^{3}+b^{3}+1=a^{2} b^{2}$. Observe that $a \\geqslant 2$, since otherwise $a=b=1$ as $a \\geqslant b$.\n\nThe right-hand side is a multiple of $a^{2}$, so the left-hand side must be as well. Thus, $b^{3}+1 \\geqslant$ $a^{2}$. Since $a \\geqslant b$, we also have\n\n$$\nb^{2}=a+\\frac{b^{3}+1}{a^{2}} \\leqslant 2 a+\\frac{1}{a^{2}}\n$$\n\nand so $b^{2} \\leqslant 2 a$ since $b^{2}$ is an integer. Thus $(2 a)^{3 / 2}+1 \\geqslant b^{3}+1 \\geqslant a^{2}$, from which we deduce $a \\leqslant 8$.\n\nNow, for each possible value of $a$ with $2 \\leqslant a \\leqslant 8$ we obtain a cubic equation for $b$ with constant coefficients. These are as follows:\n\n$$\n\\begin{array}{ll}\na=2: & b^{3}-4 b^{2}+9=0 \\\\\na=3: & b^{3}-9 b^{2}+28=0 \\\\\na=4: & b^{3}-16 b^{2}+65=0 \\\\\na=5: & b^{3}-25 b^{2}+126=0 \\\\\na=6: & b^{3}-36 b^{2}+217=0 \\\\\na=7: & b^{3}-49 b^{2}+344=0 \\\\\na=8: & b^{3}-64 b^{2}+513=0 .\n\\end{array}\n$$\n\nThe only case with an integer solution for $b$ with $a \\geqslant b$ is $a=3$, leading to $(a, b, c)=(3,2,1)$.",
"Note that the equation is symmetric. We will assume without loss of generality that $a \\geqslant b \\geqslant c$, and prove that the only solution is $(a, b, c)=(3,2,1)$.\n\nOne approach to finish the problem after establishing that $c \\leqslant 1$ is to set $k=b^{2} c^{2}-a$, which is clearly an integer and must be positive as it is equal to $\\left(b^{3}+c^{3}\\right) / a^{2}$. Then we divide into cases based on whether $k=1$ or $k \\geqslant 2$; in the first case, we have $b^{3}+1=a^{2}=\\left(b^{2}-1\\right)^{2}$ whose only positive root is $b=2$, and in the second case we have $b^{2} \\leqslant 3 a$, and so\n\n$$\nb^{4} \\leqslant(3 a)^{2} \\leqslant \\frac{9}{2}\\left(k a^{2}\\right)=\\frac{9}{2}\\left(b^{3}+1\\right),\n$$\n\nwhich implies that $b \\leqslant 4$.\n\nSet $k=\\left(b^{3}+c^{3}\\right) / a^{2} \\leqslant 2 a$, and rewrite the original equation as $a+k=(b c)^{2}$. Since $b^{3}$ and $c^{3}$ are positive integers, we have $(b c)^{3} \\geqslant b^{3}+c^{3}-1=k a^{2}-1$, so\n\n$$\na+k \\geqslant\\left(k a^{2}-1\\right)^{2 / 3}\n$$\n\nAs proved before, $k$ is a positive integer; for each value of $k \\geqslant 1$, this gives us a polynomial inequality satisfied by $a$ :\n\n$$\nk^{2} a^{4}-a^{3}-5 k a^{2}-3 k^{2} a-\\left(k^{3}-1\\right) \\leqslant 0\n$$\n\nWe now prove that $a \\leqslant 3$. Indeed,\n\n$$\n0 \\geqslant \\frac{k^{2} a^{4}-a^{3}-5 k a^{2}-3 k^{2} a-\\left(k^{3}-1\\right)}{k^{2}} \\geqslant a^{4}-a^{3}-5 a^{2}-3 a-k \\geqslant a^{4}-a^{3}-5 a^{2}-5 a,\n$$\n\nwhich fails when $a \\geqslant 4$.\n\nThis leaves ten triples with $3 \\geqslant a \\geqslant b \\geqslant c \\geqslant 1$, which may be checked manually to give $(a, b, c)=(3,2,1)$.",
"Note that the equation is symmetric. We will assume without loss of generality that $a \\geqslant b \\geqslant c$, and prove that the only solution is $(a, b, c)=(3,2,1)$.\n\nAgain, observe that $b^{3}+c^{3}=a^{2}\\left(b^{2} c^{2}-a\\right)$, so $b \\leqslant a \\leqslant b^{2} c^{2}-1$.\n\nWe consider the function $f(x)=x^{2}\\left(b^{2} c^{2}-x\\right)$. It can be seen that that on the interval $\\left[0, b^{2} c^{2}-1\\right]$ the function $f$ is increasing if $x<\\frac{2}{3} b^{2} c^{2}$ and decreasing if $x>\\frac{2}{3} b^{2} c^{2}$. Consequently, it must be the case that\n\n$$\nb^{3}+c^{3}=f(a) \\geqslant \\min \\left(f(b), f\\left(b^{2} c^{2}-1\\right)\\right)\n$$\n\nFirst, suppose that $b^{3}+c^{3} \\geqslant f\\left(b^{2} c^{2}-1\\right)$. This may be written $b^{3}+c^{3} \\geqslant\\left(b^{2} c^{2}-1\\right)^{2}$, and so\n\n$$\n2 b^{3} \\geqslant b^{3}+c^{3} \\geqslant\\left(b^{2} c^{2}-1\\right)^{2}>b^{4} c^{4}-2 b^{2} c^{2} \\geqslant b^{4} c^{4}-2 b^{3} c^{4}\n$$\n\nThus, $(b-2) c^{4}<2$, and the only solutions to this inequality have $(b, c)=(2,2)$ or $b \\leqslant 3$ and $c=1$. It is easy to verify that the only case giving a solution for $a \\geqslant b$ is $(a, b, c)=(3,2,1)$.\n\nOtherwise, suppose that $b^{3}+c^{3}=f(a) \\geqslant f(b)$. Then, we have\n\n$$\n2 b^{3} \\geqslant b^{3}+c^{3}=a^{2}\\left(b^{2} c^{2}-a\\right) \\geqslant b^{2}\\left(b^{2} c^{2}-b\\right) .\n$$\n\nConsequently $b c^{2} \\leqslant 3$, with strict inequality in the case that $b \\neq c$. Hence $c=1$ and $b \\leqslant 2$. Both of these cases have been considered already, so we are done."
] | $(1,2,3),(1,3,2),(2,1,3),(2,3,1),(3,1,2),(3,2,1)$ |
1,938 | Algebra | null | $\boxed{f(x)=-1$,$f(x)=x+1}$ | [
"$f(x)=-1$,$f(x)=x+1$"
] | true | null | Expression | null | Determine all functions $f: \mathbb{Z} \rightarrow \mathbb{Z}$ with the property that
$$
f(x-f(y))=f(f(x))-f(y)-1
\tag{1}
$$
holds for all $x, y \in \mathbb{Z}$. | [
"It is immediately checked that both functions mentioned in the answer are as desired.\n\nNow let $f$ denote any function satisfying (1) for all $x, y \\in \\mathbb{Z}$. Substituting $x=0$ and $y=f(0)$ into (1) we learn that the number $z=-f(f(0))$ satisfies $f(z)=-1$. So by plugging $y=z$ into (1) we deduce that\n\n$$\nf(x+1)=f(f(x))\n\\tag{2}\n$$\n\nholds for all $x \\in \\mathbb{Z}$. Thereby (1) simplifies to\n\n$$\nf(x-f(y))=f(x+1)-f(y)-1 .\n\\tag{3}\n$$\n\nWe now work towards showing that $f$ is linear by contemplating the difference $f(x+1)-f(x)$ for any $x \\in \\mathbb{Z}$. By applying (3) with $y=x$ and (2) in this order, we obtain\n\n$$\nf(x+1)-f(x)=f(x-f(x))+1=f(f(x-1-f(x)))+1 .\n$$\n\nSince (3) shows $f(x-1-f(x))=f(x)-f(x)-1=-1$, this simplifies to\n\n$$\nf(x+1)=f(x)+A\n$$\n\nwhere $A=f(-1)+1$ is some absolute constant.\n\nNow a standard induction in both directions reveals that $f$ is indeed linear and that in fact we have $f(x)=A x+B$ for all $x \\in \\mathbb{Z}$, where $B=f(0)$. Substituting this into (2) we obtain that\n\n$$\nA x+(A+B)=A^{2} x+(A B+B)\n$$\n\nholds for all $x \\in \\mathbb{Z}$; applying this to $x=0$ and $x=1$ we infer $A+B=A B+B$ and $A^{2}=A$. The second equation leads to $A=0$ or $A=1$. In case $A=1$, the first equation gives $B=1$, meaning that $f$ has to be the successor function. If $A=0$, then $f$ is constant and (1) shows that its constant value has to be -1 . Thereby the solution is complete.",
"We commence by deriving (2) and (3) as in the first solution. Now provided that $f$ is injective, (2) tells us that $f$ is the successor function. Thus we may assume from now on that $f$ is not injective, i.e., that there are two integers $a>b$ with $f(a)=f(b)$. A straightforward induction using (2) in the induction step reveals that we have $f(a+n)=f(b+n)$ for all nonnegative integers $n$. Consequently, the sequence $\\gamma_{n}=f(b+n)$ is periodic and thus in particular bounded, which means that the numbers\n\n$$\n\\varphi=\\min _{n \\geqslant 0} \\gamma_{n} \\quad \\text { and } \\quad \\psi=\\max _{n \\geqslant 0} \\gamma_{n}\n$$\n\nexist.\n\nLet us pick any integer $y$ with $f(y)=\\varphi$ and then an integer $x \\geqslant a$ with $f(x-f(y))=\\varphi$. Due to the definition of $\\varphi$ and (3) we have\n\n$$\n\\varphi \\leqslant f(x+1)=f(x-f(y))+f(y)+1=2 \\varphi+1\n$$\n\nwhence $\\varphi \\geqslant-1$. The same reasoning applied to $\\psi$ yields $\\psi \\leqslant-1$. Since $\\varphi \\leqslant \\psi$ holds trivially, it follows that $\\varphi=\\psi=-1$, or in other words that we have $f(t)=-1$ for all integers $t \\geqslant a$.\n\nFinally, if any integer $y$ is given, we may find an integer $x$ which is so large that $x+1 \\geqslant a$ and $x-f(y) \\geqslant a$ hold. Due to (3) and the result from the previous paragraph we get\n\n$$\nf(y)=f(x+1)-f(x-f(y))-1=(-1)-(-1)-1=-1 .\n$$\n\nThereby the problem is solved.",
"Set $d=f(0)$. By plugging $x=f(y)$ into (1) we obtain\n\n$$\nf^{3}(y)=f(y)+d+1\n\\tag{4}\n$$\n\nfor all $y \\in \\mathbb{Z}$, where the left-hand side abbreviates $f(f(f(y)))$. When we replace $x$ in (1) by $f(x)$ we obtain $f(f(x)-f(y))=f^{3}(x)-f(y)-1$ and as a consequence of (4) this simplifies to\n\n$$\nf(f(x)-f(y))=f(x)-f(y)+d\n\\tag{5}\n$$\n\nNow we consider the set\n\n$$\nE=\\{f(x)-d \\mid x \\in \\mathbb{Z}\\}\n\\tag{6}\n$$\n\nGiven two integers $a$ and $b$ from $E$, we may pick some integers $x$ and $y$ with $f(x)=a+d$ and $f(y)=b+d$; now (5) tells us that $f(a-b)=(a-b)+d$, which means that $a-b$ itself exemplifies $a-b \\in E$. Thus,\n\n$$\nE \\text { is closed under taking differences. }\n$$\n\nAlso, the definitions of $d$ and $E$ yield $0 \\in E$. If $E=\\{0\\}$, then $f$ is a constant function and (1) implies that the only value attained by $f$ is indeed -1 .\n\nSo let us henceforth suppose that $E$ contains some number besides zero. It is known that in this case (6) entails $E$ to be the set of all integer multiples of some positive integer $k$. Indeed, this holds for\n\n$$\nk=\\min \\{|x| \\mid x \\in E \\text { and } x \\neq 0\\}\n$$\n\nas one may verify by an argument based on division with remainder.\n\nThus we have\n\n$$\n\\{f(x) \\mid x \\in \\mathbb{Z}\\}=\\{k \\cdot t+d \\mid t \\in \\mathbb{Z}\\}\n\\tag{7}\n$$\n\nDue to (5) and (7) we get\n\n$$\nf(k \\cdot t)=k \\cdot t+d\n$$\n\n\n\nfor all $t \\in \\mathbb{Z}$, whence in particular $f(k)=k+d$. So by comparing the results of substituting $y=0$ and $y=k$ into (1) we learn that\n\n$$\nf(z+k)=f(z)+k\n\\tag{8}\n$$\n\nholds for all integers $z$. In plain English, this means that on any residue class modulo $k$ the function $f$ is linear with slope 1 .\n\nNow by (7) the set of all values attained by $f$ is such a residue class. Hence, there exists an absolute constant $c$ such that $f(f(x))=f(x)+c$ holds for all $x \\in \\mathbb{Z}$. Thereby (1) simplifies to\n\n$$\nf(x-f(y))=f(x)-f(y)+c-1 .\n\\tag{9}\n$$\n\nOn the other hand, considering (1) modulo $k$ we obtain $d \\equiv-1(\\bmod k)$ because of $(7)$. So by (7) again, $f$ attains the value -1 .\n\nThus we may apply (9) to some integer $y$ with $f(y)=-1$, which gives $f(x+1)=f(x)+c$. So $f$ is a linear function with slope $c$. Hence, (8) leads to $c=1$, wherefore there is an absolute constant $d^{\\prime}$ with $f(x)=x+d^{\\prime}$ for all $x \\in \\mathbb{Z}$. Using this for $x=0$ we obtain $d^{\\prime}=d$ and finally (4) discloses $d=1$, meaning that $f$ is indeed the successor function."
] | $f(x)=-1$,$f(x)=x+1$ |
1,939 | Algebra | null | $\boxed{n(n-1)}$ | [
"$n(n-1)$"
] | false | null | Expression | null | Let $n$ be a fixed positive integer. Find the maximum possible value of
$$
\sum_{1 \leqslant r<s \leqslant 2 n}(s-r-n) x_{r} x_{s}
$$
where $-1 \leqslant x_{i} \leqslant 1$ for all $i=1,2, \ldots, 2 n$. | [
"Let $Z$ be the expression to be maximized. Since this expression is linear in every variable $x_{i}$ and $-1 \\leqslant x_{i} \\leqslant 1$, the maximum of $Z$ will be achieved when $x_{i}=-1$ or 1 . Therefore, it suffices to consider only the case when $x_{i} \\in\\{-1,1\\}$ for all $i=1,2, \\ldots, 2 n$.\n\nFor $i=1,2, \\ldots, 2 n$, we introduce auxiliary variables\n\n$$\ny_{i}=\\sum_{r=1}^{i} x_{r}-\\sum_{r=i+1}^{2 n} x_{r}\n$$\n\nTaking squares of both sides, we have\n\n$$\n\\begin{aligned}\ny_{i}^{2} & =\\sum_{r=1}^{2 n} x_{r}^{2}+\\sum_{r<s \\leqslant i} 2 x_{r} x_{s}+\\sum_{i<r<s} 2 x_{r} x_{s}-\\sum_{r \\leqslant i<s} 2 x_{r} x_{s} \\\\\n& =2 n+\\sum_{r<s \\leqslant i} 2 x_{r} x_{s}+\\sum_{i<r<s} 2 x_{r} x_{s}-\\sum_{r \\leqslant i<s} 2 x_{r} x_{s},\n\\end{aligned}\n\\tag{1}\n$$\n\nwhere the last equality follows from the fact that $x_{r} \\in\\{-1,1\\}$. Notice that for every $r<s$, the coefficient of $x_{r} x_{s}$ in (1) is 2 for each $i=1, \\ldots, r-1, s, \\ldots, 2 n$, and this coefficient is -2 for each $i=r, \\ldots, s-1$. This implies that the coefficient of $x_{r} x_{s}$ in $\\sum_{i=1}^{2 n} y_{i}^{2}$ is $2(2 n-s+r)-2(s-r)=$ $4(n-s+r)$. Therefore, summing (1) for $i=1,2, \\ldots, 2 n$ yields\n\n$$\n\\sum_{i=1}^{2 n} y_{i}^{2}=4 n^{2}+\\sum_{1 \\leqslant r<s \\leqslant 2 n} 4(n-s+r) x_{r} x_{s}=4 n^{2}-4 Z\n\\tag{2}\n$$\n\nHence, it suffices to find the minimum of the left-hand side.\n\nSince $x_{r} \\in\\{-1,1\\}$, we see that $y_{i}$ is an even integer. In addition, $y_{i}-y_{i-1}=2 x_{i}= \\pm 2$, and so $y_{i-1}$ and $y_{i}$ are consecutive even integers for every $i=2,3, \\ldots, 2 n$. It follows that $y_{i-1}^{2}+y_{i}^{2} \\geqslant 4$, which implies\n\n$$\n\\sum_{i=1}^{2 n} y_{i}^{2}=\\sum_{j=1}^{n}\\left(y_{2 j-1}^{2}+y_{2 j}^{2}\\right) \\geqslant 4 n\n\\tag{3}\n$$\n\nCombining (2) and (3), we get\n\n$$\n4 n \\leqslant \\sum_{i=1}^{2 n} y_{i}^{2}=4 n^{2}-4 Z\n\\tag{4}\n$$\n\nHence, $Z \\leqslant n(n-1)$.\n\nIf we set $x_{i}=1$ for odd indices $i$ and $x_{i}=-1$ for even indices $i$, then we obtain equality in (3) (and thus in (4)). Therefore, the maximum possible value of $Z$ is $n(n-1)$, as desired.",
"We present a different method of obtaining the bound $Z \\leqslant n(n-1)$. As in the previous solution, we reduce the problem to the case $x_{i} \\in\\{-1,1\\}$. For brevity, we use the notation $[2 n]=\\{1,2, \\ldots, 2 n\\}$.\n\nConsider any $x_{1}, x_{2}, \\ldots, x_{2 n} \\in\\{-1,1\\}$. Let\n\n$$\nA=\\left\\{i \\in[2 n]: x_{i}=1\\right\\} \\quad \\text { and } \\quad B=\\left\\{i \\in[2 n]: x_{i}=-1\\right\\}\n$$\n\nFor any subsets $X$ and $Y$ of $[2 n]$ we define\n\n$$\ne(X, Y)=\\sum_{r<s, r \\in X, s \\in Y}(s-r-n)\n$$\n\nOne may observe that\n\n$$\ne(A, A)+e(A, B)+e(B, A)+e(B, B)=e([2 n],[2 n])=\\sum_{1 \\leqslant r<s \\leqslant 2 n}(s-r-n)=-\\frac{(n-1) n(2 n-1)}{3}\n$$\n\nTherefore, we have\n\n$$\nZ=e(A, A)-e(A, B)-e(B, A)+e(B, B)=2(e(A, A)+e(B, B))+\\frac{(n-1) n(2 n-1)}{3} .\n\\tag{5}\n$$\n\nThus, we need to maximize $e(A, A)+e(B, B)$, where $A$ and $B$ form a partition of $[2 n]$.\n\nDue to the symmetry, we may assume that $|A|=n-p$ and $|B|=n+p$, where $0 \\leqslant p \\leqslant n$. From now on, we fix the value of $p$ and find an upper bound for $Z$ in terms of $n$ and $p$.\n\nLet $a_{1}<a_{2}<\\cdots<a_{n-p}$ and $b_{1}<b_{2}<\\cdots<b_{n+p}$ list all elements of $A$ and $B$, respectively. Then\n\n$$\ne(A, A)=\\sum_{1 \\leqslant i<j \\leqslant n-p}\\left(a_{j}-a_{i}-n\\right)=\\sum_{i=1}^{n-p}(2 i-1-n+p) a_{i}-\\left(\\begin{array}{c}\nn-p \\\\\n2\n\\end{array}\\right) \\cdot n\n\\tag{6}\n$$\n\nand similarly\n\n$$\ne(B, B)=\\sum_{i=1}^{n+p}(2 i-1-n-p) b_{i}-\\left(\\begin{array}{c}\nn+p \\\\\n2\n\\end{array}\\right) \\cdot n\n\\tag{7}\n$$\n\nThus, now it suffices to maximize the value of\n\n$$\nM=\\sum_{i=1}^{n-p}(2 i-1-n+p) a_{i}+\\sum_{i=1}^{n+p}(2 i-1-n-p) b_{i}\n\\tag{8}\n$$\n\nIn order to get an upper bound, we will apply the rearrangement inequality to the sequence $a_{1}, a_{2}, \\ldots, a_{n-p}, b_{1}, b_{2}, \\ldots, b_{n+p}$ (which is a permutation of $1,2, \\ldots, 2 n$ ), together with the sequence of coefficients of these numbers in (8). The coefficients of $a_{i}$ form the sequence\n\n$$\nn-p-1, n-p-3, \\ldots, 1-n+p\n$$\n\nand those of $b_{i}$ form the sequence\n\n$$\nn+p-1, n+p-3, \\ldots, 1-n-p\n$$\n\n\n\nAltogether, these coefficients are, in descending order:\n\n- $n+p+1-2 i$, for $i=1,2, \\ldots, p$;\n- $n-p+1-2 i$, counted twice, for $i=1,2, \\ldots, n-p$; and\n- $-(n+p+1-2 i)$, for $i=p, p-1, \\ldots, 1$.\n\nThus, the rearrangement inequality yields\n\n$$\n\\begin{gathered}\nM \\leqslant \\sum_{i=1}^{p}(n+p+1-2 i)(2 n+1-i) \\\\\n\\quad+\\sum_{i=1}^{n-p}(n-p+1-2 i)((2 n+2-p-2 i)+(2 n+1-p-2 i)) \\\\\n\\quad-\\sum_{i=1}^{p}(n+p+1-2 i) i .\n\\end{gathered}\n\\tag{9}\n$$\n\nFinally, combining the information from (5), (6), (7), and (9), we obtain\n\n$$\n\\begin{aligned}\nZ \\leqslant & \\frac{(n-1) n(2 n-1)}{3}-2 n\\left(\\left(\\begin{array}{c}\nn-p \\\\\n2\n\\end{array}\\right)+\\left(\\begin{array}{c}\nn+p \\\\\n2\n\\end{array}\\right)\\right) \\\\\n& +2 \\sum_{i=1}^{p}(n+p+1-2 i)(2 n+1-2 i)+2 \\sum_{i=1}^{n-p}(n-p+1-2 i)(4 n-2 p+3-4 i)\n\\end{aligned}\n$$\n\nwhich can be simplified to\n\n$$\nZ \\leqslant n(n-1)-\\frac{2}{3} p(p-1)(p+1)\n$$\n\nSince $p$ is a nonnegative integer, this yields $Z \\leqslant n(n-1)$."
] | $n(n-1)$ |
1,940 | Algebra | null | $\boxed{f(x)=x$,$f(x)=2-x}$ | [
"$f(x)=x$,$f(x)=2-x$"
] | true | null | Expression | null | Find all functions $f: \mathbb{R} \rightarrow \mathbb{R}$ satisfying the equation
$$
f(x+f(x+y))+f(x y)=x+f(x+y)+y f(x)\tag{1}
$$
for all real numbers $x$ and $y$. | [
"Clearly, each of the functions $x \\mapsto x$ and $x \\mapsto 2-x$ satisfies (1). It suffices now to show that they are the only solutions to the problem.\n\nSuppose that $f$ is any function satisfying (1). Then setting $y=1$ in (1), we obtain\n\n$$\nf(x+f(x+1))=x+f(x+1)\\tag{2}\n$$\n\nin other words, $x+f(x+1)$ is a fixed point of $f$ for every $x \\in \\mathbb{R}$.\n\nWe distinguish two cases regarding the value of $f(0)$.\n\nCase 1. $f(0) \\neq 0$.\n\nBy letting $x=0$ in (1), we have\n\n$$\nf(f(y))+f(0)=f(y)+y f(0) .\n$$\n\nSo, if $y_{0}$ is a fixed point of $f$, then substituting $y=y_{0}$ in the above equation we get $y_{0}=1$. Thus, it follows from (2) that $x+f(x+1)=1$ for all $x \\in \\mathbb{R}$. That is, $f(x)=2-x$ for all $x \\in \\mathbb{R}$. Case 2. $f(0)=0$.\n\nBy letting $y=0$ and replacing $x$ by $x+1$ in (1), we obtain\n\n$$\nf(x+f(x+1)+1)=x+f(x+1)+1 .\\tag{3}\n$$\n\nFrom (1), the substitution $x=1$ yields\n\n$$\nf(1+f(y+1))+f(y)=1+f(y+1)+y f(1) .\\tag{4}\n$$\n\nBy plugging $x=-1$ into (2), we see that $f(-1)=-1$. We then plug $y=-1$ into (4) and deduce that $f(1)=1$. Hence, (4) reduces to\n\n$$\nf(1+f(y+1))+f(y)=1+f(y+1)+y .\\tag{5}\n$$\n\nAccordingly, if both $y_{0}$ and $y_{0}+1$ are fixed points of $f$, then so is $y_{0}+2$. Thus, it follows from (2) and (3) that $x+f(x+1)+2$ is a fixed point of $f$ for every $x \\in \\mathbb{R}$; i.e.,\n\n$$\nf(x+f(x+1)+2)=x+f(x+1)+2 .\n$$\n\nReplacing $x$ by $x-2$ simplifies the above equation to\n\n$$\nf(x+f(x-1))=x+f(x-1) \\text {. }\n$$\n\nOn the other hand, we set $y=-1$ in (1) and get\n\n$$\nf(x+f(x-1))=x+f(x-1)-f(x)-f(-x) .\n$$\n\nTherefore, $f(-x)=-f(x)$ for all $x \\in \\mathbb{R}$.\n\nFinally, we substitute $(x, y)$ by $(-1,-y)$ in (1) and use the fact that $f(-1)=-1$ to get\n\n$$\nf(-1+f(-y-1))+f(y)=-1+f(-y-1)+y\n$$\n\nSince $f$ is an odd function, the above equation becomes\n\n$$\n-f(1+f(y+1))+f(y)=-1-f(y+1)+y \\text {. }\n$$\n\nBy adding this equation to (5), we conclude that $f(y)=y$ for all $y \\in \\mathbb{R}$."
] | $f(x)=x$,$f(x)=2-x$ |
1,945 | Combinatorics | null | $\boxed{3024}$ | [
"3024"
] | false | null | Numerical | null | For a finite set $A$ of positive integers, we call a partition of $A$ into two disjoint nonempty subsets $A_{1}$ and $A_{2}$ good if the least common multiple of the elements in $A_{1}$ is equal to the greatest common divisor of the elements in $A_{2}$. Determine the minimum value of $n$ such that there exists a set of $n$ positive integers with exactly 2015 good partitions. | [
"Let $A=\\left\\{a_{1}, a_{2}, \\ldots, a_{n}\\right\\}$, where $a_{1}<a_{2}<\\cdots<a_{n}$. For a finite nonempty set $B$ of positive integers, denote by $\\operatorname{lcm} B$ and $\\operatorname{gcd} B$ the least common multiple and the greatest common divisor of the elements in $B$, respectively.\n\nConsider any good partition $\\left(A_{1}, A_{2}\\right)$ of $A$. By definition, $\\operatorname{lcm} A_{1}=d=\\operatorname{gcd} A_{2}$ for some positive integer $d$. For any $a_{i} \\in A_{1}$ and $a_{j} \\in A_{2}$, we have $a_{i} \\leqslant d \\leqslant a_{j}$. Therefore, we have $A_{1}=\\left\\{a_{1}, a_{2}, \\ldots, a_{k}\\right\\}$ and $A_{2}=\\left\\{a_{k+1}, a_{k+2}, \\ldots, a_{n}\\right\\}$ for some $k$ with $1 \\leqslant k<n$. Hence, each good partition is determined by an element $a_{k}$, where $1 \\leqslant k<n$. We call such $a_{k}$ partitioning.\n\nIt is convenient now to define $\\ell_{k}=\\operatorname{lcm}\\left(a_{1}, a_{2}, \\ldots, a_{k}\\right)$ and $g_{k}=\\operatorname{gcd}\\left(a_{k+1}, a_{k+2}, \\ldots, a_{n}\\right)$ for $1 \\leqslant k \\leqslant n-1$. So $a_{k}$ is partitioning exactly when $\\ell_{k}=g_{k}$.\n\nWe proceed by proving some properties of partitioning elements, using the following claim. Claim. If $a_{k-1}$ and $a_{k}$ are partitioning where $2 \\leqslant k \\leqslant n-1$, then $g_{k-1}=g_{k}=a_{k}$.\n\nProof. Assume that $a_{k-1}$ and $a_{k}$ are partitioning. Since $\\ell_{k-1}=g_{k-1}$, we have $\\ell_{k-1} \\mid a_{k}$. Therefore, $g_{k}=\\ell_{k}=\\operatorname{lcm}\\left(\\ell_{k-1}, a_{k}\\right)=a_{k}$, and $g_{k-1}=\\operatorname{gcd}\\left(a_{k}, g_{k}\\right)=a_{k}$, as desired.\n\nProperty 1. For every $k=2,3, \\ldots, n-2$, at least one of $a_{k-1}, a_{k}$, and $a_{k+1}$ is not partitioning. Proof. Suppose, to the contrary, that all three numbers $a_{k-1}, a_{k}$, and $a_{k+1}$ are partitioning. The claim yields that $a_{k+1}=g_{k}=a_{k}$, a contradiction.\n\nProperty 2. The elements $a_{1}$ and $a_{2}$ cannot be simultaneously partitioning. Also, $a_{n-2}$ and $a_{n-1}$ cannot be simultaneously partitioning\n\nProof. Assume that $a_{1}$ and $a_{2}$ are partitioning. By the claim, it follows that $a_{2}=g_{1}=\\ell_{1}=$ $\\operatorname{lcm}\\left(a_{1}\\right)=a_{1}$, a contradiction.\n\nSimilarly, assume that $a_{n-2}$ and $a_{n-1}$ are partitioning. The claim yields that $a_{n-1}=g_{n-1}=$ $\\operatorname{gcd}\\left(a_{n}\\right)=a_{n}$, a contradiction.\n\nNow let $A$ be an $n$-element set with exactly 2015 good partitions. Clearly, we have $n \\geqslant 5$. Using Property 2, we find that there is at most one partitioning element in each of $\\left\\{a_{1}, a_{2}\\right\\}$ and $\\left\\{a_{n-2}, a_{n-1}\\right\\}$. By Property 1 , there are at least $\\left\\lfloor\\frac{n-5}{3}\\right\\rfloor$ non-partitioning elements in $\\left\\{a_{3}, a_{4}, \\ldots, a_{n-3}\\right\\}$. Therefore, there are at most $(n-1)-2-\\left\\lfloor\\frac{n-5}{3}\\right\\rfloor=\\left\\lceil\\frac{2(n-2)}{3}\\right\\rceil$ partitioning elements in $A$. Thus, $\\left\\lceil\\frac{2(n-2)}{3}\\right\\rceil \\geqslant 2015$, which implies that $n \\geqslant 3024$.\n\nFinally, we show that there exists a set of 3024 positive integers with exactly 2015 partitioning elements. Indeed, in the set $A=\\left\\{2 \\cdot 6^{i}, 3 \\cdot 6^{i}, 6^{i+1} \\mid 0 \\leqslant i \\leqslant 1007\\right\\}$, each element of the form $3 \\cdot 6^{i}$ or $6^{i}$, except $6^{1008}$, is partitioning.\n\nTherefore, the minimum possible value of $n$ is 3024 ."
] | 3024 |
1,953 | Geometry | null | $\boxed{\sqrt{2}}$ | [
"$\\sqrt{2}$"
] | false | null | Numerical | null | Let $A B C$ be an acute triangle, and let $M$ be the midpoint of $A C$. A circle $\omega$ passing through $B$ and $M$ meets the sides $A B$ and $B C$ again at $P$ and $Q$, respectively. Let $T$ be the point such that the quadrilateral $B P T Q$ is a parallelogram. Suppose that $T$ lies on the circumcircle of the triangle $A B C$. Determine all possible values of $B T / B M$. | [
"Let $S$ be the center of the parallelogram $B P T Q$, and let $B^{\\prime} \\neq B$ be the point on the ray $B M$ such that $B M=M B^{\\prime}$ (see Figure 1). It follows that $A B C B^{\\prime}$ is a parallelogram. Then, $\\angle A B B^{\\prime}=\\angle P Q M$ and $\\angle B B^{\\prime} A=\\angle B^{\\prime} B C=\\angle M P Q$, and so the triangles $A B B^{\\prime}$ and $M Q P$ are similar. It follows that $A M$ and $M S$ are corresponding medians in these triangles. Hence,\n\n$$\n\\angle S M P=\\angle B^{\\prime} A M=\\angle B C A=\\angle B T A .\n\\tag{1}\n$$\n\nSince $\\angle A C T=\\angle P B T$ and $\\angle T A C=\\angle T B C=\\angle B T P$, the triangles $T C A$ and $P B T$ are similar. Again, as $T M$ and $P S$ are corresponding medians in these triangles, we have\n\n$$\n\\angle M T A=\\angle T P S=\\angle B Q P=\\angle B M P .\n\\tag{2}\n$$\n\nNow we deal separately with two cases.\n\nCase 1. $S$ does not lie on $B M$. Since the configuration is symmetric between $A$ and $C$, we may assume that $S$ and $A$ lie on the same side with respect to the line $B M$.\n\nApplying (1) and (2), we get\n\n$$\n\\angle B M S=\\angle B M P-\\angle S M P=\\angle M T A-\\angle B T A=\\angle M T B\n$$\n\nand so the triangles $B S M$ and $B M T$ are similar. We now have $B M^{2}=B S \\cdot B T=B T^{2} / 2$, so $B T=\\sqrt{2} B M$.\n\nCase 2. S lies on $B M$. It follows from (2) that $\\angle B C A=\\angle M T A=\\angle B Q P=\\angle B M P$ (see Figure 2). Thus, $P Q \\| A C$ and $P M \\| A T$. Hence, $B S / B M=B P / B A=B M / B T$, so $B T^{2}=2 B M^{2}$ and $B T=\\sqrt{2} B M$.\n\n<img_3695>\n\nFigure 1\n\n<img_4019>\n\nFigure 2",
"Again, we denote by $\\Omega$ the circumcircle of the triangle $A B C$.\n\nChoose the points $X$ and $Y$ on the rays $B A$ and $B C$ respectively, so that $\\angle M X B=\\angle M B C$ and $\\angle B Y M=\\angle A B M$ (see Figure 4). Then the triangles $B M X$ and $Y M B$ are similar. Since $\\angle X P M=\\angle B Q M$, the points $P$ and $Q$ correspond to each other in these triangles. So, if $\\overrightarrow{B P}=\\mu \\cdot \\overrightarrow{B X}$, then $\\overrightarrow{B Q}=(1-\\mu) \\cdot \\overrightarrow{B Y}$. Thus\n\n$$\n\\overrightarrow{B T}=\\overrightarrow{B P}+\\overrightarrow{B Q}=\\overrightarrow{B Y}+\\mu \\cdot(\\overrightarrow{B X}-\\overrightarrow{B Y})=\\overrightarrow{B Y}+\\mu \\cdot \\overrightarrow{Y X}\n$$\n\nwhich means that $T$ lies on the line $X Y$.\n\nLet $B^{\\prime} \\neq B$ be the point on the ray $B M$ such that $B M=M B^{\\prime}$. Then $\\angle M B^{\\prime} A=$ $\\angle M B C=\\angle M X B$ and $\\angle C B^{\\prime} M=\\angle A B M=\\angle B Y M$. This means that the triangles $B M X$, $B A B^{\\prime}, Y M B$, and $B^{\\prime} C B$ are all similar; hence $B A \\cdot B X=B M \\cdot B B^{\\prime}=B C \\cdot B Y$. Thus there exists an inversion centered at $B$ which swaps $A$ with $X, M$ with $B^{\\prime}$, and $C$ with $Y$. This inversion then swaps $\\Omega$ with the line $X Y$, and hence it preserves $T$. Therefore, we have $B T^{2}=B M \\cdot B B^{\\prime}=2 B M^{2}$, and $B T=\\sqrt{2} B M$.",
"We begin with the following lemma.\n\nLemma. Let $A B C T$ be a cyclic quadrilateral. Let $P$ and $Q$ be points on the sides $B A$ and $B C$ respectively, such that $B P T Q$ is a parallelogram. Then $B P \\cdot B A+B Q \\cdot B C=B T^{2}$.\n\nProof. Let the circumcircle of the triangle $Q T C$ meet the line $B T$ again at $J$ (see Figure 5). The power of $B$ with respect to this circle yields\n\n$$\nB Q \\cdot B C=B J \\cdot B T \\text {. }\\tag{3}\n$$\n\n\n\nWe also have $\\angle T J Q=180^{\\circ}-\\angle Q C T=\\angle T A B$ and $\\angle Q T J=\\angle A B T$, and so the triangles $T J Q$ and $B A T$ are similar. We now have $T J / T Q=B A / B T$. Therefore,\n\n$$\nT J \\cdot B T=T Q \\cdot B A=B P \\cdot B A \\text {. }\n\\tag{4}\n$$\n\nCombining (3) and (4) now yields the desired result.\n\nLet $X$ and $Y$ be the midpoints of $B A$ and $B C$ respectively (see Figure 6). Applying the lemma to the cyclic quadrilaterals $P B Q M$ and $A B C T$, we obtain\n\n$$\nB X \\cdot B P+B Y \\cdot B Q=B M^{2}\n$$\n\nand\n\n$$\nB P \\cdot B A+B Q \\cdot B C=B T^{2} \\text {. }\n$$\n\nSince $B A=2 B X$ and $B C=2 B Y$, we have $B T^{2}=2 B M^{2}$, and so $B T=\\sqrt{2} B M$.\n\n<img_3340>\n\nFigure 5\n\n<img_3448>\n\nFigure 6"
] | $\sqrt{2}$ |
1,962 | Number Theory | null | $\boxed{(2,2,2),(2,2,3),(2,3,2),(3,2,2),(2,6,11),(2,11,6),(6,2,11),(6,11,2),(11,2,6),(11,6,2),(3,5,7),(3,7,5),(5,3,7),(5,7,3),(7,3,5),(7,5,3)}$ | [
"$(2,2,2),(2,2,3),(2,3,2),(3,2,2),(2,6,11),(2,11,6),(6,2,11),(6,11,2),(11,2,6),(11,6,2),(3,5,7),(3,7,5),(5,3,7),(5,7,3),(7,3,5),(7,5,3)$"
] | true | null | Tuple | null | Determine all triples $(a, b, c)$ of positive integers for which $a b-c, b c-a$, and $c a-b$ are powers of 2 .
Explanation: A power of 2 is an integer of the form $2^{n}$, where $n$ denotes some nonnegative integer. | [
"It can easily be verified that these sixteen triples are as required. Now let $(a, b, c)$ be any triple with the desired property. If we would have $a=1$, then both $b-c$ and $c-b$ were powers of 2 , which is impossible since their sum is zero; because of symmetry, this argument shows $a, b, c \\geqslant 2$.\n\nCase 1. Among $a, b$, and $c$ there are at least two equal numbers.\n\nWithout loss of generality we may suppose that $a=b$. Then $a^{2}-c$ and $a(c-1)$ are powers of 2. The latter tells us that actually $a$ and $c-1$ are powers of 2 . So there are nonnegative integers $\\alpha$ and $\\gamma$ with $a=2^{\\alpha}$ and $c=2^{\\gamma}+1$. Since $a^{2}-c=2^{2 \\alpha}-2^{\\gamma}-1$ is a power of 2 and thus incongruent to -1 modulo 4 , we must have $\\gamma \\leqslant 1$. Moreover, each of the terms $2^{2 \\alpha}-2$ and $2^{2 \\alpha}-3$ can only be a power of 2 if $\\alpha=1$. It follows that the triple $(a, b, c)$ is either $(2,2,2)$ or $(2,2,3)$.\n\nCase 2. The numbers $a, b$, and $c$ are distinct.\n\nDue to symmetry we may suppose that\n\n$$\n2 \\leqslant a<b<c .\n\\tag{1}\n$$\n\nWe are to prove that the triple $(a, b, c)$ is either $(2,6,11)$ or $(3,5,7)$. By our hypothesis, there exist three nonnegative integers $\\alpha, \\beta$, and $\\gamma$ such that\n\n$$\nb c-a =2^{\\alpha}, \\tag{2}\n$$\n$$\na c-b =2^{\\beta}, \\tag{3}\n$$\n$$\n\\text { and } \\quad a b-c =2^{\\gamma} .\\tag{4}\n$$\n\nEvidently we have\n\n$$\n\\alpha>\\beta>\\gamma\\tag{5}\n$$\n\nDepending on how large $a$ is, we divide the argument into two further cases.\n\nCase 2.1. $\\quad a=2$.\n\nWe first prove that $\\gamma=0$. Assume for the sake of contradiction that $\\gamma>0$. Then $c$ is even by (4) and, similarly, $b$ is even by (5) and (3). So the left-hand side of (2) is congruent to 2 modulo 4 , which is only possible if $b c=4$. As this contradicts (1), we have thereby shown that $\\gamma=0$, i.e., that $c=2 b-1$.\n\nNow (3) yields $3 b-2=2^{\\beta}$. Due to $b>2$ this is only possible if $\\beta \\geqslant 4$. If $\\beta=4$, then we get $b=6$ and $c=2 \\cdot 6-1=11$, which is a solution. It remains to deal with the case $\\beta \\geqslant 5$. Now (2) implies\n\n$$\n9 \\cdot 2^{\\alpha}=9 b(2 b-1)-18=(3 b-2)(6 b+1)-16=2^{\\beta}\\left(2^{\\beta+1}+5\\right)-16,\n$$\n\nand by $\\beta \\geqslant 5$ the right-hand side is not divisible by 32 . Thus $\\alpha \\leqslant 4$ and we get a contradiction to (5).\n\n\n\nCase 2.2. $a \\geqslant 3$.\n\nPick an integer $\\vartheta \\in\\{-1,+1\\}$ such that $c-\\vartheta$ is not divisible by 4 . Now\n\n$$\n2^{\\alpha}+\\vartheta \\cdot 2^{\\beta}=\\left(b c-a \\vartheta^{2}\\right)+\\vartheta(c a-b)=(b+a \\vartheta)(c-\\vartheta)\n$$\n\nis divisible by $2^{\\beta}$ and, consequently, $b+a \\vartheta$ is divisible by $2^{\\beta-1}$. On the other hand, $2^{\\beta}=a c-b>$ $(a-1) c \\geqslant 2 c$ implies in view of (1) that $a$ and $b$ are smaller than $2^{\\beta-1}$. All this is only possible if $\\vartheta=1$ and $a+b=2^{\\beta-1}$. Now (3) yields\n\n$$\na c-b=2(a+b),\n\\tag{6}\n$$\n\nwhence $4 b>a+3 b=a(c-1) \\geqslant a b$, which in turn yields $a=3$.\n\nSo (6) simplifies to $c=b+2$ and (2) tells us that $b(b+2)-3=(b-1)(b+3)$ is a power of 2. Consequently, the factors $b-1$ and $b+3$ are powers of 2 themselves. Since their difference is 4 , this is only possible if $b=5$ and thus $c=7$. Thereby the solution is complete.",
"As in the beginning of the first solution, we observe that $a, b, c \\geqslant 2$. Depending on the parities of $a, b$, and $c$ we distinguish three cases.\n\nCase 1. The numbers $a, b$, and $c$ are even.\n\nLet $2^{A}, 2^{B}$, and $2^{C}$ be the largest powers of 2 dividing $a, b$, and $c$ respectively. We may assume without loss of generality that $1 \\leqslant A \\leqslant B \\leqslant C$. Now $2^{B}$ is the highest power of 2 dividing $a c-b$, whence $a c-b=2^{B} \\leqslant b$. Similarly, we deduce $b c-a=2^{A} \\leqslant a$. Adding both estimates we get $(a+b) c \\leqslant 2(a+b)$, whence $c \\leqslant 2$. So $c=2$ and thus $A=B=C=1$; moreover, we must have had equality throughout, i.e., $a=2^{A}=2$ and $b=2^{B}=2$. We have thereby found the solution $(a, b, c)=(2,2,2)$.\n\nCase 2. The numbers $a, b$, and $c$ are odd.\n\nIf any two of these numbers are equal, say $a=b$, then $a c-b=a(c-1)$ has a nontrivial odd divisor and cannot be a power of 2 . Hence $a, b$, and $c$ are distinct. So we may assume without loss of generality that $a<b<c$.\n\nLet $\\alpha$ and $\\beta$ denote the nonnegative integers for which $b c-a=2^{\\alpha}$ and $a c-b=2^{\\beta}$ hold. Clearly, we have $\\alpha>\\beta$, and thus $2^{\\beta}$ divides\n\n$$\na \\cdot 2^{\\alpha}-b \\cdot 2^{\\beta}=a(b c-a)-b(a c-b)=b^{2}-a^{2}=(b+a)(b-a) .\n$$\n\nSince $a$ is odd, it is not possible that both factors $b+a$ and $b-a$ are divisible by 4 . Consequently, one of them has to be a multiple of $2^{\\beta-1}$. Hence one of the numbers $2(b+a)$ and $2(b-a)$ is divisible by $2^{\\beta}$ and in either case we have\n\n$$\na c-b=2^{\\beta} \\leqslant 2(a+b) .\n\\tag{7}\n$$\n\nThis in turn yields $(a-1) b<a c-b<4 b$ and thus $a=3$ (recall that $a$ is odd and larger than 1). Substituting this back into (7) we learn $c \\leqslant b+2$. But due to the parity $b<c$ entails that $b+2 \\leqslant c$ holds as well. So we get $c=b+2$ and from $b c-a=(b-1)(b+3)$ being a power of 2 it follows that $b=5$ and $c=7$.\n\nCase 3. Among $a, b$, and $c$ both parities occur.\n\nWithout loss of generality, we suppose that $c$ is odd and that $a \\leqslant b$. We are to show that $(a, b, c)$ is either $(2,2,3)$ or $(2,6,11)$. As at least one of $a$ and $b$ is even, the expression $a b-c$ is odd; since it is also a power of 2 , we obtain\n\n$$\na b-c=1 \\text {. }\n\\tag{8}\n$$\n\nIf $a=b$, then $c=a^{2}-1$, and from $a c-b=a\\left(a^{2}-2\\right)$ being a power of 2 it follows that both $a$ and $a^{2}-2$ are powers of 2 , whence $a=2$. This gives rise to the solution $(2,2,3)$.\n\n\n\nWe may suppose $a<b$ from now on. As usual, we let $\\alpha>\\beta$ denote the integers satisfying\n\n$$\n2^{\\alpha}=b c-a \\quad \\text { and } \\quad 2^{\\beta}=a c-b\n\\tag{9}\n$$\n\nIf $\\beta=0$ it would follow that $a c-b=a b-c=1$ and hence that $b=c=1$, which is absurd. So $\\beta$ and $\\alpha$ are positive and consequently $a$ and $b$ are even. Substituting $c=a b-1$ into (9) we obtain\n\n$$\n2^{\\alpha} =a b^{2}-(a+b), \\tag{10}\n$$\n$$\n\\text { and } \\quad 2^{\\beta} =a^{2} b-(a+b) .\n\\tag{11}\n$$\n\nThe addition of both equation yields $2^{\\alpha}+2^{\\beta}=(a b-2)(a+b)$. Now $a b-2$ is even but not divisible by 4 , so the highest power of 2 dividing $a+b$ is $2^{\\beta-1}$. For this reason, the equations (10) and (11) show that the highest powers of 2 dividing either of the numbers $a b^{2}$ and $a^{2} b$ is likewise $2^{\\beta-1}$. Thus there is an integer $\\tau \\geqslant 1$ together with odd integers $A, B$, and $C$ such that $a=2^{\\tau} A, b=2^{\\tau} B, a+b=2^{3 \\tau} C$, and $\\beta=1+3 \\tau$.\n\nNotice that $A+B=2^{2 \\tau} C \\geqslant 4 C$. Moreover, (11) entails $A^{2} B-C=2$. Thus $8=$ $4 A^{2} B-4 C \\geqslant 4 A^{2} B-A-B \\geqslant A^{2}(3 B-1)$. Since $A$ and $B$ are odd with $A<B$, this is only possible if $A=1$ and $B=3$. Finally, one may conclude $C=1, \\tau=1, a=2, b=6$, and $c=11$. We have thereby found the triple $(2,6,11)$. This completes the discussion of the third case, and hence the solution. There are sixteen such triples, namely $(2,2,2)$, the three permutations of $(2,2,3)$, and the six permutations of each of $(2,6,11)$ and $(3,5,7)$\n"
] | $(2,2,2),(2,2,3),(2,3,2),(3,2,2),(2,6,11),(2,11,6),(6,2,11),(6,11,2),(11,2,6),(11,6,2),(3,5,7),(3,7,5),(5,3,7),(5,7,3),(7,3,5),(7,5,3)$ |
1,964 | Number Theory | null | $\boxed{k \geqslant 2}$ | [
"$k \\geqslant 2$"
] | false | null | Expression | null | Let $\mathbb{Z}_{>0}$ denote the set of positive integers. For any positive integer $k$, a function $f: \mathbb{Z}_{>0} \rightarrow \mathbb{Z}_{>0}$ is called $k$-good if $\operatorname{gcd}(f(m)+n, f(n)+m) \leqslant k$ for all $m \neq n$. Find all $k$ such that there exists a $k$-good function. | [
"For any function $f: \\mathbb{Z}_{>0} \\rightarrow \\mathbb{Z}_{>0}$, let $G_{f}(m, n)=\\operatorname{gcd}(f(m)+n, f(n)+m)$. Note that a $k$-good function is also $(k+1)$-good for any positive integer $k$. Hence, it suffices to show that there does not exist a 1-good function and that there exists a 2-good function.\n\nWe first show that there is no 1-good function. Suppose that there exists a function $f$ such that $G_{f}(m, n)=1$ for all $m \\neq n$. Now, if there are two distinct even numbers $m$ and $n$ such that $f(m)$ and $f(n)$ are both even, then $2 \\mid G_{f}(m, n)$, a contradiction. A similar argument holds if there are two distinct odd numbers $m$ and $n$ such that $f(m)$ and $f(n)$ are both odd. Hence we can choose an even $m$ and an odd $n$ such that $f(m)$ is odd and $f(n)$ is even. This also implies that $2 \\mid G_{f}(m, n)$, a contradiction.\n\nWe now construct a 2 -good function. Define $f(n)=2^{g(n)+1}-n-1$, where $g$ is defined recursively by $g(1)=1$ and $g(n+1)=\\left(2^{g(n)+1}\\right) !$.\n\nFor any positive integers $m>n$, set\n\n$$\nA=f(m)+n=2^{g(m)+1}-m+n-1, \\quad B=f(n)+m=2^{g(n)+1}-n+m-1 .\n$$\n\nWe need to show that $\\operatorname{gcd}(A, B) \\leqslant 2$. First, note that $A+B=2^{g(m)+1}+2^{g(n)+1}-2$ is not divisible by 4 , so that $4 \\nmid \\operatorname{gcd}(A, B)$. Now we suppose that there is an odd prime $p$ for which $p \\mid \\operatorname{gcd}(A, B)$ and derive a contradiction.\n\nWe first claim that $2^{g(m-1)+1} \\geqslant B$. This is a rather weak bound; one way to prove it is as follows. Observe that $g(k+1)>g(k)$ and hence $2^{g(k+1)+1} \\geqslant 2^{g(k)+1}+1$ for every positive integer $k$. By repeatedly applying this inequality, we obtain $2^{g(m-1)+1} \\geqslant 2^{g(n)+1}+(m-1)-n=B$.\n\nNow, since $p \\mid B$, we have $p-1<B \\leqslant 2^{g(m-1)+1}$, so that $p-1 \\mid\\left(2^{g(m-1)+1}\\right) !=g(m)$. Hence $2^{g(m)} \\equiv 1(\\bmod p)$, which yields $A+B \\equiv 2^{g(n)+1}(\\bmod p)$. However, since $p \\mid A+B$, this implies that $p=2$, a contradiction.",
"We provide an alternative construction of a 2-good function $f$.\n\nLet $\\mathcal{P}$ be the set consisting of 4 and all odd primes. For every $p \\in \\mathcal{P}$, we say that a number $a \\in\\{0,1, \\ldots, p-1\\}$ is $p$-useful if $a \\not \\equiv-a(\\bmod p)$. Note that a residue modulo $p$ which is neither 0 nor 2 is $p$-useful (the latter is needed only when $p=4$ ).\n\nWe will construct $f$ recursively; in some steps, we will also define a $p$-useful number $a_{p}$. After the $m^{\\text {th }}$ step, the construction will satisfy the following conditions:\n\n(i) The values of $f(n)$ have already been defined for all $n \\leqslant m$, and $p$-useful numbers $a_{p}$ have already been defined for all $p \\leqslant m+2$;\n\n(ii) If $n \\leqslant m$ and $p \\leqslant m+2$, then $f(n)+n \\not \\equiv a_{p}(\\bmod p)$;\n\n(iii) $\\operatorname{gcd}\\left(f\\left(n_{1}\\right)+n_{2}, f\\left(n_{2}\\right)+n_{1}\\right) \\leqslant 2$ for all $n_{1}<n_{2} \\leqslant m$.\n\nIf these conditions are satisfied, then $f$ will be a 2-good function.\n\nStep 1. Set $f(1)=1$ and $a_3=1$. Clearly, all the conditions are satisfied.\n\nStep $m$, for $m \\geqslant 2$. We need to determine $f(m)$ and, if $m+2 \\in \\mathcal{P}$, the number $a_{m+2}$.\n\nDefining $f(m)$. Let $X_{m}=\\{p \\in \\mathcal{P}: p \\mid f(n)+m$ for some $n<m\\}$. We will determine $f(m) \\bmod p$ for all $p \\in X_{m}$ and then choose $f(m)$ using the Chinese Remainder Theorem.\n\n\n\nTake any $p \\in X_{m}$. If $p \\leqslant m+1$, then we define $f(m) \\equiv-a_{p}-m(\\bmod p)$. Otherwise, if $p \\geqslant m+2$, then we define $f(m) \\equiv 0(\\bmod p)$.\n\nDefining $a_{m+2}$. Now let $p=m+2$ and suppose that $p \\in \\mathcal{P}$. We choose $a_{p}$ to be a residue modulo $p$ that is not congruent to 0,2 , or $f(n)+n$ for any $n \\leqslant m$. Since $f(1)+1=2$, there are at most $m+1<p$ residues to avoid, so we can always choose a remaining residue.\n\nWe first check that ( $i$ ii) is satisfied. We only need to check it if $p=m+2$ or $n=m$. In the former case, we have $f(n)+n \\not \\equiv a_{p}(\\bmod p)$ by construction. In the latter case, if $n=m$ and $p \\leqslant m+1$, then we have $f(m)+m \\equiv-a_{p} \\not \\equiv a_{p}(\\bmod p)$, where we make use of the fact that $a_{p}$ is $p$-useful.\n\nNow we check that (iii) holds. Suppose, to the contrary, that $p \\mid \\operatorname{gcd}(f(n)+m, f(m)+n)$ for some $n<m$. Then $p \\in X_{m}$ and $p \\mid f(m)+n$. If $p \\geqslant m+2$, then $0 \\equiv f(m)+n \\equiv n(\\bmod p)$, which is impossible since $n<m<p$.\n\nOtherwise, if $p \\leqslant m+1$, then\n\n$$\n0 \\equiv(f(m)+n)+(f(n)+m) \\equiv(f(n)+n)+(f(m)+m) \\equiv(f(n)+n)-a_{p} \\quad(\\bmod p)\n$$\n\nThis implies that $f(n)+n \\equiv a_{p}(\\bmod p)$, a contradiction with $(i i)$."
] | $k \geqslant 2$ |
1,965 | Number Theory | null | $\boxed{f(x)=a x+b$, where $b$ is an arbitrary integer, and $a$ is an arbitrary positive integer with $\mho(a)=0}$ | [
"$f(x)=a x+b$, where $b$ is an arbitrary integer, and $a$ is an arbitrary positive integer with $\\mho(a)=0$"
] | true | null | Expression | null | For every positive integer $n$ with prime factorization $n=\prod_{i=1}^{k} p_{i}^{\alpha_{i}}$, define
$$
\mho(n)=\sum_{i: p_{i}>10^{100}} \alpha_{i}\tag{1}
$$
That is, $\mho(n)$ is the number of prime factors of $n$ greater than $10^{100}$, counted with multiplicity.
Find all strictly increasing functions $f: \mathbb{Z} \rightarrow \mathbb{Z}$ such that
$$
\mho(f(a)-f(b)) \leqslant \mho(a-b) \quad \text { for all integers } a \text { and } b \text { with } a>b \text {. }
$$ | [
"A straightforward check shows that all the functions listed in the answer satisfy the problem condition. It remains to show the converse.\n\nAssume that $f$ is a function satisfying the problem condition. Notice that the function $g(x)=f(x)-f(0)$ also satisfies this condition. Replacing $f$ by $g$, we assume from now on that $f(0)=0$; then $f(n)>0$ for any positive integer $n$. Thus, we aim to prove that there exists a positive integer $a$ with $\\mho(a)=0$ such that $f(n)=a n$ for all $n \\in \\mathbb{Z}$.\n\nWe start by introducing some notation. Set $N=10^{100}$. We say that a prime $p$ is large if $p>N$, and $p$ is small otherwise; let $\\mathcal{S}$ be the set of all small primes. Next, we say that a positive integer is large or small if all its prime factors are such (thus, the number 1 is the unique number which is both large and small). For a positive integer $k$, we denote the greatest large divisor of $k$ and the greatest small divisor of $k$ by $L(k)$ and $S(k)$, respectively; thus, $k=L(k) S(k)$.\n\nWe split the proof into three steps.\n\nStep 1. We prove that for every large $k$, we have $k|f(a)-f(b) \\Longleftrightarrow k| a-b$. In other $\\overline{\\text { words, }} L(f(a)-f(b))=L(a-b)$ for all integers $a$ and $b$ with $a>b$.\n\nWe use induction on $k$. The base case $k=1$ is trivial. For the induction step, assume that $k_{0}$ is a large number, and that the statement holds for all large numbers $k$ with $k<k_{0}$.\n\nClaim 1. For any integers $x$ and $y$ with $0<x-y<k_{0}$, the number $k_{0}$ does not divide $f(x)-f(y)$.\n\nProof. Assume, to the contrary, that $k_{0} \\mid f(x)-f(y)$. Let $\\ell=L(x-y)$; then $\\ell \\leqslant x-y<k_{0}$. By the induction hypothesis, $\\ell \\mid f(x)-f(y)$, and thus $\\operatorname{lcm}\\left(k_{0}, \\ell\\right) \\mid f(x)-f(y)$. Notice that $\\operatorname{lcm}\\left(k_{0}, \\ell\\right)$ is large, and $\\operatorname{lcm}\\left(k_{0}, \\ell\\right) \\geqslant k_{0}>\\ell$. But then\n\n$$\n\\mho(f(x)-f(y)) \\geqslant \\mho\\left(\\operatorname{lcm}\\left(k_{0}, \\ell\\right)\\right)>\\mho(\\ell)=\\mho(x-y),\n$$\n\nwhich is impossible.\n\nNow we complete the induction step. By Claim 1, for every integer $a$ each of the sequences\n\n$$\nf(a), f(a+1), \\ldots, f\\left(a+k_{0}-1\\right) \\quad \\text { and } \\quad f(a+1), f(a+2), \\ldots, f\\left(a+k_{0}\\right)\n$$\n\nforms a complete residue system modulo $k_{0}$. This yields $f(a) \\equiv f\\left(a+k_{0}\\right)\\left(\\bmod k_{0}\\right)$. Thus, $f(a) \\equiv f(b)\\left(\\bmod k_{0}\\right)$ whenever $a \\equiv b\\left(\\bmod k_{0}\\right)$.\n\nFinally, if $a \\not \\equiv b\\left(\\bmod k_{0}\\right)$ then there exists an integer $b^{\\prime}$ such that $b^{\\prime} \\equiv b\\left(\\bmod k_{0}\\right)$ and $\\left|a-b^{\\prime}\\right|<k_{0}$. Then $f(b) \\equiv f\\left(b^{\\prime}\\right) \\not \\equiv f(a)\\left(\\bmod k_{0}\\right)$. The induction step is proved.\n\nStep 2. We prove that for some small integer a there exist infinitely many integers $n$ such that $\\overline{f(n)}=$ an. In other words, $f$ is linear on some infinite set.\n\nWe start with the following general statement.\n\n\n\nClaim 2. There exists a constant $c$ such that $f(t)<c t$ for every positive integer $t>N$.\n\nProof. Let $d$ be the product of all small primes, and let $\\alpha$ be a positive integer such that $2^{\\alpha}>f(N)$. Then, for every $p \\in \\mathcal{S}$ the numbers $f(0), f(1), \\ldots, f(N)$ are distinct modulo $p^{\\alpha}$. Set $P=d^{\\alpha}$ and $c=P+f(N)$.\n\nChoose any integer $t>N$. Due to the choice of $\\alpha$, for every $p \\in \\mathcal{S}$ there exists at most one nonnegative integer $i \\leqslant N$ with $p^{\\alpha} \\mid f(t)-f(i)$. Since $|\\mathcal{S}|<N$, we can choose a nonnegative integer $j \\leqslant N$ such that $p^{\\alpha} \\nmid f(t)-f(j)$ for all $p \\in \\mathcal{S}$. Therefore, $S(f(t)-f(j))<P$.\n\nOn the other hand, Step 1 shows that $L(f(t)-f(j))=L(t-j) \\leqslant t-j$. Since $0 \\leqslant j \\leqslant N$, this yields\n\n$$\nf(t)=f(j)+L(f(t)-f(j)) \\cdot S(f(t)-f(j))<f(N)+(t-j) P \\leqslant(P+f(N)) t=c t\n$$\n\nNow let $\\mathcal{T}$ be the set of large primes. For every $t \\in \\mathcal{T}$, Step 1 implies $L(f(t))=t$, so the ratio $f(t) / t$ is an integer. Now Claim 2 leaves us with only finitely many choices for this ratio, which means that there exists an infinite subset $\\mathcal{T}^{\\prime} \\subseteq \\mathcal{T}$ and a positive integer $a$ such that $f(t)=a t$ for all $t \\in \\mathcal{T}^{\\prime}$, as required.\n\nSince $L(t)=L(f(t))=L(a) L(t)$ for all $t \\in \\mathcal{T}^{\\prime}$, we get $L(a)=1$, so the number $a$ is small.\n\nStep 3. We show that $f(x)=$ ax for all $x \\in \\mathbb{Z}$.\n\nLet $R_{i}=\\{x \\in \\mathbb{Z}: x \\equiv i(\\bmod N !)\\}$ denote the residue class of $i$ modulo $N !$.\n\nClaim 3. Assume that for some $r$, there are infinitely many $n \\in R_{r}$ such that $f(n)=a n$. Then $f(x)=a x$ for all $x \\in R_{r+1}$.\n\nProof. Choose any $x \\in R_{r+1}$. By our assumption, we can select $n \\in R_{r}$ such that $f(n)=$ an and $|n-x|>|f(x)-a x|$. Since $n-x \\equiv r-(r+1)=-1(\\bmod N !)$, the number $|n-x|$ is large. Therefore, by Step 1 we have $f(x) \\equiv f(n)=a n \\equiv a x(\\bmod n-x)$, so $n-x \\mid f(x)-a x$. Due to the choice of $n$, this yields $f(x)=a x$.\n\nTo complete Step 3, notice that the set $\\mathcal{T}^{\\prime}$ found in Step 2 contains infinitely many elements of some residue class $R_{i}$. Applying Claim 3, we successively obtain that $f(x)=a x$ for all $x \\in R_{i+1}, R_{i+2}, \\ldots, R_{i+N !}=R_{i}$. This finishes the solution."
] | $f(x)=a x+b$, where $b$ is an arbitrary integer, and $a$ is an arbitrary positive integer with $\mho(a)=0$ |
1,968 | Algebra | null | $\boxed{2}$ | [
"2"
] | false | null | Numerical | null | For a sequence $x_{1}, x_{2}, \ldots, x_{n}$ of real numbers, we define its price as
$$
\max _{1 \leqslant i \leqslant n}\left|x_{1}+\cdots+x_{i}\right|
$$
Given $n$ real numbers, Dave and George want to arrange them into a sequence with a low price. Diligent Dave checks all possible ways and finds the minimum possible price $D$. Greedy George, on the other hand, chooses $x_{1}$ such that $\left|x_{1}\right|$ is as small as possible; among the remaining numbers, he chooses $x_{2}$ such that $\left|x_{1}+x_{2}\right|$ is as small as possible, and so on. Thus, in the $i^{\text {th }}$ step he chooses $x_{i}$ among the remaining numbers so as to minimise the value of $\left|x_{1}+x_{2}+\cdots+x_{i}\right|$. In each step, if several numbers provide the same value, George chooses one at random. Finally he gets a sequence with price $G$.
Find the least possible constant $c$ such that for every positive integer $n$, for every collection of $n$ real numbers, and for every possible sequence that George might obtain, the resulting values satisfy the inequality $G \leqslant c D$. | [
"If the initial numbers are $1,-1,2$, and -2 , then Dave may arrange them as $1,-2,2,-1$, while George may get the sequence $1,-1,2,-2$, resulting in $D=1$ and $G=2$. So we obtain $c \\geqslant 2$.\n\nTherefore, it remains to prove that $G \\leqslant 2 D$. Let $x_{1}, x_{2}, \\ldots, x_{n}$ be the numbers Dave and George have at their disposal. Assume that Dave and George arrange them into sequences $d_{1}, d_{2}, \\ldots, d_{n}$ and $g_{1}, g_{2}, \\ldots, g_{n}$, respectively. Put\n\n$$\nM=\\max _{1 \\leqslant i \\leqslant n}\\left|x_{i}\\right|, \\quad S=\\left|x_{1}+\\cdots+x_{n}\\right|, \\quad \\text { and } \\quad N=\\max \\{M, S\\}\n$$\n\nWe claim that\n\n$$\nD \\geqslant S,\n\\tag{1}\n$$\n$$\nD \\geqslant \\frac{M}{2}, \\quad \\text { and } \n\\tag{2}\n$$\n$$\nG \\leqslant N=\\max \\{M, S\\} \n\\tag{3}\n$$\n\nThese inequalities yield the desired estimate, as $G \\leqslant \\max \\{M, S\\} \\leqslant \\max \\{M, 2 S\\} \\leqslant 2 D$.\n\nThe inequality (1) is a direct consequence of the definition of the price.\n\nTo prove (2), consider an index $i$ with $\\left|d_{i}\\right|=M$. Then we have\n\n$$\nM=\\left|d_{i}\\right|=\\left|\\left(d_{1}+\\cdots+d_{i}\\right)-\\left(d_{1}+\\cdots+d_{i-1}\\right)\\right| \\leqslant\\left|d_{1}+\\cdots+d_{i}\\right|+\\left|d_{1}+\\cdots+d_{i-1}\\right| \\leqslant 2 D\n$$\n\nas required.\n\nIt remains to establish (3). Put $h_{i}=g_{1}+g_{2}+\\cdots+g_{i}$. We will prove by induction on $i$ that $\\left|h_{i}\\right| \\leqslant N$. The base case $i=1$ holds, since $\\left|h_{1}\\right|=\\left|g_{1}\\right| \\leqslant M \\leqslant N$. Notice also that $\\left|h_{n}\\right|=S \\leqslant N$.\n\nFor the induction step, assume that $\\left|h_{i-1}\\right| \\leqslant N$. We distinguish two cases.\n\nCase 1. Assume that no two of the numbers $g_{i}, g_{i+1}, \\ldots, g_{n}$ have opposite signs.\n\nWithout loss of generality, we may assume that they are all nonnegative. Then one has $h_{i-1} \\leqslant h_{i} \\leqslant \\cdots \\leqslant h_{n}$, thus\n\n$$\n\\left|h_{i}\\right| \\leqslant \\max \\left\\{\\left|h_{i-1}\\right|,\\left|h_{n}\\right|\\right\\} \\leqslant N\n$$\n\nCase 2. Among the numbers $g_{i}, g_{i+1}, \\ldots, g_{n}$ there are positive and negative ones.\n\n\n\nThen there exists some index $j \\geqslant i$ such that $h_{i-1} g_{j} \\leqslant 0$. By the definition of George's sequence we have\n\n$$\n\\left|h_{i}\\right|=\\left|h_{i-1}+g_{i}\\right| \\leqslant\\left|h_{i-1}+g_{j}\\right| \\leqslant \\max \\left\\{\\left|h_{i-1}\\right|,\\left|g_{j}\\right|\\right\\} \\leqslant N\n$$\n\nThus, the induction step is established."
] | 2 |
1,969 | Algebra | null | $\boxed{f(n) = 2 n+1007}$ | [
"$f(n) = 2 n+1007$"
] | false | null | Expression | null | Determine all functions $f: \mathbb{Z} \rightarrow \mathbb{Z}$ satisfying
$$
f(f(m)+n)+f(m)=f(n)+f(3 m)+2014
\tag{1}
$$
for all integers $m$ and $n$. | [
"Let $f$ be a function satisfying (1). Set $C=1007$ and define the function $g: \\mathbb{Z} \\rightarrow \\mathbb{Z}$ by $g(m)=f(3 m)-f(m)+2 C$ for all $m \\in \\mathbb{Z}$; in particular, $g(0)=2 C$. Now (1) rewrites as\n\n$$\nf(f(m)+n)=g(m)+f(n)\n$$\n\nfor all $m, n \\in \\mathbb{Z}$. By induction in both directions it follows that\n\n$$\nf(t f(m)+n)=\\operatorname{tg}(m)+f(n)\n\\tag{2}\n$$\n\nholds for all $m, n, t \\in \\mathbb{Z}$. Applying this, for any $r \\in \\mathbb{Z}$, to the triples $(r, 0, f(0))$ and $(0,0, f(r))$ in place of $(m, n, t)$ we obtain\n\n$$\nf(0) g(r)=f(f(r) f(0))-f(0)=f(r) g(0) \\text {. }\n$$\n\nNow if $f(0)$ vanished, then $g(0)=2 C>0$ would entail that $f$ vanishes identically, contrary to (1). Thus $f(0) \\neq 0$ and the previous equation yields $g(r)=\\alpha f(r)$, where $\\alpha=\\frac{g(0)}{f(0)}$ is some nonzero constant.\n\nSo the definition of $g$ reveals $f(3 m)=(1+\\alpha) f(m)-2 C$, i.e.,\n\n$$\nf(3 m)-\\beta=(1+\\alpha)(f(m)-\\beta)\n\\tag{3}\n$$\n\nfor all $m \\in \\mathbb{Z}$, where $\\beta=\\frac{2 C}{\\alpha}$. By induction on $k$ this implies\n\n$$\nf\\left(3^{k} m\\right)-\\beta=(1+\\alpha)^{k}(f(m)-\\beta)\n\\tag{4}\n$$\n\nfor all integers $k \\geqslant 0$ and $m$.\n\nSince $3 \\nmid 2014$, there exists by (1) some value $d=f(a)$ attained by $f$ that is not divisible by 3 . Now by (2) we have $f(n+t d)=f(n)+t g(a)=f(n)+\\alpha \\cdot t f(a)$, i.e.,\n\n$$\nf(n+t d)=f(n)+\\alpha \\cdot t d\n\\tag{5}\n$$\n\nfor all $n, t \\in \\mathbb{Z}$.\n\nLet us fix any positive integer $k$ with $d \\mid\\left(3^{k}-1\\right)$, which is possible, since $\\operatorname{gcd}(3, d)=1$. E.g., by the Euler-Fermat theorem, we may take $k=\\varphi(|d|)$. Now for each $m \\in \\mathbb{Z}$ we get\n\n$$\nf\\left(3^{k} m\\right)=f(m)+\\alpha\\left(3^{k}-1\\right) m\n$$\n\nfrom (5), which in view of (4) yields $\\left((1+\\alpha)^{k}-1\\right)(f(m)-\\beta)=\\alpha\\left(3^{k}-1\\right) m$. Since $\\alpha \\neq 0$, the right hand side does not vanish for $m \\neq 0$, wherefore the first factor on the left hand side cannot vanish either. It follows that\n\n$$\nf(m)=\\frac{\\alpha\\left(3^{k}-1\\right)}{(1+\\alpha)^{k}-1} \\cdot m+\\beta\n$$\n\n\n\nSo $f$ is a linear function, say $f(m)=A m+\\beta$ for all $m \\in \\mathbb{Z}$ with some constant $A \\in \\mathbb{Q}$. Plugging this into (1) one obtains $\\left(A^{2}-2 A\\right) m+(A \\beta-2 C)=0$ for all $m$, which is equivalent to the conjunction of\n\n$$\nA^{2}=2 A \\quad \\text { and } \\quad A \\beta=2 C .\n\\tag{6}\n$$\n\nThe first equation is equivalent to $A \\in\\{0,2\\}$, and as $C \\neq 0$ the second one gives\n\n$$\nA=2 \\quad \\text { and } \\quad \\beta=C .\n\\tag{7}\n$$\n\nThis shows that $f$ is indeed the function mentioned in the answer and as the numbers found in (7) do indeed satisfy the equations (6) this function is indeed as desired."
] | $f(n) = 2 n+1007$ |
1,970 | Algebra | null | $\boxed{(-\infty, 0) \cup\{1\}$.}$ | [
"$(-\\infty, 0) \\cup\\{1\\}$."
] | false | null | Interval | null | Consider all polynomials $P(x)$ with real coefficients that have the following property: for any two real numbers $x$ and $y$ one has
$$
\left|y^{2}-P(x)\right| \leqslant 2|x| \text { if and only if }\left|x^{2}-P(y)\right| \leqslant 2|y|
\tag{1}
$$
Determine all possible values of $P(0)$. | [
"Part I. We begin by verifying that these numbers are indeed possible values of $P(0)$. To see that each negative real number $-C$ can be $P(0)$, it suffices to check that for every $C>0$ the polynomial $P(x)=-\\left(\\frac{2 x^{2}}{C}+C\\right)$ has the property described in the statement of the problem. Due to symmetry it is enough for this purpose to prove $\\left|y^{2}-P(x)\\right|>2|x|$ for any two real numbers $x$ and $y$. In fact we have\n\n$$\n\\left|y^{2}-P(x)\\right|=y^{2}+\\frac{x^{2}}{C}+\\frac{(|x|-C)^{2}}{C}+2|x| \\geqslant \\frac{x^{2}}{C}+2|x| \\geqslant 2|x|\n$$\n\nwhere in the first estimate equality can only hold if $|x|=C$, whilst in the second one it can only hold if $x=0$. As these two conditions cannot be met at the same time, we have indeed $\\left|y^{2}-P(x)\\right|>2|x|$.\n\nTo show that $P(0)=1$ is possible as well, we verify that the polynomial $P(x)=x^{2}+1$ satisfies (1). Notice that for all real numbers $x$ and $y$ we have\n\n$$\n\\begin{aligned}\n\\left|y^{2}-P(x)\\right| \\leqslant 2|x| & \\Longleftrightarrow\\left(y^{2}-x^{2}-1\\right)^{2} \\leqslant 4 x^{2} \\\\\n& \\Longleftrightarrow 0 \\leqslant\\left(\\left(y^{2}-(x-1)^{2}\\right)\\left((x+1)^{2}-y^{2}\\right)\\right. \\\\\n& \\Longleftrightarrow 0 \\leqslant(y-x+1)(y+x-1)(x+1-y)(x+1+y) \\\\\n& \\Longleftrightarrow 0 \\leqslant\\left((x+y)^{2}-1\\right)\\left(1-(x-y)^{2}\\right) .\n\\end{aligned}\n$$\n\nSince this inequality is symmetric in $x$ and $y$, we are done.\n\nPart II. Now we show that no values other than those mentioned in the answer are possible for $P(0)$. To reach this we let $P$ denote any polynomial satisfying (1) and $P(0) \\geqslant 0$; as we shall see, this implies $P(x)=x^{2}+1$ for all real $x$, which is actually more than what we want.\n\nFirst step: We prove that $P$ is even.\n\nBy (1) we have\n\n$$\n\\left|y^{2}-P(x)\\right| \\leqslant 2|x| \\Longleftrightarrow\\left|x^{2}-P(y)\\right| \\leqslant 2|y| \\Longleftrightarrow\\left|y^{2}-P(-x)\\right| \\leqslant 2|x|\n$$\n\nfor all real numbers $x$ and $y$. Considering just the equivalence of the first and third statement and taking into account that $y^{2}$ may vary through $\\mathbb{R}_{\\geqslant 0}$ we infer that\n\n$$\n[P(x)-2|x|, P(x)+2|x|] \\cap \\mathbb{R}_{\\geqslant 0}=[P(-x)-2|x|, P(-x)+2|x|] \\cap \\mathbb{R}_{\\geqslant 0}\n$$\n\nholds for all $x \\in \\mathbb{R}$. We claim that there are infinitely many real numbers $x$ such that $P(x)+2|x| \\geqslant 0$. This holds in fact for any real polynomial with $P(0) \\geqslant 0$; in order to see this, we may assume that the coefficient of $P$ appearing in front of $x$ is nonnegative. In this case the desired inequality holds for all sufficiently small positive real numbers.\n\nFor such numbers $x$ satisfying $P(x)+2|x| \\geqslant 0$ we have $P(x)+2|x|=P(-x)+2|x|$ by the previous displayed formula, and hence also $P(x)=P(-x)$. Consequently the polynomial $P(x)-P(-x)$ has infinitely many zeros, wherefore it has to vanish identically. Thus $P$ is indeed even.\n\n\n\nSecond step: We prove that $P(t)>0$ for all $t \\in \\mathbb{R}$.\n\nLet us assume for a moment that there exists a real number $t \\neq 0$ with $P(t)=0$. Then there is some open interval $I$ around $t$ such that $|P(y)| \\leqslant 2|y|$ holds for all $y \\in I$. Plugging $x=0$ into (1) we learn that $y^{2}=P(0)$ holds for all $y \\in I$, which is clearly absurd. We have thus shown $P(t) \\neq 0$ for all $t \\neq 0$.\n\nIn combination with $P(0) \\geqslant 0$ this informs us that our claim could only fail if $P(0)=0$. In this case there is by our first step a polynomial $Q(x)$ such that $P(x)=x^{2} Q(x)$. Applying (1) to $x=0$ and an arbitrary $y \\neq 0$ we get $|y Q(y)|>2$, which is surely false when $y$ is sufficiently small.\n\nThird step: We prove that $P$ is a quadratic polynomial.\n\nNotice that $P$ cannot be constant, for otherwise if $x=\\sqrt{P(0)}$ and $y$ is sufficiently large, the first part of (1) is false whilst the second part is true. So the degree $n$ of $P$ has to be at least 1 . By our first step $n$ has to be even as well, whence in particular $n \\geqslant 2$.\n\nNow assume that $n \\geqslant 4$. Plugging $y=\\sqrt{P(x)}$ into (1) we get $\\left|x^{2}-P(\\sqrt{P(x)})\\right| \\leqslant 2 \\sqrt{P(x)}$ and hence\n\n$$\nP(\\sqrt{P(x)}) \\leqslant x^{2}+2 \\sqrt{P(x)}\n$$\n\nfor all real $x$. Choose positive real numbers $x_{0}, a$, and $b$ such that if $x \\in\\left(x_{0}, \\infty\\right)$, then $a x^{n}<$ $P(x)<b x^{n}$; this is indeed possible, for if $d>0$ denotes the leading coefficient of $P$, then $\\lim _{x \\rightarrow \\infty} \\frac{P(x)}{x^{n}}=d$, whence for instance the numbers $a=\\frac{d}{2}$ and $b=2 d$ work provided that $x_{0}$ is chosen large enough.\n\nNow for all sufficiently large real numbers $x$ we have\n\n$$\na^{n / 2+1} x^{n^{2} / 2}<a P(x)^{n / 2}<P(\\sqrt{P(x)}) \\leqslant x^{2}+2 \\sqrt{P(x)}<x^{n / 2}+2 b^{1 / 2} x^{n / 2},\n$$\n\ni.e.\n\n$$\nx^{\\left(n^{2}-n\\right) / 2}<\\frac{1+2 b^{1 / 2}}{a^{n / 2+1}}\n$$\n\nwhich is surely absurd. Thus $P$ is indeed a quadratic polynomial.\n\nFourth step: We prove that $P(x)=x^{2}+1$.\n\nIn the light of our first three steps there are two real numbers $a>0$ and $b$ such that $P(x)=$ $a x^{2}+b$. Now if $x$ is large enough and $y=\\sqrt{a} x$, the left part of (1) holds and the right part reads $\\left|\\left(1-a^{2}\\right) x^{2}-b\\right| \\leqslant 2 \\sqrt{a} x$. In view of the fact that $a>0$ this is only possible if $a=1$. Finally, substituting $y=x+1$ with $x>0$ into (1) we get\n\n$$\n|2 x+1-b| \\leqslant 2 x \\Longleftrightarrow|2 x+1+b| \\leqslant 2 x+2,\n$$\n\ni.e.,\n\n$$\nb \\in[1,4 x+1] \\Longleftrightarrow b \\in[-4 x-3,1]\n$$\n\nfor all $x>0$. Choosing $x$ large enough, we can achieve that at least one of these two statements holds; then both hold, which is only possible if $b=1$, as desired."
] | $(-\infty, 0) \cup\{1\}$. |
1,974 | Combinatorics | null | $\boxed{\lfloor\sqrt{n-1}\rfloor}$ | [
"$\\lfloor\\sqrt{n-1}\\rfloor$"
] | false | null | Expression | null | Let $n \geqslant 2$ be an integer. Consider an $n \times n$ chessboard divided into $n^{2}$ unit squares. We call a configuration of $n$ rooks on this board happy if every row and every column contains exactly one rook. Find the greatest positive integer $k$ such that for every happy configuration of rooks, we can find a $k \times k$ square without a rook on any of its $k^{2}$ unit squares. | [
"Let $\\ell$ be a positive integer. We will show that (i) if $n>\\ell^{2}$ then each happy configuration contains an empty $\\ell \\times \\ell$ square, but (ii) if $n \\leqslant \\ell^{2}$ then there exists a happy configuration not containing such a square. These two statements together yield the answer.\n\n(i). Assume that $n>\\ell^{2}$. Consider any happy configuration. There exists a row $R$ containing a rook in its leftmost square. Take $\\ell$ consecutive rows with $R$ being one of them. Their union $U$ contains exactly $\\ell$ rooks. Now remove the $n-\\ell^{2} \\geqslant 1$ leftmost columns from $U$ (thus at least one rook is also removed). The remaining part is an $\\ell^{2} \\times \\ell$ rectangle, so it can be split into $\\ell$ squares of size $\\ell \\times \\ell$, and this part contains at most $\\ell-1$ rooks. Thus one of these squares is empty.\n\n(ii). Now we assume that $n \\leqslant \\ell^{2}$. Firstly, we will construct a happy configuration with no empty $\\ell \\times \\ell$ square for the case $n=\\ell^{2}$. After that we will modify it to work for smaller values of $n$.\n\nLet us enumerate the rows from bottom to top as well as the columns from left to right by the numbers $0,1, \\ldots, \\ell^{2}-1$. Every square will be denoted, as usual, by the pair $(r, c)$ of its row and column numbers. Now we put the rooks on all squares of the form $(i \\ell+j, j \\ell+i)$ with $i, j=0,1, \\ldots, \\ell-1$ (the picture below represents this arrangement for $\\ell=3$ ). Since each number from 0 to $\\ell^{2}-1$ has a unique representation of the form $i \\ell+j(0 \\leqslant i, j \\leqslant \\ell-1)$, each row and each column contains exactly one rook.\n\n<img_3607>\n\nNext, we show that each $\\ell \\times \\ell$ square $A$ on the board contains a rook. Consider such a square $A$, and consider $\\ell$ consecutive rows the union of which contains $A$. Let the lowest of these rows have number $p \\ell+q$ with $0 \\leqslant p, q \\leqslant \\ell-1$ (notice that $p \\ell+q \\leqslant \\ell^{2}-\\ell$ ). Then the rooks in this union are placed in the columns with numbers $q \\ell+p,(q+1) \\ell+p, \\ldots,(\\ell-1) \\ell+p$, $p+1, \\ell+(p+1), \\ldots,(q-1) \\ell+p+1$, or, putting these numbers in increasing order,\n\n$$\np+1, \\ell+(p+1), \\ldots,(q-1) \\ell+(p+1), q \\ell+p,(q+1) \\ell+p, \\ldots,(\\ell-1) \\ell+p\n$$\n\nOne readily checks that the first number in this list is at most $\\ell-1$ (if $p=\\ell-1$, then $q=0$, and the first listed number is $q \\ell+p=\\ell-1)$, the last one is at least $(\\ell-1) \\ell$, and the difference between any two consecutive numbers is at most $\\ell$. Thus, one of the $\\ell$ consecutive columns intersecting $A$ contains a number listed above, and the rook in this column is inside $A$, as required. The construction for $n=\\ell^{2}$ is established.\n\n\n\nIt remains to construct a happy configuration of rooks not containing an empty $\\ell \\times \\ell$ square for $n<\\ell^{2}$. In order to achieve this, take the construction for an $\\ell^{2} \\times \\ell^{2}$ square described above and remove the $\\ell^{2}-n$ bottom rows together with the $\\ell^{2}-n$ rightmost columns. We will have a rook arrangement with no empty $\\ell \\times \\ell$ square, but several rows and columns may happen to be empty. Clearly, the number of empty rows is equal to the number of empty columns, so one can find a bijection between them, and put a rook on any crossing of an empty row and an empty column corresponding to each other."
] | $\lfloor\sqrt{n-1}\rfloor$ |
1,977 | Combinatorics | null | $\boxed{100}$ | [
"100"
] | false | null | Numerical | null | We are given an infinite deck of cards, each with a real number on it. For every real number $x$, there is exactly one card in the deck that has $x$ written on it. Now two players draw disjoint sets $A$ and $B$ of 100 cards each from this deck. We would like to define a rule that declares one of them a winner. This rule should satisfy the following conditions:
1. The winner only depends on the relative order of the 200 cards: if the cards are laid down in increasing order face down and we are told which card belongs to which player, but not what numbers are written on them, we can still decide the winner.
2. If we write the elements of both sets in increasing order as $A=\left\{a_{1}, a_{2}, \ldots, a_{100}\right\}$ and $B=\left\{b_{1}, b_{2}, \ldots, b_{100}\right\}$, and $a_{i}>b_{i}$ for all $i$, then $A$ beats $B$.
3. If three players draw three disjoint sets $A, B, C$ from the deck, $A$ beats $B$ and $B$ beats $C$, then $A$ also beats $C$.
How many ways are there to define such a rule? Here, we consider two rules as different if there exist two sets $A$ and $B$ such that $A$ beats $B$ according to one rule, but $B$ beats $A$ according to the other. | [
"We prove a more general statement for sets of cardinality $n$ (the problem being the special case $n=100$, then the answer is $n$ ). In the following, we write $A>B$ or $B<A$ for \" $A$ beats $B$ \".\n\nPart I. Let us first define $n$ different rules that satisfy the conditions. To this end, fix an index $k \\in\\{1,2, \\ldots, n\\}$. We write both $A$ and $B$ in increasing order as $A=\\left\\{a_{1}, a_{2}, \\ldots, a_{n}\\right\\}$ and $B=\\left\\{b_{1}, b_{2}, \\ldots, b_{n}\\right\\}$ and say that $A$ beats $B$ if and only if $a_{k}>b_{k}$. This rule clearly satisfies all three conditions, and the rules corresponding to different $k$ are all different. Thus there are at least $n$ different rules.\n\nPart II. Now we have to prove that there is no other way to define such a rule. Suppose that our rule satisfies the conditions, and let $k \\in\\{1,2, \\ldots, n\\}$ be minimal with the property that\n\n$$\nA_{k}=\\{1,2, \\ldots, k, n+k+1, n+k+2, \\ldots, 2 n\\} \\prec B_{k}=\\{k+1, k+2, \\ldots, n+k\\} .\n$$\n\nClearly, such a $k$ exists, since this holds for $k=n$ by assumption. Now consider two disjoint sets $X=\\left\\{x_{1}, x_{2}, \\ldots, x_{n}\\right\\}$ and $Y=\\left\\{y_{1}, y_{2}, \\ldots, y_{n}\\right\\}$, both in increasing order (i.e., $x_{1}<x_{2}<\\cdots<x_{n}$ and $y_{1}<y_{2}<\\cdots<y_{n}$ ). We claim that $X<Y$ if (and only if - this follows automatically) $x_{k}<y_{k}$.\n\nTo prove this statement, pick arbitrary real numbers $u_{i}, v_{i}, w_{i} \\notin X \\cup Y$ such that\n\n$$\nu_{1}<u_{2}<\\cdots<u_{k-1}<\\min \\left(x_{1}, y_{1}\\right), \\quad \\max \\left(x_{n}, y_{n}\\right)<v_{k+1}<v_{k+2}<\\cdots<v_{n},\n$$\n\nand\n\n$$\nx_{k}<v_{1}<v_{2}<\\cdots<v_{k}<w_{1}<w_{2}<\\cdots<w_{n}<u_{k}<u_{k+1}<\\cdots<u_{n}<y_{k},\n$$\n\nand set\n\n$$\nU=\\left\\{u_{1}, u_{2}, \\ldots, u_{n}\\right\\}, V=\\left\\{v_{1}, v_{2}, \\ldots, v_{n}\\right\\}, W=\\left\\{w_{1}, w_{2}, \\ldots, w_{n}\\right\\}\n$$\n\nThen\n\n- $u_{i}<y_{i}$ and $x_{i}<v_{i}$ for all $i$, so $U<Y$ and $X<V$ by the second condition.\n\n\n\n- The elements of $U \\cup W$ are ordered in the same way as those of $A_{k-1} \\cup B_{k-1}$, and since $A_{k-1}>B_{k-1}$ by our choice of $k$, we also have $U>W$ (if $k=1$, this is trivial).\n- The elements of $V \\cup W$ are ordered in the same way as those of $A_{k} \\cup B_{k}$, and since $A_{k} \\prec B_{k}$ by our choice of $k$, we also have $V<W$.\n\nIt follows that\n\n$$\nX<V<W<U<Y\n$$\n\nso $X<Y$ by the third condition, which is what we wanted to prove.",
"Another possible approach to Part II of this problem is induction on $n$. For $n=1$, there is trivially only one rule in view of the second condition.\n\nIn the following, we assume that our claim (namely, that there are no possible rules other than those given in Part I) holds for $n-1$ in place of $n$. We start with the following observation: Claim. At least one of the two relations\n\n$$\n(\\{2\\} \\cup\\{2 i-1 \\mid 2 \\leqslant i \\leqslant n\\})<(\\{1\\} \\cup\\{2 i \\mid 2 \\leqslant i \\leqslant n\\})\n$$\n\nand\n\n$$\n(\\{2 i-1 \\mid 1 \\leqslant i \\leqslant n-1\\} \\cup\\{2 n\\})<(\\{2 i \\mid 1 \\leqslant i \\leqslant n-1\\} \\cup\\{2 n-1\\})\n$$\n\nholds.\n\nProof. Suppose that the first relation does not hold. Since our rule may only depend on the relative order, we must also have\n\n$$\n(\\{2\\} \\cup\\{3 i-2 \\mid 2 \\leqslant i \\leqslant n-1\\} \\cup\\{3 n-2\\})>(\\{1\\} \\cup\\{3 i-1 \\mid 2 \\leqslant i \\leqslant n-1\\} \\cup\\{3 n\\}) .\n$$\n\nLikewise, if the second relation does not hold, then we must also have\n\n$$\n(\\{1\\} \\cup\\{3 i-1 \\mid 2 \\leqslant i \\leqslant n-1\\} \\cup\\{3 n\\})>(\\{3\\} \\cup\\{3 i \\mid 2 \\leqslant i \\leqslant n-1\\} \\cup\\{3 n-1\\}) .\n$$\n\nNow condition 3 implies that\n\n$$\n(\\{2\\} \\cup\\{3 i-2 \\mid 2 \\leqslant i \\leqslant n-1\\} \\cup\\{3 n-2\\})>(\\{3\\} \\cup\\{3 i \\mid 2 \\leqslant i \\leqslant n-1\\} \\cup\\{3 n-1\\}),\n$$\n\nwhich contradicts the second condition.\n\nNow we distinguish two cases, depending on which of the two relations actually holds:\n\nFirst case: $(\\{2\\} \\cup\\{2 i-1 \\mid 2 \\leqslant i \\leqslant n\\})<(\\{1\\} \\cup\\{2 i \\mid 2 \\leqslant i \\leqslant n\\})$.\n\nLet $A=\\left\\{a_{1}, a_{2}, \\ldots, a_{n}\\right\\}$ and $B=\\left\\{b_{1}, b_{2}, \\ldots, b_{n}\\right\\}$ be two disjoint sets, both in increasing order. We claim that the winner can be decided only from the values of $a_{2}, \\ldots, a_{n}$ and $b_{2}, \\ldots, b_{n}$, while $a_{1}$ and $b_{1}$ are actually irrelevant. Suppose that this was not the case, and assume without loss of generality that $a_{2}<b_{2}$. Then the relative order of $a_{1}, a_{2}, \\ldots, a_{n}, b_{2}, \\ldots, b_{n}$ is fixed, and the position of $b_{1}$ has to decide the winner. Suppose that for some value $b_{1}=x, B$ wins, while for some other value $b_{1}=y, A$ wins.\n\nWrite $B_{x}=\\left\\{x, b_{2}, \\ldots, b_{n}\\right\\}$ and $B_{y}=\\left\\{y, b_{2}, \\ldots, b_{n}\\right\\}$, and let $\\varepsilon>0$ be smaller than half the distance between any two of the numbers in $B_{x} \\cup B_{y} \\cup A$. For any set $M$, let $M \\pm \\varepsilon$ be the set obtained by adding/subtracting $\\varepsilon$ to all elements of $M$. By our choice of $\\varepsilon$, the relative order of the elements of $\\left(B_{y}+\\varepsilon\\right) \\cup A$ is still the same as for $B_{y} \\cup A$, while the relative order of the elements of $\\left(B_{x}-\\varepsilon\\right) \\cup A$ is still the same as for $B_{x} \\cup A$. Thus $A<B_{x}-\\varepsilon$, but $A>B_{y}+\\varepsilon$. Moreover, if $y>x$, then $B_{x}-\\varepsilon \\prec B_{y}+\\varepsilon$ by condition 2, while otherwise the relative order of\n\n\n\nthe elements in $\\left(B_{x}-\\varepsilon\\right) \\cup\\left(B_{y}+\\varepsilon\\right)$ is the same as for the two sets $\\{2\\} \\cup\\{2 i-1 \\mid 2 \\leqslant i \\leqslant n\\}$ and $\\{1\\} \\cup\\{2 i \\mid 2 \\leqslant i \\leqslant n\\}$, so that $B_{x}-\\varepsilon<B_{y}+\\varepsilon$. In either case, we obtain\n\n$$\nA \\prec B_{x}-\\varepsilon \\prec B_{y}+\\varepsilon<A,\n$$\n\nwhich contradicts condition 3 .\n\nSo we know now that the winner does not depend on $a_{1}, b_{1}$. Therefore, we can define a new rule $<^{*}$ on sets of cardinality $n-1$ by saying that $A \\prec^{*} B$ if and only if $A \\cup\\{a\\} \\prec B \\cup\\{b\\}$ for some $a, b$ (or equivalently, all $a, b$ ) such that $a<\\min A, b<\\min B$ and $A \\cup\\{a\\}$ and $B \\cup\\{b\\}$ are disjoint. The rule $<^{*}$ satisfies all conditions again, so by the induction hypothesis, there exists an index $i$ such that $A \\prec^{*} B$ if and only if the $i^{\\text {th }}$ smallest element of $A$ is less than the $i^{\\text {th }}$ smallest element of $B$. This implies that $C<D$ if and only if the $(i+1)^{\\text {th }}$ smallest element of $C$ is less than the $(i+1)^{\\text {th }}$ smallest element of $D$, which completes our induction.\n\nSecond case: $(\\{2 i-1 \\mid 1 \\leqslant i \\leqslant n-1\\} \\cup\\{2 n\\})<(\\{2 i \\mid 1 \\leqslant i \\leqslant n-1\\} \\cup\\{2 n-1\\})$. Set $-A=\\{-a \\mid a \\in A\\}$ for any $A \\subseteq \\mathbb{R}$. For any two disjoint sets $A, B \\subseteq \\mathbb{R}$ of cardinality $n$, we write $A \\prec^{\\circ} B$ to mean $(-B) \\prec(-A)$. It is easy to see that $\\prec^{\\circ}$ defines a rule to determine a winner that satisfies the three conditions of our problem as well as the relation of the first case. So it follows in the same way as in the first case that for some $i, A \\prec^{\\circ} B$ if and only if the $i^{\\text {th }}$ smallest element of $A$ is less than the $i^{\\text {th }}$ smallest element of $B$, which is equivalent to the condition that the $i^{\\text {th }}$ largest element of $-A$ is greater than the $i^{\\text {th }}$ largest element of $-B$. This proves that the original rule $<$ also has the desired form."
] | 100 |
1,988 | Number Theory | null | $\boxed{(n-2) 2^{n}+1}$ | [
"$(n-2) 2^{n}+1$"
] | false | null | Expression | null | Let $n \geqslant 2$ be an integer, and let $A_{n}$ be the set
$$
A_{n}=\left\{2^{n}-2^{k} \mid k \in \mathbb{Z}, 0 \leqslant k<n\right\} .
$$
Determine the largest positive integer that cannot be written as the sum of one or more (not necessarily distinct) elements of $A_{n}$. | [
"Part I. First we show that every integer greater than $(n-2) 2^{n}+1$ can be represented as such a sum. This is achieved by induction on $n$.\n\nFor $n=2$, the set $A_{n}$ consists of the two elements 2 and 3 . Every positive integer $m$ except for 1 can be represented as the sum of elements of $A_{n}$ in this case: as $m=2+2+\\cdots+2$ if $m$ is even, and as $m=3+2+2+\\cdots+2$ if $m$ is odd.\n\nNow consider some $n>2$, and take an integer $m>(n-2) 2^{n}+1$. If $m$ is even, then consider\n\n$$\n\\frac{m}{2} \\geqslant \\frac{(n-2) 2^{n}+2}{2}=(n-2) 2^{n-1}+1>(n-3) 2^{n-1}+1\n$$\n\nBy the induction hypothesis, there is a representation of the form\n\n$$\n\\frac{m}{2}=\\left(2^{n-1}-2^{k_{1}}\\right)+\\left(2^{n-1}-2^{k_{2}}\\right)+\\cdots+\\left(2^{n-1}-2^{k_{r}}\\right)\n$$\n\nfor some $k_{i}$ with $0 \\leqslant k_{i}<n-1$. It follows that\n\n$$\nm=\\left(2^{n}-2^{k_{1}+1}\\right)+\\left(2^{n}-2^{k_{2}+1}\\right)+\\cdots+\\left(2^{n}-2^{k_{r}+1}\\right)\n$$\n\ngiving us the desired representation as a sum of elements of $A_{n}$. If $m$ is odd, we consider\n\n$$\n\\frac{m-\\left(2^{n}-1\\right)}{2}>\\frac{(n-2) 2^{n}+1-\\left(2^{n}-1\\right)}{2}=(n-3) 2^{n-1}+1\n$$\n\nBy the induction hypothesis, there is a representation of the form\n\n$$\n\\frac{m-\\left(2^{n}-1\\right)}{2}=\\left(2^{n-1}-2^{k_{1}}\\right)+\\left(2^{n-1}-2^{k_{2}}\\right)+\\cdots+\\left(2^{n-1}-2^{k_{r}}\\right)\n$$\n\nfor some $k_{i}$ with $0 \\leqslant k_{i}<n-1$. It follows that\n\n$$\nm=\\left(2^{n}-2^{k_{1}+1}\\right)+\\left(2^{n}-2^{k_{2}+1}\\right)+\\cdots+\\left(2^{n}-2^{k_{r}+1}\\right)+\\left(2^{n}-1\\right)\n$$\n\ngiving us the desired representation of $m$ once again.\n\nPart II. It remains to show that there is no representation for $(n-2) 2^{n}+1$. Let $N$ be the smallest positive integer that satisfies $N \\equiv 1\\left(\\bmod 2^{n}\\right)$, and which can be represented as a sum of elements of $A_{n}$. Consider a representation of $N$, i.e.,\n\n$$\nN=\\left(2^{n}-2^{k_{1}}\\right)+\\left(2^{n}-2^{k_{2}}\\right)+\\cdots+\\left(2^{n}-2^{k_{r}}\\right),\\tag{1}\n$$\n\nwhere $0 \\leqslant k_{1}, k_{2}, \\ldots, k_{r}<n$. Suppose first that two of the terms in the sum are the same, i.e., $k_{i}=k_{j}$ for some $i \\neq j$. If $k_{i}=k_{j}=n-1$, then we can simply remove these two terms to get a representation for\n\n$$\nN-2\\left(2^{n}-2^{n-1}\\right)=N-2^{n}\n$$\n\n\n\nas a sum of elements of $A_{n}$, which contradicts our choice of $N$. If $k_{i}=k_{j}=k<n-1$, replace the two terms by $2^{n}-2^{k+1}$, which is also an element of $A_{n}$, to get a representation for\n\n$$\nN-2\\left(2^{n}-2^{k}\\right)+2^{n}-2^{k+1}=N-2^{n} .\n$$\n\nThis is a contradiction once again. Therefore, all $k_{i}$ have to be distinct, which means that\n\n$$\n2^{k_{1}}+2^{k_{2}}+\\cdots+2^{k_{r}} \\leqslant 2^{0}+2^{1}+2^{2}+\\cdots+2^{n-1}=2^{n}-1\n$$\n\nOn the other hand, taking (1) modulo $2^{n}$, we find\n\n$$\n2^{k_{1}}+2^{k_{2}}+\\cdots+2^{k_{r}} \\equiv-N \\equiv-1 \\quad\\left(\\bmod 2^{n}\\right)\n$$\n\nThus we must have $2^{k_{1}}+2^{k_{2}}+\\cdots+2^{k_{r}}=2^{n}-1$, which is only possible if each element of $\\{0,1, \\ldots, n-1\\}$ occurs as one of the $k_{i}$. This gives us\n\n$$\nN=n 2^{n}-\\left(2^{0}+2^{1}+\\cdots+2^{n-1}\\right)=(n-1) 2^{n}+1 .\n$$\n\nIn particular, this means that $(n-2) 2^{n}+1$ cannot be represented as a sum of elements of $A_{n}$.",
"The fact that $m=(n-2) 2^{n}+1$ cannot be represented as a sum of elements of $A_{n}$ can also be shown in other ways. We prove the following statement by induction on $n$ :\n\nClaim. If $a, b$ are integers with $a \\geqslant 0, b \\geqslant 1$, and $a+b<n$, then $a 2^{n}+b$ cannot be written as a sum of elements of $A_{n}$.\n\nProof. The claim is clearly true for $n=2$ (since $a=0, b=1$ is the only possibility). For $n>2$, assume that there exist integers $a, b$ with $a \\geqslant 0, b \\geqslant 1$ and $a+b<n$ as well as elements $m_{1}, m_{2}, \\ldots, m_{r}$ of $A_{n}$ such that\n\n$$\na 2^{n}+b=m_{1}+m_{2}+\\cdots+m_{r} .\n$$\n\nWe can suppose, without loss of generality, that $m_{1} \\geqslant m_{2} \\geqslant \\cdots \\geqslant m_{r}$. Let $\\ell$ be the largest index for which $m_{\\ell}=2^{n}-1\\left(\\ell=0\\right.$ if $\\left.m_{1} \\neq 2^{n}-1\\right)$. Clearly, $\\ell$ and $b$ must have the same parity. Now\n\n$$\n(a-\\ell) 2^{n}+(b+\\ell)=m_{\\ell+1}+m_{\\ell+2}+\\cdots+m_{r}\n$$\n\nand thus\n\n$$\n(a-\\ell) 2^{n-1}+\\frac{b+\\ell}{2}=\\frac{m_{\\ell+1}}{2}+\\frac{m_{\\ell+2}}{2}+\\cdots+\\frac{m_{r}}{2}\n$$\n\nNote that $m_{\\ell+1} / 2, m_{\\ell+2} / 2, \\ldots, m_{r} / 2$ are elements of $A_{n-1}$. Moreover, $a-\\ell$ and $(b+\\ell) / 2$ are integers, and $(b+\\ell) / 2 \\geqslant 1$. If $a-\\ell$ was negative, then we would have\n\n$$\na 2^{n}+b \\geqslant \\ell\\left(2^{n}-1\\right) \\geqslant(a+1)\\left(2^{n}-1\\right)=a 2^{n}+2^{n}-a-1\n$$\n\nthus $n \\geqslant a+b+1 \\geqslant 2^{n}$, which is impossible. So $a-\\ell \\geqslant 0$. By the induction hypothesis, we must have $a-\\ell+\\frac{b+\\ell}{2} \\geqslant n-1$, which gives us a contradiction, since\n\n$$\na-\\ell+\\frac{b+\\ell}{2} \\leqslant a-\\ell+b+\\ell-1=a+b-1<n-1\n$$\n\nConsidering the special case $a=n-2, b=1$ now completes the proof.",
"Denote by $B_{n}$ the set of all positive integers that can be written as a sum of elements of $A_{n}$. In this solution, we explicitly describe all the numbers in $B_{n}$ by an argument similar to the first solution.\n\nFor a positive integer $n$, we denote by $\\sigma_{2}(n)$ the sum of its digits in the binary representation. Notice that every positive integer $m$ has a unique representation of the form $m=s 2^{n}-t$ with some positive integer $s$ and $0 \\leqslant t \\leqslant 2^{n}-1$.\n\nLemma. For any two integers $s \\geqslant 1$ and $0 \\leqslant t \\leqslant 2^{n}-1$, the number $m=s 2^{n}-t$ belongs to $B_{n}$ if and only if $s \\geqslant \\sigma_{2}(t)$.\n\nProof. For $t=0$, the statement of the Lemma is obvious, since $m=2 s \\cdot\\left(2^{n}-2^{n-1}\\right)$.\n\nNow suppose that $t \\geqslant 1$, and let\n\n$$\nt=2^{k_{1}}+\\cdots+2^{k_{\\sigma}} \\quad\\left(0 \\leqslant k_{1}<\\cdots<k_{\\sigma} \\leqslant n-1, \\quad \\sigma=\\sigma_{2}(t)\\right)\n$$\n\nbe its binary expansion. If $s \\geqslant \\sigma$, then $m \\in B_{n}$ since\n\n$$\nm=(s-\\sigma) 2^{n}+\\left(\\sigma 2^{n}-t\\right)=2(s-\\sigma) \\cdot\\left(2^{n}-2^{n-1}\\right)+\\sum_{i=1}^{\\sigma}\\left(2^{n}-2^{k_{i}}\\right)\n$$\n\nAssume now that there exist integers $s$ and $t$ with $1 \\leqslant s<\\sigma_{2}(t)$ and $0 \\leqslant t \\leqslant 2^{n}-1$ such that the number $m=s 2^{n}-t$ belongs to $B_{n}$. Among all such instances, choose the one for which $m$ is smallest, and let\n\n$$\nm=\\sum_{i=1}^{d}\\left(2^{n}-2^{\\ell_{i}}\\right) \\quad\\left(0 \\leqslant \\ell_{i} \\leqslant n-1\\right)\n$$\n\nbe the corresponding representation. If all the $\\ell_{i}^{\\prime}$ 's are distinct, then $\\sum_{i=1}^{d} 2^{\\ell_{i}} \\leqslant \\sum_{j=0}^{n-1} 2^{j}=2^{n}-1$, so one has $s=d$ and $t=\\sum_{i=1}^{d} 2^{\\ell_{i}}$, whence $s=d=\\sigma_{2}(t)$; this is impossible. Therefore, two of the $\\ell_{i}$ 's must be equal, say $\\ell_{d-1}=\\ell_{d}$. Then $m \\geqslant 2\\left(2^{n}-2^{\\ell_{d}}\\right) \\geqslant 2^{n}$, so $s \\geqslant 2$.\n\nNow we claim that the number $m^{\\prime}=m-2^{n}=(s-1) 2^{n}-t$ also belongs to $B_{n}$, which contradicts the minimality assumption. Indeed, one has\n\n$$\n\\left(2^{n}-2^{\\ell_{d-1}}\\right)+\\left(2^{n}-2^{\\ell_{d}}\\right)=2\\left(2^{n}-2^{\\ell_{d}}\\right)=2^{n}+\\left(2^{n}-2^{\\ell_{d}+1}\\right),\n$$\n\nso\n\n$$\nm^{\\prime}=\\sum_{i=1}^{d-2}\\left(2^{n}-2^{\\ell_{i}}\\right)+\\left(2^{n}-2^{\\ell_{d}+1}\\right)\n$$\n\nis the desired representation of $m^{\\prime}$ (if $\\ell_{d}=n-1$, then the last summand is simply omitted). This contradiction finishes the proof.\n\nBy our lemma, the largest number $M$ which does not belong to $B_{n}$ must have the form\n\n$$\nm_{t}=\\left(\\sigma_{2}(t)-1\\right) 2^{n}-t\n$$\n\nfor some $t$ with $1 \\leqslant t \\leqslant 2^{n}-1$, so $M$ is just the largest of these numbers. For $t_{0}=2^{n}-1$ we have $m_{t_{0}}=(n-1) 2^{n}-\\left(2^{n}-1\\right)=(n-2) 2^{n}+1$; for every other value of $t$ one has $\\sigma_{2}(t) \\leqslant n-1$, thus $m_{t} \\leqslant(\\sigma(t)-1) 2^{n} \\leqslant(n-2) 2^{n}<m_{t_{0}}$. This means that $M=m_{t_{0}}=(n-2) 2^{n}+1$."
] | $(n-2) 2^{n}+1$ |
1,997 | Algebra | null | $\boxed{n=k+4}$ | [
"$n=k+4$"
] | false | null | Expression | null | Let $k \geqslant 2$ be an integer. Find the smallest integer $n \geqslant k+1$ with the property that there exists a set of $n$ distinct real numbers such that each of its elements can be written as a sum of $k$ other distinct elements of the set. | [
"First we show that $n \\geqslant k+4$. Suppose that there exists such a set with $n$ numbers and denote them by $a_{1}<a_{2}<\\cdots<a_{n}$.\n\nNote that in order to express $a_{1}$ as a sum of $k$ distinct elements of the set, we must have $a_{1} \\geqslant a_{2}+\\cdots+a_{k+1}$ and, similarly for $a_{n}$, we must have $a_{n-k}+\\cdots+a_{n-1} \\geqslant a_{n}$. We also know that $n \\geqslant k+1$.\n\nIf $n=k+1$ then we have $a_{1} \\geqslant a_{2}+\\cdots+a_{k+1}>a_{1}+\\cdots+a_{k} \\geqslant a_{k+1}$, which gives a contradiction.\n\nIf $n=k+2$ then we have $a_{1} \\geqslant a_{2}+\\cdots+a_{k+1} \\geqslant a_{k+2}$, that again gives a contradiction.\n\nIf $n=k+3$ then we have $a_{1} \\geqslant a_{2}+\\cdots+a_{k+1}$ and $a_{3}+\\cdots+a_{k+2} \\geqslant a_{k+3}$. Adding the two inequalities we get $a_{1}+a_{k+2} \\geqslant a_{2}+a_{k+3}$, again a contradiction.\n\nIt remains to give an example of a set with $k+4$ elements satisfying the condition of the problem. We start with the case when $k=2 l$ and $l \\geqslant 1$. In that case, denote by $A_{i}=\\{-i, i\\}$ and take the set $A_{1} \\cup \\cdots \\cup A_{l+2}$, which has exactly $k+4=2 l+4$ elements. We are left to show that this set satisfies the required condition.\n\nNote that if a number $i$ can be expressed in the desired way, then so can $-i$ by negating the expression. Therefore, we consider only $1 \\leqslant i \\leqslant l+2$.\n\nIf $i<l+2$, we sum the numbers from some $l-1$ sets $A_{j}$ with $j \\neq 1, i+1$, and the numbers $i+1$ and -1 .\n\nFor $i=l+2$, we sum the numbers from some $l-1$ sets $A_{j}$ with $j \\neq 1, l+1$, and the numbers $l+1$ and 1 .\n\nIt remains to a give a construction for odd $k=2 l+1$ with $l \\geqslant 1$ (since $k \\geqslant 2$ ). To that end, we modify the construction for $k=2 l$ by adding 0 to the previous set.\n\nThis is a valid set as 0 can be added to each constructed expression, and 0 can be expressed as follows: take the numbers $1,2,-3$ and all the numbers from the remaining $l-1$ sets $A_{4}, A_{5}, \\cdots, A_{l+2}$."
] | $n=k+4$ |
1,998 | Algebra | null | $\boxed{f(x)=\frac{1}{x}}$ | [
"$f(x)=\\frac{1}{x}$"
] | false | null | Expression | null | Let $\mathbb{R}_{>0}$ be the set of positive real numbers. Find all functions $f: \mathbb{R}_{>0} \rightarrow \mathbb{R}_{>0}$ such that, for every $x \in \mathbb{R}_{>0}$, there exists a unique $y \in \mathbb{R}_{>0}$ satisfying
$$
x f(y)+y f(x) \leqslant 2 .
$$ | [
"First we prove that the function $f(x)=1 / x$ satisfies the condition of the problem statement. The AM-GM inequality gives\n\n$$\n\\frac{x}{y}+\\frac{y}{x} \\geqslant 2\n$$\n\nfor every $x, y>0$, with equality if and only if $x=y$. This means that, for every $x>0$, there exists a unique $y>0$ such that\n\n$$\n\\frac{x}{y}+\\frac{y}{x} \\leqslant 2\n$$\n\nnamely $y=x$.\n\nLet now $f: \\mathbb{R}_{>0} \\rightarrow \\mathbb{R}_{>0}$ be a function that satisfies the condition of the problem statement. We say that a pair of positive real numbers $(x, y)$ is $\\operatorname{good}$ if $x f(y)+y f(x) \\leqslant 2$. Observe that if $(x, y)$ is good, then so is $(y, x)$.\n\nLemma 1.0. If $(x, y)$ is good, then $x=y$.\n\nProof. Assume that there exist positive real numbers $x \\neq y$ such that $(x, y)$ is good. The uniqueness assumption says that $y$ is the unique positive real number such that $(x, y)$ is good. In particular, $(x, x)$ is not a good pair. This means that\n\n$$\nx f(x)+x f(x)>2\n$$\n\nand thus $x f(x)>1$. Similarly, $(y, x)$ is a good pair, so $(y, y)$ is not a good pair, which implies $y f(y)>1$. We apply the AM-GM inequality to obtain\n\n$$\nx f(y)+y f(x) \\geqslant 2 \\sqrt{x f(y) \\cdot y f(x)}=2 \\sqrt{x f(x) \\cdot y f(y)}>2\n$$\n\nThis is a contradiction, since $(x, y)$ is a good pair.\n\nBy assumption, for any $x>0$, there always exists a good pair containing $x$, however Lemma 1 implies that the only good pair that can contain $x$ is $(x, x)$, so\n\n$$\nx f(x) \\leqslant 1 \\quad \\Longleftrightarrow \\quad f(x) \\leqslant \\frac{1}{x},\n$$\n\nfor every $x>0$.\n\nIn particular, with $x=1 / f(t)$ for $t>0$, we obtain\n\n$$\n\\frac{1}{f(t)} \\cdot f\\left(\\frac{1}{f(t)}\\right) \\leqslant 1\n$$\n\nHence\n\n$$\nt \\cdot f\\left(\\frac{1}{f(t)}\\right) \\leqslant t f(t) \\leqslant 1\n$$\n\nWe claim that $(t, 1 / f(t))$ is a good pair for every $t>0$. Indeed,\n\n$$\nt \\cdot f\\left(\\frac{1}{f(t)}\\right)+\\frac{1}{f(t)} f(t)=t \\cdot f\\left(\\frac{1}{f(t)}\\right)+1 \\leqslant 2\n$$\n\nLemma 1 implies that $t=1 / f(t) \\Longleftrightarrow f(t)=1 / t$ for every $t>0$.\n\n\n1. We give an alternative way to prove that $f(x)=1 / x$ assuming $f(x) \\leqslant 1 / x$ for every $x>0$.\n\nIndeed, if $f(x)<1 / x$ then for every $a>0$ with $f(x)<1 / a<1 / x$ (and there are at least two of them), we have\n\n$$\na f(x)+x f(a)<1+\\frac{x}{a}<2 .\n$$\n\nHence $(x, a)$ is a good pair for every such $a$, a contradiction. We conclude that $f(x)=1 / x$.\n\n\n2. We can also conclude from Lemma 1 and $f(x) \\leqslant 1 / x$ as follows.\n\nLemma 2. The function $f$ is decreasing.\n\nProof. Let $y>x>0$. Lemma 1 says that $(x, y)$ is not a good pair, but $(y, y)$ is. Hence\n\n$$\nx f(y)+y f(x)>2 \\geqslant 2 y f(y)>y f(y)+x f(y),\n$$\n\nwhere we used $y>x$ (and $f(y)>0$ ) in the last inequality. This implies that $f(x)>f(y)$, showing that $f$ is decreasing.\n\nWe now prove that $f(x)=1 / x$ for all $x$. Fix a value of $x$ and note that for $y>x$ we must have $x f(x)+y f(x)>x f(y)+y f(x)>2$ (using that $f$ is decreasing for the first step), hence $f(x)>\\frac{2}{x+y}$. The last inequality is true for every $y>x>0$. If we fix $x$ and look for the supremum of the expression $\\frac{2}{x+y}$ over all $y>x$, we get\n\n$$\nf(x) \\geqslant \\frac{2}{x+x}=\\frac{1}{x}\n$$\n\nSince we already know that $f(x) \\leqslant 1 / x$, we conclude that $f(x)=1 / x$.",
"As in the first solution, we note that $f(x)=1 / x$ is a solution, and we set out to prove that it is the only one. We write $g(x)$ for the unique positive real number such that $(x, g(x))$ is a good pair. In this solution, we prove Lemma 2 without assuming Lemma 1.\n\nLemma 2. The function $f$ is decreasing.\n\nProof. Consider $x<y$. It holds that $y f(g(y))+g(y) f(y) \\leqslant 2$. Moreover, because $y$ is the only positive real number such that $(g(y), y)$ is a good pair and $x \\neq y$, we have $x f(g(y))+g(y) f(x)>$ 2. Combining these two inequalities yields\n\n$$\nx f(g(y))+g(y) f(x)>2 \\geqslant y f(g(y))+g(y) f(y)\n$$\n\nor $f(g(y))(x-y)>g(y)(f(y)-f(x))$. Because $g(y)$ and $f(g(y))$ are both positive while $x-y$ is negative, it follows that $f(y)<f(x)$, showing that $f$ is decreasing.\n\nWe now prove Lemma 1 using Lemma 2. Suppose that $x \\neq y$ but $x f(y)+y f(x) \\leqslant 2$. As in the first solution, we get $x f(x)+x f(x)>2$ and $y f(y)+y f(y)>2$, which implies $x f(x)+y f(y)>2$. Now\n\n$$\nx f(x)+y f(y)>2 \\geqslant x f(y)+y f(x)\n$$\n\nimplies $(x-y)(f(x)-f(y))>0$, which contradicts the fact that $f$ is decreasing. So $y=x$ is the unique $y$ such that $(x, y)$ is a good pair, and in particular we have $f(x) \\leqslant 1 / x$.\n\nWe can now conclude the proof",
"As in the other solutions we verify that the function $f(x)=1 / x$ is a solution. We first want to prove the following lemma:\n\nLemma 3. For all $x \\in \\mathbb{R}_{>0}$ we actually have $x f(g(x))+g(x) f(x)=2$ (that is: the inequality is actually an equality).\n\n\n\nProof. We proceed by contradiction: Assume there exists some number $x>0$ such that for $y=g(x)$ we have $x f(y)+y f(x)<2$. Then for any $0<\\epsilon<\\frac{2-x f(y)-y f(x)}{2 f(x)}$ we have, by uniqueness of $y$, that $x f(y+\\epsilon)+(y+\\epsilon) f(x)>2$. Therefore\n\n$$\n\\begin{aligned}\nf(y+\\epsilon) & >\\frac{2-(y+\\epsilon) f(x)}{x}=\\frac{2-y f(x)-\\epsilon f(x)}{x} \\\\\n& >\\frac{2-y f(x)-\\frac{2-x f(y)-y f(x)}{2}}{x} \\\\\n& =\\frac{2-x f(y)-y f(x)}{2 x}+f(y)>f(y) .\n\\end{aligned}\n\\tag{1}\n$$\n\nFurthermore, for every such $\\epsilon$ we have $g(y+\\epsilon) f(y+\\epsilon)+(y+\\epsilon) f(g(y+\\epsilon)) \\leqslant 2$ and $g(y+\\epsilon) f(y)+y f(g(y+\\epsilon))>2($ since $y \\neq y+\\epsilon=g(g(y+\\epsilon)))$. This gives us the two inequalities\n\n$$\nf(g(y+\\epsilon)) \\leqslant \\frac{2-g(y+\\epsilon) f(y+\\epsilon)}{y+\\epsilon} \\quad \\text { and } \\quad f(g(y+\\epsilon))>\\frac{2-g(y+\\epsilon) f(y)}{y} \\text {. }\n$$\n\nCombining these two inequalities and rearranging the terms leads to the inequality\n\n$$\n2 \\epsilon<g(y+\\epsilon)[(y+\\epsilon) f(y)-y f(y+\\epsilon)] \\text {. }\n$$\n\nMoreover combining with the inequality (1) we obtain\n\n$$\n2 \\epsilon<g(y+\\epsilon)\\left[(y+\\epsilon) f(y)-y\\left(\\frac{2-x f(y)-y f(x)}{2 x}+f(y)\\right)\\right]=g(y+\\epsilon)\\left[\\epsilon f(y)-y \\frac{2-x f(y)-y f(x)}{2 x}\\right]\n$$\n\nWe now reach the desired contradiction, since for $\\epsilon$ sufficiently small we have that the left hand side is positive while the right hand side is negative.\n\nWith this lemma it then follows that for all $x, y \\in \\mathbb{R}_{>0}$ we have\n\n$$\nx f(y)+y f(x) \\geqslant 2\n$$\n\nsince for $y=g(x)$ we have equality and by uniqueness for $y \\neq g(x)$ the inequality is strict.\n\nIn particular for every $x \\in \\mathbb{R}_{>0}$ and for $y=x$ we have $2 x f(x) \\geqslant 2$, or equivalently $f(x) \\geqslant 1 / x$ for all $x \\in \\mathbb{R}_{>0}$. With this inequality we obtain for all $x \\in \\mathbb{R}_{>0}$\n\n$$\n2 \\geqslant x f(g(x))+g(x) f(x) \\geqslant \\frac{x}{g(x)}+\\frac{g(x)}{x} \\geqslant 2\n$$\n\nwhere the first inequality comes from the problem statement. Consequently each of these inequalities must actually be an equality, and in particular we obtain $f(x)=1 / x$ for all $x \\in \\mathbb{R}_{>0}$.",
"Again, let us prove that $f(x)=1 / x$ is the only solution. Let again $g(x)$ be the unique positive real number such that $(x, g(x))$ is a good pair.\n\nLemma 4. The function $f$ is strictly convex.\n\nProof. Consider the function $q_{s}(x)=f(x)+s x$ for some real number $s$. If $f$ is not strictly convex, then there exist $u<v$ and $t \\in(0,1)$ such that\n\n$$\nf(t u+(1-t) v) \\geqslant t f(u)+(1-t) f(v) .\n$$\n\nHence\n\n$$\n\\begin{aligned}\nq_{s}(t u+(1-t) v) & \\geqslant t f(u)+(1-t) f(v)+s(t u+(1-t) v) \\\\\n& =t q_{s}(u)+(1-t) q_{s}(v)\n\\end{aligned}\n$$\n\n\n\nLet $w=t u+(1-t) v$ and consider the case $s=f(g(w)) / g(w)$. For that particular choice of $s$, the function $q_{s}(x)$ has a unique minimum at $x=w$. However, since $q_{s}(w) \\geqslant t q_{s}(u)+(1-t) q_{s}(v)$, it must hold $q_{s}(u) \\leqslant q_{s}(w)$ or $q_{s}(v) \\leqslant q_{s}(w)$, a contradiction.\n\nLemma 5. The function $f$ is continuous.\n\nProof. Since $f$ is strictly convex and defined on an open interval, it is also continuous.\n\nwe can now prove that $f(x) \\leqslant 1 / x$. If $f(x)<1 / x$, then we consider the function $h(y)=x f(y)+y f(x)$ which is continuous. Since $h(x)<2$, there exist at least two distinct $z \\neq x$ such that $h(z)<2$ giving that $(x, z)$ is good pair for both values of $z$, a contradiction. We conclude that $f(x)=1 / x$ as desired."
] | $f(x)=\frac{1}{x}$ |
2,000 | Algebra | null | $\boxed{2,3,4}$ | [
"2,3,4"
] | true | null | Numerical | null | Find all positive integers $n \geqslant 2$ for which there exist $n$ real numbers $a_{1}<\cdots<a_{n}$ and a real number $r>0$ such that the $\frac{1}{2} n(n-1)$ differences $a_{j}-a_{i}$ for $1 \leqslant i<j \leqslant n$ are equal, in some order, to the numbers $r^{1}, r^{2}, \ldots, r^{\frac{1}{2} n(n-1)}$. | [
"We first show a solution for each $n \\in\\{2,3,4\\}$. We will later show the impossibility of finding such a solution for $n \\geqslant 5$.\n\nFor $n=2$, take for example $\\left(a_{1}, a_{2}\\right)=(1,3)$ and $r=2$.\n\nFor $n=3$, take the root $r>1$ of $x^{2}-x-1=0$ (the golden ratio) and set $\\left(a_{1}, a_{2}, a_{3}\\right)=$ $\\left(0, r, r+r^{2}\\right)$. Then\n\n$$\n\\left(a_{2}-a_{1}, a_{3}-a_{2}, a_{3}-a_{1}\\right)=\\left(r, r^{2}, r+r^{2}=r^{3}\\right)\n$$\n\nFor $n=4$, take the root $r \\in(1,2)$ of $x^{3}-x-1=0$ (such a root exists because $1^{3}-1-1<0$ and $\\left.2^{3}-2-1>0\\right)$ and set $\\left(a_{1}, a_{2}, a_{3}, a_{4}\\right)=\\left(0, r, r+r^{2}, r+r^{2}+r^{3}\\right)$. Then\n\n$$\n\\left(a_{2}-a_{1}, a_{3}-a_{2}, a_{4}-a_{3}, a_{3}-a_{1}, a_{4}-a_{2}, a_{4}-a_{1}\\right)=\\left(r, r^{2}, r^{3}, r^{4}, r^{5}, r^{6}\\right)\n$$\n\nFor $n \\geqslant 5$, we will proceed by contradiction. Suppose there exist numbers $a_{1}<\\cdots<a_{n}$ and $r>1$ satisfying the conditions of the problem. We start with a lemma:\n\nLemma. We have $r^{n-1}>2$.\n\nProof. There are only $n-1$ differences $a_{j}-a_{i}$ with $j=i+1$, so there exists an exponent $e \\leqslant n$ and a difference $a_{j}-a_{i}$ with $j \\geqslant i+2$ such that $a_{j}-a_{i}=r^{e}$. This implies\n\n$$\nr^{n} \\geqslant r^{e}=a_{j}-a_{i}=\\left(a_{j}-a_{j-1}\\right)+\\left(a_{j-1}-a_{i}\\right)>r+r=2 r\n$$\n\nthus $r^{n-1}>2$ as desired.\n\nTo illustrate the general approach, we first briefly sketch the idea behind the argument in the special case $n=5$. In this case, we clearly have $a_{5}-a_{1}=r^{10}$. Note that there are 3 ways to rewrite $a_{5}-a_{1}$ as a sum of two differences, namely\n\n$$\n\\left(a_{5}-a_{4}\\right)+\\left(a_{4}-a_{1}\\right),\\left(a_{5}-a_{3}\\right)+\\left(a_{3}-a_{1}\\right),\\left(a_{5}-a_{2}\\right)+\\left(a_{2}-a_{1}\\right) .\n$$\n\nUsing the lemma above and convexity of the function $f(n)=r^{n}$, we argue that those three ways must be $r^{10}=r^{9}+r^{1}=r^{8}+r^{4}=r^{7}+r^{6}$. That is, the \"large\" exponents keep dropping by 1 , while the \"small\" exponents keep increasing by $n-2, n-3, \\ldots, 2$. Comparing any two such equations, we then get a contradiction unless $n \\leqslant 4$.\n\nNow we go back to the full proof for any $n \\geqslant 5$. Denote $b=\\frac{1}{2} n(n-1)$. Clearly, we have $a_{n}-a_{1}=r^{b}$. Consider the $n-2$ equations of the form:\n\n$$\na_{n}-a_{1}=\\left(a_{n}-a_{i}\\right)+\\left(a_{i}-a_{1}\\right) \\text { for } i \\in\\{2, \\ldots, n-1\\}\n$$\n\nIn each equation, one of the two terms on the right-hand side must be at least $\\frac{1}{2}\\left(a_{n}-a_{1}\\right)$. But from the lemma we have $r^{b-(n-1)}=r^{b} / r^{n-1}<\\frac{1}{2}\\left(a_{n}-a_{1}\\right)$, so there are at most $n-2$ sufficiently large elements in $\\left\\{r^{k} \\mid 1 \\leqslant k<b\\right\\}$, namely $r^{b-1}, \\ldots, r^{b-(n-2)}$ (note that $r^{b}$ is already used for $a_{n}-a_{1}$ ). Thus, the \"large\" terms must be, in some order, precisely equal to elements in\n\n$$\nL=\\left\\{r^{b-1}, \\ldots, r^{b-(n-2)}\\right\\}\n$$\n\nNext we claim that the \"small\" terms in the $n-2$ equations must be equal to the elements in\n\n$$\nS=\\left\\{r^{b-(n-2)-\\frac{1}{2} i(i+1)} \\mid 1 \\leqslant i \\leqslant n-2\\right\\}\n$$\n\n\n\nin the corresponding order (the largest \"large\" term with the smallest \"small\" term, etc.). Indeed, suppose that\n\n$$\nr^{b}=a_{n}-a_{1}=r^{b-i}+r^{\\alpha_{i}} \\text { for } i \\in\\{1, \\ldots, n-2\\},\n$$\n\nwhere $1 \\leqslant \\alpha_{1}<\\cdots<\\alpha_{n-2} \\leqslant b-(n-1)$. Since $r>1$ and $f(r)=r^{n}$ is convex, we have\n\n$$\nr^{b-1}-r^{b-2}>r^{b-2}-r^{b-3}>\\ldots>r^{b-(n-3)}-r^{b-(n-2)},\n$$\n\nimplying\n\n$$\nr^{\\alpha_{2}}-r^{\\alpha_{1}}>r^{\\alpha_{3}}-r^{\\alpha_{2}}>\\ldots>r^{\\alpha_{n-2}}-r^{\\alpha_{n-3}} .\n$$\n\nConvexity of $f(r)=r^{n}$ further implies\n\n$$\n\\alpha_{2}-\\alpha_{1}>\\alpha_{3}-\\alpha_{2}>\\ldots>\\alpha_{n-2}-\\alpha_{n-3}\n$$\n\nNote that $\\alpha_{n-2}-\\alpha_{n-3} \\geqslant 2$ : Otherwise we would have $\\alpha_{n-2}-\\alpha_{n-3}=1$ and thus\n\n$$\nr^{\\alpha_{n-3}} \\cdot(r-1)=r^{\\alpha_{n-2}}-r^{\\alpha_{n-3}}=r^{b-(n-3)}-r^{b-(n-2)}=r^{b-(n-2)} \\cdot(r-1)\n$$\n\nimplying that $\\alpha_{n-3}=b-(n-2)$, a contradiction. Therefore, we have\n\n$$\n\\begin{aligned}\n\\alpha_{n-2}-\\alpha_{1} & =\\left(\\alpha_{n-2}-\\alpha_{n-3}\\right)+\\cdots+\\left(\\alpha_{2}-\\alpha_{1}\\right) \\\\\n& \\geqslant 2+3+\\cdots+(n-2) \\\\\n& =\\frac{1}{2}(n-2)(n-1)-1=\\frac{1}{2} n(n-3) .\n\\end{aligned}\n$$\n\nOn the other hand, from $\\alpha_{n-2} \\leqslant b-(n-1)$ and $\\alpha_{1} \\geqslant 1$ we get\n\n$$\n\\alpha_{n-2}-\\alpha_{1} \\leqslant b-n=\\frac{1}{2} n(n-1)-n=\\frac{1}{2} n(n-3),\n$$\n\nimplying that equalities must occur everywhere and the claim about the small terms follows.\n\nNow, assuming $n-2 \\geqslant 2$, we have the two different equations:\n\n$$\nr^{b}=r^{b-(n-2)}+r^{b-(n-2)-1} \\text { and } r^{b}=r^{b-(n-3)}+r^{b-(n-2)-3}\n$$\n\nwhich can be rewritten as\n\n$$\nr^{n-1}=r+1 \\quad \\text { and } \\quad r^{n+1}=r^{4}+1\n\\tag{1}\n$$\n\nSimple algebra now gives\n\n$$\nr^{4}+1=r^{n+1}=r^{n-1} \\cdot r^{2}=r^{3}+r^{2} \\Longrightarrow(r-1)\\left(r^{3}-r-1\\right)=0 .\n$$\n\nSince $r \\neq 1$, using Equation (1) we conclude $r^{3}=r+1=r^{n-1}$, thus $n=4$, which gives a contradiction."
] | 2,3,4 |
2,004 | Combinatorics | null | $\boxed{506}$ | [
"506"
] | false | null | Numerical | null | $A \pm 1 \text{-}sequence$ is a sequence of 2022 numbers $a_{1}, \ldots, a_{2022}$, each equal to either +1 or -1 . Determine the largest $C$ so that, for any $\pm 1 -sequence$, there exists an integer $k$ and indices $1 \leqslant t_{1}<\ldots<t_{k} \leqslant 2022$ so that $t_{i+1}-t_{i} \leqslant 2$ for all $i$, and
$$
\left|\sum_{i=1}^{k} a_{t_{i}}\right| \geqslant C
$$ | [
"First, we prove that this can always be achieved. Without loss of generality, suppose at least $\\frac{2022}{2}=1011$ terms of the \\pm 1 -sequence are +1 . Define a subsequence as follows: starting at $t=0$, if $a_{t}=+1$ we always include $a_{t}$ in the subsequence. Otherwise, we skip $a_{t}$ if we can (i.e. if we included $a_{t-1}$ in the subsequence), otherwise we include it out of necessity, and go to the next $t$. Clearly, this subsequence will include all $+1 \\mathrm{~s}$. Also, for each -1 included in the sequence, a -1 must have been skipped, so at most $\\left\\lfloor\\frac{1011}{2}\\right\\rfloor=505$ can be included. Hence the sum is at least $1011-505=506$, as desired.\n\nNext, we prove that, for the \\pm 1 -sequence\n\n$$\n(\\{-1\\},\\{+1,+1\\},\\{-1,-1\\},\\{+1,+1\\}, \\ldots,\\{+1,+1\\},\\{-1,-1\\},\\{+1\\}),\n$$\n\neach admissible subsequence $a_{t_{i}}$ has $-506 \\leqslant \\sum_{i} a_{t_{i}} \\leqslant 506$. We say that the terms inside each curly bracket is a block. In total, there are 1012 blocks - 506 of them hold +1-s, and 506 of them hold -1 s. (The two blocks at each end hold 1 number each, each other block holds 2.)\n\nSuppose an admissible subsequence includes terms from $k$ blocks holding +1 -s. Then, in each -1 -pair in between the +1 -pairs, the subsequence must also include at least one -1 . There can be at most two +1 s included from each +1 -block, and at least one -1 must be included from each -1 -block, so the sum is at most $2 k-(k-1)=k+1$.\n\nFor $k<506$, this is at most 506. If $k=506$, one of the +1 -blocks must be the one at the end, meaning it can only include one +1 , so that the maximum in this case is only $k$, not $k+1$, so in this case the sum is also at most 506.\n\nHence we have shown that for any admissible subsequence, $\\sum_{i} a_{t_{i}} \\leqslant 506$. Analogously we can show that $-506 \\leqslant \\sum_{i} a_{t_{i}}$, meaning that $C \\leqslant 506$ as desired."
] | 506 |
2,006 | Combinatorics | null | $\boxed{2271380}$ | [
"2271380"
] | false | null | Numerical | null | In each square of a garden shaped like a $2022 \times 2022$ board, there is initially a tree of height 0 . A gardener and a lumberjack alternate turns playing the following game, with the gardener taking the first turn:
- The gardener chooses a square in the garden. Each tree on that square and all the surrounding squares (of which there are at most eight) then becomes one unit taller.
- The lumberjack then chooses four different squares on the board. Each tree of positive height on those squares then becomes one unit shorter.
We say that a tree is majestic if its height is at least $10^{6}$. Determine the largest number $K$ such that the gardener can ensure there are eventually $K$ majestic trees on the board, no matter how the lumberjack plays. | [
"We solve the problem for a general $3 N \\times 3 N$ board. First, we prove that the lumberjack has a strategy to ensure there are never more than $5 N^{2}$ majestic trees. Giving the squares of the board coordinates in the natural manner, colour each square where at least one of its coordinates are divisible by 3 , shown below for a $9 \\times 9$ board:\n\n<img_3271>\n\nThen, as each $3 \\times 3$ square on the board contains exactly 5 coloured squares, each move of the gardener will cause at most 4 trees on non-coloured squares to grow. The lumberjack may therefore cut those trees, ensuring no tree on a non-coloured square has positive height after his turn. Hence there cannot ever be more majestic trees than coloured squares, which is $5 N^{2}$.\n\nNext, we prove the gardener may ensure there are $5 N^{2}$ majestic trees. In fact, we prove this statement in a modified game which is more difficult for the gardener: on the lumberjack's turn in the modified game, he may decrement the height of all trees on the board except those the gardener did not just grow, in addition to four of the trees the gardener just grew. Clearly, a sequence of moves for the gardener which ensures that there are $K$ majestic trees in the modified game also ensures this in the original game.\n\n\n\nLet $M=\\left(\\begin{array}{l}9 \\\\ 5\\end{array}\\right)$; we say that a $m a p$ is one of the $M$ possible ways to mark 5 squares on a $3 \\times 3$ board. In the modified game, after the gardener chooses a $3 \\times 3$ subboard on the board, the lumberjack chooses a map in this subboard, and the total result of the two moves is that each tree marked on the map increases its height by 1, each tree in the subboard which is not in the map remains unchanged, and each tree outside the subboard decreases its height by 1 . Also note that if the gardener chooses a $3 \\times 3$ subboard $M l$ times, the lumberjack will have to choose some map at least $l$ times, so there will be at least 5 trees which each have height $\\geqslant l$.\n\nThe strategy for the gardener will be to divide the board into $N^{2}$ disjoint $3 \\times 3$ subboards, number them $0, \\ldots, N^{2}-1$ in some order. Then, for $b=N^{2}-1, \\ldots, 0$ in order, he plays $10^{6} M(M+1)^{b}$ times on subboard number $b$. Hence, on subboard number $b$, the moves on that subboard will first ensure 5 of its trees grows by at least $10^{6}(M+1)^{b}$, and then each move after that will decrease their heights by 1 . (As the trees on subboard $b$ had height 0 before the gardener started playing there, no move made on subboards $\\geqslant b$ decreased their heights.) As the gardener makes $10^{6} M(M+1)^{b-1}+\\ldots=10^{6}\\left((M+1)^{b}-1\\right)$ moves after he finishes playing on subboard $b$, this means that on subboard $b$, there will be 5 trees of height at least $10^{6}(M+1)^{b}-10^{6}\\left((M+1)^{b}-1\\right)=10^{6}$, hence each of the subboard has 5 majestic trees, which was what we wanted."
] | 2271380 |
2,010 | Combinatorics | null | $\boxed{3}$ | [
"3"
] | false | null | Numerical | null | Lucy starts by writing $s$ integer-valued 2022-tuples on a blackboard. After doing that, she can take any two (not necessarily distinct) tuples $\mathbf{v}=\left(v_{1}, \ldots, v_{2022}\right)$ and $\mathbf{w}=\left(w_{1}, \ldots, w_{2022}\right)$ that she has already written, and apply one of the following operations to obtain a new tuple:
$$
\begin{aligned}
& \mathbf{v}+\mathbf{w}=\left(v_{1}+w_{1}, \ldots, v_{2022}+w_{2022}\right) \\
& \mathbf{v} \vee \mathbf{w}=\left(\max \left(v_{1}, w_{1}\right), \ldots, \max \left(v_{2022}, w_{2022}\right)\right)
\end{aligned}
$$
and then write this tuple on the blackboard.
It turns out that, in this way, Lucy can write any integer-valued 2022-tuple on the blackboard after finitely many steps. What is the smallest possible number $s$ of tuples that she initially wrote? | [
"We solve the problem for $n$-tuples for any $n \\geqslant 3$ : we will show that the answer is $s=3$, regardless of the value of $n$.\n\nFirst, let us briefly introduce some notation. For an $n$-tuple $\\mathbf{v}$, we will write $\\mathbf{v}_{i}$ for its $i$-th coordinate (where $1 \\leqslant i \\leqslant n$ ). For a positive integer $n$ and a tuple $\\mathbf{v}$ we will denote by $n \\cdot \\mathbf{v}$ the tuple obtained by applying addition on $\\mathbf{v}$ with itself $n$ times. Furthermore, we denote by $\\mathbf{e}(i)$ the tuple which has $i$-th coordinate equal to one and all the other coordinates equal to zero. We say that a tuple is positive if all its coordinates are positive, and negative if all its coordinates are negative.\n\nWe will show that three tuples suffice, and then that two tuples do not suffice.\n\n**Three tuples suffice.** Write $\\mathbf{c}$ for the constant-valued tuple $\\mathbf{c}=(-1, \\ldots,-1)$.\n\nWe note that it is enough for Lucy to be able to make the tuples $\\mathbf{e}(1), \\ldots, \\mathbf{e}(n)$, $\\mathbf{c}$; from those any other tuple $\\mathbf{v}$ can be made as follows. First we choose some positive integer $k$ such that $k+\\mathbf{v}_{i}>0$ for all $i$. Then, by adding a positive number of copies of $\\mathbf{c}, \\mathbf{e}(1), \\ldots, \\mathbf{e}(n)$, she can make\n\n$$\nk \\mathbf{c}+\\left(k+\\mathbf{v}_{1}\\right) \\cdot \\mathbf{e}(1)+\\cdots+\\left(k+\\mathbf{v}_{n}\\right) \\cdot \\mathbf{e}(n)\n$$\n\nwhich we claim is equal to $\\mathbf{v}$. Indeed, this can be checked by comparing coordinates: the $i$-th coordinate of the right-hand side is $-k+\\left(k+\\mathbf{v}_{i}\\right)=\\mathbf{v}_{i}$ as needed.\n\nLucy can take her three starting tuples to be $\\mathbf{a}, \\mathbf{b}$ and $\\mathbf{c}$, such that $\\mathbf{a}_{i}=-i^{2}, \\mathbf{b}_{i}=i$ and $\\mathbf{c}=-1$ (as above).\n\nFor any $1 \\leqslant j \\leqslant n$, write $\\mathbf{d}(j)$ for the tuple $2 \\cdot \\mathbf{a}+4 j \\cdot \\mathbf{b}+\\left(2 j^{2}-1\\right) \\cdot \\mathbf{c}$, which Lucy can make by adding together $\\mathbf{a}, \\mathbf{b}$ and $\\mathbf{c}$ repeatedly. This has $i$ th term\n\n$$\n\\begin{aligned}\n\\mathbf{d}(j)_{i} & =2 \\mathbf{a}_{i}+4 j \\mathbf{b}_{i}+\\left(2 j^{2}-1\\right) \\mathbf{c}_{i} \\\\\n& =-2 i^{2}+4 i j-\\left(2 j^{2}-1\\right) \\\\\n& =1-2(i-j)^{2}\n\\end{aligned}\n$$\n\nThis is 1 if $j=i$, and at most -1 otherwise. Hence Lucy can produce the tuple $\\mathbf{1}=(1, \\ldots, 1)$ as $\\mathbf{d}(1) \\vee \\cdots \\vee \\mathbf{d}(n)$.\n\nShe can then produce the constant tuple $\\mathbf{0}=(0, \\ldots, 0)$ as $\\mathbf{1}+\\mathbf{c}$, and for any $1 \\leqslant j \\leqslant n$ she can then produce the tuple $\\mathbf{e}(j)$ as $\\mathbf{d}(j) \\vee \\mathbf{0}$. Since she can now produce $\\mathbf{e}(1), \\ldots, \\mathbf{e}(n)$ and already had $\\mathbf{c}$, she can (as we argued earlier) produce any integer-valued tuple.\n\n\n\n**Two tuples do not suffice.** We start with an observation: Let $a$ be a non-negative real number and suppose that two tuples $\\mathbf{v}$ and $\\mathbf{w}$ satisfy $\\mathbf{v}_{j} \\geqslant a \\mathbf{v}_{k}$ and $\\mathbf{w}_{j} \\geqslant a \\mathbf{w}_{k}$ for some $1 \\leqslant j, k \\leqslant n$. Then we claim that the same inequality holds for $\\mathbf{v}+\\mathbf{w}$ and $\\mathbf{v} \\vee \\mathbf{w}$ : Indeed, the property for the sum is verified by an easy computation:\n\n$$\n(\\mathbf{v}+\\mathbf{w})_{j}=\\mathbf{v}_{j}+\\mathbf{w}_{j} \\geqslant a \\mathbf{v}_{k}+a \\mathbf{w}_{k}=a(\\mathbf{v}+\\mathbf{w})_{k}\n$$\n\nFor the second operation, we denote by $\\mathbf{m}$ the tuple $\\mathbf{v} \\vee \\mathbf{w}$. Then $\\mathbf{m}_{j} \\geqslant \\mathbf{v}_{j} \\geqslant a \\mathbf{v}_{k}$ and $\\mathbf{m}_{j} \\geqslant \\mathbf{w}_{j} \\geqslant a \\mathbf{w}_{k}$. Since $\\mathbf{m}_{k}=\\mathbf{v}_{k}$ or $\\mathbf{m}_{k}=\\mathbf{w}_{k}$, the observation follows.\n\nAs a consequence of this observation we have that if all starting tuples satisfy such an inequality, then all generated tuples will also satisfy it, and so we would not be able to obtain every integer-valued tuple.\n\nLet us now prove that Lucy needs at least three starting tuples. For contradiction, let us suppose that Lucy started with only two tuples $\\mathbf{v}$ and $\\mathbf{w}$. We are going to distinguish two cases. In the first case, suppose we can find a coordinate $i$ such that $\\mathbf{v}_{i}, \\mathbf{w}_{i} \\geqslant 0$. Both operations preserve the sign, thus we can not generate any tuple that has negative $i$-th coordinate. Similarly for $\\mathbf{v}_{i}, \\mathbf{w}_{i} \\leqslant 0$.\n\nSuppose the opposite, i.e., for every $i$ we have either $\\mathbf{v}_{i}>0>\\mathbf{w}_{i}$, or $\\mathbf{v}_{i}<0<\\mathbf{w}_{i}$. Since we assumed that our tuples have at least three coordinates, by pigeonhole principle there exist two coordinates $j \\neq k$ such that $\\mathbf{v}_{j}$ has the same sign as $\\mathbf{v}_{k}$ and $\\mathbf{w}_{j}$ has the same sign as $\\mathbf{w}_{k}$ (because there are only two possible combinations of signs).\n\nWithout loss of generality assume that $\\mathbf{v}_{j}, \\mathbf{v}_{k}>0$ and $\\mathbf{w}_{j}, \\mathbf{w}_{k}<0$. Let us denote the positive real number $\\mathbf{v}_{j} / \\mathbf{v}_{k}$ by $a$. If $\\mathbf{w}_{j} / \\mathbf{w}_{k} \\leqslant a$, then both inequalities $\\mathbf{v}_{j} \\geqslant a \\mathbf{v}_{k}$ and $\\mathbf{w}_{j} \\geqslant a \\mathbf{w}_{k}$ are satisfied. On the other hand, if $\\mathbf{w}_{j} / \\mathbf{w}_{k} \\leqslant a$, then both $\\mathbf{v}_{k} \\geqslant(1 / a) \\mathbf{v}_{j}$ and $\\mathbf{w}_{k} \\geqslant(1 / a) \\mathbf{w}_{j}$ are satisfied. In either case, we have found the desired inequality satisfied by both starting tuples, a contradiction with the observation above."
] | 3 |
2,011 | Combinatorics | null | $\boxed{2 n^{2}-2 n+1}$ | [
"$2 n^{2}-2 n+1$"
] | false | null | Expression | null | Alice fills the fields of an $n \times n$ board with numbers from 1 to $n^{2}$, each number being used exactly once. She then counts the total number of good paths on the board. A good path is a sequence of fields of arbitrary length (including 1) such that:
(i) The first field in the sequence is one that is only adjacent to fields with larger numbers,
(ii) Each subsequent field in the sequence is adjacent to the previous field,
(iii) The numbers written on the fields in the sequence are in increasing order.
Two fields are considered adjacent if they share a common side. Find the smallest possible number of good paths Alice can obtain, as a function of $n$. | [
"We will call any field that is only adjacent to fields with larger numbers a well. Other fields will be called non-wells. Let us make a second $n \\times n$ board $B$ where in each field we will write the number of good sequences which end on the corresponding field in the original board $A$. We will thus look for the minimal possible value of the sum of all entries in $B$.\n\nWe note that any well has just one good path ending in it, consisting of just the well, and that any other field has the number of good paths ending in it equal to the sum of this quantity for all the adjacent fields with smaller values, since a good path can only come into the field from a field of lower value. Therefore, if we fill in the fields in $B$ in increasing order with respect to their values in $A$, it follows that each field not adjacent to any already filled field will receive a 1, while each field adjacent to already filled fields will receive the sum of the numbers already written on these adjacent fields.\n\nWe note that there is at least one well in $A$, that corresponding with the field with the entry 1 in $A$. Hence, the sum of values of fields in $B$ corresponding to wells in $A$ is at least 1 . We will now try to minimize the sum of the non-well entries, i.e. of the entries in $B$ corresponding to the non-wells in $A$. We note that we can ascribe to each pair of adjacent fields the value of the lower assigned number and that the sum of non-well entries will then equal to the sum of the ascribed numbers. Since the lower number is still at least 1, the sum of non-well entries will at least equal the number of pairs of adjacent fields, which is $2 n(n-1)$. Hence, the total minimum sum of entries in $B$ is at least $2 n(n-1)+1=2 n^{2}-2 n+1$. The necessary conditions for the minimum to be achieved is for there to be only one well and for no two entries in $B$ larger than 1 to be adjacent to each other.\n\nWe will now prove that the lower limit of $2 n^{2}-2 n+1$ entries can be achieved. This amounts to finding a way of marking a certain set of squares, those that have a value of 1 in $B$, such that no two unmarked squares are adjacent and that the marked squares form a connected tree with respect to adjacency.\n\nFor $n=1$ and $n=2$ the markings are respectively the lone field and the L-trimino. Now, for $n>2$, let $s=2$ for $n \\equiv 0,2 \\bmod 3$ and $s=1$ for $n \\equiv 1 \\bmod 3$. We will take indices $k$ and $l$ to be arbitrary non-negative integers. For $n \\geqslant 3$ we will construct a path of marked squares in the first two columns consisting of all squares of the form $(1, i)$ where $i$ is not of the form $6 k+s$ and $(2, j)$ where $j$ is of the form $6 k+s-1,6 k+s$ or $6+s+1$. Obviously, this path is connected. Now, let us consider the fields $(2,6 k+s)$ and $(1,6 k+s+3)$. For each considered field $(i, j)$ we will mark all squares of the form $(l, j)$ for $l>i$ and $(i+2 k, j \\pm 1)$. One can easily see that no set of marked fields will produce a cycle, that the only fields of the unmarked form $(1,6 k+s),(2+2 l+1,6 k+s \\pm 1)$ and $(2+2 l, 6 k+s+3 \\pm 1)$ and that no two are adjacent, since\n\n\n\nthe consecutive considered fields are in columns of opposite parity. Examples of markings are given for $n=3,4,5,6,7$, and the corresponding constructions for $A$ and $B$ are given for $n=5$.\n<img_3672>"
] | $2 n^{2}-2 n+1$ |
2,012 | Combinatorics | null | $\boxed{2500,7500}$ | [
"2500,7500"
] | true | null | Numerical | null | Let $\mathbb{Z}_{\geqslant 0}$ be the set of non-negative integers, and let $f: \mathbb{Z}_{\geqslant 0} \times \mathbb{Z}_{\geqslant 0} \rightarrow \mathbb{Z}_{\geqslant 0}$ be a bijection such that whenever $f\left(x_{1}, y_{1}\right)>f\left(x_{2}, y_{2}\right)$, we have $f\left(x_{1}+1, y_{1}\right)>f\left(x_{2}+1, y_{2}\right)$ and $f\left(x_{1}, y_{1}+1\right)>f\left(x_{2}, y_{2}+1\right)$.
Let $N$ be the number of pairs of integers $(x, y)$, with $0 \leqslant x, y<100$, such that $f(x, y)$ is odd. Find the smallest and largest possible value of $N$. | [
"We defer the constructions to the end of the solution. Instead, we begin by characterizing all such functions $f$, prove a formula and key property for such functions, and then solve the problem, providing constructions.\n\n**Characterization** Suppose $f$ satisfies the given relation. The condition can be written more strongly as\n\n$$\n\\begin{aligned}\nf\\left(x_{1}, y_{1}\\right)>f\\left(x_{2}, y_{2}\\right) & \\Longleftrightarrow f\\left(x_{1}+1, y_{1}\\right)>f\\left(x_{2}+1, y_{2}\\right) \\\\\n& \\Longleftrightarrow f\\left(x_{1}, y_{1}+1\\right)>f\\left(x_{2}, y_{2}+1\\right)\n\\end{aligned}\n$$\n\nIn particular, this means for any $(k, l) \\in \\mathbb{Z}^{2}, f(x+k, y+l)-f(x, y)$ has the same sign for all $x$ and $y$.\n\nCall a non-zero vector $(k, l) \\in \\mathbb{Z}_{\\geqslant 0} \\times \\mathbb{Z}_{\\geqslant 0}$ a needle if $f(x+k, y)-f(x, y+l)>0$ for all $x$ and $y$. It is not hard to see that needles and non-needles are both closed under addition, and thus under scalar division (whenever the quotient lives in $\\mathbb{Z}^{2}$ ).\n\nIn addition, call a positive rational number $\\frac{k}{l}$ a grade if the vector $(k, l)$ is a needle. (Since needles are closed under scalar multiples and quotients, this is well-defined.)\n\nClaim. Grades are closed upwards.\n\nProof. Consider positive rationals $k_{1} / l_{1}<k_{2} / l_{2}$ with $k_{1} / l_{1}$ a grade. Then:\n\n- $\\left(k_{1}, l_{1}\\right)$ is a needle\n- so $\\left(k_{1} l_{2}, l_{1} l_{2}\\right)$ is a needle,\n- so $\\left(k_{2} l_{1}, l_{1} l_{2}\\right)$ is a needle (as $k_{2} l_{1}-k_{1} l_{2}>0$ and $(1,0)$ is a needle).\n\nThus $\\left(k_{2}, l_{2}\\right)$ is a needle, as wanted.\n\nClaim. A grade exists.\n\nProof. If no positive integer $n$ is a grade, then $f(1,0)>f(0, n)$ for all $n$ which is impossible.\n\nSimilarly, there is an $n$ such that $f(0,1)<f(n, 0)$, thus $1 / n$ is not a grade for some large $n$. That means that small positive rational values are not grades, then there is a switch, and after that all values are grades. Call the place of that switch $\\alpha$. Here $\\alpha$ is the infimum of the grades.\n\nClaim (Key property). If $x_{1}+y_{1} \\alpha>x_{2}+y_{2} \\alpha$ then $f\\left(x_{1}, y_{1}\\right)>f\\left(x_{2}, y_{2}\\right)$.\n\nProof. If both $x_{1} \\geqslant x_{2}$ and $y_{1} \\geqslant y_{2}$ this is clear.\n\nSuppose $x_{1} \\geqslant x_{2}$ and $y_{1}<y_{2}$. Then $\\frac{x_{1}-x_{2}}{y_{2}-y_{1}}>\\alpha$ is a grade. This gives $f\\left(x_{1}, y_{1}\\right)>f\\left(x_{2}, y_{2}\\right)$. Suppose $x_{1}<x_{2}$ and $y_{1} \\geqslant y_{2}$. Then $\\frac{x_{2}-x_{1}}{u_{1}-u_{2}}<\\alpha$ is not a grade. This gives $f\\left(x_{2}, y_{2}\\right)<f\\left(x_{1}, y_{1}\\right)$.\n\nFrom those observations we get the following claim.\n\nClaim. The function $f$ orders pairs $(x, y)$ based on the value of $x+y \\alpha$. If $\\alpha$ is rational, tiebreaking is done by larger $x$ - or $y$-coordinate (depending on whether $\\alpha$ is a grade).\n\n\n\nWe can imagine this the following way: take a line with slope $-\\frac{1}{\\alpha}$ under the first quadrant of the plane. And we start to move this line upward (but it stays parallel to the original line). First it hits $(0,0)$, so $f(0,0)=0$. And each time the line hits a point $p, f(p)$ is the number of points hit before. If $\\alpha \\in \\mathbb{Q}$, it is possible that the line hits multiple points. Then those points are ordered the same way as their $x$ or $y$ coordinates, depending on whether $\\alpha$ is a grade.\n\nWe understood the behaviour of $f$, now we need to focus on the region of $A=\\{(x, y) \\in$ $\\left.\\mathbb{Z}_{\\geqslant 0} \\times \\mathbb{Z}_{\\geqslant 0} \\mid x<100, y<100\\right\\}$. First, we can assume that $\\alpha$ is irrational. If we change it a little bit in the right direction, the behaviour and values of the $f$ function does not change in $A$.\n\nClaim.\n\n$$\nf(x, y)+f(x+1, y+1)=f(x+1, y)+f(x, y+1)+1\n$$\n\nProof.\n\n$$\n\\begin{gathered}\nf(x+1, y+1)-f(x, y+1)= \\\\\n\\#\\left\\{(a, b) \\in \\mathbb{Z}_{\\geqslant 0} \\times \\mathbb{Z}_{\\geqslant 0} \\mid x+(y+1) \\alpha \\leqslant a+b \\alpha<(x+1)+(y+1) \\alpha\\right\\}= \\\\\n\\#\\left\\{(a, b) \\in \\mathbb{Z}_{\\geqslant 0} \\times \\mathbb{Z}_{>0} \\mid x+(y+1) \\alpha \\leqslant a+b \\alpha<(x+1)+(y+1) \\alpha\\right\\}+ \\\\\n\\#\\left\\{(a, 0) \\in \\mathbb{Z}_{\\geqslant 0} \\times \\mathbb{Z}_{\\geqslant 0} \\mid(x+1)+y \\alpha \\leqslant a<(x+1)+(y+1) \\alpha\\right\\}= \\\\\n\\#\\left\\{(a, b) \\in \\mathbb{Z}_{\\geqslant 0} \\times \\mathbb{Z}_{\\geqslant 0} \\mid x+y \\alpha \\leqslant a+b \\alpha<(x+1)+y \\alpha\\right\\}+1=f(x+1, y)-f(x, y) .\n\\end{gathered}\n$$\n\nFrom this claim we immediately get that $2500 \\leqslant N \\leqslant 7500$; now we show that those bounds are indeed sharp.\n\nRemember that if $\\alpha$ is irrational then\n\n$$\nf(a, b)=\\#\\left\\{(x, y) \\in \\mathbb{Z}_{\\geqslant 0} \\times \\mathbb{Z}_{\\geqslant 0} \\mid x+y \\alpha<a+b \\alpha\\right\\}\n$$\n\nConstruction for 7500 Select $\\alpha \\approx 199.999$.\n\nClaim. \n\n1. $f(n, 0)=n$ for $0 \\leqslant n \\leqslant 100$.\n2. $f(0, k) \\equiv k \\bmod 2$ for $0 \\leqslant k \\leqslant 100$.\n\nProof.\n\n1. $f(n, 0)=\\#\\{(x, y) \\mid x+y \\alpha<n\\}=\\#\\{(x, y) \\mid x+199 y<n\\}=n$.\n2. \n\n$$\n\\begin{gathered}\nf(0, k)=\\#\\{(x, y) \\mid x+y \\alpha<k \\alpha\\}=\\sum_{l=0}^{k-1} \\#\\{(x, l) \\mid x+l \\alpha<k \\alpha\\} \\\\\n\\quad=\\sum_{l=0}^{k-1} \\#\\{x \\mid x<(k-l) \\alpha\\}=\\sum_{l=0}^{k-1} 200(k-l)-1=200 A-k\n\\end{gathered}\n$$\n\nfor some integer $A$.\n\nFrom this claim, using the equality $f(x, y)+f(x+1, y+1)=f(x+1, y)+f(x, y+1)+1$, we can prove that mod 2 the region $A$ looks like the following: in the rows $(-, 2 y)$ the remainders modulo 2 alternate, while the rows $(-, 2 y+1)$ contain only odd numbers.\n\n\n\n<img_3591>\n\nThe numbers mod 2 in the construction for 7500.\n\nConstruction for 2500 Select $\\alpha \\approx 200.001$.\n\nClaim. \n\n1. $f(n, 0)=n$ for $0 \\leqslant n \\leqslant 100$.\n2. $f(0, k) \\equiv 0 \\bmod 2$ for $0 \\leqslant k \\leqslant 100$.\n\nProof.\n\n1. As above.\n2. Similarly to the above:\n\n$$\n\\begin{aligned}\nf(0, k) & =\\#\\{(x, y) \\mid x+y \\alpha<k \\alpha\\}=\\sum_{l=0}^{k-1} \\#\\{(x, l) \\mid x+l \\alpha<k \\alpha\\} \\\\\n& =\\sum_{l=0}^{k-1} \\#\\{x \\mid x<(k-l) \\alpha\\}=\\sum_{l=0}^{k-1} 200(k-l)=200 A\n\\end{aligned}\n$$\n\nfor some integer $A$.\n\nSimilarly to the above, we can prove that mod 2 the region $A$ looks like the following: in the rows $(-, 2 y)$ the remainder modulo 2 alternate, while the rows $(-, 2 y+1)$ contain only even numbers.\n\n<img_3697>\n\nThe numbers mod 2 in the construction for 7500."
] | 2500,7500 |
2,021 | Number Theory | null | $\boxed{1344}$ | [
"1344"
] | false | null | Numerical | null | A number is called Norwegian if it has three distinct positive divisors whose sum is equal to 2022. Determine the smallest Norwegian number.
(Note: The total number of positive divisors of a Norwegian number is allowed to be larger than 3.) | [
"Observe that 1344 is a Norwegian number as 6, 672 and 1344 are three distinct divisors of 1344 and $6+672+1344=2022$. It remains to show that this is the smallest such number.\n\nAssume for contradiction that $N<1344$ is Norwegian and let $N / a, N / b$ and $N / c$ be the three distinct divisors of $N$, with $a<b<c$. Then\n\n$$\n2022=N\\left(\\frac{1}{a}+\\frac{1}{b}+\\frac{1}{c}\\right)<1344\\left(\\frac{1}{a}+\\frac{1}{b}+\\frac{1}{c}\\right)\n$$\n\nand so\n\n$$\n\\left(\\frac{1}{a}+\\frac{1}{b}+\\frac{1}{c}\\right)>\\frac{2022}{1344}=\\frac{337}{224}=\\frac{3}{2}+\\frac{1}{224} .\n$$\n\nIf $a>1$ then\n\n$$\n\\frac{1}{a}+\\frac{1}{b}+\\frac{1}{c} \\leqslant \\frac{1}{2}+\\frac{1}{3}+\\frac{1}{4}=\\frac{13}{12}<\\frac{3}{2}\n$$\n\nso it must be the case that $a=1$. Similarly, it must hold that $b<4$ since otherwise\n\n$$\n1+\\frac{1}{b}+\\frac{1}{c} \\leqslant 1+\\frac{1}{4}+\\frac{1}{5}<\\frac{3}{2}\n$$\n\nThis leaves two cases to check, $b=2$ and $b=3$.\n\nCase $b=3$. Then\n\n$$\n\\frac{1}{c}>\\frac{3}{2}+\\frac{1}{224}-1-\\frac{1}{3}>\\frac{1}{6}\n$$\n\nso $c=4$ or $c=5$. If $c=4$ then\n\n$$\n2022=N\\left(1+\\frac{1}{3}+\\frac{1}{4}\\right)=\\frac{19}{12} N\n$$\n\nbut this is impossible as $19 \\nmid 2022$. If $c=5$ then\n\n$$\n2022=N\\left(1+\\frac{1}{3}+\\frac{1}{5}\\right)=\\frac{23}{15} N\n$$\n\nwhich again is impossible, as $23 \\nmid 2022$.\n\nCase $b=2$. Note that $c<224$ since\n\n$$\n\\frac{1}{c}>\\frac{3}{2}+\\frac{1}{224}-1-\\frac{1}{2}=\\frac{1}{224}\n$$\n\nIt holds that\n\n$$\n2022=N\\left(1+\\frac{1}{2}+\\frac{1}{c}\\right)=\\frac{3 c+2}{2 c} N \\Rightarrow(3 c+2) N=4044 c\n$$\n\nSince $(c, 3 c-2)=(c, 2) \\in\\{1,2\\}$, then $3 c+2 \\mid 8088=2^{3} \\cdot 3 \\cdot 337$ which implies that $3 c+2 \\mid 2^{3} \\cdot 337$. But since $3 c+2 \\geqslant 3 \\cdot 3+2>8=2^{3}$ and $3 c+2 \\neq 337$, then it must hold that $3 c+2 \\geqslant 2 \\cdot 337$, contradicting $c<224$."
] | 1344 |
2,022 | Number Theory | null | $\boxed{7}$ | [
"7"
] | false | null | Numerical | null | Find all positive integers $n>2$ such that
$$
n ! \mid \prod_{\substack{p<q \leqslant n \\ p, q \text { primes }}}(p+q)
$$ | [
"Assume that $n$ satisfies $n ! \\mid \\prod_{p<q \\leqslant n}(p+q)$ and let $2=p_{1}<p_{2}<\\cdots<p_{m} \\leqslant n$ be the primes in $\\{1,2, \\ldots, n\\}$. Each such prime divides $n$ !. In particular, $p_{m} \\mid p_{i}+p_{j}$ for some $p_{i}<p_{j} \\leqslant n$. But\n\n$$\n0<\\frac{p_{i}+p_{j}}{p_{m}}<\\frac{p_{m}+p_{m}}{p_{m}}=2\n$$\n\nso $p_{m}=p_{i}+p_{j}$ which implies $m \\geqslant 3, p_{i}=2$ and $p_{m}=2+p_{j}=2+p_{m-1}$.\n\nSimilarly, $p_{m-1} \\mid p_{k}+p_{l}$ for some $p_{k}<p_{l} \\leqslant n$. But\n\n$$\n0<\\frac{p_{l}+p_{k}}{p_{m-1}} \\leqslant \\frac{p_{m}+p_{m-1}}{p_{m-1}}=\\frac{2 p_{m-1}+2}{p_{m-1}}<3\n$$\n\nso either $p_{m-1}=p_{l}+p_{k}$ or $2 p_{m-1}=p_{l}+p_{k}$. As above, the former case gives $p_{m-1}=2+p_{m-2}$. If $2 p_{m-1}=p_{l}+p_{k}$, then $p_{m-1}<p_{k}$, so $k=m$ and\n\n$$\n2 p_{m-1}=p_{l}+p_{m-1}+2 \\Rightarrow p_{m-1}=p_{l}+2=p_{m-2}+2\n$$\n\nEither way, $p_{m-2}>2$ and 3 divides one of $p_{m-2}, p_{m-1}=p_{m-2}+2$ and $p_{m}=p_{m-2}+4$. This implies $p_{m-2}=3$ and thus $p_{m}=7$, giving $7 \\leqslant n<11$.\n\nFinally, a quick computation shows that $7 ! \\mid \\prod_{p<q \\leqslant 7}(p+q)$ but 8 ! $\\nmid \\prod_{p<q \\leqslant 7}(p+q)$, so neither does 9 ! and 10 !."
] | 7 |
2,024 | Number Theory | null | $\boxed{(2,2,2),(3,4,3)}$ | [
"$(2,2,2),(3,4,3)$"
] | true | null | Tuple | null | Find all triples of positive integers $(a, b, p)$ with $p$ prime and
$$
a^{p}=b !+p
$$ | [
"Clearly, $a>1$. We consider three cases.\n\nCase 1: We have $a<p$. Then we either have $a \\leqslant b$ which implies $a \\mid a^{p}-b$ ! $=p$ leading to a contradiction, or $a>b$ which is also impossible since in this case we have $b ! \\leqslant a !<a^{p}-p$, where the last inequality is true for any $p>a>1$.\n\nCase 2: We have $a>p$. In this case $b !=a^{p}-p>p^{p}-p \\geqslant p$ ! so $b>p$ which means that $a^{p}=b !+p$ is divisible by $p$. Hence, $a$ is divisible by $p$ and $b !=a^{p}-p$ is not divisible by $p^{2}$. This means that $b<2 p$. If $a<p^{2}$ then $a / p<p$ divides both $a^{p}$ and $b$ ! and hence it also divides $p=a^{p}-b$ ! which is impossible. On the other hand, the case $a \\geqslant p^{2}$ is also impossible since then $a^{p} \\geqslant\\left(p^{2}\\right)^{p}>(2 p-1) !+p \\geqslant b !+p$.\n\nCase 3: We have $a=p$. In this case $b !=p^{p}-p$. One can check that the values $p=2,3$ lead to the claimed solutions and $p=5$ does not lead to a solution. So we now assume that $p \\geqslant 7$. We have $b !=p^{p}-p>p !$ and so $b \\geqslant p+1$ which implies that\n\n$$\nv_{2}((p+1) !) \\leqslant v_{2}(b !)=v_{2}\\left(p^{p-1}-1\\right) \\stackrel{L T E}{=} 2 v_{2}(p-1)+v_{2}(p+1)-1=v_{2}\\left(\\frac{p-1}{2} \\cdot(p-1) \\cdot(p+1)\\right)\n$$\n\nwhere in the middle we used lifting-the-exponent lemma. On the RHS we have three factors of $(p+1)$ !. But, due to $p+1 \\geqslant 8$, there are at least 4 even numbers among $1,2, \\ldots, p+1$, so this case is not possible.",
"Clearly, $a>1$. We consider three cases.\n\nCase 1: We have $a<p$. Then we either have $a \\leqslant b$ which implies $a \\mid a^{p}-b$ ! $=p$ leading to a contradiction, or $a>b$ which is also impossible since in this case we have $b ! \\leqslant a !<a^{p}-p$, where the last inequality is true for any $p>a>1$.\n\nCase 2: We have $a>p$. In this case $b !=a^{p}-p>p^{p}-p \\geqslant p$ ! so $b>p$ which means that $a^{p}=b !+p$ is divisible by $p$. Hence, $a$ is divisible by $p$ and $b !=a^{p}-p$ is not divisible by $p^{2}$. This means that $b<2 p$. If $a<p^{2}$ then $a / p<p$ divides both $a^{p}$ and $b$ ! and hence it also divides $p=a^{p}-b$ ! which is impossible. On the other hand, the case $a \\geqslant p^{2}$ is also impossible since then $a^{p} \\geqslant\\left(p^{2}\\right)^{p}>(2 p-1) !+p \\geqslant b !+p$.\n\nCase 3: We have $a=p$. In this case $b !=p^{p}-p$. One can check that the values $p=2,3$ lead to the claimed solutions and $p=5$ does not lead to a solution. For $p \\geqslant 5$ we have $b !=p\\left(p^{p-1}-1\\right)$. By Zsigmondy's Theorem there exists some prime $q$ that divides $p^{p-1}-1$ but does not divide $p^{k}-1$ for $k<p-1$. It follows that $\\operatorname{ord}_{q}(p)=p-1$, and hence $q \\equiv 1$ $\\bmod (p-1)$. Note that $p \\neq q$. But then we must have $q \\geqslant 2 p-1$, giving\n\n$b ! \\geqslant(2 p-1) !=[1 \\cdot(2 p-1)] \\cdot[2 \\cdot(2 p-2)] \\cdots \\cdots[(p-1) \\cdot(p+1)] \\cdot p>(2 p-1)^{p-1} p>p^{p}>p^{p}-p$, a contradiction."
] | $(2,2,2),(3,4,3)$ |
2,029 | Algebra | null | $\boxed{f(x)=1}$ | [
"$f(x)=1$"
] | false | null | Expression | null | Let $\mathbb{Q}_{>0}$ denote the set of all positive rational numbers. Determine all functions $f: \mathbb{Q}_{>0} \rightarrow \mathbb{Q}_{>0}$ satisfying
$$
f\left(x^{2} f(y)^{2}\right)=f(x)^{2} f(y)
\tag{*}
$$
for all $x, y \in \mathbb{Q}_{>0}$. | [
"Take any $a, b \\in \\mathbb{Q}_{>0}$. By substituting $x=f(a), y=b$ and $x=f(b), y=a$ into $(*)$ we get\n\n$$\nf(f(a))^{2} f(b)=f\\left(f(a)^{2} f(b)^{2}\\right)=f(f(b))^{2} f(a)\n$$\n\nwhich yields\n\n$$\n\\frac{f(f(a))^{2}}{f(a)}=\\frac{f(f(b))^{2}}{f(b)} \\quad \\text { for all } a, b \\in \\mathbb{Q}>0\n$$\n\nIn other words, this shows that there exists a constant $C \\in \\mathbb{Q}_{>0}$ such that $f(f(a))^{2}=C f(a)$, or\n\n$$\n\\left(\\frac{f(f(a))}{C}\\right)^{2}=\\frac{f(a)}{C} \\quad \\text { for all } a \\in \\mathbb{Q}_{>0}\n\\tag{1}\n$$\n\nDenote by $f^{n}(x)=\\underbrace{f(f(\\ldots(f}_{n}(x)) \\ldots))$ the $n^{\\text {th }}$ iteration of $f$. Equality (1) yields\n\n$$\n\\frac{f(a)}{C}=\\left(\\frac{f^{2}(a)}{C}\\right)^{2}=\\left(\\frac{f^{3}(a)}{C}\\right)^{4}=\\cdots=\\left(\\frac{f^{n+1}(a)}{C}\\right)^{2^{n}}\n$$\n\nfor all positive integer $n$. So, $f(a) / C$ is the $2^{n}$-th power of a rational number for all positive integer $n$. This is impossible unless $f(a) / C=1$, since otherwise the exponent of some prime in the prime decomposition of $f(a) / C$ is not divisible by sufficiently large powers of 2 . Therefore, $f(a)=C$ for all $a \\in \\mathbb{Q}_{>0}$.\n\nFinally, after substituting $f \\equiv C$ into $(*)$ we get $C=C^{3}$, whence $C=1$. So $f(x) \\equiv 1$ is the unique function satisfying $(*)$."
] | $f(x)=1$ |
2,032 | Algebra | null | $\boxed{\frac{2016}{2017^{2}}}$ | [
"$\\frac{2016}{2017^{2}}$"
] | false | null | Numerical | null | Let $a_{0}, a_{1}, a_{2}, \ldots$ be a sequence of real numbers such that $a_{0}=0, a_{1}=1$, and for every $n \geqslant 2$ there exists $1 \leqslant k \leqslant n$ satisfying
$$
a_{n}=\frac{a_{n-1}+\cdots+a_{n-k}}{k}
$$
Find the maximal possible value of $a_{2018}-a_{2017}$. | [
"The claimed maximal value is achieved at\n\n$$\n\\begin{gathered}\na_{1}=a_{2}=\\cdots=a_{2016}=1, \\quad a_{2017}=\\frac{a_{2016}+\\cdots+a_{0}}{2017}=1-\\frac{1}{2017}, \\\\\na_{2018}=\\frac{a_{2017}+\\cdots+a_{1}}{2017}=1-\\frac{1}{2017^{2}} .\n\\end{gathered}\n$$\n\nNow we need to show that this value is optimal. For brevity, we use the notation\n\n$$\nS(n, k)=a_{n-1}+a_{n-2}+\\cdots+a_{n-k} \\quad \\text { for nonnegative integers } k \\leqslant n \\text {. }\n$$\n\nIn particular, $S(n, 0)=0$ and $S(n, 1)=a_{n-1}$. In these terms, for every integer $n \\geqslant 2$ there exists a positive integer $k \\leqslant n$ such that $a_{n}=S(n, k) / k$.\n\nFor every integer $n \\geqslant 1$ we define\n\n$$\nM_{n}=\\max _{1 \\leqslant k \\leqslant n} \\frac{S(n, k)}{k}, \\quad m_{n}=\\min _{1 \\leqslant k \\leqslant n} \\frac{S(n, k)}{k}, \\quad \\text { and } \\quad \\Delta_{n}=M_{n}-m_{n} \\geqslant 0\n$$\n\nBy definition, $a_{n} \\in\\left[m_{n}, M_{n}\\right]$ for all $n \\geqslant 2$; on the other hand, $a_{n-1}=S(n, 1) / 1 \\in\\left[m_{n}, M_{n}\\right]$. Therefore,\n\n$$\na_{2018}-a_{2017} \\leqslant M_{2018}-m_{2018}=\\Delta_{2018},\n$$\n\nand we are interested in an upper bound for $\\Delta_{2018}$.\n\nAlso by definition, for any $0<k \\leqslant n$ we have $k m_{n} \\leqslant S(n, k) \\leqslant k M_{n}$; notice that these inequalities are also valid for $k=0$.\n\nClaim 1. For every $n>2$, we have $\\Delta_{n} \\leqslant \\frac{n-1}{n} \\Delta_{n-1}$.\n\nProof. Choose positive integers $k, \\ell \\leqslant n$ such that $M_{n}=S(n, k) / k$ and $m_{n}=S(n, \\ell) / \\ell$. We have $S(n, k)=a_{n-1}+S(n-1, k-1)$, so\n\n$$\nk\\left(M_{n}-a_{n-1}\\right)=S(n, k)-k a_{n-1}=S(n-1, k-1)-(k-1) a_{n-1} \\leqslant(k-1)\\left(M_{n-1}-a_{n-1}\\right),\n$$\n\nsince $S(n-1, k-1) \\leqslant(k-1) M_{n-1}$. Similarly, we get\n\n$$\n\\ell\\left(a_{n-1}-m_{n}\\right)=(\\ell-1) a_{n-1}-S(n-1, \\ell-1) \\leqslant(\\ell-1)\\left(a_{n-1}-m_{n-1}\\right) .\n$$\n\nSince $m_{n-1} \\leqslant a_{n-1} \\leqslant M_{n-1}$ and $k, \\ell \\leqslant n$, the obtained inequalities yield\n\n$$\n\\begin{array}{ll}\nM_{n}-a_{n-1} \\leqslant \\frac{k-1}{k}\\left(M_{n-1}-a_{n-1}\\right) \\leqslant \\frac{n-1}{n}\\left(M_{n-1}-a_{n-1}\\right) \\text { and } \\\\\na_{n-1}-m_{n} \\leqslant \\frac{\\ell-1}{\\ell}\\left(a_{n-1}-m_{n-1}\\right) \\leqslant \\frac{n-1}{n}\\left(a_{n-1}-m_{n-1}\\right) .\n\\end{array}\n$$\n\nTherefore,\n\n$$\n\\Delta_{n}=\\left(M_{n}-a_{n-1}\\right)+\\left(a_{n-1}-m_{n}\\right) \\leqslant \\frac{n-1}{n}\\left(\\left(M_{n-1}-a_{n-1}\\right)+\\left(a_{n-1}-m_{n-1}\\right)\\right)=\\frac{n-1}{n} \\Delta_{n-1}\n$$\n\nBack to the problem, if $a_{n}=1$ for all $n \\leqslant 2017$, then $a_{2018} \\leqslant 1$ and hence $a_{2018}-a_{2017} \\leqslant 0$. Otherwise, let $2 \\leqslant q \\leqslant 2017$ be the minimal index with $a_{q}<1$. We have $S(q, i)=i$ for all $i=1,2, \\ldots, q-1$, while $S(q, q)=q-1$. Therefore, $a_{q}<1$ yields $a_{q}=S(q, q) / q=1-\\frac{1}{q}$.\n\nNow we have $S(q+1, i)=i-\\frac{1}{q}$ for $i=1,2, \\ldots, q$, and $S(q+1, q+1)=q-\\frac{1}{q}$. This gives us\n\n$$\nm_{q+1}=\\frac{S(q+1,1)}{1}=\\frac{S(q+1, q+1)}{q+1}=\\frac{q-1}{q} \\quad \\text { and } \\quad M_{q+1}=\\frac{S(q+1, q)}{q}=\\frac{q^{2}-1}{q^{2}}\n$$\n\nso $\\Delta_{q+1}=M_{q+1}-m_{q+1}=(q-1) / q^{2}$. Denoting $N=2017 \\geqslant q$ and using Claim 1 for $n=q+2, q+3, \\ldots, N+1$ we finally obtain\n\n$$\n\\Delta_{N+1} \\leqslant \\frac{q-1}{q^{2}} \\cdot \\frac{q+1}{q+2} \\cdot \\frac{q+2}{q+3} \\cdots \\frac{N}{N+1}=\\frac{1}{N+1}\\left(1-\\frac{1}{q^{2}}\\right) \\leqslant \\frac{1}{N+1}\\left(1-\\frac{1}{N^{2}}\\right)=\\frac{N-1}{N^{2}},\n$$\n\nas required.",
"We present a different proof of the estimate $a_{2018}-a_{2017} \\leqslant \\frac{2016}{2017^{2}}$. We keep the same notations of $S(n, k), m_{n}$ and $M_{n}$ from the previous solution.\n\nNotice that $S(n, n)=S(n, n-1)$, as $a_{0}=0$. Also notice that for $0 \\leqslant k \\leqslant \\ell \\leqslant n$ we have $S(n, \\ell)=S(n, k)+S(n-k, \\ell-k)$.\n\nClaim 2. For every positive integer $n$, we have $m_{n} \\leqslant m_{n+1}$ and $M_{n+1} \\leqslant M_{n}$, so the segment $\\left[m_{n+1}, M_{n+1}\\right]$ is contained in $\\left[m_{n}, M_{n}\\right]$.\n\nProof. Choose a positive integer $k \\leqslant n+1$ such that $m_{n+1}=S(n+1, k) / k$. Then we have\n\n$$\nk m_{n+1}=S(n+1, k)=a_{n}+S(n, k-1) \\geqslant m_{n}+(k-1) m_{n}=k m_{n},\n$$\n\nwhich establishes the first inequality in the Claim. The proof of the second inequality is similar.\n\nClaim 3. For every positive integers $k \\geqslant n$, we have $m_{n} \\leqslant a_{k} \\leqslant M_{n}$.\n\nProof. By Claim 2, we have $\\left[m_{k}, M_{k}\\right] \\subseteq\\left[m_{k-1}, M_{k-1}\\right] \\subseteq \\cdots \\subseteq\\left[m_{n}, M_{n}\\right]$. Since $a_{k} \\in\\left[m_{k}, M_{k}\\right]$, the claim follows.\n\nClaim 4. For every integer $n \\geqslant 2$, we have $M_{n}=S(n, n-1) /(n-1)$ and $m_{n}=S(n, n) / n$.\n\nProof. We use induction on $n$. The base case $n=2$ is routine. To perform the induction step, we need to prove the inequalities\n\n$$\n\\frac{S(n, n)}{n} \\leqslant \\frac{S(n, k)}{k} \\quad \\text { and } \\quad \\frac{S(n, k)}{k} \\leqslant \\frac{S(n, n-1)}{n-1}\n\\tag{1}\n$$\n\nfor every positive integer $k \\leqslant n$. Clearly, these inequalities hold for $k=n$ and $k=n-1$, as $S(n, n)=S(n, n-1)>0$. In the sequel, we assume that $k<n-1$.\n\nNow the first inequality in (1) rewrites as $n S(n, k) \\geqslant k S(n, n)=k(S(n, k)+S(n-k, n-k))$, or, cancelling the terms occurring on both parts, as\n\n$$\n(n-k) S(n, k) \\geqslant k S(n-k, n-k) \\Longleftrightarrow S(n, k) \\geqslant k \\cdot \\frac{S(n-k, n-k)}{n-k}\n$$\n\nBy the induction hypothesis, we have $S(n-k, n-k) /(n-k)=m_{n-k}$. By Claim 3, we get $a_{n-i} \\geqslant m_{n-k}$ for all $i=1,2, \\ldots, k$. Summing these $k$ inequalities we obtain\n\n$$\nS(n, k) \\geqslant k m_{n-k}=k \\cdot \\frac{S(n-k, n-k)}{n-k}\n$$\n\nas required.\n\nThe second inequality in (1) is proved similarly. Indeed, this inequality is equivalent to\n\n$$\n\\begin{aligned}\n(n-1) S(n, k) \\leqslant k S(n, n-1) & \\Longleftrightarrow(n-k-1) S(n, k) \\leqslant k S(n-k, n-k-1) \\\\\n& \\Longleftrightarrow S(n, k) \\leqslant k \\cdot \\frac{S(n-k, n-k-1)}{n-k-1}=k M_{n-k} ;\n\\end{aligned}\n$$\n\nthe last inequality follows again from Claim 3, as each term in $S(n, k)$ is at most $M_{n-k}$.\n\nNow we can prove the required estimate for $a_{2018}-a_{2017}$. Set $N=2017$. By Claim 4 ,\n\n$$\n\\begin{aligned}\na_{N+1}-a_{N} \\leqslant M_{N+1}-a_{N}=\\frac{S(N+1, N)}{N}-a_{N} & =\\frac{a_{N}+S(N, N-1)}{N}-a_{N} \\\\\n& =\\frac{S(N, N-1)}{N}-\\frac{N-1}{N} \\cdot a_{N} .\n\\end{aligned}\n$$\n\nOn the other hand, the same Claim yields\n\n$$\na_{N} \\geqslant m_{N}=\\frac{S(N, N)}{N}=\\frac{S(N, N-1)}{N}\n$$\n\nNoticing that each term in $S(N, N-1)$ is at most 1 , so $S(N, N-1) \\leqslant N-1$, we finally obtain\n\n$$\na_{N+1}-a_{N} \\leqslant \\frac{S(N, N-1)}{N}-\\frac{N-1}{N} \\cdot \\frac{S(N, N-1)}{N}=\\frac{S(N, N-1)}{N^{2}} \\leqslant \\frac{N-1}{N^{2}} .\n$$"
] | $\frac{2016}{2017^{2}}$ |
2,035 | Algebra | null | $\boxed{\frac{8}{\sqrt[3]{7}}}$ | [
"$\\frac{8}{\\sqrt[3]{7}}$"
] | false | null | Numerical | null | Find the maximal value of
$$
S=\sqrt[3]{\frac{a}{b+7}}+\sqrt[3]{\frac{b}{c+7}}+\sqrt[3]{\frac{c}{d+7}}+\sqrt[3]{\frac{d}{a+7}}
$$
where $a, b, c, d$ are nonnegative real numbers which satisfy $a+b+c+d=100$. | [
"Since the value $8 / \\sqrt[3]{7}$ is reached, it suffices to prove that $S \\leqslant 8 / \\sqrt[3]{7}$.\n\nAssume that $x, y, z, t$ is a permutation of the variables, with $x \\leqslant y \\leqslant z \\leqslant t$. Then, by the rearrangement inequality,\n\n$$\nS \\leqslant\\left(\\sqrt[3]{\\frac{x}{t+7}}+\\sqrt[3]{\\frac{t}{x+7}}\\right)+\\left(\\sqrt[3]{\\frac{y}{z+7}}+\\sqrt[3]{\\frac{z}{y+7}}\\right)\n$$\n\nClaim. The first bracket above does not exceed $\\sqrt[3]{\\frac{x+t+14}{7}}$.\n\nProof. Since\n\n$$\nX^{3}+Y^{3}+3 X Y Z-Z^{3}=\\frac{1}{2}(X+Y-Z)\\left((X-Y)^{2}+(X+Z)^{2}+(Y+Z)^{2}\\right)\n$$\n\nthe inequality $X+Y \\leqslant Z$ is equivalent (when $X, Y, Z \\geqslant 0$ ) to $X^{3}+Y^{3}+3 X Y Z \\leqslant Z^{3}$. Therefore, the claim is equivalent to\n\n$$\n\\frac{x}{t+7}+\\frac{t}{x+7}+3 \\sqrt[3]{\\frac{x t(x+t+14)}{7(x+7)(t+7)}} \\leqslant \\frac{x+t+14}{7}\n$$\n\nNotice that\n\n$$\n\\begin{array}{r}\n3 \\sqrt[3]{\\frac{x t(x+t+14)}{7(x+7)(t+7)}}=3 \\sqrt[3]{\\frac{t(x+7)}{7(t+7)} \\cdot \\frac{x(t+7)}{7(x+7)} \\cdot \\frac{7(x+t+14)}{(t+7)(x+7)}} \\\\\n\\leqslant \\frac{t(x+7)}{7(t+7)}+\\frac{x(t+7)}{7(x+7)}+\\frac{7(x+t+14)}{(t+7)(x+7)}\n\\end{array}\n$$\n\nby the AM-GM inequality, so it suffices to prove\n\n$$\n\\frac{x}{t+7}+\\frac{t}{x+7}+\\frac{t(x+7)}{7(t+7)}+\\frac{x(t+7)}{7(x+7)}+\\frac{7(x+t+14)}{(t+7)(x+7)} \\leqslant \\frac{x+t+14}{7}\n$$\n\nA straightforward check verifies that the last inequality is in fact an equality.\n\nThe claim leads now to\n\n$$\nS \\leqslant \\sqrt[3]{\\frac{x+t+14}{7}}+\\sqrt[3]{\\frac{y+z+14}{7}} \\leqslant 2 \\sqrt[3]{\\frac{x+y+z+t+28}{14}}=\\frac{8}{\\sqrt[3]{7}}\n$$\n\nthe last inequality being due to the AM-CM inequality (or to the fact that $\\sqrt[3]{ }$ is concave on $[0, \\infty))$.",
"We present a different proof for the estimate $S \\leqslant 8 / \\sqrt[3]{7}$.\n\nStart by using Hölder's inequality:\n\n$$\nS^{3}=\\left(\\sum_{\\mathrm{cyc}} \\frac{\\sqrt[6]{a} \\cdot \\sqrt[6]{a}}{\\sqrt[3]{b+7}}\\right)^{3} \\leqslant \\sum_{\\mathrm{cyc}}(\\sqrt[6]{a})^{3} \\cdot \\sum_{\\mathrm{cyc}}(\\sqrt[6]{a})^{3} \\cdot \\sum_{\\mathrm{cyc}}\\left(\\frac{1}{\\sqrt[3]{b+7}}\\right)^{3}=\\left(\\sum_{\\text {cyc }} \\sqrt{a}\\right)^{2} \\sum_{\\mathrm{cyc}} \\frac{1}{b+7}\n$$\n\nNotice that\n\n$$\n\\frac{(x-1)^{2}(x-7)^{2}}{x^{2}+7} \\geqslant 0 \\Longleftrightarrow x^{2}-16 x+71 \\geqslant \\frac{448}{x^{2}+7}\n$$\n\nyields\n\n$$\n\\sum \\frac{1}{b+7} \\leqslant \\frac{1}{448} \\sum(b-16 \\sqrt{b}+71)=\\frac{1}{448}\\left(384-16 \\sum \\sqrt{b}\\right)=\\frac{48-2 \\sum \\sqrt{b}}{56} .\n$$\n\nFinally,\n\n$$\nS^{3} \\leqslant \\frac{1}{56}\\left(\\sum \\sqrt{a}\\right)^{2}\\left(48-2 \\sum \\sqrt{a}\\right) \\leqslant \\frac{1}{56}\\left(\\frac{\\sum \\sqrt{a}+\\sum \\sqrt{a}+\\left(48-2 \\sum \\sqrt{a}\\right)}{3}\\right)^{3}=\\frac{512}{7}\n$$\n\nby the AM-GM inequality. The conclusion follows."
] | $\frac{8}{\sqrt[3]{7}}$ |
2,037 | Combinatorics | null | $\boxed{100}$ | [
"100"
] | false | null | Numerical | null | Queenie and Horst play a game on a $20 \times 20$ chessboard. In the beginning the board is empty. In every turn, Horst places a black knight on an empty square in such a way that his new knight does not attack any previous knights. Then Queenie places a white queen on an empty square. The game gets finished when somebody cannot move.
Find the maximal positive $K$ such that, regardless of the strategy of Queenie, Horst can put at least $K$ knights on the board. | [
"We show two strategies, one for Horst to place at least 100 knights, and another strategy for Queenie that prevents Horst from putting more than 100 knights on the board.\n\nA strategy for Horst: Put knights only on black squares, until all black squares get occupied.\n\nColour the squares of the board black and white in the usual way, such that the white and black squares alternate, and let Horst put his knights on black squares as long as it is possible. Two knights on squares of the same colour never attack each other. The number of black squares is $20^{2} / 2=200$. The two players occupy the squares in turn, so Horst will surely find empty black squares in his first 100 steps.\n\nA strategy for Queenie: Group the squares into cycles of length 4, and after each step of Horst, occupy the opposite square in the same cycle.\n\nConsider the squares of the board as vertices of a graph; let two squares be connected if two knights on those squares would attack each other. Notice that in a $4 \\times 4$ board the squares can be grouped into 4 cycles of length 4 , as shown in Figure 1. Divide the board into parts of size $4 \\times 4$, and perform the same grouping in every part; this way we arrange the 400 squares of the board into 100 cycles (Figure 2).\n\n<img_3696>\n\nFigure 1\n\n<img_4002>\n\nFigure 2\n\n<img_3138>\n\nFigure 3\n\nThe strategy of Queenie can be as follows: Whenever Horst puts a new knight to a certain square $A$, which is part of some cycle $A-B-C-D-A$, let Queenie put her queen on the opposite square $C$ in that cycle (Figure 3). From this point, Horst cannot put any knight on $A$ or $C$ because those squares are already occupied, neither on $B$ or $D$ because those squares are attacked by the knight standing on $A$. Hence, Horst can put at most one knight on each cycle, that is at most 100 knights in total."
] | 100 |
2,040 | Combinatorics | null | $\boxed{k\left(4 k^{2}+k-1\right) / 2}$ | [
"$k\\left(4 k^{2}+k-1\\right) / 2$"
] | false | null | Expression | null | Let $k$ be a positive integer. The organising committee of a tennis tournament is to schedule the matches for $2 k$ players so that every two players play once, each day exactly one match is played, and each player arrives to the tournament site the day of his first match, and departs the day of his last match. For every day a player is present on the tournament, the committee has to pay 1 coin to the hotel. The organisers want to design the schedule so as to minimise the total cost of all players' stays. Determine this minimum cost. | [
"Enumerate the days of the tournament $1,2, \\ldots,\\left(\\begin{array}{c}2 k \\\\ 2\\end{array}\\right)$. Let $b_{1} \\leqslant b_{2} \\leqslant \\cdots \\leqslant b_{2 k}$ be the days the players arrive to the tournament, arranged in nondecreasing order; similarly, let $e_{1} \\geqslant \\cdots \\geqslant e_{2 k}$ be the days they depart arranged in nonincreasing order (it may happen that a player arrives on day $b_{i}$ and departs on day $e_{j}$, where $i \\neq j$ ). If a player arrives on day $b$ and departs on day $e$, then his stay cost is $e-b+1$. Therefore, the total stay cost is\n\n$$\n\\Sigma=\\sum_{i=1}^{2 k} e_{i}-\\sum_{i=1}^{2 k} b_{i}+n=\\sum_{i=1}^{2 k}\\left(e_{i}-b_{i}+1\\right)\n$$\n\nBounding the total cost from below. To this end, estimate $e_{i+1}-b_{i+1}+1$. Before day $b_{i+1}$, only $i$ players were present, so at most $\\left(\\begin{array}{l}i \\\\ 2\\end{array}\\right)$ matches could be played. Therefore, $b_{i+1} \\leqslant\\left(\\begin{array}{l}i \\\\ 2\\end{array}\\right)+1$. Similarly, at most $\\left(\\begin{array}{l}i \\\\ 2\\end{array}\\right)$ matches could be played after day $e_{i+1}$, so $e_{i} \\geqslant\\left(\\begin{array}{c}2 k \\\\ 2\\end{array}\\right)-\\left(\\begin{array}{c}i \\\\ 2\\end{array}\\right)$. Thus,\n\n$$\ne_{i+1}-b_{i+1}+1 \\geqslant\\left(\\begin{array}{c}\n2 k \\\\\n2\n\\end{array}\\right)-2\\left(\\begin{array}{c}\ni \\\\\n2\n\\end{array}\\right)=k(2 k-1)-i(i-1)\n$$\n\nThis lower bound can be improved for $i>k$ : List the $i$ players who arrived first, and the $i$ players who departed last; at least $2 i-2 k$ players appear in both lists. The matches between these players were counted twice, though the players in each pair have played only once. Therefore, if $i>k$, then\n\n$$\ne_{i+1}-b_{i+1}+1 \\geqslant\\left(\\begin{array}{c}\n2 k \\\\\n2\n\\end{array}\\right)-2\\left(\\begin{array}{l}\ni \\\\\n2\n\\end{array}\\right)+\\left(\\begin{array}{c}\n2 i-2 k \\\\\n2\n\\end{array}\\right)=(2 k-i)^{2}\n$$\n\nAn optimal tournament, We now describe a schedule in which the lower bounds above are all achieved simultaneously. Split players into two groups $X$ and $Y$, each of cardinality $k$. Next, partition the schedule into three parts. During the first part, the players from $X$ arrive one by one, and each newly arrived player immediately plays with everyone already present. During the third part (after all players from $X$ have already departed) the players from $Y$ depart one by one, each playing with everyone still present just before departing.\n\nIn the middle part, everyone from $X$ should play with everyone from $Y$. Let $S_{1}, S_{2}, \\ldots, S_{k}$ be the players in $X$, and let $T_{1}, T_{2}, \\ldots, T_{k}$ be the players in $Y$. Let $T_{1}, T_{2}, \\ldots, T_{k}$ arrive in this order; after $T_{j}$ arrives, he immediately plays with all the $S_{i}, i>j$. Afterwards, players $S_{k}$, $S_{k-1}, \\ldots, S_{1}$ depart in this order; each $S_{i}$ plays with all the $T_{j}, i \\leqslant j$, just before his departure, and $S_{k}$ departs the day $T_{k}$ arrives. For $0 \\leqslant s \\leqslant k-1$, the number of matches played between $T_{k-s}$ 's arrival and $S_{k-s}$ 's departure is\n\n$$\n\\sum_{j=k-s}^{k-1}(k-j)+1+\\sum_{j=k-s}^{k-1}(k-j+1)=\\frac{1}{2} s(s+1)+1+\\frac{1}{2} s(s+3)=(s+1)^{2}\n$$\n\nThus, if $i>k$, then the number of matches that have been played between $T_{i-k+1}$ 's arrival, which is $b_{i+1}$, and $S_{i-k+1}$ 's departure, which is $e_{i+1}$, is $(2 k-i)^{2}$; that is, $e_{i+1}-b_{i+1}+1=(2 k-i)^{2}$, showing the second lower bound achieved for all $i>k$.\n\nIf $i \\leqslant k$, then the matches between the $i$ players present before $b_{i+1}$ all fall in the first part of the schedule, so there are $\\left(\\begin{array}{l}i \\\\ 2\\end{array}\\right)$ such, and $b_{i+1}=\\left(\\begin{array}{l}i \\\\ 2\\end{array}\\right)+1$. Similarly, after $e_{i+1}$, there are $i$ players left, all $\\left(\\begin{array}{l}i \\\\ 2\\end{array}\\right)$ matches now fall in the third part of the schedule, and $e_{i+1}=\\left(\\begin{array}{c}2 k \\\\ 2\\end{array}\\right)-\\left(\\begin{array}{l}i \\\\ 2\\end{array}\\right)$. The first lower bound is therefore also achieved for all $i \\leqslant k$.\n\nConsequently, all lower bounds are achieved simultaneously, and the schedule is indeed optimal.\n\nEvaluation. Finally, evaluate the total cost for the optimal schedule:\n\n$$\n\\begin{aligned}\n\\Sigma & =\\sum_{i=0}^{k}(k(2 k-1)-i(i-1))+\\sum_{i=k+1}^{2 k-1}(2 k-i)^{2}=(k+1) k(2 k-1)-\\sum_{i=0}^{k} i(i-1)+\\sum_{j=1}^{k-1} j^{2} \\\\\n& =k(k+1)(2 k-1)-k^{2}+\\frac{1}{2} k(k+1)=\\frac{1}{2} k\\left(4 k^{2}+k-1\\right)\n\\end{aligned}\n$$",
"Consider any tournament schedule. Label players $P_{1}, P_{2}, \\ldots, P_{2 k}$ in order of their arrival, and label them again $Q_{2 k}, Q_{2 k-1}, \\ldots, Q_{1}$ in order of their departure, to define a permutation $a_{1}, a_{2}, \\ldots, a_{2 k}$ of $1,2, \\ldots, 2 k$ by $P_{i}=Q_{a_{i}}$.\n\nWe first describe an optimal tournament for any given permutation $a_{1}, a_{2}, \\ldots, a_{2 k}$ of the indices $1,2, \\ldots, 2 k$. Next, we find an optimal permutation and an optimal tournament.\n\nOptimisation for a fixed $a_{1}, \\ldots, a_{2 k}$. We say that the cost of the match between $P_{i}$ and $P_{j}$ is the number of players present at the tournament when this match is played. Clearly, the Committee pays for each day the cost of the match of that day. Hence, we are to minimise the total cost of all matches.\n\nNotice that $Q_{2 k}$ 's departure does not precede $P_{2 k}$ 's arrival. Hence, the number of players at the tournament monotonically increases (non-strictly) until it reaches $2 k$, and then monotonically decreases (non-strictly). So, the best time to schedule the match between $P_{i}$ and $P_{j}$ is either when $P_{\\max (i, j)}$ arrives, or when $Q_{\\max \\left(a_{i}, a_{j}\\right)}$ departs, in which case the cost is $\\min \\left(\\max (i, j), \\max \\left(a_{i}, a_{j}\\right)\\right)$.\n\nConversely, assuming that $i>j$, if this match is scheduled between the arrivals of $P_{i}$ and $P_{i+1}$, then its cost will be exactly $i=\\max (i, j)$. Similarly, one can make it cost $\\max \\left(a_{i}, a_{j}\\right)$. Obviously, these conditions can all be simultaneously satisfied, so the minimal cost for a fixed sequence $a_{1}, a_{2}, \\ldots, a_{2 k}$ is\n\n$$\n\\Sigma\\left(a_{1}, \\ldots, a_{2 k}\\right)=\\sum_{1 \\leqslant i<j \\leqslant 2 k} \\min \\left(\\max (i, j), \\max \\left(a_{i}, a_{j}\\right)\\right)\n$$\n\nOptimising the sequence $\\left(a_{i}\\right)$. Optimisation hinges on the lemma below.\n\nLemma. If $a \\leqslant b$ and $c \\leqslant d$, then\n\n$$\n\\begin{aligned}\n\\min (\\max (a, x), \\max (c, y))+\\min & (\\max (b, x), \\max (d, y)) \\\\\n& \\geqslant \\min (\\max (a, x), \\max (d, y))+\\min (\\max (b, x), \\max (c, y))\n\\end{aligned}\n$$\n\nProof. Write $a^{\\prime}=\\max (a, x) \\leqslant \\max (b, x)=b^{\\prime}$ and $c^{\\prime}=\\max (c, y) \\leqslant \\max (d, y)=d^{\\prime}$ and check that $\\min \\left(a^{\\prime}, c^{\\prime}\\right)+\\min \\left(b^{\\prime}, d^{\\prime}\\right) \\geqslant \\min \\left(a^{\\prime}, d^{\\prime}\\right)+\\min \\left(b^{\\prime}, c^{\\prime}\\right)$.\n\nConsider a permutation $a_{1}, a_{2}, \\ldots, a_{2 k}$ such that $a_{i}<a_{j}$ for some $i<j$. Swapping $a_{i}$ and $a_{j}$ does not change the $(i, j)$ th summand in (1), and for $\\ell \\notin\\{i, j\\}$ the sum of the $(i, \\ell)$ th and the $(j, \\ell)$ th summands does not increase by the Lemma. Hence the optimal value does not increase, but the number of disorders in the permutation increases. This process stops when $a_{i}=2 k+1-i$ for all $i$, so the required minimum is\n\n$$\n\\begin{aligned}\nS(2 k, 2 k-1, \\ldots, 1) & =\\sum_{1 \\leqslant i<j \\leqslant 2 k} \\min (\\max (i, j), \\max (2 k+1-i, 2 k+1-j)) \\\\\n& =\\sum_{1 \\leqslant i<j \\leqslant 2 k} \\min (j, 2 k+1-i)\n\\end{aligned}\n$$\n\nThe latter sum is fairly tractable and yields the stated result; we omit the details."
] | $k\left(4 k^{2}+k-1\right) / 2$ |
2,045 | Geometry | null | $\boxed{t(0,4]}$ | [
"$t(0,4]$"
] | false | null | Interval | null | A circle $\omega$ of radius 1 is given. A collection $T$ of triangles is called good, if the following conditions hold:
(i) each triangle from $T$ is inscribed in $\omega$;
(ii) no two triangles from $T$ have a common interior point.
Determine all positive real numbers $t$ such that, for each positive integer $n$, there exists a good collection of $n$ triangles, each of perimeter greater than $t$. | [
"First, we show how to construct a good collection of $n$ triangles, each of perimeter greater than 4 . This will show that all $t \\leqslant 4$ satisfy the required conditions.\n\nConstruct inductively an $(n+2)$-gon $B A_{1} A_{2} \\ldots A_{n} C$ inscribed in $\\omega$ such that $B C$ is a diameter, and $B A_{1} A_{2}, B A_{2} A_{3}, \\ldots, B A_{n-1} A_{n}, B A_{n} C$ is a good collection of $n$ triangles. For $n=1$, take any triangle $B A_{1} C$ inscribed in $\\omega$ such that $B C$ is a diameter; its perimeter is greater than $2 B C=4$. To perform the inductive step, assume that the $(n+2)$-gon $B A_{1} A_{2} \\ldots A_{n} C$ is already constructed. Since $A_{n} B+A_{n} C+B C>4$, one can choose a point $A_{n+1}$ on the small arc $\\widehat{C A_{n}}$, close enough to $C$, so that $A_{n} B+A_{n} A_{n+1}+B A_{n+1}$ is still greater than 4 . Thus each of these new triangles $B A_{n} A_{n+1}$ and $B A_{n+1} C$ has perimeter greater than 4 , which completes the induction step.\n\n<img_3904>\n\nWe proceed by showing that no $t>4$ satisfies the conditions of the problem. To this end, we assume that there exists a good collection $T$ of $n$ triangles, each of perimeter greater than $t$, and then bound $n$ from above.\n\nTake $\\varepsilon>0$ such that $t=4+2 \\varepsilon$.\n\nClaim. There exists a positive constant $\\sigma=\\sigma(\\varepsilon)$ such that any triangle $\\Delta$ with perimeter $2 s \\geqslant 4+2 \\varepsilon$, inscribed in $\\omega$, has area $S(\\Delta)$ at least $\\sigma$.\n\nProof. Let $a, b, c$ be the side lengths of $\\Delta$. Since $\\Delta$ is inscribed in $\\omega$, each side has length at most 2. Therefore, $s-a \\geqslant(2+\\varepsilon)-2=\\varepsilon$. Similarly, $s-b \\geqslant \\varepsilon$ and $s-c \\geqslant \\varepsilon$. By Heron's formula, $S(\\Delta)=\\sqrt{s(s-a)(s-b)(s-c)} \\geqslant \\sqrt{(2+\\varepsilon) \\varepsilon^{3}}$. Thus we can set $\\sigma(\\varepsilon)=\\sqrt{(2+\\varepsilon) \\varepsilon^{3}}$.\n\nNow we see that the total area $S$ of all triangles from $T$ is at least $n \\sigma(\\varepsilon)$. On the other hand, $S$ does not exceed the area of the disk bounded by $\\omega$. Thus $n \\sigma(\\varepsilon) \\leqslant \\pi$, which means that $n$ is bounded from above."
] | $t(0,4]$ |
2,063 | Algebra | null | $\boxed{k=2 n-1}$ | [
"$k=2 n-1$"
] | false | null | Expression | null | Let $n$ be a positive integer. Find the smallest integer $k$ with the following property: Given any real numbers $a_{1}, \ldots, a_{d}$ such that $a_{1}+a_{2}+\cdots+a_{d}=n$ and $0 \leqslant a_{i} \leqslant 1$ for $i=1,2, \ldots, d$, it is possible to partition these numbers into $k$ groups (some of which may be empty) such that the sum of the numbers in each group is at most 1 . | [
"If $d=2 n-1$ and $a_{1}=\\cdots=a_{2 n-1}=n /(2 n-1)$, then each group in such a partition can contain at most one number, since $2 n /(2 n-1)>1$. Therefore $k \\geqslant 2 n-1$. It remains to show that a suitable partition into $2 n-1$ groups always exists.\n\nWe proceed by induction on $d$. For $d \\leqslant 2 n-1$ the result is trivial. If $d \\geqslant 2 n$, then since\n\n$$\n\\left(a_{1}+a_{2}\\right)+\\ldots+\\left(a_{2 n-1}+a_{2 n}\\right) \\leqslant n\n$$\n\nwe may find two numbers $a_{i}, a_{i+1}$ such that $a_{i}+a_{i+1} \\leqslant 1$. We \"merge\" these two numbers into one new number $a_{i}+a_{i+1}$. By the induction hypothesis, a suitable partition exists for the $d-1$ numbers $a_{1}, \\ldots, a_{i-1}, a_{i}+a_{i+1}, a_{i+2}, \\ldots, a_{d}$. This induces a suitable partition for $a_{1}, \\ldots, a_{d}$.",
"We will show that it is even possible to split the sequence $a_{1}, \\ldots, a_{d}$ into $2 n-1$ contiguous groups so that the sum of the numbers in each groups does not exceed 1. Consider a segment $S$ of length $n$, and partition it into segments $S_{1}, \\ldots, S_{d}$ of lengths $a_{1}, \\ldots, a_{d}$, respectively, as shown below. Consider a second partition of $S$ into $n$ equal parts by $n-1$ \"empty dots\".\n\n<img_3272>\n\nAssume that the $n-1$ empty dots are in segments $S_{i_{1}}, \\ldots, S_{i_{n-1}}$. (If a dot is on the boundary of two segments, we choose the right segment). These $n-1$ segments are distinct because they have length at most 1 . Consider the partition:\n\n$$\n\\left\\{a_{1}, \\ldots, a_{i_{1}-1}\\right\\},\\left\\{a_{i_{1}}\\right\\},\\left\\{a_{i_{1}+1}, \\ldots, a_{i_{2}-1}\\right\\},\\left\\{a_{i_{2}}\\right\\}, \\ldots\\left\\{a_{i_{n-1}}\\right\\},\\left\\{a_{i_{n-1}+1}, \\ldots, a_{d}\\right\\}\n$$\n\nIn the example above, this partition is $\\left\\{a_{1}, a_{2}\\right\\},\\left\\{a_{3}\\right\\},\\left\\{a_{4}, a_{5}\\right\\},\\left\\{a_{6}\\right\\}, \\varnothing,\\left\\{a_{7}\\right\\},\\left\\{a_{8}, a_{9}, a_{10}\\right\\}$. We claim that in this partition, the sum of the numbers in this group is at most 1.\n\nFor the sets $\\left\\{a_{i_{t}}\\right\\}$ this is obvious since $a_{i_{t}} \\leqslant 1$. For the sets $\\left\\{a_{i_{t}}+1, \\ldots, a_{i_{t+1}-1}\\right\\}$ this follows from the fact that the corresponding segments lie between two neighboring empty dots, or between an endpoint of $S$ and its nearest empty dot. Therefore the sum of their lengths cannot exceed 1.",
"First put all numbers greater than $\\frac{1}{2}$ in their own groups. Then, form the remaining groups as follows: For each group, add new $a_{i} \\mathrm{~s}$ one at a time until their sum exceeds $\\frac{1}{2}$. Since the last summand is at most $\\frac{1}{2}$, this group has sum at most 1 . Continue this procedure until we have used all the $a_{i}$ s. Notice that the last group may have sum less than $\\frac{1}{2}$. If the sum of the numbers in the last two groups is less than or equal to 1, we merge them into one group. In the end we are left with $m$ groups. If $m=1$ we are done. Otherwise the first $m-2$ have sums greater than $\\frac{1}{2}$ and the last two have total sum greater than 1 . Therefore $n>(m-2) / 2+1$ so $m \\leqslant 2 n-1$ as desired."
] | $k=2 n-1$ |
2,064 | Combinatorics | null | $\boxed{2013}$ | [
"2013"
] | false | null | Numerical | null | In the plane, 2013 red points and 2014 blue points are marked so that no three of the marked points are collinear. One needs to draw $k$ lines not passing through the marked points and dividing the plane into several regions. The goal is to do it in such a way that no region contains points of both colors.
Find the minimal value of $k$ such that the goal is attainable for every possible configuration of 4027 points. | [
"Firstly, let us present an example showing that $k \\geqslant 2013$. Mark 2013 red and 2013 blue points on some circle alternately, and mark one more blue point somewhere in the plane. The circle is thus split into 4026 arcs, each arc having endpoints of different colors. Thus, if the goal is reached, then each arc should intersect some of the drawn lines. Since any line contains at most two points of the circle, one needs at least 4026/2 $=2013$ lines.\n\nIt remains to prove that one can reach the goal using 2013 lines. First of all, let us mention that for every two points $A$ and $B$ having the same color, one can draw two lines separating these points from all other ones. Namely, it suffices to take two lines parallel to $A B$ and lying on different sides of $A B$ sufficiently close to it: the only two points between these lines will be $A$ and $B$.\n\nNow, let $P$ be the convex hull of all marked points. Two cases are possible.\n\nCase 1. Assume that $P$ has a red vertex $A$. Then one may draw a line separating $A$ from all the other points, pair up the other 2012 red points into 1006 pairs, and separate each pair from the other points by two lines. Thus, 2013 lines will be used.\n\nCase 2. Assume now that all the vertices of $P$ are blue. Consider any two consecutive vertices of $P$, say $A$ and $B$. One may separate these two points from the others by a line parallel to $A B$. Then, as in the previous case, one pairs up all the other 2012 blue points into 1006 pairs, and separates each pair from the other points by two lines. Again, 2013 lines will be used.",
"Let us present a different proof of the fact that $k=2013$ suffices. In fact, we will prove a more general statement:\n\nIf $n$ points in the plane, no three of which are collinear, are colored in red and blue arbitrarily, then it suffices to draw $\\lfloor n / 2\\rfloor$ lines to reach the goal.\n\nWe proceed by induction on $n$. If $n \\leqslant 2$ then the statement is obvious. Now assume that $n \\geqslant 3$, and consider a line $\\ell$ containing two marked points $A$ and $B$ such that all the other marked points are on one side of $\\ell$; for instance, any line containing a side of the convex hull works.\n\nRemove for a moment the points $A$ and $B$. By the induction hypothesis, for the remaining configuration it suffices to draw $\\lfloor n / 2\\rfloor-1$ lines to reach the goal. Now return the points $A$ and $B$ back. Three cases are possible.\n\nCase 1. If $A$ and $B$ have the same color, then one may draw a line parallel to $\\ell$ and separating $A$ and $B$ from the other points. Obviously, the obtained configuration of $\\lfloor n / 2\\rfloor$ lines works.\n\nCase 2. If $A$ and $B$ have different colors, but they are separated by some drawn line, then again the same line parallel to $\\ell$ works.\n\n\n\nCase 3. Finally, assume that $A$ and $B$ have different colors and lie in one of the regions defined by the drawn lines. By the induction assumption, this region contains no other points of one of the colors - without loss of generality, the only blue point it contains is $A$. Then it suffices to draw a line separating $A$ from all other points.\n\nThus the step of the induction is proved."
] | 2013 |
2,075 | Number Theory | null | $\boxed{f(n)=n}$ | [
"$f(n)=n$"
] | false | null | Expression | null | Let $\mathbb{Z}_{>0}$ be the set of positive integers. Find all functions $f: \mathbb{Z}_{>0} \rightarrow \mathbb{Z}_{>0}$ such that
$$
m^{2}+f(n) \mid m f(m)+n
$$
for all positive integers $m$ and $n$. | [
"Setting $m=n=2$ tells us that $4+f(2) \\mid 2 f(2)+2$. Since $2 f(2)+2<2(4+f(2))$, we must have $2 f(2)+2=4+f(2)$, so $f(2)=2$. Plugging in $m=2$ then tells us that $4+f(n) \\mid 4+n$, which implies that $f(n) \\leqslant n$ for all $n$.\n\nSetting $m=n$ gives $n^{2}+f(n) \\mid n f(n)+n$, so $n f(n)+n \\geqslant n^{2}+f(n)$ which we rewrite as $(n-1)(f(n)-n) \\geqslant 0$. Therefore $f(n) \\geqslant n$ for all $n \\geqslant 2$. This is trivially true for $n=1$ also.\n\nIt follows that $f(n)=n$ for all $n$. This function obviously satisfies the desired property.",
"Setting $m=f(n)$ we get $f(n)(f(n)+1) \\mid f(n) f(f(n))+n$. This implies that $f(n) \\mid n$ for all $n$.\n\nNow let $m$ be any positive integer, and let $p>2 m^{2}$ be a prime number. Note that $p>m f(m)$ also. Plugging in $n=p-m f(m)$ we learn that $m^{2}+f(n)$ divides $p$. Since $m^{2}+f(n)$ cannot equal 1, it must equal $p$. Therefore $p-m^{2}=f(n) \\mid n=p-m f(m)$. But $p-m f(m)<p<2\\left(p-m^{2}\\right)$, so we must have $p-m f(m)=p-m^{2}$, i.e., $f(m)=m$.",
"Plugging $m=1$ we obtain $1+f(n) \\leqslant f(1)+n$, so $f(n) \\leqslant n+c$ for the constant $c=$ $f(1)-1$. Assume that $f(n) \\neq n$ for some fixed $n$. When $m$ is large enough (e.g. $m \\geqslant \\max (n, c+1)$ ) we have\n\n$$\nm f(m)+n \\leqslant m(m+c)+n \\leqslant 2 m^{2}<2\\left(m^{2}+f(n)\\right)\n$$\n\nso we must have $m f(m)+n=m^{2}+f(n)$. This implies that\n\n$$\n0 \\neq f(n)-n=m(f(m)-m)\n$$\n\nwhich is impossible for $m>|f(n)-n|$. It follows that $f$ is the identity function."
] | $f(n)=n$ |