0
$\begingroup$

Given a sequence of numbers $S = \langle s_1,\dots,s_n \rangle$ I want to sum all the elements of S that the index is odd.

Would the following be a good notation or is there a more compact (and better) way to write that? $\sum_{i=0,i \in 2\mathbb{N}-1}^{|S|} s_i$

Thanks!

$\endgroup$
2
  • $\begingroup$ Those would be the elements with even index. $\endgroup$ Nov 25, 2014 at 0:30
  • $\begingroup$ Yes, you are right. Just edited. $\endgroup$
    – user194174
    Nov 25, 2014 at 1:04

2 Answers 2

4
$\begingroup$

How about $\displaystyle \sum_{i=0}^{\lfloor\frac{n-1}{2}\rfloor} s_{2i+1}$?

$\endgroup$
1
  • $\begingroup$ Maybe if I simplify the upper bound! Thank you! $\endgroup$
    – user194174
    Nov 25, 2014 at 1:05
2
$\begingroup$

I think $i=0,i\in 2\mathbb N$ looks confusing. Better might be $ \displaystyle \sum_{{i=0} \atop {i \ \text{even}}}^n s_i $ or $\displaystyle\sum_{{i=0} \atop {i \ \text{odd}}}^n s_i $

$\endgroup$
1
  • $\begingroup$ Seems a good solution. Is the "i even" a notation commonly used? Thanks! $\endgroup$
    – user194174
    Nov 25, 2014 at 1:06

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .