Skip to main content

Section 5.1 Sequences

Remember that a set has no order. For example, \(\{1,2\}\) and \(\{2,1\}\) are the same set. Often, we care about the order objects are in. When we would like to order a set of objects, we put them into a sequence.

Definition 5.1.1.

An interval of natural numbers is any of the three following subsets of \(\mathbb{N}\text{:}\)

  • \(I = \{m, m+1, m+2, \ldots, n-1, n\}\) for natural numbers \(m < n\)

  • \(I = \{m, m+1, m+2, \ldots\}\) for a natural number \(m\)

  • \(\displaystyle I = \mathbb{N}\)

The above definition allows us to phrase the following definition in a simpler way.

Definition 5.1.2.

Let \(I\) be an interval of natural numbers and let \(X\) be any set. A sequence is a function \(a:I \to X\text{.}\) We write \(a_n\) instead of \(a(n)\text{.}\) Here, \(n\) is the index and \(a_n\) is the term. We denote the entire sequence as \((a_n)\) (when the start and endpoints are stated elsewhere or are unimportant), \((a_n)_{n=k}^\infty\) (for an infinite sequence starting with \(a_k\)), or \((a_n)_{n=k}^m\) (for a finite sequence starting at \(a_k\) and ending at \(a_m\)).

A finite sequence is called a word from the alphabet \(X\text{.}\)

Once again we have chosen a more technical, functional definition where we instead could have said “a sequence is a totally ordered list of objects.” It is worth considering the way in which a function can “port structure” from one set to another. If we wanted a totally ordered set it is hard to imagine a better candidate than \(\mathbb{N}\text{.}\) The sequence transfers the order structure from \(\mathbb{N}\) into whatever set \(X\) we like.

As another note, parentheses are sort of the counterpart to curly braces. When \(\{\) and \(\}\) denote a structure without order, \((\) and \()\) denote a structure with order. We will follow this convention throughout this book.

Consider the sequence

\begin{equation*} (a_n)_{n=1}^\infty = (1, 4, 9, 16, 25, \ldots) \end{equation*}

Here, \(a_1 = 1\text{,}\) \(a_2 = 4\text{,}\) \(a_3 = 9\text{,}\) etc. The function from \(\{1, 2, \ldots\}\) maps \(3\) to \(9\text{,}\) for example. Observing that each term is the square of its index, this sequence may be represented in “closed form” by writing \(a_n=n^2\text{.}\)

Definition 5.1.4.

A sequence \((a_n)\) may be expressed in closed form if \(a_n\) can be expressed in terms of the index \(n\) under a finite set of arithmetic operations, elementary functions, and trigonometric functions.

“Closed form” is loosely defined and the definition depends on the author, but basically it means that you only need to know \(n\) to know \(a_n\text{.}\)

Consider the sequence \((n!)_{n=0}^\infty\) of factorials, which we encountered in the last chapter. Recall that

\begin{equation*} n! = 1 \times 2 \times 3 \times \cdots \times (n-1) \times n \end{equation*}

and that \(0! = 1\text{.}\) This definition of \(n!\) only relies on \(n\) and finitely many multiplications, so, it is a closed form expression for \(n!\text{.}\)

To find the eighth term of the sequence (starting at zero that's where \(n=7\)), we simply calculate

\begin{equation*} 7! = 7 \times 6 \times 5 \times 4 \times 3 \times 2 \times 1 = 5040 \end{equation*}

Notice in the example above that

\begin{align*} 7! \amp = 7 \times 6 \times 5 \times 4 \times 3 \times 2 \times 1\\ \amp = 7 \times \big( 6 \times 5 \times 4 \times 3 \times 2 \times 1 \big)\\ \amp = 7 \times 6! \end{align*}

It turns out that we could calculate \(7!\) even easier if we knew \(6!\text{.}\) This is true in general:

\begin{equation*} n! = n \times \big( (n-1) \times (n-2) \times \cdots \times 2 \times 1 \big) = n(n-1)! \end{equation*}

We will discuss recursively generated sequences in the next section.

By the way, there is no restriction that the terms of sequences need to be numbers.

Consider the sequence \((A_n)_1^\infty\) of sets defined in the following way:

\begin{equation*} A_n = \{0, \pm n, \pm 2n, \pm 3n, \ldots\} \end{equation*}

So, \(A_1 = \mathbb{Z}\text{,}\) \(A_2\) is the set of even integers,

\begin{equation*} A_3 = \{\ldots, -9, -6, -3, 0, 3, 6, 9, \ldots \} \end{equation*}

and so on. In this case, the function underlying the sequence is the function \(A:I \to \mathscr{P}(\mathbb{Z})\) where \(I\) is the interval \(\{1, 2, \ldots\}\text{.}\)