See also GeometricSums .
Here we explain by example a simple way to get an upper bound on a sum.
For example, consider the sum
We can bound this sum from above as follows:
Thus, the sum is O(n2).
In general, a sum of n terms is at most n times the maximum term.
We can use a similar trick to bound the sum from below. We use the fact that the sum is at least the sum of its n/2 largest terms:
Thus, the sum is Ω(n2).