How to prove this inequality $\sum_{i=1}^{n}\left(x^k_{i}\ln{x_{i}}\ln{\frac{x_{i}}{n}}\right)\le 0$ 
Let $x_{i}\ge 0$ for $i\in\{1,2,\cdots,n\}$ and $x_{1}+x_{2}+\cdots+x_{n}=n$ for $n\ge 3$
Show that for all strictly positive integers $k\ge2$ the following inequality holds :
  $$\sum_{i=1}^{n}x^k_{i}\ln{x_{i}}\ln{\dfrac{x_{i}}{n}}\le 0$$

We consider
$$f(x)=x^k\ln{x}\ln{\dfrac{x}{n}}$$
Then
$$f'(x)=kx^{k-1}\ln{x}\cdot\ln{\dfrac{x}{n}}+x^{k-1}\ln{\dfrac{x}{n}}+\dfrac{x^{k-1}}{n}\ln{x}$$
$$\Longrightarrow 
f''(x)=k(k-1)x^{k-2}\cdot\ln{x}\cdot\ln{\dfrac{x}{n}}+kx^{k-2}\ln{\dfrac{x}{n}}+\dfrac{kx^{k-2}}{n}\ln{x}+(k-1)x^{k-2}\ln{\dfrac{x}{n}}+\dfrac{x^{k-2}}{n}+\dfrac{k-1}{n}x^{k-2}\ln{x}+\dfrac{x^{k-2}}{n}.$$
Unfortunatly I can't know  the sign of $f''(x)$ because I want to use Jensen's Inequality to prove it.
So how can we prove this inequality ? 
 A: Firstly, you diffrentiated it wrongly:
$$f(x)=x^k\ln{x}\ln{\dfrac{x}{n}}$$
$$f'(x)=kx^{k-1}\ln{x}\ln{\dfrac{x}{n}}+x^{k-1}\ln{\dfrac{x}{n}}+x^{k-1}\ln{x}$$
$$f'(x)=x^{k-1}\left(k\ln x\ln\frac xn+\ln \frac xn+\ln x\right)$$
$$f''(x)=(k-1)x^{k-2}\left(k\ln x\ln\frac xn+\ln \frac xn+\ln x\right)+x^{k-1}\left(\frac  kx\ln\frac xn+\frac kx\ln x+\frac1x+\frac1x\right)$$
$$f''(x)=(k-1)x^{k-2}\left(k\ln x\ln\frac xn+\ln \frac xn+\ln x\right)+x^{k-2}\left(k\ln\frac xn+k\ln x+2\right)$$
$$f''(x)=x^{k-2}\left(k(k-1)\ln x\ln\frac xn+(k-1)\ln\frac xn+(k-1)\ln x+k\ln\frac xn+k\ln x+2\right)$$
$$f''(x)=x^{k-2}\left(k(k-1)\ln x\ln\frac xn+(2k-1)\ln\frac {x^2}n+2\right)$$

As $k>2$, $x^{k-2}>0$ Also $x<n$.See this graph:

A: While $x_i<=1$ or $x_i>=e$ then $x_i^k\ln^2{x_i}\ln{\dfrac{x_i}n}\ge x_i^k\ln{x_i}\ln{\dfrac{x_i}n}$
If we call $y$ $x$'s between $x_i \le 1$ or $x_i \ge e$ 
and we call $z$ $x$'s between $x_i \ge 1$ or $x_i \le e$.
After that point we write greater function then $\sum_{i=1}^{n}x^k_{i}\ln{x_{i}}$$ ( \ln{x_i}-\ln{n})$
$gf(x)=\sum_{i=1}^{n}y^k_{i}\ln^2{y_{i}}$$ ( \ln{y_i}-\ln{n}) + \sum_{i=1}^{n}z^k_{i}\ln{z_{i}}$$ ( \ln{z_i}-\ln{n})$
then write this functions positive parts 'p' negative parts 'n'
$gf(x)=\sum_{i=1}^{n}p*p*n+\sum_{i=1}^{n}p*p*n -> gf(x)=n+n=n$
That means 'gf' is negative function because it is bigger than $\sum_{i=1}^{n}x^k_{i}\ln{x_{i}}$$ ( \ln{x_i}-\ln{n})$ we prove
$\sum_{i=1}^{n}x^k_{i}\ln{x_{i}}$$ ( \ln{x_i}-\ln{n})$$\le 0$
I hope it will help.
I have better solution
$\sum_{i=1}^{n}x^k_{i}\ln{x_{i}}$$ ( \ln{x_i}-\ln{n})$$\le \lim_{a->0}\sum_{i=1}^{n}(n-a)^k\ln{(n-a)}$$ ( \ln{(n-a)}-\ln{n})$
$\lim_{a->0}\sum_{i=1}^{n}(n-a)^k\ln{(n-a)}$$ ( \ln{(n-a)}-\ln{n})\le0$
$\lim_{a->0}\sum_{i=1}^{n}(positive)*(positive)$$*(megative)\le0$
then again lesser function should satisfy that rule.
$\sum_{i=1}^{n}x^k_{i}\ln{x_{i}}$$ ( \ln{x_i}-\ln{n})$$\le 0$
It is inspired by user45... from comments.
A: I think you need to look at  $\ln\frac{x_i}{n}$ in your equation. Since, $$x_1 + x_2 + \dots + x_n = n$$
therefore $$x_i < n$$
and notice that $$\ln\frac{x_i}{n} = \ln(x_i) - \ln(n) \implies \ln\frac{x_i}{n} < 0$$
hence the expression $${x_i}^k\ln{x_i}\ln\frac{x_i}{n} < 0$$
as ${x_i}^k$ and $\ln{x_i}$ are going to be positive. Hence the sum of all negative numbers is going to be less than zero.
