Section 6.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 6.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 6.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.
Example 6.1.3.
Consider the sequence
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 6.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{.}\)
Example 6.1.5.
Consider the sequence \((n!)_{n=0}^\infty\) of factorials, which we encountered in the last chapter. Recall that
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
Notice in the example above that
It turns out that we could calculate \(7!\) even easier if we knew \(6!\text{.}\) This is true in general:
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.
Example 6.1.6.
Consider the sequence \((A_n)_1^\infty\) of sets defined in the following way:
So, \(A_1 = \mathbb{Z}\text{,}\) \(A_2\) is the set of even integers,
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{.}\)