Can we conclude that this summation is positive? The summation is:
$$S_n=n\sum_{i=0}^n x_i^2- \left ( \sum_{i=0}^nx_i\right)^2$$
where $n>1$ and $x_1,x_2,\ldots,x_n\in \mathbb{R}$.
I'm trying to prove that if $x_i\neq x_j$ for $i\neq j$ then $S>0$. 
If $n=2$, it's easy:
$$ S_2=(x_1-x_2)^2>0$$
But if $n\geq 3$ seems it's hardy to do. I thought about using induction, but I'm not be able to finish. Can someone help me?
Thanks.
 A: Let $\displaystyle \bar{x}=\frac{\sum_{i=1}^{n}x_i}{n}$
$$\sum_{i=1}^n \left(x_i-\bar{x}\right)^2=\sum_{i=1}^n \left(x_i^2+\bar{x}^2-2x_i\bar{x}\right)=\left(\sum_{i=1}^n x_i^2+n\bar{x}^2-2\bar{x}\sum_{i=1}^n x_i\right)=\left(\sum_{i=1}^n x_i^2+n\bar{x}^2-2n\bar{x}\left(\frac{\sum_{i=1}^n x_i}{n}\right)\right)=\left(\sum_{i=1}^n x_i^2+n\bar{x}^2-2n\bar{x}^2\right)=\left(\sum_{i=1}^n x_i^2-n\bar{x}^2\right)$$
So we have $$S_n=n\left(\sum_{i=1}^n x_i^2-n\left(\frac{\sum_{i=1}^n x_i}{n}\right)^2\right)=n\left(\sum_{i=1}^n x_i^2-n\bar{x}^2\right)=n\sum_{i=1}n (x_i-\bar{x})^2\ge 0$$
A: Show by expanding that your expression is equal to
$$\sum_{i\ne j}(x_i-x_j)^2.$$
That is the natural generalization of your calculation in the case $n=2$. 
Note that for positivity it is enough to have one pair $\{i,j\}$ such that $x_i\ne x_j$. 
A: Another interpretation which hides the work.
Consider a uniform random variable such that $X(n) = x_i$.
Recall that $$Var(X) = E[(X-\mu)^2] = E[X^2] - E[X]^2 = \sum \frac{x_i^2}{n} - \left( \sum \frac{x_i} {n} \right)^2$$
Multiply by $n^2$ to get your expression. Since Variance is always non-negative by definition (expected value of non-negative values), hence your expression is non-negative.
Since variance is positive if the values are not all equal, hence the condition that $x_i \neq x_j$ means that the expression is positive.
A: This question is not quite a duplicate of this one, but it's fairly close.
