Functional inequality $\sum_{1\le i
Let $n\in\mathbb N, n\ge 2$. Does there exist a set of non-zero real numbers $a_1, a_2,..,a_n$ with this condition:
If function $f: \mathbb R \rightarrow \mathbb R$ satisfies the  inequality
$$\sum_{1\le i<j\le n}f(x_i+x_j)\ge \frac{n(n-1)}{2}f(a_1x_1+a_2x_2+...+a_nx_n)$$
for all real numbers $x_1, x_2,..,x_n$ then it is constant.
I have no idea how to solve this problem.

Proof added below the original answer, using the same idea and notation.

Change variables so that $x_i = y_i/2$ and $a_i = b_i/2$.  Then we want a set $b_1,\dots,b_n$ such that 

(average of function at all the points $\frac{y_i + y_j}{2}) \geq f(\sum b_i y_i)$ 

implies that the function is constant.
A natural guess is that this could be true if all the $b_i$ are different, so that by permuting the $y$'s we generate $n!$ inequalities on $f(x)$ and these could constrain things.
I guess that we also need $\sum b_i = 1$ since otherwise a sufficiently convex function or its negative might satisfy the inequality.
If $\sum b_i = 1$ and some of the $b$'s are larger than $1/2$, for example if $b_1 = 1$ and all others are $0$, then the average of $f$ at the points $(y_i + y_j)/2$ should be intermediate between the values at the "more extreme" combinations with $b_i$ as weights, but the inequality requires the average to be larger than all of the $b$-combinations, and this would force constancy.  
Thus I conjecture that the answer is that for positive $b$'s the property holds whenever $\sum b_i =1$ and some $b_i > 1/2$.  If this conjecture is too strong, then taking $b_1 \in (\frac{1}{2},1)$ and $b_1 + b_2 = 1$ with all other $b_i$ equal to $0$, should work. 

Here is an outline of a proof for $b_1 > 3/4$ and all other $b_i > 0$ with $\sum b_i = 1$. 
Let $X_n$ be the $n$-tuple of $x_i$ in which we set $x_1=+1$, $x_n = -1$ and all other $x_i = 0$. 
All values of $(x_i + x_j)/2$ are in $[-\frac{1}{2},\frac{1}{2}]$.  However the maximum ($M$) and minimum ($m$) values of $\sum b_i x_{\pi(i)}$ for $\pi$ a permutation of $\lbrace 1,2,3,\dots,n \rbrace$ are bigger than $1/2$ in absolute value.  On the interval $[m,M]$, because of the inequality on $f(x)$ there is an interior point $c \in (m,M)$ (the value of $(x_i+x_j)/2$ at which $f$ is largest) for which $f(c) \geq \max (f(m), f(M))$.  By taking other sets $aX_n + b$ the same property is true for all intervals on the real line.
Therefore $f(x)$ has the property that for every interval $[m,M]$ with $M > m$, there exists a point $c \in (m,M)$ with $f(c) \geq \max(f(m),f(M))$.  This is an extremely strong constraint on a function, it implies there is no interval on which the function is strictly monotonic.  For any function with enough points of continuity it implies the function is constant.  There are functions discontinous at all rational points that have this property.
Thus in any "reasonable" class of functions the only solutions are constant.  
For $n=2$ the inequality (with $b_1 > 3/4$) implies the function is constant without any conditions.  It is probably also true for larger $n$ that no condition is necessary.  Having isolated discontinuities is sufficient, for all $n$, to force $f$ constant.
