An Introduction to Summation Notation (or, Everything About Summation Notation You Need for the Test, and Then Some) Remember that summation notation (using ∑ to write a sum rather than a bunch of + symbols) is basically a convenient form of shorthand. For instance, the following sum is read as “the sum over i from one to five of two i”, and is a shorthand for the sum 2(1) + 2(2) + 2(3) + 2(4) + 2(5), which can also be written as 2 + 4 + 6 + 8 + 10. Therefore we may write As another example, we have 7 i 2 12 2 2 3 2 4 2 5 2 6 2 7 2 140 i 1 We also might want to go the other way, that is, given a sum like 2+5+8+11+14, we might want to write the sum in sigma notation. In this case we have five terms, so we would start off with, say, We now want to find the function f that belongs to the right of the sum. Looking at our series, we see that the first term must be 2, so we require that f(1) = 2. Similarly the second term must be 5, so we require that f(2) = 5. We also require that f(3) = 8, f(4) = 11, and f(5) = 14. What sort of function meets these requirements? Maybe the answer is clear, but if not we might try graphing the ordered pairs (i, f(i)) and see if we detect a pattern: 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 Y-Values 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 Clearly this is a linear function, and if it’s still not clear from the graph what function this is, a bit of analysis will show us that the slope is 3 (because, e.g., ) and that the y-intercept is -1. Therefore this function is , and we can now conclude that Of course, we could have written this sum in a number of different ways; for instance, if we were feeling particularly masochistic, we could have written although since the coefficients were rounded to three decimal places the answer won’t be exact (but it could be made so, if we really wanted to put in the effort). In fact, we could in theory find an infinite number of functions for which f(1) = 2, f(2) = 5, …, f(5) = 14, and any of them would be a correct answer. Nor was it necessary that we start with i=1. We could have selected any value of i. For instance, if we started from i=0 we would have that f(0) = 2, f(1) = 5, …, f(4) = 14. We could plot those points as well: Note that the slope is still the same, but now the y-intercept is 2. Thus the desired equation is now f(x) = 3x+2, and we have Neither of the forms and is better than the other; both are completely accurate, and by changing the indices to other numbers we could alter the look yet again, but all of them would still describe the same sum. Now that we’re more comfortable with summation notation, we might want to answer a few questions: Q: What if i doesn’t appear in the sum, e.g., as in ? A: No problem. In this case [the constant function] and we have f(1)=3, f(2)=3, f(3)=3, f(4)=3, and so on. Thus we have Q: Do we have to use i as the index? A: No. In fact, we frequently use j or k as an index as well. For instance, if we were working with complex numbers, where i could refer to the square root of negative one, it would be confusing and improper to have i as an index as well. Mathematically and are exactly equivalent. Q: What about when we have a constant like n in our summation, e.g., as in ? A: We treat it just like we would any other constant like, for instance, 10. The only difference is that we can’t write out the entire expression without using either sigma notation or ellipses. We might write the above as And that’s the best we can do, unless we do a bit of algebraic manipulation to show that . The form is called a closed- form expression, and is usually preferable to either half of the equation above, but unfortunately closed form expressions (a) don’t always exist and (b) aren’t always easy to find. For instance, most of the time we will be using summation notation in this class to refer to random data points which, by virtue of their randomness, would not be expected to follow some nice, easily described function.