# Is there a way to change the order of these summation terms

$$\sum_{K=2}^{N}\sum_{L=1}^{\lfloor\frac{K}{2}\rfloor-1}$$

I want to have the $L$ summation on the outside and the $K$ summation on the inside somehow. Can this be done?

-
Are these $L$ and $K$ finite sum terms? What happens when you expand the sum fully? Can you regroup the terms? –  abiessu Aug 11 '13 at 4:52
I tried that and couldn't find any clean way to do it –  user2175923 Aug 11 '13 at 4:53
For any fixed value of $L$, $K$ travels from $2L$ to $N$, So the inner sum is $\sum_{K=2L}^N$. –  André Nicolas Aug 11 '13 at 4:53
I tried that already; it led me to make the outer sum L=1 to floor(N/2) which is wrong –  user2175923 Aug 11 '13 at 4:58

## 1 Answer

$$\sum_{k=2}^Na_k\sum_{j=1}^{[\frac{k}{2}]-1}b_j=a_4(b_1)+a_5(b_1)+a_6(b_1+b_2)+a_7(b_1+b_2)+a_8(b_1+b_2+b_3)...$$ $$=b_1(a_4+a_5+a_6...a_N)+b_2(a_6+a_7+a_8+...a_N)+b_3(a_8+a_9+a_{10}...+a_N)...$$ $$=\sum_{k=1}^{[\frac{N}{2}]-1}b_k\sum_{j=2(k+1)}^{N}a_j$$

So that we get,

$$\sum_{k=2}^Na_k\sum_{j=1}^{[\frac{k}{2}]-1}b_j=\sum_{k=1}^{[\frac{N}{2}]-1}b_k\sum_{j=2(k+1)}^{N}a_j$$

-
This is not correct –  user2175923 Aug 11 '13 at 5:08
Why is this not correct? –  Ethan Aug 11 '13 at 5:09
Try sample N=10, then try adding up +1 for each iteration of the inner loop. Correct one gives you 16, the rewrite gives 25 –  user2175923 Aug 11 '13 at 5:12
You get 16 with the new one? k=1 to 5. so j=2 to 10, 4 to 10, 6 to 10, 8 to 10, 10 to 10. That's 9+7+5+3+1=25 –  user2175923 Aug 11 '13 at 5:17
It looks like the mistake is on my end. My inner bound is not floor(K/2) but rather floor(K/2)-1 –  user2175923 Aug 11 '13 at 5:21