I'm trying to solve this problem. Could someone please help?. Thanks.

x and y are row vectors having non-negative elements. The elements of x are arranged in the increasing order of magnitude. The positions of elements of y can be re-arranged. How can I show that xy' is maximum when the elements of y are also arranged in the increasing order of magnitude?

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

Here is a suggestion to get you started. First consider the case where there are only two x's and two y's, i.e. the dimension of the vectors is 2. See if you can prove that case. Then you may be able to use that result to help prove the more general case.

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

Thanks awkward. I went down that path and proved that it is true for 2 and 3 but then when I tried to use induction method, I couldn't prove it for n+1 after assuming that it is true for n. It is very involved. Is there any theorem that we can use to prove this?

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

Instead of induction, you might try an indirect proof. Suppose the statement is false. Then what?

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

I'm not sure if I understand correctly.

Do you mean that you have a finite-dimensional vector space with and then you construct

, where n is the dimension of you vector space?

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

Yes, that's essentially correct, although I don't think viewing the sum as an inner product in a vector space is going to prove useful in this case. Just think of it as a sum.

If the statement is false, then there must be a set of x's and y's where the x's are in ascending order, the y's are _not_ in ascending order, and the associated sum is maximized. There must be an i and j with i < j and . What would it do to the sum if you switched them?

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

if x_{i} ≤ x_{j} and y_{j} < y_{i}, (for i < j) then:

x_{i}y_{i} + x_{j}y_{j} ≤ x_{j}y_{i} + x_{j}y_{j} < x_{j}y_{i} + x_{j}y_{j}

the sum on the very LHS is from our supposedly "maximized" sum, and yet by switching just two terms (all the rest stay the same) we have created a "bigger sum" (on the far RHS). how can this be?

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

Your proof is not clear to me. .....How did you get the two inequlities and how do you conclude that the question is incorrect? Please help.

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

Yes, that's what it is. If you take them as vectors in vector space, I think swapping the elements of y would not change its magnitude but it will change the angle that it makes with vector x. So, the inner product will be different and could reach its maximum when the elements of y are arranged in the increasing order as well. Any thoughts mastermind2007?

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

this has nothing to do with angle!

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

It does have something to do with the angle

where is the smallest angle between and . The dot product is maximized when . In general you will not be able to make but by rearranging the elements of you are going to make as small as possible. The idea is that the two vectors will be close to one another in all the coordinates simultaneously. Ranjan is just thinking about this geometrically.

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

Thanks Vlasev. I'm still struggling to have this problem proved analytically though it seems to be correct. Any idea?

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

Ranjan, you have been told a lot already but it may be somewhat confusing. For example, what 'awkward' basically told you is to consider (for contradiction) a case where is in ascending order but is not in ascending order and their dot product is maximum. Deveno is not showing the the question is incorrect but is working out what 'awkward' suggested.

Here is a slightly different view. We'll show that if is not in ascending order, we can sort it a little bit (by swapping elements) to make it more so in ascending order and keep the dot product either the same or larger.

Suppose that you are given in ascending order and not in ascending order. Then there must be entries for which but . This is essentially a statement that is not sorted. Now we sort a little bit by swapping these two entries. Call this new vector . It is the same as but now and . How much better is the dot product with ? Well, we can check by taking the difference

This happens because when . This equals

Now because is in an ascending order and we have

That is, sorting by swapping tow elements that are in the wrong order makes the dot product at least as big as the initial product. Since the vectors have finitely many entries, we can continue sorting like this until we have all its entries in ascending order. The procedure above shows that the dot product stays the same (at worst) or increases a bit (if ). I hope this clarifies things for you.

Re: I'm trying to solve this problem. Could someone please help?. Thanks.

Thanks Vlasev. That's really a nice proof.