The logistic model

Introduction

The logistic growth model is the differential equation:

\frac{dy(t)}{dt} = ay(t) - by(t)^2

for any t\in[t_0, t_{final}], with the initial condition:

y(t_0) = y_0

where :

  • a > 0 and b > 0 are two real parameters,

  • y(t) is the size of the population at time t,

  • t_0 is the initial time,

  • y_0 is the initial population at time t=t_0,

  • t_{final} is the final time.

The a parameter sets the growth rate of the population. The b parameter acts as a competition parameter which limits the size of the population by increasing the competition between its members.

In [1], the author uses this model to simulate the growth of the U.S. population. To do this, the author uses the U.S. census data from 1790 to 1910. For this time interval, R. Pearl and L. Reed [2] computed the following values of the parameters:

a = 0.03134, \qquad b = 1.5887 \times 10^{-10}.

Our goal is to use the logistic growth model in order to simulate the solution for a larger time interval, from 1790 to 2000:

t_0 = 1790, \qquad t_{final} = 2000.

Then we can compare the predictions of this model with the real evolution of the U.S. population.

We can prove that, if y_0 > 0, then the limit population is:

y_{limit} =\frac{a}{b}.

In 1790, the U.S. population was 3.9 Millions inhabitants:

y_0 = 3.9 \times 10^6.

We can prove that the exact solution of the ordinary differential equation is:

y(t)=\frac{ay_0}{by_0+(a-by_0 ) \exp(-a(t-t_0)) }

for any t\in[t_0, t_{final}].

We want to see the solution of the ordinary differential equation when uncertainties are taken into account in the parameters:

  • the initial U.S. population y_0,

  • the parameters a and b.

Indeed, Pearl and Reed [2] estimated the parameters a and b using the U.S. census data from 1790 to 1910 while we have the data up to 2000. Moreover, the method used by Pearl and Reed to estimate the parameters could be improved; they only used 3 dates to estimate the parameters instead of using least squares, for example. Finally, Pearl and Reed did not provide confidence intervals for the parameters a and b.

Normalizing the data

The order of magnitude of a and b are very different. In order to mitigate this, we consider the parameter c as the logarithm of b:

c = \log(b).

This leads to the value:

c = \log\left(1.5887 \times 10^{-10}\right) = -22.58.

The order of magnitude of the population is 10^6. This is why we consider the normalized population in millions:

z(t) = \frac{y(t)}{10^6}

for any t\in[t_0, t_{final}].

Let z_0 be the initial population:

z_0 = z(t_0).

Uncertainties

Uncertainty can be accounted for by turning z_0, a and c into independent random variables Z_0, A and C with Gaussian distributions. From this point onward, z_0, a and b respectively denote \mathbb{E}[Z_0], \mathbb{E}[A] and \mathbb{E}[C].

Variable

Distribution

Z_0

gaussian, mean z_0, coefficient of variation 10%

A

gaussian, mean a, coefficient of variation 30%

C

gaussian, mean c, coefficient of variation 30%

No particular probabilistic method was used to set these distributions. An improvement would be to use calibration methods to get a better quantification of these distributions. Calibration methods could be used to get a better quantification of these distributions.

Notes

  • This example is based on [1], chapter “First order differential equations”, page 28. The data used in [1] are from [3]. The logistic growth model was first suggested by Pierre François Verhulst near 1840. The data are from [1] for the time interval from 1790 to 1950, then from [2] for the time interval from 1960 to 2000.

  • Calibrating this model may require to take into account for the time dependency of the measures.

References

[1] Martin Braun. Differential equations and their applications, Fourth Edition. Texts in applied mathematics. Springer, 1993.

[2] Cleve Moler. Numerical Computing with Matlab. Society for Industrial Applied Mathematics, 2004.

[3] Raymond Pearl and Lowell Reed. On the rate of growth of the population of the united states since 1790 and its mathematical representation. Proceedings of the National Academy of Sciences, 1920.

API documentation

class LogisticModel(t0=1790.0, y0=3900000.0, a=0.03134, b=1.5887e-10, populationFactor=1000000.0)

Data class for the logistic model.

In the physical model, the inputs and parameters are ordered as presented in the next table. Notice that there are no parameters in the physical model.

Index

Input variable

0

t1

1

t2

21

t22

22

a

23

c

Examples

>>> from openturns.usecases import logistic_model
>>> # Load the logistic model
>>> lm = logistic_model.LogisticModel()
>>> print(lm.data[:5])
    [ Time            U.S. Population ]
0 : [ 1790               3.9          ]
1 : [ 1800               5.3          ]
2 : [ 1810               7.2          ]
3 : [ 1820               9.6          ]
4 : [ 1830              13            ]
>>> print("Inputs:", lm.model.getInputDescription())
Inputs: [t0,t1,t2,t3,t4,t5,t6,t7,t8,t9,t10,t11,t12,t13,t14,t15,t16,t17,t18,t19,t20,t21,a,c]#24
>>> print("Outputs:", lm.model.getOutputDescription())
Outputs: [z0,z1,z2,z3,z4,z5,z6,z7,z8,z9,z10,z11,z12,z13,z14,z15,z16,z17,z18,z19,z20,z21]#22
Attributes:
t0float, optional

Initial time. The default is 1790.

y0float, optional

Initial population (at t0). The default is 3.9e6.

afloat, optional

8Parameter of the model. The default is 0.03134.

bfloat, optional

Parameter of the model. The default is 1.5887e-10.

populationFactorfloat, optional

The multiplication factor to scale the population. The default is 1.0e6.

distY0Normal distribution

ot.Normal(y0, 0.1 * y0)

distANormal distribution

ot.Normal(a, 0.3 * a)

distBNormal distribution

ot.Normal(b, 0.3 * b)

distXJointDistribution

The joint distribution of the input parameters.

modelPythonFunction

The logistic model of growth. The input has input dimension 24 and output dimension 22. More precisely, we have \vect{X} = (t_1, ..., t_{22}, a, c) and \vect{Y} = (y_1, ..., y_{22}).

dataSample of size 22 and dimension 2

A data set containing 22 dates from 1790 to 2000. First marginal represents dates and second marginal the population in millions.

Examples based on this use case

Logistic growth model

Logistic growth model

Calibration of the logistic model

Calibration of the logistic model