An olympiad-like inequality I found this problem in my old paper :

Let $f(x)$ be a convex function on $(0,\infty)$ such that $\forall x>0$ we have $f(x)>0$ and $n\geq 3$ a natural number then we have :
  $$\Big(f(1)^{f(1)}f(2)^{f(2)}\cdots f(n)^{f(n)}\Big)^{\frac{1}{f(1)+f(2)+\cdots + f(n)}}+\Big(f(1)f(2)\cdots f(n)\Big)^{\frac{1}{n}}\leq f(1)+f(n) $$

I try to use Jensen's inequality we have :
$$\ln\Big( \Big(f(1)^{f(1)}f(2)^{f(2)}\cdots f(n)^{f(n)}\Big)^{\frac{1}{f(1)+f(2)+\cdots + f(n)}} \Big)\leq \ln\Big(\frac{f^2(1)+f^2(2)+\cdots+f^2(n)}{f(1)+f(2)+\cdots+f(n)}\Big)$$
Remains to show this :
$$\ln\Big(\frac{f^2(1)+f^2(2)+\cdots+f^2(n)}{f(1)+f(2)+\cdots+f(n)}\Big)\leq \ln\Big(f(1)+f(n)-\Big(f(1)f(2)\cdots f(n)\Big)^{\frac{1}{n}}\Big)$$
This last inequality is true for $f(x)=e^x$ but certainly not for $f(x)=x$
Furthermore this result recall me the Mercer's inequality (see here)
Finally If the function $f(x)$ is concave and positive the inequality of the beginning is reversed .
I think it's too hard for an maths competition but you can use the tools you want .
I prefer hints as answer.
Thanks a lot for sharing your time and knowledge .
Edit :
Ooops I don't mentionned that the case $n=2$ is special it correspond to this
New bound for Am-Gm of 2 variables
Second edit :
I disturbed me a little bit but I think we can add the following constraint.
I add the fact that $\ln(f(x))$ must be concave on $(0,\infty)$.If it's doesn't work too can someone prove the inequality for $f(x)=x\alpha$ where $\alpha>0$ ?
Thanks again !
 A: I think that the inequality is not true for $n=3$ and
$$f(x) = \mathrm{e}^{ax^2 + bx + c}$$
where
\begin{align}
a &= -\frac{1}{2}\ln 10 + \frac{1}{2}\ln 800 - \ln \frac{3}{20} \approx 4.088133303, \\
b &= \frac{5}{2}\ln 10 - \frac{3}{2}\ln 800 + 4 \ln \frac{3}{20} \approx -11.85893480, \\
c &= -3\ln 10 + \ln 800 - 3\ln \frac{3}{20} \approx 5.468216404.
\end{align}
Explanation:
First, we have $f''(x) = \mathrm{e}^{ax^2 + bx + c}(4a^2x^2 + 4abx + b^2 + 2a)$.
It is easy to prove that $f''(x) > 0$ for $x > 0$.
Thus, $f(x)$ is a convex function on $(0, \infty)$. Also $f(x) > 0$ is obvious.
Second, we have $f(1) = \frac{1}{10}, \ f(2) = \frac{3}{20}, \ f(3) = 800$.
For convenience, denote $A = f(1), \ B = f(2), \ C = f(3)$.
By using Maple software, it is easy to check that
\begin{align}
(A+B+C) \ln (A + C - (ABC)^{1/3}) - \Big(A\ln A + B\ln B + C\ln C\Big)
\approx -0.007135.
\end{align}
This disproves the inequality.
A: Hint: Normalize both sides by $\sum_i f(i)$ and take a look at case $n=3$: 

Red axis corresponds to $\frac{f_2}{\sum_i f_i}$, green axis to $\frac{f_1}{\sum_i f_i}$, point $N = (\frac{1}{n},...,\frac{1}{n})$ corresponds to $f_1=f_2=...=f_n$, all points to the left of $N$ - to the convex sequences $\{f_i\}$, the curved surface corresponds to the normalized left hand side, hyperplane - to the normalized right hand side. 
Rigorous proof will involve a study of the geometry of the surface given by the image of the set $\{w \in \mathbb{R}^n : \sum_i w_i = 1\}$ (simplex) under the map $w \to \prod_i w_i^{w_i} + \prod_i w_i^\frac{1}{n}$.
Detailed argument: (to be finished)


*

*Slight change of notation: 


\begin{equation}
    f_i := f(i) \quad w_i := \frac{f_i}{\sum_i f_i}.
\end{equation}
Our inequality becomes
\begin{equation}
\prod_i f_i ^{w_i} + \prod_i f_i^\frac{1}{n} \leq f_1 + f_n.
\end{equation}


*Divide both sides of inequality by $\sum_i f_i$:


\begin{equation}
 \prod_i w_i^{w_i} + \prod_i w_i^\frac{1}{n} \leq w_1 + w_n.
\end{equation}
One can recognize entropy probability ($\exp(-H(w))$ where $H(w)$ is the entropy of distribution $w$) and geometric mean in the functions on the left side.
\begin{equation}
    E(w) := \prod_i w_i^{w_i} \quad  G(w) := \prod_i w_i^\frac{1}{n}.
\end{equation}


*Left hand side has a critical point $\bar w = (\frac{1}{n},...,\frac{1}{n})$. 

*Study of Hessian evaluated at this $\bar w$.

*Study the behavior of $L(\lambda; w^*) = E(\lambda \bar w + (1-\lambda) w^*)+G(\lambda \bar w + (1-\lambda) w^*)$ depending on $w^*$.

*...some more math gymnastics...

*Q.E.D.!

