A paradigm change

1.2. A paradigm change#

Most functions that we encounter in our mathematical training are smooth and infinitely differentiable. In this case, they have a Taylor Series:

\[ f(x) = c_0 + c_1 x + c_2 x^2 + \cdots \]

where \(c_0 = f(0)\),   \(c_1 = f'(0)\),   \(c_2 = f''(0)/2\),   \(\ldots\),   \(c_n = f^{(n)}(0)/n!\),   \(\ldots\).

Usually when we think about a function \(f(x)\), we are interested in the values it produces for a given input \(x\). If asked to visualize a function \(y = (1 + x^2)/2\), many of us will think of the parabola plotted below.

Hide code cell source

import matplotlib.pyplot as plt
import numpy as np

x = np.linspace(-2,2,100)
plt.plot(x, (1+x**2)/2)
plt.xlabel('$x$')
plt.ylabel('$y$')

plt.show()
../../_images/76df880d1a2f50038aa17bd49143c1906bdfd65cee337688cf1bf681c62204c9.png

Very few of us would instead think of the sequence of numbers: \(c_0=1/2\),   \(c_1=0\),   \(c_2=1/2\),   \(c_3=0\),   \(c_4=0\),   \(\ldots\).

Remark 1.1 (Function and Taylor Series: the usual approach)

Usually, the values of the function for different values of \(x\) form the ``concrete object’’ we want to know about. In this paradigm, the Taylor Series is mostly useful to help us calculate the values of the function and to understand the shape of its graph.

We are going to switch our focus. For our purposes, we will be primarily interested in the coefficients of the Taylor Series. We will only care about the values of the function when we can use them to learn about properties of the sequence of coefficients.

Remark 1.2 (Function and Taylor Series: the generating function approach)

In the paradigm we will use, the sequence of coefficients of the Taylor Series is the ``concrete object’’ we want to study. The values of the function and the shape of the graph are mostly useful for what they tell us about the sequence.

1.2.1. Definitions#

Our focus on the sequence of coefficients of a function’s Taylor Series expansion motivates the following definition:

Definition 1.1 (Generating Function)

Given a seqence of numbers \(c_0\), \(c_1\), \(\ldots\), the function

\[ f(x) = \sum_{n=0}^\infty c_n x^n \]

is the Generating Function of the sequence.

Sometimes we will call this an Ordinary Generating Function or OGF.

Our goal in creating a generating function is to apply tools we learn in other areas of mathematics (addition, multiplication, differentiation, composition, etc) to the function in order to learn properties of the sequence and the process that creates that sequence.

There are many special classes of generating functions. We will discover later that when the coefficients come from a probability distribution of non-negative integers the operations of adding, multiplying, differentiating, and composing generating functions correspond to properties related to reproduction. This motivates the study of a special kind of generating function:

Definition 1.2 (Probability Generating Function)

Given a probability distribution for non-negative integers where \(p_n\) is the probability of \(n\) and \(\sum_{n=0}^\infty p_n = 1\), the function

\[ \mu(x) = \sum_{n=0}^\infty p_n x^n \]

is the Probability Generating Function (PGF) of the distribution.

So a PGF is simply an OGF whose coefficients correspond to a probability distribution for non-negative integers. For our purposes we will usually be interested in the specific case where \(p_k\) is the probability one organism creates \(k\) offspring.

By performing mathematical operations with the function \(\mu(x)\) we will learn how to calculate things such as

  • The probability of extinction within \(g\) generations,

  • The expected number of organisms after \(g\) generations,

  • The probability of exactly \(n\) organisms after \(g\) generations, and many related quantities of interest.

1.2.2. Two famous quotes#

To illustrate some of the ideas underlying how we use generating functions, here are two famous quotes about them, illustrated using the Taylor Series \(e^x = 1 + x + \frac{1}{2} x^2 + \frac{1}{6}x^3 + \cdots\), the generating function for the sequence \(c_n = \frac{1}{n!}\):

“A generating function is a clothesline on which we hang up a sequence of numbers for display.” H. Wilf

../../_images/clothesline.png

Fig. 1.1 Hanging the sequence \(1, 1, 1/2, 1/6, \ldots, 1/n!, \ldots\) on a clothesline.#

This “clothesline” is an organized way of displaying a sequence of numbers. However, one of the benefits of generating functions is that we can often rewrite a generating function in a compact way, which is captured in the following:

“A generating function is a device somewhat similar to a bag. Instead of carrying many little objects detachedly, which could be embarrassing, we put them all in a bag, and then we have only one object to carry, the bag.”  George Pólya

../../_images/bag2.png

Fig. 1.2 Putting the clothesline into a compact bag which we can label as \(e^x\).#