210
8 Solving Ordinary Differential Equations
Case 2 With a continuously increasing rate, we could have been asked to solve
V
(t) = V (t),
V (0) = 1 L,
0 s < t ≤ 3 s .
This particular ODE is very similar to the ODE we will address when we next turn
to population growth (in fact, it may be seen as a special case of the latter).
The Forward Euler Method: A Brief Encounter If we had proceeded to solve
these ODEs by something called the Forward Euler method (or Euler’s method), we
could (if we wanted) have written the solution codes exactly as they were developed
above! Thus, we have already used the essentials of Euler’s method without stating
it.
In the following sections, the Forward Euler method will be thoroughly explained
and elaborated on, while we demonstrate how the approach may be used to solve
different ODEs numerically.
8.2 Population Growth: A First Order ODE
Our first real taste of differential equations regards modeling the growth of some
population, such as a cell culture, an animal population, or a human population. The
ideas even extend trivially to growth of money in a bank.
Let N(t) be the number of individuals in the population at time t. How can we
predict the evolution of N with time? Below we shall derive a differential equation
whose solution is N(t). The equation we will derive reads
N
(t) = rN(t),
(8.1)
where r is a number. Note that although N obviously is an integer in real life, we
model N as a real-valued function. We choose to do this, because the solutions of
differential equations are (normally continuous) real-valued functions. An integervalued N(t) in the model would lead to a lot of mathematical difficulties. Also,
talking about, e.g., 2.5 individuals is no problem in mathematics, even though we
must be a bit careful when applying this in a practical setting!
You may know, or find out, that the solution N(t) = Ce rt , where C is
any number. To make this solution unique, we need to fix C, which is done by
prescribing the value of N at some time, usually at t = 0. If N(0) is given as N 0 ,
we get N(t) = N 0 e rt .
In general, a differential equation model consists of a differential equation, such
as (8.1) and an initial condition, such as N(0) = N 0 . With a known initial condition,
the differential equation can be solved for the unknown function and the solution is
unique.
It is very rare that we can find the solution of a differential equation as easy as
the ODE in this example allows. Normally, one has to apply certain mathematical
methods. Still, these methods can only handle some of the simplest differential
equations. However, with numerical methods and a bit of programming, we can
Précédent

- 230/350

Suivant