A. Summations
Exercises
A.1-1
Any function belonging to is upper bounded by . Using the definition of the big O notation, implies for some real constant and all . Define and . For all (assuming
The asymptotic variable on both sides is whilst is essentially fixed. Regardless how we substitute those functions on the left, their sum is asymptotically bounded from above by a corresponding sum of upper bounds as .
This equation is frequently employed in analysis of algorithms. Suppose our algorithm consists of sections whose running times are , and . The total time is commensurate with their sum, which by our equation is .
A.1-2
A.1-3
A.1-4
Notice that our infinite series is absolutely convergent, since it transforms into a decreasing geometric series with . Consequently, we can even rearrange the terms, although the derivation below only relies on the linearity of convergent series. Denote the original sum as S, thus
A.1-5
The upper bound is
The lower bound demands more work, as we drop half of the terms and try to bound a partial sum.
Theorem 3.1 implies that .
A.1-6
Differentiating both sides of the infinite geometric series (A.11) gives
A.1-7 🌟
The upper bound is
The lower bound can be attained by splitting the summation as in Exercise A.1-5 assuming , so that .
Theorem 3.1 implies that .
★ A.1-8 🌟
Equations (A.8) and (A.9) are our starting points.
We will keep all constants and bundle them under single O(1) only in the last step for better visibility. Observe that for all real constants , and . Let us multiply the leftmost and rightmost expressions by 2.
★ A.1-9 🌟
We have an infinite sum similar to the one in (A.11) with . The linearity property also applies to infinite convergent series, but first we must prove that our series converges. For the sake of variety, let’s use the direct comparison test. The infinite sum in (A.11) converges for the given , thus we can use it as a reference. For all it is indeed true that , so our series converges.
First we will use the linearity property of summations and afterward apply (A.11) and (A.7).
★ A.1-10 🌟
If , then the result is zero, so assume that . Let , since .
The story is similar to the previous exercise, although we cannot use the same convergence test. The limit comparison test turns out to be appropriate. We will again use the sum in (A.11) as a reference (using instead of ), since we know it converges. All terms in both sums are positive (recall that ), so we can calculate the limit.
According to the test, our sum converges. We can now proceed exactly as in the previous exercise.
We have tweaked the starting index for in the expansion, hence that extra -1. After reversing the initial substitution we get
★ A.1-11 🌟
Observe that all terms of the product are positive. Therefore, we can convert a formula with a product to a formula with a summation by using the identity from the book.
A.2-1
is a monotonically decreasing function, so we can use integral approximation (A.19) to bound the summation.
A.2-2
A.2-3
The idea is to split the range 1 to n into pieces and lower-bound the contribution of each piece by 1/2. The pieces are the same as in the case of calculating the upper bound. The only difference is that the representative (pivot) of each piece is instead of for . Furthermore, some pieces may be missing in the last segment (for ), but this is OK for getting the lower bound.
A.2-4
is monotonically increasing, so we can use integral approximation (A.18) to bound the summation.
A.2-5
We would have an improper integral, since f(k) is undefined for .
Problems
A-1 Bounding summations
a.
b.
The upper bound is
The lower bound is
Theorem 3.1 implies that .
c.
The upper bound is
The lower bound is
Theorem 3.1 implies that .
Last updated