Ecosystem Modeling I Kate Hedstrom, ARSC November 2008.

Slides:



Advertisements
Similar presentations
Finite Difference Discretization of Hyperbolic Equations: Linear Problems Lectures 8, 9 and 10.
Advertisements

Differential Equations
Numerical Methods for Partial Differential Equations CAAM 452 Spring 2005 Lecture 9 Instructor: Tim Warburton.
PLOTTING PHASE PORTRAITS WITH MATLAB:
Chapter 8 Elliptic Equation.
Modeling with Systems of Differential Equations
Predation (Chapter 18) Predator-prey cycles Models of predation
Chapter 6 Models for Population Population models for single species –Malthusian growth model –The logistic model –The logistic model with harvest –Insect.
Living organisms exist within webs of interactions with other living creatures, the most important of which involve eating or being eaten (trophic interactions).
1 Predator-Prey Oscillations in Space (again) Sandi Merchant D-dudes meeting November 21, 2005.
Sect. 6.6: Damped, Driven Pendulum Consider a plane pendulum subject to an an applied torque N & subject to damping by the viscosity η of the medium (say,
Computational Biology, Part 17 Biochemical Kinetics I Robert F. Murphy Copyright  1996, All rights reserved.
Atms 4320 Lab 2 Anthony R. Lupo. Lab 2 -Methodologies for evaluating the total derviatives in the fundamental equations of hydrodynamics  Recall that.
Computer-Aided Analysis on Energy and Thermofluid Sciences Y.C. Shih Fall 2011 Chapter 6: Basics of Finite Difference Chapter 6 Basics of Finite Difference.
AOSS 321, Winter 2009 Earth System Dynamics Lecture 11 2/12/2009 Christiane Jablonowski Eric Hetland
Lecture 34 - Ordinary Differential Equations - BVP CVEN 302 November 28, 2001.
Chapter 9 Differential equations
Dynamical Systems Analysis II: Evaluating Stability, Eigenvalues By Peter Woolf University of Michigan Michigan Chemical Process Dynamics.
Ordinary Differential Equations (ODEs) 1Daniel Baur / Numerical Methods for Chemical Engineers / Implicit ODE Solvers Daniel Baur ETH Zurich, Institut.
Particle Systems Ed Angel Professor of Computer Science, Electrical and Computer Engineering, and Media Arts Director, Arts Technology Center University.
1 Chapter 9 Differential Equations: Classical Methods A differential equation (DE) may be defined as an equation involving one or more derivatives of an.
Numerical Methods for Partial Differential Equations CAAM 452 Spring 2005 Lecture 2 Instructor: Tim Warburton.
MATH 685/ CSI 700/ OR 682 Lecture Notes Lecture 10. Ordinary differential equations. Initial value problems.
Numerical Solutions to ODEs Nancy Griffeth January 14, 2014 Funding for this workshop was provided by the program “Computational Modeling and Analysis.
Continuous Time Signals
The Nature of Exponential Growth Writing growth and decay problems with base e.
Lecture 35 Numerical Analysis. Chapter 7 Ordinary Differential Equations.
Tutorial 5: Numerical methods - buildings Q1. Identify three principal differences between a response function method and a numerical method when both.
Autumn 2008 EEE8013 Revision lecture 1 Ordinary Differential Equations.
1 Chapter 8 Ordinary differential equation Mathematical methods in the physical sciences 3rd edition Mary L. Boas Lecture 5 Introduction of ODE.
Math 3120 Differential Equations with Boundary Value Problems Chapter 2: First-Order Differential Equations Section 2-6: A Numerical Method.
1 Spring 2003 Prof. Tim Warburton MA557/MA578/CS557 Lecture 5a.
Ch 9.5: Predator-Prey Systems In Section 9.4 we discussed a model of two species that interact by competing for a common food supply or other natural resource.
Boyce/DiPrima 9 th ed, Ch 8.5: More on Errors; Stability Elementary Differential Equations and Boundary Value Problems, 9 th edition, by William E. Boyce.
Computational Biology, Part 15 Biochemical Kinetics I Robert F. Murphy Copyright  1996, 1999, 2000, All rights reserved.
Ch 9.8: Chaos and Strange Attractors: The Lorenz Equations
LURE 2009 SUMMER PROGRAM John Alford Sam Houston State University.
Integration of 3-body encounter. Figure taken from
Linear Equations in Two Variables A Linear Equation in Two Variables is any equation that can be written in the form where A and B are not both zero.
Chapter 2 Laplace Transform 2.1 Introduction The Laplace transform method can be used for solving linear differential equations. Laplace transforms can.
MA/CS 375 Fall MA/CS 375 Fall 2002 Lecture 12.
Ch 1.3: Classification of Differential Equations
Gravity waves derivation ATM Fall, Introduction Gravity waves describe how environment responds to disturbances, such as by oscillating parcels.
Motivation As we’ve seen, chaos in nonlinear oscillator systems, such as the driven damped pendulum discussed last time is very complicated! –The nonlinear.
Subsea Control and Communications Systems
Modelling concepts Modelling in discrete time (difference equations, also known as updating equations) Modelling in continuous time (differential equations)
An Overview of Biogeochemical Modeling in ROMS
Ch 8.2: Improvements on the Euler Method Consider the initial value problem y' = f (t, y), y(t 0 ) = y 0, with solution  (t). For many problems, Euler’s.
ECE 576 – Power System Dynamics and Stability Prof. Tom Overbye Dept. of Electrical and Computer Engineering University of Illinois at Urbana-Champaign.
Game Technology Animation V Generate motion of objects using numerical simulation methods Physically Based Animation.
Ordinary Differential Equations
Lecture 39 Numerical Analysis. Chapter 7 Ordinary Differential Equations.
Ecosystem Modeling II Kate Hedstrom, ARSC November 2006 With help from Sarah Hinckley, Katja Fennel, Georgina Gibson, and Hal Batchelder.
1 Spring 2003 Prof. Tim Warburton MA557/MA578/CS557 Lecture 25.
Predator/Prey. Two big themes: 1.Predators can limit prey populations. This keeps populations below K.
Time Integration Schemes Bill Skamarock NCAR/MMM 1.Canonical equations for scheme analyses. 2.Time-integration schemes used in NWP models.
Ch 9.6: Liapunov’s Second Method In Section 9.3 we showed how the stability of a critical point of an almost linear system can usually be determined from.
Computational Models.
Lecture 4: Numerical Stability
Laplace Transforms Chapter 3 Standard notation in dynamics and control
ECE 576 – Power System Dynamics and Stability
Mechanical Engineering at Virginia Tech
AOSS 321, Winter 2009 Earth System Dynamics Lecture 11 2/12/2009
Differential Equations:
CSE 245: Computer Aided Circuit Simulation and Verification
6.1 day 2 Euler’s Method Leonhard Euler made a huge number of contributions to mathematics, almost half after he was totally blind. (When this portrait.
5.3 Higher-Order Taylor Methods
Reading Between the Lines!
Presentation transcript:

Ecosystem Modeling I Kate Hedstrom, ARSC November 2008

Annual Phytoplankton Cycle Strong vertical mixing in winter, low sun angle keep phytoplankton numbers low Spring sun and reduced winds contribute to stratitification, lead to spring bloom Stratification prevents mixing from bringing up fresh nutrients, plants become nutrient limited, also zooplankton eat down the plants

Annual Cycle Continued In the fall, the grazing animals have declined or gone into winter dormancy, early storms bring in nutrients, get a smaller fall bloom Winter storms and reduced sun lead to reduced numbers of plants in spite of ample nutrients We want to model these processes to better understand them and their interannual variability

One Species The equation for one species, growing without bounds: The known solution to this ordinary differential equation:

Difference Equation Replacing the time derivative with a finite change: Solving for the new time as a function of the old time:

Sticking in Some Numbers Try b = 0.1, delta t = 1, initial N = 10 If the units are days, we have e times more critters after 10 days In the plot, green is the exact solution while blue is the approximate solution using a one- day timestep

Linear Plot

Log Plot

Sources of Errors Size of timestep relative to timescales in the problem Numerical scheme Roundoff errors How do you tell which is the trouble here? Since the numerical growth is also exponential, we can adjust (tune) the time constant to obtain the correct solution

Two Species First rate equations for two species (one prey, one predator) were written by Lotka and Volterra during the 1920’s and 1930’s: Coupled, nonlinear, differential equations N 1 is prey, N 2 is predator, b, d, K 1, K 2 are constants, t is time

Assumptions Prey will grow exponentially without limit if no predators Rate of prey being eaten is proportional to the number of prey and the number of predators New predators happen immediately after eating prey No other prey options

Steady Solution No change in time: Trivial solution is N 1 = N 2 = 0 Any solution satisfying the following is also steady:

Difference Equations We can make an approximation to the differential equations by assuming finite timesteps: These equations can be solved on a computer Need initial values for N 1, N 2, plus values for the constants

Numerical Solution One steady solution is given by N 1 =1000, N 2 =10, d=0.1, b=0.1, K 1 =0.01, K 2 = Using delta t =1, we get the steady solution numerically Any perturbation from the initial values for N 1 and N 2 will lead to expanding oscillations.

Initial N 1 =999

Initial N 1 =980

Red is ten times predator, blue is prey Horizontal axis is time Uncontionally unstable

Why the instability? Invalid assumption in the equations –No limit to the number of prey supported –No alternate prey Unstable numerical scheme Did you code it right?

Limit on the Prey Modifying the growth term for an environment that supports up to M prey: This equation is nonlinear, harder to solve exactly Growth rate becomes negative if N 1 > M

One Species

Limiter in Lotka-Volterra Model

Lotka-Volterra PZ Model Same model as the original two component model: Different constants: P=N 1 =75, Z=N 2 =10, b=a=1, etc. Need a smaller timestep than one day for such large growth rates

dt=0.1 dt=0.001

Hmmm The author is obviously using dt=0.1 He then adds a Z cannibalism term to damp the oscillations: This acts very much like the damper on the prey species

My Results with Cannibalism

Planetary Orbits

Euler Timestep and Orbits

Leapfrog Step Second-order accurate Stable for orbits Even steps and odd steps are decoupled

Timestepping Schemes Euler –Unconditionally unstable for some classes of problems –Errors are linear in delta t (low order) Others –There are many, many other options –Some are higher order –Each has its own stability properties

Back to Lotka-Volterra Euler step, dt=0.01

Leapfrog-Trapezoidal Step Second-order accurate, more stable

Large Amplitude Cycles

Conclusions Lotka-Volterra is cyclic, not unstable Simple-minded numerical schemes can get us in trouble Putting in more terms can lead to realistic-looking results, such as the limits on exponential growth More complex ecosystem models still use Euler stepping with the damping terms

Questions Timestep vs. timestepping scheme Data - growth rate data, say, to improve or disprove a model Error bars