**3.B-1 General Solution**

The general logistic equation is a modification of the exponential model in which the growth is tempered by the factor (
). Therefore, the model consists of the ODE

**> ** |
**logistic_ode := diff( x(t), t ) = A * x(t) * ( K - x(t) );** |

with, for example, an initial condition of the form

**> ** |
**logistic_ic := x(0)=X[0];** |

Initially, when
is small, the factor
is essentially constant, so the population obeys an exponential growth law. As
increases and approaches
, the factor
tends towards zero, so the rate of change,
, approaches zero also. Thus,
approaches a constant, and the growth is said to be *self*-*limiting*.

This ODE is easily separated by the obvious division, resulting in

**> ** |
**sep_log_ode := logistic_ode / (x(t)*(K-x(t)));** |

Integrating from the initial time, 0, to any other time
, yields

**> ** |
**part_log_soln := subs( _t=t, logistic_ic, map(int,sep_log_ode,t=0.._t, continuous) );** |

and solving for
to obtain the explicit solution, gives

**> ** |
**part_expl_soln := collect(op( solve( part_log_soln, {x(t)} ) ),exp);** |

A quick check that this is, in fact, a solution to the original ODE shows

**> ** |
**odetest( part_expl_soln, logistic_ode );** |

and, for the initial condition,

**> ** |
**eval( part_expl_soln, t=0 );** |

**3.B-2 Carrying Capacity**

Before discussing the generic properties of the logistic model, it is instructive to use graphical methods to examine a specific example. For parameter values, choose

**> ** |
**param := { A = 1/2, K=3 };** |

so the logistic equation becomes

**> ** |
**l_ode := subs(param,logistic_ode);** |

Then, the direction field for this model is seen in Figure 3.1.

**> ** |
**DEplot( l_ode, x(t), t=0..10, x=0..10, arrows=SMALL, title="Figure 3.1" );** |

An *equilibrium* *solution* of the differential equation
is any solution
for which
, __identically__. Hence, an equilibrium solution is a __constant__ solution. Such constant solutions show up on the direction field as horizontal lines, corresponding to the constant value of
.

Figure 3.1 suggests that
might be an equilibrium solution. Closer inspection of Figure 3.1 suggests that
might also be an equilibrium solution. These potential equilibrium solutions can be found analytically by solving the equation
= 0 for its roots. The roots of the equation

**> ** |
**EQUILIB_EQN := rhs(l_ode) = 0;** |

are found to be

**> ** |
**solve(EQUILIB_EQN, x(t));** |

Initial conditions that will produce the equilibrium solutions are

**> ** |
**equil_ic := [ [x(0)=0], [x(0)=3] ];** |

Use of these initial conditions in the __
DEplot
__ command yields Figure 3.2.

**> ** |
**equil_plot := DEplot( l_ode, x(t), t=0..5, equil_ic, x=0..10,** |

**> ** |
** arrows=SMALL, linecolor=CYAN, title="Figure 3.2" ):** |

Figure 3.3 shows a sample of solutions with initial conditions *between* the two equilibria.

**> ** |
**ic1 := [ [x(0)=i/2] $ i=1..5 ]:** |

**> ** |
**soln_plot1 := DEplot( l_ode, x(t), t=0..5, ic1, x=0..10, arrows=SMALL,** |

**> ** |
** linecolor=GREEN, title="Figure 3.3" ):** |

Note that all of these solutions are increasing and appear to approach
as
continues to increase.

Figure 3.4 shows a sample of solutions with initial conditions above the positive equilibrium.

**> ** |
**ic2 := [ [x(0)=2*i] $ i=2..5 ]:** |

**> ** |
**soln_plot2 := DEplot( l_ode, x(t), t=0..5, ic2, x=0..10, arrows=SMALL,** |

**> ** |
** linecolor=BLUE, stepsize=0.1, title="Figure 3.4" ):** |

These solutions are all decreasing and also appear to approach the
as
increases.

The composite plot is appears in Figure 3.5.

**> ** |
**display( [equil_plot, soln_plot1, soln_plot2], title="Figure 3.5" );** |

To investigate some of the general properties of solutions to the logistic equation, recall that the equilibrium solutions are

**> ** |
**equil_sol := solve( rhs(logistic_ode)=0, {x(t)} );** |

A quick inspection of the ODE shows that
> 0 when 0 <
<
and
< 0 when
>
. The long-term behavior of the solutions can be determined from the explicit solution to the IVP by evaluating the following limit.

**> ** |
**limit_size := Limit( part_expl_soln, t=infinity );** |

The limit exists as a finite number only if both
and
are nonnegative. With these physically reasonable assumptions, the limit is

**> ** |
**value( limit_size ) assuming A>=0, K>=0;** |

Because all solutions with
decrease to
and all solutions with 0 <
<
increase to
, the parameter
is known as the *carrying* *capacity* of the logistic equation.

The equilibrium solution
is called a *stable* *equilibrium* because, as
increases, nearby solutions, those close and on either side of it, tend towards the equilibrium. This is shown very well in Figure 3.5.

The equilibrium solution
is called an *unstable* *equilibrium* because, as
increases, nearby solutions, those close and on either side of it, move away from the equilibrium. Figure 3.6, exhibiting solutions starting both above and below the equilibrium solution
, shows that this equilibrium is unstable.

**> ** |
**DEplot( l_ode, x(t), t=0..1, [[x(0)=1],[x(0)=0],[x(0)=-1]], x=-2..2, arrows=SMALL,** |

**> ** |
** linecolor=[green,red,green], stepsize=0.1, title="Figure 3.6" );** |

An equilibrium solution can also be called *semi*-*stable* if, as
increases, nearby solutions on one side approach the equilibrium, but nearby solutions on the other move away from the equilibrium. Adifferential equation with a semi-stable equilibrium would be the equation

**> ** |
**SS_ode := diff(x(t),t) = x(t)*(1-x(t))^2;** |

The equilibrium solutions are
and
, with the latter being the semi-stable equilibrium, as shown in Figure 3.7.

**> ** |
**DEplot(SS_ode, x(t),t=0..1, [[x(0)=1],[x(0)=.5],[x(0)=1.5]], x=0..2, arrows=medium, dirgrid=[10,10], linecolor=[red,green,green], stepsize=0.1, title="Figure 3.7" );** |

Solutions starting above
move away from this equilibrium, but solutions starting below
move towards it. Solutions on one side of the equilibrium are attracted to the equilibrium, but solutions on the other side are repelled.