[Martin Taylor 2007.06.02.08.51]
This morning there is a thread on the System Dynamics mailing list dealing with the difference between discrete and continuous models, which I thought might be useful to copy here.
I realize that the serious PCT modellers understand the situation, and use techniques to avoid the oscillatory artefacts to which discrete models can be prone, but nevertheless, John Sterman's contribution to this thread seems to me to be the most lucid explanation of the issue that I have seen. It might also be useful to others who want to get into the modelling business.
Initially, I intended to send just Sterman's message, but I think putting the all together is more useful. If you read only one of these four messages, make it Sterman's.
Martin
=============From the System Dynamics Mailing List=================
Posted by "Welch, Cory" <Cory_Welch@nrel.gov>
I am currently engaged in a debate regarding continuous-time vs.
discrete-time modeling. As a result, I came across two articles that
claim a first order difference equation (they use the logistic equation
as an example) is capable of a) oscillation, and b) chaotic behavior. As
any good system dynamicist knows, this is of course impossible. These
articles are referenced countless times in ecology literature.
At first glance, it seems to me that the articles are mistakenly
interpreting instability resulting from using discrete time rather than
continuous time as "true" oscillation.
First, I am wondering whether I am correct in my interpretation.
Second, I wonder anyone on this list knows of a published rebuttal
specific to the contentions set forth in these articles (I am aware of
the discussion on oscillation in Business Dynamics).
Finally, if anyone can point me toward publications regarding the merits
of continuous-time vs. discrete time modeling, it would be greatly
appreciated.
Best regards,
Cory Welch
Articles referred to above:
Robert M. May "Simple mathematical models with very complicated
dynamics" Nature, Vol 261, June 10, 1976, pp. 459-467.
Robert M. May, George F. Oster "Bifurcations and Dynamic Complexity in
Simple Ecological Models" The American Naturalist, Vol. 110, No. 974
(Jul. - Aug., 1976), pp. 573-599
···
==================================================
Posted by John Sterman <jsterman@MIT.EDU>
A continuous time first-order system of the form
1. dx/dt = f(x)
cannot oscillate, whether it is linear or nonlinear. The system has
only one eigenvalue, so can never oscillate (even if it is
nonlinear). To get oscillation in continuous time requires at least
2 state variables. To get chaos in continuous time requires at least
three states and particular nonlinearities.
A discrete-time first-order system (mapping) of the form
2. x(t+1) = F(x(t))
can oscillate and, if it is nonlinear in a particular way, can
generate period doublings, chaos, and other interesting dynamics.
One way to think about this is to reformulate the discrete-time map
in continuous time. The difference-equation formulation implies that
there is a time delay of 1 "period" in the feedback loop from x to
its rate of change. Further, that delay is a "pipeline" delay:
output(t) = intput(t-L), where L is the length of the delay, in this
case, one "period". The pipeline delay is the limit of the Erlang
delay family as the order of the Erlang delay goes to infinity (it is
thus also called an infinite-order delay). Consequently, the
continuous time equivalent of the discrete-time mapping eq. 2. is
actually an infinite-order system. Such a system can oscillate of
course and can generate chaos etc.
Difference equations became popular (in economics, at least) because
economic data are typically published at regular intervals such as
quarterly or annually, and it was convenient for econometric
estimation to model economic dynamics as proceeding in discrete
steps. However, while difference equations are often useful, one
must be careful because there is an irreducible time delay of at
least 1 period in every feedback loop. If the length of this period
is long relative to the time constants for the real-world processes
being modeled, the result can be the introduction of spurious
dynamics (e.g., oscillations caused by the time step). Further, any
more complex delays must be integer multiples of the "period" between
time steps in the difference equations. This is often inappropriate
and inconsistent with the data.
It's generally better practice to model the dynamics of a system
continuously, explicitly representing relevant time delays as the
data suggest, including their mean and distribution, rather than
assuming a pipeline delay of 1 period in the updating of every state
variable.
John Sterman
Posted by John Sterman <jsterman@MIT.EDU>
posting date Fri, 1 Jun 2007 07:39:50 -0400
==================================================
Posted by yaman barlas <ybarlas@boun.edu.tr>
Dear Cory;
It IS possible for a 1st order time-discrete model (i.e difference) equation to
oscillate. It does NOT even have to be non-linear. Here is a short proof: take the
simplest linear, constant-coefficient, 1st order equation x(k+1) = ax(k).
Now try an a value between -1 and 0. You will get damped oscillations. For
a<-1, you will get growing oscillations. You may want to play with different
a's.
As for the interpretation: there is NO numerical stability/error problem here
at all. When you iterate this first order model, what you obtain is actually its
EXACT mathematical behavior. So, the true behavior of a first order
time-discrete system can be oscillatory.
What we are used to hear in SD community ('first order systems can not
oscillate') assumes the model is continuous.
It is great that you brought this up. The implication of this important
difference between continuous and discrete systems is that we must be careful
and EXPLICIT in our assumption in this respect. When we build a continuous
model, we must mean it and must never use arbitrary/careless dt values. (Such
dt values would imply some 'arbitrary' discrete-time models, with potentially
very different dynamics). Similarly, when we build time-discrete models and use
dt=1, we must again mean it and know the fact that would be delaing with quite
different dynamics. Time continuous and discrete models are quite different
creatures.
About your final question on chaos in the first order discrete logistic model,
yes, it is well known with this property. (The articles you refer to are very
important classics). Since this particular model is non-linear, it CAN exhibit
strange attractors and chaos, even though it is first order. Again, here is an
example: The simplest discrete logistic equation is: x(k+1) = ax(k)(1-x(k)).
It is known to start exhibiting near chaotic behavior, after a=3.8 and becoming
wilder and wilder as it approaches 4. Perhaps you may want to play with it?
best wishes,
Yaman Barlas
---------------------------------------------------------------------------
Professor, Industrial Engineering Dept.
Bogazici University,
34342 Bebek, Istanbul, TURKEY
Posted by yaman barlas <ybarlas@boun.edu.tr>
posting date Fri, 1 Jun 2007 19:44:18 +0300
_______________________________________________
================================================================
Posted by Scott Rockart <srockart@duke.edu>
Hi Cory,
Tu (Dynamical Systems, 2nd edition 1994, Springer-Verlag) has a nice concise discussion of limit cycles and chaotic behavior in difference and differential equations which makes specific use of the logistic equation as an example (see section 10.3). His discussion supports rather than refutes the conclusions that both oscillation and chaos are possible in the first order difference equations, but notes that continuous functions must be at least second order for limit cycles and third order for chaos.
Sterman makes similar points (omitting proofs) on page 290 of Business Dynamics (see footnote). In light of that, the debate seems to be whether and when the behavior of the difference equations reflect the behavior of the systems of interest rather than merely reflecting integration errors.
Best,
Scott
Posted by Scott Rockart <srockart@duke.edu>
posting date Fri, 01 Jun 2007 16:17:34 -0400
_______________________________________________