# Necessary and sufficient conditions for weighted sum

Fix positive numbers $x_1,\dots,x_n$ with $\sum_{i=1}^nx_i=1$. For any positive numbers $a_1\leq\dots\leq a_n$, we define $$Y=a_1x_1+\dots+a_nx_n,$$ and $y_i=\frac{a_ix_i}{Y}$for all $1\leq i\leq n$.

What are all the possible sequences $(y_1,\dots,y_n)$, i.e., sequences that appear as $(y_1,\dots,y_n)$ for some $a_1\leq\dots\leq a_n$? Are there some succinct sufficient or necessary conditions?

For example, one necessary condition is $y_1\leq x_1$. This is because $$y_1=\frac{a_1x_1}{a_1x_1+\dots+a_nx_n}\leq\frac{a_1x_1}{a_1x_1+\dots+a_1x_n}=x_1.$$ Similarly it is necessary that $y_n\geq x_n$. Are these two together already sufficient?

• I don't have any precise set of conditions (honestly, I don't think it is possible to express them simply), but the two conditions you mentioned are not sufficient. Consider the sequence $x_1, \dots, x_4 = 1/4, \dots, 1/4$, and the coefficients $a_i = i$. The sequence $(y_i)$ satisfies your two conditions, but so does the sequence ($y_1, y_3, y_2, y_4$). – Mariuslp Aug 24 '16 at 15:54
• @Mariuslp I take your point that the two conditions that I mentioned are not sufficient. So for $(x_1,\dots,x_4)=(1/4,\dots,1/4)$, the sequence $(y_i)$ that can appear are exactly those with $y_1\le y_2\le y_3\le y_4$, right? This is a simple condition for this particular case. – pi66 Aug 24 '16 at 16:44
• If all the $x_i$ are equal to some $x$, then yes, because your $y_i$ are defined by $y_i = K\cdot a_i$, (with $K = \frac xY \geq 0$) and the sequences that satisfy your conditions are the ones such that the $a_i$ are increasing with $i$, which is (in this case) equivalent to the $y_i$ increasing with $i$ – Mariuslp Aug 24 '16 at 22:57
• It's necessary and sufficient that $y_i/x_i \le y_j/x_j$ for all $i < j$. I'm not sure what other kind of condition you would want... – arghbleargh Aug 26 '16 at 0:00
• @arghbleargh : There are two more conditions needed. – Michael Aug 28 '16 at 14:50

Fix a vector $(x_1, ..., x_n)$ with positive entries. Then $(y_1, ..., y_n)$ is a vector that satisfies the requirements with respect to $(x_1, ..., x_n)$ if and only if it satisfies the following three conditions:
1) $y_i>0$ for all $i \in \{1, ..., n\}$.
2) $\frac{y_i}{x_i} \leq \frac{y_{i+1}}{x_{i+1}}$ for all $i \in \{1, ..., n-1\}$.
3) $\sum_{i=1}^n y_i = 1$.