Commit cf2f7a6e authored by Diego Jahn's avatar Diego Jahn
Browse files

Add model

parent 06b792e8
<MorpheusModel version="4">
<Details>Example showing Predator-prey model by Rosenzweig.
The Rosenzweig model is the Lotka-Volterra model with logistic growth and type 2 functional response.
Rosenzweig, Michael. 1971. "The Paradox of Enrichment" Science Vol. 171: pp. 385–387
Illustrates how to
- create a simple ODE model
- log and plot data as time course</Details>
<Variable value="0.1" symbol="N"/>
<Variable value="0.5" symbol="P"/>
<System time-step="0.1" solver="Runge-Kutta [fixed, O(4)]">
<Constant name="halftime" value="0.5" symbol="a"/>
<Constant name="growth rate" value="0.1" symbol="r"/>
<Constant name="consumption rate" value="0.1" symbol="c"/>
<Constant name="conversion rate" value="0.05" symbol="b"/>
<Constant name="mortality rate" value="0.01" symbol="m"/>
<Constant name="Carrying capacity" value="0.8" symbol="K"/>
<DiffEqn symbol-ref="N">
<Expression>r*N*(1-N/K) - c*N / (a+N)*P
<DiffEqn symbol-ref="P">
<Expression>b*N / (a+N)*P - m*P</Expression>
<!-- <Disabled>
<Function symbol="c">
<Expression>0.1 + time*0.00001</Expression>
<Event trigger="when true" time-step="1">
<Condition>N &lt; 0.001</Condition>
<Rule symbol-ref="N">
<Lattice class="linear">
<Size value="1, 0, 0" symbol="size"/>
<SpaceSymbol symbol="space"/>
<StartTime value="0"/>
<StopTime value="5000" symbol="stoptime"/>
<TimeSymbol symbol="time"/>
<Logger time-step="5">
<Symbol symbol-ref="N"/>
<Symbol symbol-ref="P"/>
<TextOutput file-format="csv"/>
<Plot time-step="-1">
<Style style="lines" line-width="2.0"/>
<Terminal terminal="png"/>
<Symbol symbol-ref="time"/>
<Symbol symbol-ref="N"/>
<Symbol symbol-ref="P"/>
<Plot time-step="-1">
<Style style="lines" line-width="2.0"/>
<Terminal terminal="png"/>
<Symbol symbol-ref="N"/>
<Symbol symbol-ref="P"/>
<Color-bar palette="rainbow">
<Symbol symbol-ref="time"/>
<ModelGraph include-tags="#untagged" format="svg" reduced="false"/>
MorpheusModelID: M0005
authors: [M. L. Rosenzweig]
title: "Predator-prey model by Rosenzweig"
date: "2021-01-19T12:42:00+01:00"
lastmod: "2021-02-30T17:04:00+01:00"
- /model/M0005/
- /models/M0005/
- Logger
- Lotka–Volterra Equations
- Predator–Prey
Built-in Examples:
parent: ODE
weight: 50
weight: 60
## Introduction
This model implements an extension of the well-known [Lotka-Volterra system](
It illustrates how to
- create a simple ODE model and
- log and plot data as time course.
![](predator-prey.png "Output of predator-prey example model.")
## Description
The [Rosenzweig model](#reference) is the Lotka-Volterra model with logistic growth and type 2 functional response.
First, the `Space` and `Time` of a simulation is specified, here defined as a single lattice site and $5000\ \mathrm{atu}$ (arbitrary time units). In `Global` (see figure below), two `Variable`s for predator and prey densities are set up. The differential equations themselves are specified in a `System` which consists of a number of `Constant`s and two `DiffEqn` (differential equations) and are computed using the `runge-kutta` solver.
![](predator-prey-global-section.png "Global section of the model.")
Output in terms of a text file as well as a plot is created by a `Logger`, the plugin in the `Analysis` section.
## Things to try
- Bring the system into a stable steady state (fixed point, no oscillations) by changing parameters in `Global`/`System`/`Constant`.
## Reference
>M. L. Rosenzweig: [Paradox of Enrichment: Destabilization of Exploitation Ecosystems in Ecological Time][reference]. *Science* **171** (3969): 385-387, 1971.
\ No newline at end of file
In Morpheus GUI: ```Examples``````ODE``````PredatorPrey.xml```.
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment