function ShowRabbits()
% Predator-Prey Simulation

% The interaction parameter...
alpha = .01;

% The population densities for rabbits and foxes at time t(1)...
r(1) = 300;
f(1) = 150;
% This is a fixed point: r(1) = 1/alpha; f(1) = 2/alpha;
t(1) = 0;

% Simulate to t = tFinal taking n = nSteps
tFinal = 20;
nSteps = 1000;

% Step length...
h = tFinal/nSteps;

% Simulate...
for k=1:nSteps
drk = 2*r(k) - alpha*r(k)*f(k);
r(k+1) = r(k) + h*drk;
dfk = -f(k) + alpha*r(k)*f(k);
f(k+1) = f(k) + h*dfk;
t(k+1) = t(k)+h;
end
% Display...
plot(t,r,'k','linewidth',3)
hold on
plot(t,f,'r','linewidth',3)
legend('Rabbits','Foxes')
hold off

shg