# Compare sum of squares between two sets of numbers

I have two sets of numbers satisfying: $x_1+x_2+...+x_n >= y_1+y_2+...+y_n$ Whether it is the case: $x_1^2+x_2^2+...+x_n^2 >= y_1^2+y_2^2+...+y_n^2$ ($x_i^2$ presents the square of xi). $x_i, y_i$ here are not negative numbers.

• Clearly not. Take $0<x_i<-y_i$. – Mark Viola Nov 23 '16 at 16:06
• I edited my question. Numbers here are not negative – Mr Black Nov 23 '16 at 16:14

This is incorrect. Consider for example $x_1 = \ldots = x_n = 1$, $y_1 = n$ and $y_2 = \ldots y_n = 0$.

Generally speaking, if $x_1 + \ldots + x_n = K$ are nonnegative numbers, then $x_1^2 + \ldots + x_n^2$ can assume any value between $\frac{K^2}{n}$ and $K^2$. The lower bound is attained iff all $x_1$ are equal to $\frac{K}{n}$ and the upper bound is achieved for $x_1 = K$, $x_2 = \ldots = x_n = 0$.

I have a WRONG approach to this problem but I don't know what is wrong, Since

$x_{1}+x_{2}\ldots+x_{n}\ge y_{1}+y_{2}\ldots+y_{n}$

We take integral of both side, due to the Monotony of integral:

$\frac{1}{2}\int(x_{1}+x_{2}\ldots+x_{n})dx \ge \frac{1}{2}\int(y_{1}+y_{2}\ldots+y_{n})dy$

This is a linear combination so:

$\frac{1}{2}\int x_{1}dx_{1}+\ldots +\frac{1}{2}\int x_{n}dx_{n} \ge \frac{1}{2}\int y_{1}dy_{1}+\ldots +\frac{1}{2}\int y_{n}dy_{n}$

Thus

$x_{1}^2+x_{2}^2+\ldots+x_{n}^2 \ge y_{1}^2+y_{2}^2+\ldots+y_{n}^2$

What is wrong here?

• Check: You're integrating wrt what over what domain? – Macavity Nov 23 '16 at 17:46
• @Macavity I'm integrating wrt to random variables x and y in domain [0,+oo]. If I write this way: $\sum x \ge \sum y => \int \sum x \ge \int \sum y$ – Gehua Zhang Nov 23 '16 at 19:43
• And why do you think that would hold true? – Macavity Nov 24 '16 at 1:05