Let $a_1,\ldots,a_n$ and $b_1\ldots,b_n$ be $2n$ real numbers. Prove that there exists an integer $k$ with $1\le k\le n$ such that $ \sum_{i=1}^n|a_i-a_k| ~~\le~~ \sum_{i=1}^n|b_i-a_k|.$ (Proposed by Gerhard Woeginger, Austria)
Problem
Source: MMC 2014 Problem 1
Tags: induction, inequalities, triangle inequality, algebra, n-variable inequality
09.06.2014 14:51
WLOG assume an ordering. Say $a_1\ge a_2\ge \cdots \ge a_n$ and $b_1\ge b_2\ge \cdots \ge b_n$. Now we induct on $n$. Clearly, $n=1$ is trivial. Now we come to proving the inductive step. We have some cases. Case-1: $b_n\le a_n$. Then by induction there is a $1\le k\le n-1$ for the set of $2n-2$ reals excluding $b_n,a_n$ such that : ${\sum_{i=1}^{n-1} |b_i-a_k| \ge \sum_{i=1}^{n-1}|a_i-a_k|}$ And we have $b_n\le a_n\le a_k$ hence $|a_n-a_k|\le |b_n-a_k|$ thus see that $a_k$ works for $2n$ as well. Case-2: $a_1\le b_1$ Then there is $2\le k\le n$ such that $\sum_{i=2}^{n}|a_i-a_k|\le \sum_{i=2}^{n}|b_i-b_k|$ and we also have $a_k\le a_1\le b_1$ hence $|a_1-a_k|\le |b_1-b_k|$, and thus we are done for this case also. Case-3: For all $i$, $a_n\le b_i\le a_1$ Let $\sum_{i=1}^{n}|a_i-x|=f(x)$ and $\sum_{i=1}^{n}|b_i-x|=g(x)$. See that $f(a_1)+f(a_n)=g(a_1)+g(a_n)=n(a_1-a_n)$. Now suppose $f(a_1)>g(a_1),f(a_n)>g(a_n)$ then we reach a contradiction then there is $1\le k\le n$ such that $f(a_k)\le g(a_k)$ in this case here $k=1$ or $n$. Thus proved in all cases.$\blacksquare$
13.06.2014 18:37
Suppose that $ a_1 \le a_2 \le ... \le a_n $ and $ b_1 \le b_2 \le ... \le b_n $ Now, notice that $ |a_i-a_1|+|a_i-a_n|=a_n-a_1 \le |b_j-a_1|+|b_j-a_n| $ for $ 1\le i,j \le n $ (by using triangle inequality) Therefore, the statement must be true for $ k=1 $ or $ k=n $.
16.06.2015 13:11
Yes.To be more precise if $a_s,a_l$ be the smallest and largest of the $a_i$'s and $b_s,b_l$ be the smallest and largest of the $b_i$'s then $|a_l-a_i|+|a_i-a_s|=a_l-a_s \le |b_i-a_l|+|b_i-a_s|$.Summing over all $i$ we get $\sum_{i=1}^{n}{|a_i-a_l|}+\sum_{i=1}^{n}{|a_i-a_s|} \le \sum_{i=1}^{n}{|b_i-a_l|}+\sum_{i=1}^{n}{|b_i-a_s|}$.Thus $k=s$ or $k=l$.