{"year": "2003", "tier": "T3", "problem_label": "1", "problem_type": null, "exam": "BalticWay", "problem": "Let $\\mathbb{Q}_{+}$be the set of positive rational numbers. Find all functions $f: \\mathbb{Q}_{+} \\rightarrow \\mathbb{Q}_{+}$which for all $x \\in \\mathbb{Q}_{+}$fulfil\n\n(1) $f\\left(\\frac{1}{x}\\right)=f(x)$\n\n(2) $\\left(1+\\frac{1}{x}\\right) f(x)=f(x+1)$", "solution": "Set $g(x)=\\frac{f(x)}{f(1)}$. Function $g$ fulfils (1), (2) and $g(1)=1$. First we prove that if $g$ exists then it is unique. We prove that $g$ is uniquely defined on $x=\\frac{p}{q}$ by induction on $\\max (p, q)$. If $\\max (p, q)=1$ then $x=1$ and $g(1)=1$. If $p=q$ then $x=1$ and $g(x)$ is unique. If $p \\neq q$ then we can assume (according to (1)) that $p>q$. From (2) we get $g\\left(\\frac{p}{q}\\right)=\\left(1+\\frac{q}{p-q}\\right) g\\left(\\frac{p-q}{q}\\right)$. The induction assumption and $\\max (p, q)>\\max (p-q, q) \\geq 1$ now give that $g\\left(\\frac{p}{q}\\right)$ is unique.\n\nDefine the function $g$ by $g\\left(\\frac{p}{q}\\right)=p q$ where $p$ and $q$ are chosen such that $\\operatorname{gcd}(p, q)=1$. It is easily seen that $g$ fulfils (1), (2) and $g(1)=1$. All functions fulfilling (1) and (2) are therefore $f\\left(\\frac{p}{q}\\right)=a p q$, where $\\operatorname{gcd}(p, q)=1$ and $a \\in \\mathbb{Q}_{+}$.", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n1.", "solution_match": "\nSolution:"}} {"year": "2003", "tier": "T3", "problem_label": "2", "problem_type": null, "exam": "BalticWay", "problem": "Prove that any real solution of\n\n$$\nx^{3}+p x+q=0\n$$\n\nsatisfies the inequality $4 q x \\leq p^{2}$.", "solution": "Let $x_{0}$ be a root of the qubic, then $x^{3}+p x+q=\\left(x-x_{0}\\right)\\left(x^{2}+a x+b\\right)=$ $x^{3}+\\left(a-x_{0}\\right) x^{2}+\\left(b-a x_{0}\\right) x-b x_{0}$. So $a=x_{0}, p=b-a x_{0}=b-x_{0}^{2},-q=b x_{0}$. Hence $p^{2}=b^{2}-2 b x_{0}^{2}+x_{0}^{4}$. Also $4 x_{0} q=-4 x_{0}^{2} b$. So $p^{2}-4 x_{0} q=b^{2}+2 b x_{0}^{2}+x_{0}^{4}=\\left(b+x_{0}^{2}\\right)^{2} \\geq 0$.", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n2.", "solution_match": "\nSolution:"}} {"year": "2003", "tier": "T3", "problem_label": "2", "problem_type": null, "exam": "BalticWay", "problem": "Prove that any real solution of\n\n$$\nx^{3}+p x+q=0\n$$\n\nsatisfies the inequality $4 q x \\leq p^{2}$.", "solution": "As the equation $x_{0} x^{2}+p x+q=0$ has a root $\\left(x=x_{0}\\right)$, we must have $D \\geq 0 \\Leftrightarrow p^{2}-4 q x_{0} \\geq 0$. (Also the equation $x^{2}+p x+q x_{0}=0$ having the root $x=x_{0}^{2}$ can be considered.)", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n2.", "solution_match": "\nSolution 2:"}} {"year": "2003", "tier": "T3", "problem_label": "3", "problem_type": null, "exam": "BalticWay", "problem": "Let $x, y$ and $z$ be positive real numbers such that $x y z=1$. Prove that\n\n$$\n(1+x)(1+y)(1+z) \\geq 2\\left(1+\\sqrt[3]{\\frac{y}{x}}+\\sqrt[3]{\\frac{z}{y}}+\\sqrt[3]{\\frac{x}{z}}\\right)\n$$", "solution": "Put $a=b x, b=c y$ and $c=a z$. The given inequality then takes the form\n\n$$\n\\begin{aligned}\n\\left(1+\\frac{a}{b}\\right)\\left(1+\\frac{b}{c}\\right)\\left(1+\\frac{c}{a}\\right) & \\geq 2\\left(1+\\sqrt[3]{\\frac{b^{2}}{a c}}+\\sqrt[3]{\\frac{c^{2}}{a b}}+\\sqrt[3]{\\frac{a^{2}}{b c}}\\right) \\\\\n& =2\\left(1+\\frac{a+b+c}{3 \\sqrt[3]{a b c}}\\right) .\n\\end{aligned}\n$$\n\nBy the AM-GM inequality we have\n\n$$\n\\begin{aligned}\n\\left(1+\\frac{a}{b}\\right)\\left(1+\\frac{b}{c}\\right)\\left(1+\\frac{c}{a}\\right) & =\\frac{a+b+c}{a}+\\frac{a+b+c}{b}+\\frac{a+b+c}{c}-1 \\\\\n& \\geq 3\\left(\\frac{a+b+c}{\\sqrt[3]{a b c}}\\right)-1 \\geq 2 \\frac{a+b+c}{\\sqrt[3]{a b c}}+3-1=2\\left(1+\\frac{a+b+c}{\\sqrt[3]{a b c}}\\right) .\n\\end{aligned}\n$$", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n3.", "solution_match": "\nSolution:"}} {"year": "2003", "tier": "T3", "problem_label": "3", "problem_type": null, "exam": "BalticWay", "problem": "Let $x, y$ and $z$ be positive real numbers such that $x y z=1$. Prove that\n\n$$\n(1+x)(1+y)(1+z) \\geq 2\\left(1+\\sqrt[3]{\\frac{y}{x}}+\\sqrt[3]{\\frac{z}{y}}+\\sqrt[3]{\\frac{x}{z}}\\right)\n$$", "solution": "Expanding the left side we obtain\n\n$$\nx+y+z+\\frac{1}{x}+\\frac{1}{y}+\\frac{1}{z} \\geq 2\\left(\\sqrt[3]{\\frac{y}{x}}+\\sqrt[3]{\\frac{z}{y}}+\\sqrt[3]{\\frac{x}{z}}\\right)\n$$\n\nAs $\\sqrt[3]{\\frac{y}{x}} \\leq \\frac{1}{3}\\left(y+\\frac{1}{x}+1\\right)$ etc., it suffices to prove that\n\n$$\nx+y+z+\\frac{1}{x}+\\frac{1}{y}+\\frac{1}{z} \\geq \\frac{2}{3}\\left(x+y+z+\\frac{1}{x}+\\frac{1}{y}+\\frac{1}{z}\\right)+2\n$$\n\nwhich follows from $a+\\frac{1}{a} \\geq 2$.", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n3.", "solution_match": "\nSolution 2:"}} {"year": "2003", "tier": "T3", "problem_label": "4", "problem_type": null, "exam": "BalticWay", "problem": "Let $a, b, c$ be positive real numbers. Prove that\n\n$$\n\\frac{2 a}{a^{2}+b c}+\\frac{2 b}{b^{2}+c a}+\\frac{2 c}{c^{2}+a b} \\leq \\frac{a}{b c}+\\frac{b}{c a}+\\frac{c}{a b} .\n$$", "solution": "First we prove that\n\n$$\n\\frac{2 a}{a^{2}+b c} \\leq \\frac{1}{2}\\left(\\frac{1}{b}+\\frac{1}{c}\\right)\n$$\n\nwhich is equivalent to $0 \\leq b(a-c)^{2}+c(a-b)^{2}$, and therefore holds true. Now we turn to the inequality\n\n$$\n\\frac{1}{b}+\\frac{1}{c} \\leq \\frac{1}{2}\\left(\\frac{2 a}{b c}+\\frac{b}{c a}+\\frac{c}{a b}\\right),\n$$\n\nwhich by multiplying by $2 a b c$ is seen to be equivalent to $0 \\leq(a-b)^{2}+(a-c)^{2}$. Hence we have proved that\n\nAnalogously we have\n\n$$\n\\frac{2 a}{a^{2}+b c} \\leq \\frac{1}{4}\\left(\\frac{2 a}{b c}+\\frac{b}{c a}+\\frac{c}{a b}\\right) .\n$$\n\n$$\n\\begin{aligned}\n\\frac{2 b}{b^{2}+c a} & \\leq \\frac{1}{4}\\left(\\frac{2 b}{c a}+\\frac{c}{a b}+\\frac{a}{b c}\\right) \\\\\n\\frac{2 c}{c^{2}+a b} & \\leq \\frac{1}{4}\\left(\\frac{2 c}{a b}+\\frac{a}{b c}+\\frac{b}{c a}\\right)\n\\end{aligned}\n$$\n\nand it suffices to sum the above three inequalities.", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n4.", "solution_match": "\nSolution:"}} {"year": "2003", "tier": "T3", "problem_label": "4", "problem_type": null, "exam": "BalticWay", "problem": "Let $a, b, c$ be positive real numbers. Prove that\n\n$$\n\\frac{2 a}{a^{2}+b c}+\\frac{2 b}{b^{2}+c a}+\\frac{2 c}{c^{2}+a b} \\leq \\frac{a}{b c}+\\frac{b}{c a}+\\frac{c}{a b} .\n$$", "solution": "As $a^{2}+b c \\geq 2 a \\sqrt{b c}$ etc., it is sufficient to prove that\n\n$$\n\\frac{1}{\\sqrt{b c}}+\\frac{1}{\\sqrt{a c}}+\\frac{1}{\\sqrt{a b}} \\leq \\frac{a}{b c}+\\frac{b}{c a}+\\frac{c}{a b}\n$$\n\nwhich can be obtained by \"inserting\" $\\frac{1}{a}+\\frac{1}{b}+\\frac{1}{c}$ between the left side and the right side.", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n4.", "solution_match": "\nSolution 2:"}} {"year": "2003", "tier": "T3", "problem_label": "5", "problem_type": null, "exam": "BalticWay", "problem": "A sequence $\\left(a_{n}\\right)$ is defined as follows: $a_{1}=\\sqrt{2}, a_{2}=2$, and $a_{n+1}=a_{n} a_{n-1}^{2}$ for $n \\geq 2$. Prove that for every $n \\geq 1$ we have\n\n$$\n\\left(1+a_{1}\\right)\\left(1+a_{2}\\right) \\cdots\\left(1+a_{n}\\right)<(2+\\sqrt{2}) a_{1} a_{2} \\cdots a_{n} .\n$$", "solution": "First we prove inductively that for $n \\geq 1, a_{n}=2^{2^{n-2}}$. We have $a_{1}=2^{2^{-1}}$, $a_{2}=2^{2^{0}}$ and\n\n$$\na_{n+1}=2^{2^{n-2}} \\cdot\\left(2^{2^{n-3}}\\right)^{2}=2^{2^{n-2}} \\cdot 2^{2^{n-2}}=2^{2^{n-1}} .\n$$\n\nSince $1+a_{1}=1+\\sqrt{2}$, we must prove, that\n\n$$\n\\left(1+a_{2}\\right)\\left(1+a_{3}\\right) \\cdots\\left(1+a_{n}\\right)<2 a_{2} a_{3} \\cdots a_{n} .\n$$\n\nThe right-hand side is equal to\n\n$$\n2^{1+2^{0}+2^{1}+\\cdots+2^{n-2}}=2^{2^{n-1}}\n$$\n\nand the left-hand side\n\n$$\n\\begin{aligned}\n\\left(1+2^{2^{0}}\\right) & \\left(1+2^{2^{1}}\\right) \\cdots\\left(1+2^{2^{n-2}}\\right) \\\\\n& =1+2^{2^{0}}+2^{2^{1}}+2^{2^{0}+2^{1}}+2^{2^{2}}+\\cdots+2^{2^{0}+2^{1}+\\cdots+2^{n-2}} \\\\\n& =1+2+2^{2}+2^{3}+\\cdots+2^{2^{n-1}-1} \\\\\n& =2^{2^{n-1}}-1 .\n\\end{aligned}\n$$\n\nThe proof is complete.", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n5.", "solution_match": "\nSolution:"}} {"year": "2003", "tier": "T3", "problem_label": "6", "problem_type": null, "exam": "BalticWay", "problem": "Let $n \\geq 2$ and $d \\geq 1$ be integers with $d \\mid n$, and let $x_{1}, x_{2}, \\ldots, x_{n}$ be real numbers such that $x_{1}+x_{2}+\\cdots+x_{n}=0$. Prove that there are at least $\\left(\\begin{array}{l}n-1 \\\\ d-1\\end{array}\\right)$ choices of $d$ indices $1 \\leq i_{1}10000$, so $a \\cdot b \\notin X$. So $X$ may have 9901 elements.\n\nSuppose that $x_{1}1$ and consider the pairs\n\n$$\n\\begin{gathered}\n200-x_{1},\\left(200-x_{1}\\right) \\cdot x_{1} \\\\\n200-x_{2},\\left(200-x_{2}\\right) \\cdot x_{2} \\\\\n\\vdots \\\\\n200-x_{k},\\left(200-x_{k}\\right) \\cdot x_{k}\n\\end{gathered}\n$$\n\nClearly $x_{1}2 b+p-2 k$ and $p$ is a prime, we conclude $2 b+p+2 k=p^{2}$ and $2 b+p-2 k=1$. By adding these equations we get $2 b+p=\\frac{p^{2}+1}{2}$ and then $b=\\left(\\frac{p-1}{2}\\right)^{2}$, so $a=b+p=\\left(\\frac{p+1}{2}\\right)^{2}$. By checking we conclude that all the solutions are $(a, b)=\\left(\\left(\\frac{p+1}{2}\\right)^{2},\\left(\\frac{p-1}{2}\\right)^{2}\\right)$ with $p$ a prime greater than 2 .", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n16.", "solution_match": "\nSolution:"}} {"year": "2003", "tier": "T3", "problem_label": "16", "problem_type": null, "exam": "BalticWay", "problem": "Find all pairs of positive integers $(a, b)$ such that $a-b$ is a prime and $a b$ is a perfect square. Answer: Pairs $(a, b)=\\left(\\left(\\frac{p+1}{2}\\right)^{2},\\left(\\frac{p-1}{2}\\right)^{2}\\right)$, where $p$ is a prime greater than 2 .", "solution": "Let $p$ be a prime such that $a-b=p$ and let $a b=k^{2}$. We have $(b+p) b=k^{2}$, so $\\operatorname{gcd}(b, b+p)=\\operatorname{gcd}(b, p)$ is equal either to 1 or $p$. If $\\operatorname{gcd}(b, b+p)=p$, let $b=b_{1} p$. Then $p^{2} b_{1}\\left(b_{1}+1\\right)=k^{2}, b_{1}\\left(b_{1}+1\\right)=m^{2}$, but this equation has no solutions.\n\nHence $\\operatorname{gcd}(b, b+p)=1$, and\n\n$$\nb=u^{2} \\quad b+p=v^{2}\n$$\n\nso that $p=v^{2}-u^{2}=(v+u)(v-u)$. This in turn implies that $v-u=1$ and $v+u=p$, from which we finally obtain $a=\\left(\\frac{p+1}{2}\\right)^{2}, b=\\left(\\frac{p-1}{2}\\right)^{2}$, where $p$ must be an odd prime.", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n16.", "solution_match": "\nSolution 2:"}} {"year": "2003", "tier": "T3", "problem_label": "17", "problem_type": null, "exam": "BalticWay", "problem": "All the positive divisors of a positive integer $n$ are stored into an array in increasing order. Mary has to write a program which decides for an arbitrarily chosen divisor $d>1$ whether it is a prime. Let $n$ have $k$ divisors not greater than $d$. Mary claims that it suffices to check divisibility of $d$ by the first $\\lceil k / 2\\rceil$ divisors of $n$ : If a divisor of $d$ greater than 1 is found among them, then $d$ is composite, otherwise d is prime. Is Mary right?\n\nAnswer: Yes, Mary is right.", "solution": "Let $d>1$ be a divisor of $n$. Suppose Mary's program outputs \"composite\" for $d$. That means it has found a divisor of $d$ greater than 1 . Since $d>1$, the array contains at least 2 divisors of $d$, namely 1 and $d$. Thus Mary's program does not check divisibility of $d$ by $d$ (the first half gets complete before reaching $d$ ) which means that the divisor found lays strictly between 1 and $d$. Hence $d$ is composite indeed.\n\nSuppose now $d$ being composite. Let $p$ be its smallest prime divisor; then $\\frac{d}{p} \\geq p$ or, equivalently, $d \\geq p^{2}$. As $p$ is a divisor of $n$, it occurs in the array. Let $a_{1}, \\ldots, a_{k}$ all divisors of $n$ smaller than $p$. Then $p a_{1}, \\ldots, p a_{k}$ are less than $p^{2}$ and hence less than $d$.\n\nAs $a_{1}, \\ldots, a_{k}$ are all relatively prime with $p$, all the numbers $p a_{1}, \\ldots, p a_{k}$ divide $n$. The numbers $a_{1}, \\ldots, a_{k}, p a_{1}, \\ldots, p a_{k}$ are pairwise different by construction. Thus there are at least $2 k+1$ divisors of $n$ not greater than $d$. So Mary's program checks divisibility of $d$ by at least $k+1$ smallest divisors of $n$, among which it finds $p$, and outputs \"composite\".", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n17.", "solution_match": "\nSolution:"}} {"year": "2003", "tier": "T3", "problem_label": "18", "problem_type": null, "exam": "BalticWay", "problem": "Every integer is coloured with exactly one of the colours BLUE, GREEN, RED, YELLOW. Can this be done in such a way that if $a, b, c, d$ are not all 0 and have the same colour, then $3 a-2 b \\neq 2 c-3 d$ ?\n\nAnswer: Yes.", "solution": "A colouring with the required property can be defined as follows. For a non-zero integer $k$ let $k^{*}$ be the integer uniquely defined by $k=5^{m} \\cdot k^{*}$, where $m$ is a nonnegative integer and $5 \\nmid k^{*}$. We also define $0^{*}=0$. Two non-zero integers $k_{1}, k_{2}$ receive the same colour if and only if $k_{1}^{*} \\equiv k_{2}^{*}(\\bmod 5)$; we assign 0 any colour.\n\nAssume $a, b, c, d$ has the same colour and that $3 a-2 b=2 c-3 d$, which we rewrite as $3 a-2 b-2 c+3 d=0$. Dividing both sides by the largest power of 5 which simultaneously divides $a, b, c, d$ (this makes sense since not all of $a, b, c, d$ are 0 ), we obtain\n\n$$\n3 \\cdot 5^{A} \\cdot a^{*}-2 \\cdot 5^{B} \\cdot b^{*}-2 \\cdot 5^{C} \\cdot c^{*}+3 \\cdot 5^{D} \\cdot d^{*}=0,\n$$\n\nwhere $A, B, C, D$ are nonnegative integers at least one of which is equal to 0 . The above equality implies\n\n$$\n3\\left(5^{A} \\cdot a^{*}+5^{B} \\cdot b^{*}+5^{C} \\cdot c^{*}+5^{D} \\cdot d^{*}\\right) \\equiv 0 \\quad(\\bmod 5) .\n$$\n\nAssume $a, b, c, d$ are all non-zero. Then $a^{*} \\equiv b^{*} \\equiv c^{*} \\equiv d^{*} \\not \\equiv 0(\\bmod 5)$. This implies\n\n$$\n5^{A}+5^{B}+5^{C}+5^{D} \\equiv 0 \\quad(\\bmod 5)\n$$\n\nwhich is impossible since at least one of the numbers $A, B, C, D$ is equal to 0 . If one or more of $a, b, c, d$ are 0 , we simply omit the corresponding terms from (1), and the same conclusion holds.", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n18.", "solution_match": "\nSolution:"}} {"year": "2003", "tier": "T3", "problem_label": "19", "problem_type": null, "exam": "BalticWay", "problem": "Let $a$ and $b$ be positive integers. Prove that if $a^{3}+b^{3}$ is the square of an integer, then $a+b$ is not a product of two different prime numbers.", "solution": "Suppose $a+b=p q$, where $p \\neq q$ are two prime numbers. We may assume that $p \\neq 3$. Since\n\n$$\na^{3}+b^{3}=(a+b)\\left(a^{2}-a b+b^{2}\\right)\n$$\n\nis a square, the number $a^{2}-a b+b^{2}=(a+b)^{2}-3 a b$ must be divisible by $p$ and $q$, whence $3 a b$ must be divisible by $p$ and $q$. But $p \\neq 3$, so $p \\mid a$ or $p \\mid b$; but $p \\mid a+b$, so $p \\mid a$ and $p \\mid b$. Write $a=p k, b=p \\ell$ for some integers $k, \\ell$. Notice that $q=3$, since otherwise, repeating the above argument, we would have $q|a, q| b$ and $a+b>p q)$. So we have\n\n$$\n3 p=a+b=p(k+\\ell)\n$$\n\nand we conclude that $a=p, b=2 p$ or $a=2 p, b=p$. Then $a^{3}+b^{3}=9 p^{3}$ is obviously not a square, a contradiction.", "metadata": {"resource_path": "BalticWay/segmented/en-bw03sol.jsonl", "problem_match": "\n19.", "solution_match": "\nSolution:"}} {"year": "2003", "tier": "T3", "problem_label": "20", "problem_type": null, "exam": "BalticWay", "problem": "Let $n$ be a positive integer such that the sum of all the positive divisors of $n$ (except $n$ ) plus the number of these divisors is equal to $n$. Prove that $n=2 m^{2}$ for some integer $m$.", "solution": "Let $t_{1}