## Unit10Summation

### Subsection10.1Sequences

We already briefly discussed sequences. When working with sums and the "Sigma" notation for summations, you need to be able to write formulas for sequences you understand intuitively. For example, if you want to write the sequence $$7, 9, 11, 13, \ldots$$ in the notation $$\{ b_n : n \geq 1 \}\text{,}$$ so that $$b_1 = 7\text{,}$$$$b_2 = 9$$ and so on, one choice would be to say,

Let $$\{ b_n : n \geq 1 \}$$ be the sequence defined by $$b_n := 5 + 2n\text{.}$$

The subscript $$n$$ is called the index

(plural: indices). Indexing can begin at any natural number. In this case, as is most common, we began at $$n=1\text{.}$$ Defining $$\{ b_n : n \geq 3 \}$$ by $$b_n := 1 + 2n$$ yields the same sequence: $$7, 9, 11, 13, \ldots\text{.}$$

Secondly, the informal notation $$7, 9, 11, 13, \ldots$$ is not mathematically precise because it assumes we all agree exactly what the pattern is. Producing a formula for the $$n^{th}$$ term removes any ambiguity. A formula is often necessary if you want to sum the sequence or to use it to define other sequences. This section considers some common types of sequences and gives you some practice writing a formula for the general term.

Write a formula for the general term of the “place value” sequence $$1, 10, 100,$$ $$1000, 10000, \ldots\text{.}$$ You can choose any letter for the indexing variable (we chose $$n$$ above), the sequence name (we chose $$b$$ above) and the starting index (we chose 1 at first, then 3 for constrast). Whatever you choose, write the definition in a full sentence, similar to the quoted sentence above.

###### Definition10.1.
A sequence is called arithmetic if the difference between successive terms is constant.

Our example sequence $$7, 9, 11, 13, \ldots$$ is an arithmetic sequence with common difference 2. It is particularly easy to write a formula for the general term of an arithmetic sequence if you start indexing at zero. The $$n^{th}$$ term is the zeroth term plus $$n$$ copies of the common difference. In notation, if the common difference is $$d$$ and the sequence is $$\{ a_k : k \geq 0 \}\text{,}$$this means $$a_k = a_0 + k d\text{.}$$ Setting $$a_0 = 7$$ and $$d = 2$$ gives $$a_k = 7 + 2k$$ for the sequence $$7, 9, 11, 13, \ldots\text{.}$$

Which of these sequences appear to be arithmetic sequences?

• the sequence defined for \​(n \geq 0\) by \​(b_n := 14 - n/2\)

• the sequence defined for \​(n \geq 0\) by \​(b_n := 1/(5+2n)\)

• \​(9 , -11 , 13 , -15, \ldots\)

• \​(\sin (1) , \sin (3) , \sin(5), \sin(7), \ldots\)

• \​(30, 27, 24, 21,\ldots\)

###### Definition10.2.
A sequence is called geometric if the ratio between successive terms is constant. In other words, if the sequence is $$\{ u_j \}\text{,}$$ then the ratio $$u_{j+1} / u_j$$ has some common value $$r$$ for all $$j\text{.}$$
For example, the sequence $$10, 20, 40, 80, 160, \ldots$$ is geometric with common ratio 2.

Write a formula for the general term of this geometric sequence. Use the variable $$n$$ and write a formula for the $$n^{th}$$ term. Assume the sequence starts with $$n=1\text{.}$$

$$10\cdot 2^{n-1}$$

Sequences with alternating signs appear often enough that it's a good idea to know a way to write their general term. The key to being able to write such sequences is to notice that $$(-1)^n$$ bounces back and forth between $$+1$$ and $$-1\text{.}$$ The odd terms are negative, so starting with $$n=1$$ (or 3 or 5, etc.) starts with $$-1$$ whereas starting with 0 (or 2, -2, etc.) starts with $$+1\text{.}$$ You can incorporate this in a sum as a multiplicative factor and it will change the sign of every second term. Thus for example, to write the sequence $$1, -2, 3, - 4 \ldots$$ you can write $$(-1)^{n+1} \cdot n \, .$$ Note that we used $$(-1)^{n+1}$$ rather than $$(-1)^n$$ so that the term corresponding to $$n=1$$ was positive rather than negative.

When the sum has a pattern that takes a couple of steps to repeat, the greatest integer function can be useful. For example, $$1, 1, 1, 2, 2, 2, 3, 3, 3, \ldots$$ can be written as $$a_n := \left \lfloor \frac{n+2}{3} \right \rfloor$$ for $$n \geq 1\text{.}$$ Actually, it comes out a little more simply if you index starting from zero: $$a_n := \left \lfloor \frac{n}{3} \right \rfloor + 1$$ for $$n \geq 0\text{.}$$

Definitions by cases work for sequences just the way they do for functions. Suppose you want to define a sequence with an opposite sign on every third term, such as $$-1, -1, 1, -1 -1 , 1 , \ldots\text{.}$$ You can do this by cases as follows.

\begin{equation*} a_n := \begin{cases} -1 & \hspace{0.2in} n \mbox{ is not a multiple of } 3 \\ 1 & n \mbox{ is a multiple of } 3 \end{cases}. \; . \end{equation*}

Plenty of sequences don't fit any of these molds. Writing a formula for the general term is a matter of trying an expression, seeing if it works, then if not, tinkering to get it right.

### Subsection10.2Finite series

Let's talk for a minute about a notation you have likely seen before. It is called the "Sigma" notation because that's the name of the Greek letter $$\Sigma\text{.}$$ The notation involves an indexing variable which runs between a lower limit and an upper limit. The lower and upper limits are required to be integers\footnote{This is unlike computer science, where a loop counter can increment by any number}. If the indexing variable is $$n\text{,}$$the lower limit is $$L\text{,}$$the upper limit is $$U$$ and the general term is $$b_n\text{,}$$the summation looks like $$\displaystyle\sum_{n=L}^U b_n\text{.}$$ What this means is to add together all the values of $$b_n$$ starting with $$n=L$$ and ending with $$n=U\text{.}$$

###### Example10.3.
$$\displaystyle\sum_{n=1}^{5} 2^{-n}$$ represents the sum
\begin{equation*} \frac{1}{2} + \frac{1}{4} + \frac{1}{8} + \frac{1}{16} + \frac{1}{32}. \end{equation*}

The summand, as you can see, is usually a function of the indexing variable; otherwise, the summand would not change from term to term. There may be other variables, for example $$\displaystyle\sum_{k=3}^6 k x$$ evaluates to $$3x + 4x + 5x + 6x\text{,}$$which is equal to $$18x\text{.}$$ Note that this other variable $$x$$ persists when the sum is evaluated. It is a free variable. On the other hand, the index of summation, $$k$$ in this case, is a bound variable. It runs over a set of values (in this case 3 to 6) and does not appear in the final value.

In the sum $$\displaystyle\sum_{k=1}^n \frac{C}{k}\text{,}$$which of the variables $$k\text{,}$$ $$n$$ and $$C$$ are free and which are bound?

$$k\text{:}$$

• free

• bound

$$n\text{:}$$

• free

• bound

$$C\text{:}$$

• free

• bound

$$\text{bound}$$

$$\text{free}$$

$$\text{free}$$

When a sequence is summed, the result is called a series (the plural is also series).

###### Example10.4.

The sum $$\displaystyle\sum_{n=5}^{19} \frac{3}{n-2}$$ represents a series with 15 terms because there are 15 integers in the range from 5 to 19. Informally, we might write this sum by writing the first few terms and the last term, with dots in between (traditionally the dots are centered for series, as opposed to at the bottom of the line for sequences). Thus we would write $${\frac{3}{3} + \frac{3}{4} + \cdots + \frac{3}{17}}\text{,}$$ assuming this conveyed enough information for the reader to understand the precise sum.

Of course there is no reason why the index should go from 5 to 19. There have to be fifteen terms, but why not write the sum with the index going from 1 to 15? Then it would look like

\begin{equation*} \displaystyle\sum_{n=1}^{15} \frac{3}{n+2} \, . \end{equation*}

Another natural choice is to let the index run from 0 to 14:

\begin{equation*} \displaystyle\sum_{n=0}^{14} \frac{3}{n+3} \, . \end{equation*}

All three of these formulas represent the exact same sum.

Write a summation that sums the integers from 1 to 100 for which the lower limit is $$-5\text{.}$$ You’ll get an answer like

\begin{equation*} \displaystyle\sum_{p=-5}^{N}\text{formula here} \end{equation*}

$$N=$$

The formula is

$$94$$

$$p+6$$

### Subsection10.3Some series you can explicitly sum

The series in Example 10.4 sums to a rational number. According to Excel it is equal to $$23763863/4084080\text{.}$$ There isn't any really nice formula for this sum in terms of the values 5 and 19 and the function $$n \mapsto 3/(n-2)\text{.}$$ In fact most series don't have nice summation formulas. Arithmetic and geometric series are exceptions. Because they are common and the formulas are simple and useful, we include them in this course.

##### Arithmetic series.

Here's an example of how to sum an arithmetic series, which generalizes easily to summing any arithmetic series. This particular example is a well known piece of mathematical folklore (google "Gauss child sum").

###### Example10.5.
Problem
Sum the numbers from 1 to 100.
Solution
Pair the numbers starting from both ends: 1 pairs with 100, 2 pairs with 99, and so forth, ending at 50 paired with 51. There are 50 pairs each summing to 101, so the sum is $$50 \times 101 = 5050\text{.}$$ Figure 10.6. A diagram of the solution described in Example 10.5.

Another way to get the same formula is only slightly different.

###### Example10.7.

Evaluate $${\displaystyle\sum_{n=13}^{29} n}\text{.}$$ There are 17 terms and the average is 21, which can be computed by averaging the first and last terms: $$(13+29)/2 = 21\text{.}$$ Therefore, the sum is equal to $$17 \times 21 = 357\text{.}$$

Suppose we want to sum the arithmetic series $$\displaystyle\sum_{k=\ell}^u a + kd\text{.}$$ We have already seen that every arithmetic series can be written this way, so this exercise solves the problem of summing every arithmetic series (yet is easy enough to put in an exercise!).

1. How many terms are there in this series?

2. Pairing from both ends, what is the common sum of each pair?

3. If the number of terms is even, what is the formula for the sum?

4. If the number of terms is odd, what is the formula?

Hint.

This is more general than our usual exercise. You might find it easier to try a few examples with numbers (i.e., try $$L=5,U=12,a=1\text{;}$$ then try $$L=3,U=9,a=2$$) before doing the exercise with algebraic expressions.

$$u-l+1$$

$$2a+ud+ld$$

$$\frac{\left(2a+ud+ld\right)\!\left(u-l+1\right)}{2}$$

$$\frac{\left(2a+ud+ld\right)\!\left(u-l\right)}{2}+2a+ud+ld$$

##### Geometric series.

The standard trick for summing geometric series is to notice that the sum and $$r$$ times the sum are very similar. It is easiest to explain with an example.

###### Example10.8.

Evaluate $${\displaystyle\sum_{n=1}^{10} 7 \cdot 4^{n-1}}\text{.}$$ To do this we let $$S$$ denote the value of the sum. We then evaluate $$S - 4S$$ (because $$r=4$$). I have written this out so you can see the cancellation better.

\begin{align*} S - 4S & = & 7 + 28 + 112 + \cdots + 7 \cdot 4^9 \\ & & - \hspace{1.2ex} (28 + 112 + \cdots + 7 \cdot 4^9 + 7 \cdot 4^{10} ) \, . \\ \mbox{Thus,} && \\ (1-4) S & = & 7 - 7 \cdot 4^{10} \, . \end{align*}

From this we easily get $$S = (7 - 7 \cdot 4^{10}) / (1-4) = 7 (4^{10}-1)/3 = 2446675\text{.}$$

The chance that it takes precisely $$n$$ rolls of a standard die in order to roll your first 6 is $$(5/6)^{n-1} (1/6)\text{.}$$ Sum 10 terms of a geometric series to find the chance that you first see a 6 by the time of your tenth roll. Enter your answer as a decimal to three places.

$$6-6\cdot \left(\frac{5}{6}\right)^{10}$$

Now let's evaluate the general form $${\displaystyle\sum_{n=1}^M A \cdot r^{n-1}}\text{.}$$

Letting $$S$$ denote the sum we have $$S - rS = A - A r^M$$ and therefore

\begin{equation*} S = A \, \frac{1 - r^M}{1-r} \, . \end{equation*}

When $$A$$ and $$r$$ are positive, all the terms are positive, hence the sum is positive as well. When $$r < 1$$ this is very evident from the formula. When $$r > 1$$ it is true as well, but easier to see multiplying top and bottom by $$-1$$ so as to get $$A (r^M-1) / (r-1)\text{.}$$ When $$r=1$$ this quotient is undefined, however the sum is very easy: $$M$$ copies of $$A$$ sum to $$A \cdot M\text{.}$$

### Subsection10.4Infinite series

No discussion of series would be satisfied if it didn't answer the question, "Is $$0.9999\ldots$$ (repeating) actually equal to 1?" As you can probably guess, it is a matter of definition. However, there is a standard definition, and therefore we can in fact supply an answer (see below).

###### Definition10.9.
\begin{equation*} \displaystyle\sum_{n=L}^\infty b_n := \lim_{M \to \infty} \displaystyle\sum_{n=L}^M b_n \, . \end{equation*}

This definition might require a bit of unpacking. First of all, the colon-equal is right: the symbol $$\displaystyle\sum_{n=L}^\infty b_n$$ on the left is not already defined, and we are defining it to be the value on the right. So what we are saying is that the sum of an infinite series is the limit of a certain sequence, called the sequence of partial sums.

###### Example10.10.

How does this definition apply to the so-called harmonic series, $$\displaystyle\sum_{n=1}^\infty 1/n\text{?}$$ It says that this infinite sum is equal to the limit of the sequence $$\{ H_M \}\text{,}$$where $$H_M$$ is the harmonic number $$\displaystyle\sum_{n=1}^M 1/n\text{.}$$ The harmonic numbers $$H_M$$ are said to be the partial sums of the harmonic series. Interpreting the infinite sum in this way doesn't tell us whether the limit is defined, or if so, what it is, it just tells us that if we can evaluate the limit $$\lim_{M \to \infty} H_M\text{,}$$ this is by definition the sum of the harmonic series. If the limit is undefined, then the sum of the harmonic series is undefined.

The alternating harmonic series is the series

\begin{equation*} 1 - 1/2 + 1/3 - 1/4 + \cdots \end{equation*}
1. Write this as an infinite summation, using the variable $$k$$ and starting from $$k=1\text{.}$$

$$\displaystyle\sum_{k=1}^\infty$$

2. Write the value of this infinite sum as a limit.

3. State your guess as to the general behavior of this limit:

• This sum is defined.

• This sum is undefined because it tends to $$\infty\text{.}$$

• This sum is undefined because it tends to $$-\infty\text{.}$$

.

4. If you answered that the sum is defined, make a guess as to its value.

$$\frac{\left(-1\right)^{k+1}}{k}$$

$$\text{This sum is defined.}$$

Because we know how to sum finite geometric series, we can sum infinite geometric series.
###### Example10.11.
Problem
evaluate $$1 + 1/2 + 1/4 + 1/8 \cdots\text{.}$$
Solution
this is the infinite sequence $$\displaystyle\sum_{n=0}^\infty (1/2)^n\text{.}$$ The value is the limit of the partial sums $$S_M := \displaystyle\sum_{n=0}^M (1/2)^n\text{.}$$ Evaluating these finite sums gives
\begin{equation*} S_M = \frac{1 - (1/2)^{M+1}}{1 - 1/2} = 2 - \frac{1}{2^M} \, . \end{equation*}
The infinite sum is then $$\lim_{M \to \infty} 2 - (1/2)^M$$ which is clearly equal to 2.

Write $$0.9999\ldots$$ (repeating) as an infinite geometric series.

Now evaluate your series to see if it is really equal to 1.

### Subsection10.5Financial applications

When writing equations for balance sheets of loans, annuities, endowments and other investment schemes, it helps to be able to convert quickly between continuous growth and discrete-time growth such as monthly, quarterly or yearly. Recall from Example 7.8 that an interest rate (written as a real number, so you need to divide by 100 if it is quoted as a percent) of $$r$$ corresponds to a growth factor of $$e^r$$ over the course of a year. The increase in an initial amount $$M$$ over a year is $$e^r M - M = (e^r - 1) M\text{.}$$ This increase is proportional to $$M$$ of course, and the constant of proportionality $$e^r - 1$$ is called the annual yield. Denoting this by $$y\text{,}$$we can state either in terms of the other:

\begin{equation} y = e^r - 1 \qquad ; \qquad r = \ln (1+y) \, .\label{eq-APY}\tag{10.1} \end{equation}

For those committed to stating things in terms of percentages, let $$Y = 100 y$$ denote the annual percentage yield (APY) and $$R = 100 r$$ denote the percentage interest rate, this becomes

\begin{equation*} Y = 100 (e^{R/100} - 1) \qquad ; \qquad R = 100 \ln (1 + Y/100) \, . \end{equation*}

The best interest rate you could get in January, 2020 on a conventional savings account was 2%. What is the APY? Answer to four decimal places.

$$0.0202013\hbox{ or }2.02013$$

Consider a mortgage loan (loan for a house) or car loan. Typically payments on these are made monthly, which we will take to be every $$1/12$$ of a year. In this case the factor by which your debt grows each month is $$e^{r/12}\text{,}$$where $$r$$ is the (annual) interest rate. That's only if you don't pay off the loan. Actually, these loans are typically configured so you pay a fixed amount every month until the loan is paid off in an integer number of months (usually, in fact, an integer number of years). To agree on some notation, let $$r$$ be the annual interest rate, $$P$$ be the principal, that is the initial debt, and let $$M$$ be the monthly payment.

In order to deal successfully with used car sales people, it's helpful to understand how these determine your balance over the successive months. The key relation is to understand what happens from one month to the next. We will discuss this, then leave the rest of the balance sheet computation for in-class discussion and homework. To determine your debt after a month, just take your initial debt $$P\text{,}$$ multiply by the factor $$e^{r/12}$$ for the growth of the debt over the first month, and subtract the amount you just paid off, namely $$M\text{.}$$ We can write this as $$P_1 = e^{r/12} P_0 - M\text{.}$$ It holds equally from any month to the next: $$P_{n+1} = e^{r/12} P_n - M\text{,}$$where $$P_n$$ is your debt after $$n$$ months.

How about your retirement account? Say you put $$M$$ dollars every month into an interest bearing account. How much do you have after $$n$$ months? It's the same formula, with an opposite sign because you're adding to your balance, not subtracting.

Write a formula for your retirement balance after $$n+1$$ months, $$P_{n+1}\text{,}$$ in terms of your balance $$P_n$$ after $$n$$ months.

A guaranteed rate annuity works similarly. By the time you retire you have put $$P$$ dollars into an account. (How did this happen? See Checkpoint 133) You hand this over to a company who guarantees you a certain APY every year, call it $$Y\text{.}$$ Each year you also withdraw a fixed amount to live on, call it $$M\text{.}$$

Write a formula for $$P_{n+1}$$ in terms of $$P_n\text{,}$$ $$Y\text{,}$$ and $$M\text{.}$$

The University of Pennsylvania's endowment works something like this. The balance increases by roughly 5% each year due to the growth of the investments and new donations. Meanwhile, during the year, the university spends roughly 3.4% of the present endowment. Unlike the formula for growth of a retirement fund or reduction of debt, this one is only approximate because the actual return varies. Nevertheless, it is useful for forecasting. Let $$E_n$$ denote the size of the endowment after $$n$$ years.

What is the relation of $$E_n$$ to $$E_{n+1}\text{?}$$

In what way does this formula differ from the other three (loan, retirement account, annuity)?