# Contents

## Idea

Quantitative ecology is the application of mathematical and statistical tools to problems in the field of ecology.

## Example

### Predator-prey model

Suppose we have some rabbits that reproduce endlessly, with their numbers growing at a rate proportional to their population. Let $x(t)$ be the number of animals at time $t$. Then we have:

$\frac{d x}{d t} = r x$

where $r$ is the growth rate. This equation gives exponential growth: it has solutions of the form

$x(t) = x_0 e^{r t}$

To get a slightly more realistic model, we can add ‘limits to growth’. Instead of a constant growth rate, let’s try a growth rate that decreases as the population increases. Let’s say it decreases in a linear way, and drops to zero when the population hits some value $K$. Then we have

$\frac{d x}{d t} = r (1-x/K) x$

This is called the "logistic equation". $K$ is known as the Carrying capacity. The idea is that the environment has enough resources to support this population. If the population is less than the carrying capacity, it’ll grow; if it’s more, it’ll shrink.

One can solve the logistic equation by hand by separating the variables and integrating both sides; it’s a standard exercise in calculus. The solutions are called "logistic functions", and they look sort of like this:

The above graph shows the simplest solution:

$x = \frac{e^t}{e^t + 1}$

of the simplest logistic equation:

$\frac{ d x}{d t} = (1 - x)x$

Here the carrying capacity is 1. Populations less than 1 sound a bit silly, so think of it as 1 million rabbits. You can see how the solution starts out growing almost exponentially and then levels off. There’s a very different-looking solution where the population starts off above the carrying capacity and decreases. There’s also an unrealistic solution involving negative populations. But whenever the population starts out positive, it approaches the carrying capacity.

The solution where the population just stays at the carrying capacity:

$x = 1$

is called a stable equilibrium, because it’s constant in time and nearby solutions approach it.

But now let’s introduce another species: some wolves, which eat the rabbits. Let $x$ be the number of rabbits, and $y$ the number of wolves. Before the rabbits meet the wolves, let’s assume they obey the logistic equation:

$\frac{ d x}{d t} = x(1-x/K)$

And before the wolves meet the rabbits, let’s assume they obey this equation:

$\frac{ d y}{d t} = -y$

so that their numbers would decay exponentially to zero if there were nothing to eat.

So far it’s not very interesting. But now let’s include a term that describes how predators eat prey. Let’s say that on top of the above effect, the predators grow in numbers, and the prey decrease, at a rate proportional to:

$x y/(1+x).$

For small numbers of prey and predators, this means that predation increases nearly linearly with both $x$ and $y$. But if you have one wolf surrounded by a million rabbits, the rate at which it eats rabbits won’t double if you double the number of rabbits! So, this formula includes a limit on predation as the number of prey increases.

For example, let’s consider these equations:

$\frac{ d x}{d t} = x(1-x/K) - 4x y/(x+1)$

and

$\frac{ d y}{d t} = -y + 2x y/(x+1)$

The constants 4 and 2 here have been chosen for simplicity rather than realism.

Before we plunge ahead and solve these equations numerically, let’s see what we can do by hand. Setting $d x/d t = 0$ gives the interesting parabola

$y = \frac{1}{4}(1-x/K)(x+1)$

together with the boring line $x = 0$. (If you start with no rabbits, that is how it will stay.)

Setting $d y/d t = 0$ gives the interesting line

$x=1$

together with the boring line $y = 0$. (If you start with no wolves, that’s how it will stay.)

The interesting parabola and the interesting line separate the $x y$ plane into four parts, so these curves are called separatrices. They meet at the point

$y = \frac{1 - 1/K}{2}$

which of course is an equilibrium, since $d x / d t = d y / d t = 0$ there. But when $K \lt 1$ this equilibrium occurs at a negative value of $y$, and negative populations make no sense.

So, if $K \lt 1$ there is no equilibrium population, and with a bit more work one can see the problem: the predators die out. For larger values of $K$ there is an equilibrium. But the nature of this equilibrium depends on $K$: that’s the interesting part. We could figure this out analytically, but first look at two of Graham’s plots. Here’s a solution when $K = 2.5$: The grey lines are the separatrices. The red curve shows a solution of the equations, with the numbers showing the passage of time. So, you can see that the solution spirals in towards the equilibrium. That’s what you expect of a stable equilibrium.

Here’s a picture when $K = 3.5$: The red and blue curves are two solutions, again numbered to show how time passes. The red curve spirals in towards the dotted grey curve. The blue one spirals out towards it. The grey curve is also a solution. It’s called a stable limit cycle because it’s periodic, and nearby solutions move closer and closer to it.

With a bit more work, we can show analytically that whenever $1 \lt K \lt 3$ there is a stable equilibrium, and when $K \gt 3$ there is a limit cycle. As we turn up $K$, when $K$ hits 3 the stable equilibrium suddenly becomes a tiny stable limit cycle. This is a Hopf bifurcation.

Now, what if we add noise? Where we before had a stable equilibrium, we now can get irregular cycles — because the noise keeps pushing the solution away from the equilibrium! The next picture shows a solution in $K=2.5$ case, with white noise added: The following graph shows a longer run in the noisy $K=2.5$ case, with rabbits ($x$) in black and wolves ($y$) in gray: There is irregular periodicity — and as you’d expect, the predators tends to lag behind the prey. A burst in the rabbit population causes a rise in the wolf population; a crash in rabbits causes a crash in wolves.

This sort of phenomenon is actually seen in nature sometimes. The most famous case involves the snowshoe hare and the lynx in Canada. It was first noted by MacLulich:

• D. A. MacLulich, Fluctuations in the Numbers of the Varying Hare (Lepus americanus), University of Toronto Studies Biological Series 43, University of Toronto Press, Toronto, 1937.

The snowshoe hare is also known as the “varying hare”, because its coat varies in color quite dramatically. In the summer it looks like this:

In the winter it looks like this:

The Canada lynx is an impressive creature:

But they only weigh 8-11 kilograms, nothing like a tiger or lion.

The Canada lynx rely for the snowshoe hare for 60% to 97% of their diet. This could be why the hare has evolved such magnificent protective coloration. This is also why their populations are tightly coupled. They rise and crash in irregular cycles that look a bit like what we saw in our simplified model: This cycle looks a bit more strongly periodic than the graph we saw above, so to fit this data, we might want to choose parameters that give a limit cycle rather than a stable equilibrium.

Of course, everything about population biology is vastly more complicated than the simple models discussed so far. Some obvious complications include:

• the population of animals changes discretely rather than continuously;

• animals move around in space, so a detailed model might consider a density of animals depending on location, rather than the mere number of animals.

More specific complications include:

• snowshoe hare breed in the spring, and their diet varies dramatically over the course of year;

• the lynx also eat rodents and birds, sometimes deer, and also carrion when it’s available;

• the hare will eat dead mice and even dead hare when they’re available;

• the lynx can control the size of their litter depending on the abundance of food.

And all these facts are probably just the tip of the iceberg. So, it’s best to think of models here as crude caricatures designed to illustrate a few features of a very complex system.

A preliminary version of the above article appears as a blog post based on Graham Jones’ work here in the Azimuth Library:

The R code used to simulate the predator-prey model discussed above is available here on the Azimuth Library: R code for predator prey.

Some introductory textbooks include:

• Michael R. Rose, Quantitative Ecological Theory, Johns Hopkins University Press, Maryland, 1987.

and

• Marc Mangel, The Theoretical Biologist’s Toolbox: Quantitative Methods for Ecology and Evolutionary Biology, Cambridge U. Press, Cambridge, 2006.

The second one is very user-friendly and has sections on:

1. Four examples and a metaphor

2. Topics from ordinary and partial differential equations

3. Probability and statistics

4. The evolutionary biology of parasitoids

5. The population biology of disease

6. An introduction to some of the problems of sustainable fisheries

7. The basics of stochastic population dynamics

8. Applications of stochastic population dynamics to ecology, evolution, and biodemography