Sums can be concisely written using the upper-case Greek letter sigma. For example,
is read, "The sum, for i from 1 to 4, of 2i2." This is:
Often the upper limit of the index (written above the sigma) is some other variable involved in the analysis, such as n. For example, in Section C.3, we will see a formula for the sum of the first n positive integers:
In order to wrangle an expression into a form for which we have a formula, it is often useful to add or remove terms. For example:
Substitution of variables is another useful technique. For example, to evaluate the sum
we define n = 2m. Then:
Sum notation is sometimes used more casually. For example, to describe the total value of all of the cars on a sales lot, we might write:
Part I: Object-Oriented Programming
Encapsulation
Polymorphism
Inheritance
Part II: Linear Structures
Stacks and Queues
Array-Based Structures
Linked Structures
Part III: Algorithms
Analysis of Algorithms
Searching and Sorting
Recursion
Part IV: Trees and Sets
Trees
Sets
Part V: Advanced Topics
Advanced Linear Structures
Strings
Advanced Trees
Graphs
Memory Management
Out to the Disk
Part VI: Appendices
A. Review of Java
B. Unified Modeling Language
C. Summation Formulae
D. Further Reading
Index