# Step By Step Calculus » 8.2 - Sequences and Series

Synopsis
It is often useful to consider functions whose domains are the natural numbers or perhaps a subset of the integers. Such a function is called a sequence. A sequence can be defined by listing enough of its values to see how to continue: \left\{s_1,s_2,s_3,...\right\}\left\{s_1,s_2,s_3,...\right\}, where s_{n}s_{n} is the value of the function at nn. For example, \{ 1, \; \dfrac{1}{2}, \; \dfrac{1}{3} ,\; \dfrac{1}{4} , \; \ldots \} \{ 1, \; \dfrac{1}{2}, \; \dfrac{1}{3} ,\; \dfrac{1}{4} , \; \ldots \} .
It is more common to express a sequence by giving a formula for the value at each natural number. For example, \left\{\dfrac{n}{n+1}\right\}_{n=1}^{\infty}\left\{\dfrac{n}{n+1}\right\}_{n=1}^{\infty}. In both notations, list and function, unless stated otherwise we understand that n \in \mathbb{N}n \in \mathbb{N}, that is, nn goes from 11 to “ \infty \infty ”. In some situations it is more natural to allow nn to progress through a subset of \mathbb{Z} \mathbb{Z}, for example
\displaystyle \{ \sin(n) \}_{n=-2}^{\infty} =\{ \sin(-2), \; \sin(-1), \; \sin(0), \; \sin(1) , \; \dots \, \} \, .
\displaystyle \{ \sin(n) \}_{n=-2}^{\infty} =\{ \sin(-2), \; \sin(-1), \; \sin(0), \; \sin(1) , \; \dots \, \} \, .
Another important way to define a sequence is through recursion. In this situation, each successive term in the sequence is defined in terms of its predecessors by a given function. Usually the dependence is on the preceding one or two terms: s_{n} = f(s_{n-1}, s_{n-2})s_{n} = f(s_{n-1}, s_{n-2}). Of course, we have to give the first term or terms needed to start generating the sequence. For example,
\displaystyle s_{n} = \sqrt{2 - s_{n-1}}, \; s_{1} = 0.7 \; \rightarrow \; \{ 0.7, \; \sqrt{2 - 0.7}, \; \sqrt{2 - \sqrt{1.3}} , \; \ldots \,
\displaystyle s_{n} = \sqrt{2 - s_{n-1}}, \; s_{1} = 0.7 \; \rightarrow \; \{ 0.7, \; \sqrt{2 - 0.7}, \; \sqrt{2 - \sqrt{1.3}} , \; \ldots \,
We have three different ways to visually represent a sequence. We can plot the points (n, x_{n})(n, x_{n}) in the Cartesian plane, we can plot a line graph in the Cartesian plane based on these points, and (most importantly) we can plot the points s_{n}s_{n} on the real line. For the sequence \displaystyle\left\{ \, \dfrac{1}{n} \, \right\}_{n=1}^{\infty}\displaystyle\left\{ \, \dfrac{1}{n} \, \right\}_{n=1}^{\infty} the three visual representations look like this:

A final and important type of sequence is the sequence of partial sums of a series. An infinite series, often just called a series, is an infinite sum: \sum\limits_{i=1}^{\infty} a_i \sum\limits_{i=1}^{\infty} a_i , where the numbers a_{i}a_{i} being added are assumed given. For example, \sum\limits_{i=1}^{\infty} \frac{1}{i^{2}} = \frac{1}{1} + \frac{1}{4} + \frac{1}{9} + \dots \sum\limits_{i=1}^{\infty} \frac{1}{i^{2}} = \frac{1}{1} + \frac{1}{4} + \frac{1}{9} + \dots . Since we can not carry out an infinite addition process, we resort to an examination of the sequence of partial sums \{ s_{1}, \; s_{2}, \; \ldots \} \{ s_{1}, \; s_{2}, \; \ldots \}, where
\displaystyle s_{1} = a_{1} , \; s_{2} = a_{1} +a_{2} , \; s_{3} = a_{1} +a_{2} + a_{3} , \; \dots \; s_{n} = \sum_{i=1}^{n} a_{i}, \; \ldots
\displaystyle s_{1} = a_{1} , \; s_{2} = a_{1} +a_{2} , \; s_{3} = a_{1} +a_{2} + a_{3} , \; \dots \; s_{n} = \sum_{i=1}^{n} a_{i}, \; \ldots
The n^{th}n^{th} term s_ns_n is called the n^{\textrm{th}}n^{\textrm{th}}partial sum of the given series. Sometimes it is possible to come up with a formula for the partial sums of a given series. Induction is often very useful in establishing the validity of a closed-form formula for the partial sums.
One important type of series is the geometric series, where a_i=cr^ia_i=cr^i for some given c,r\in\mathbb{R}c,r\in\mathbb{R}. Here rr is called the ratio, since it is the ratio of two successive terms.