next up previous
Next: Homework - optional Up: No Title Previous: Cobwebbing

The predator-prey model revisited

Consider the two-dimensional example:

\begin{eqnarray*}x_{n+1} & = & rx_{n}(1-x_{n})-ax_{n}y_{n}\\
y_{n+1} & = & gy_{n}+bx_{n}y_{n}

This is a predator-prey model, with xn the prey and yn the predators. We have seen in class that if the parameter b is large enough, then there is a coexistent state in which there are both predators and prey. However, we also showed that if b gets too large, this coexistent state is unstable. So what happens? The loss of stability is through a pair of complex eigenvalues, so theory says we can expect an invariant circle (almost periodic behavior). Here is the ODE file:
# discrete predator prey
par g=.8,b=1.5,a=1,r=2.5
init y=1.17,x=.13
@ meth=discrete,total=200
We will look at the phaseplane. Click on /ppcViewaxes /ppc2D ( \fbox{{\bf v}} \fbox{{\bf 2}}) and fill in the resulting dialog box as follows:
\fbox{\begin{tabular}{l\vert l}
{\tt X-axis:} X & {\tt Xmax:} 1 \\
... Xlabel:} prey \\
{\tt Ymin:} 0 & {\tt Ylabel:} predator
and click on \fbox{{\tt Ok}}. You have now set it up to plot prey along the X-axis and predators along the Y-axis. Lastly, we want to make sure only dots are plotted so we will edit the graphics curve. Click on \fbox{{\tt Graphic stuff}} \fbox{{\tt Edit Curve}} ( \fbox{{\bf g}} \fbox{{\bf e}}) and accept 0 as the curve to edit by clicking \fbox{{\bf Enter}}. Now change the Line type in the dialog box from 1 to 0 and click on \fbox{{\tt Ok}}. Linetype 0 is just a point. Run the simulation ( \fbox{{\bf i}} \fbox{{\bf g}}). You should just see a dot. Now change the initial conditions to (x=.6, y=.01) to simulate a whole lot of rabbits and a small number of foxes. Click on \fbox{{\tt Go}} in the Initial Data Windowand watch those rabbits get eaten. Not the spiraling in toward the equilibrium. Change the parameter b to 2.2, erase the screen (in Main Window, tap \fbox{{\bf e}}), and rerun the simulation. You should see an invariant circle appear in which neither settles to a steady state, but rather, they tend to a closed curve. Add more iterates to the simulation by clicking \fbox{{\tt Continue}} and typing in, say 800. The circle is more evident. Quit if you want, or continue to fool around. To quit tap \fbox{{\bf f}} \fbox{{\bf q}} \fbox{{\bf y}}.

next up previous
Next: Homework - optional Up: No Title Previous: Cobwebbing
G. Bard Ermentrout