Here we were looking at solutions of the predator-prey problem: dx/dt = x - 4*x*y dy/dt = -y + 2*x*y >> help sys_runge_kutta_2 the program takes the intial data x_0 and y_0 at the initial time t_0 and computes up to time t_final using n timesteps. It creates three vectors, t, x and y, which you can then plot against each other plot(x,y), hold on, plot(x(1),y(1),'o') [t,x,y] = sys_runge_kutta_2(x_0,y_0,t_0,t_final,n) >> x_0 = 1; y_0 = 1; t_0 = 0; t_final = 30; n = 1000; >> [t,x,y] = sys_runge_kutta_2(x_0,y_0,t_0,t_final,n); >> figure(2) We find that the solution appears to go in a counter-clockwise orbit around the fixed point (1/2,1/4): >> plot(x,y) >> figure(1) We find that the solutions appear to be periodic in time, with the expected behavior when viewed in terms of predator and prey. >> plot(t,x), hold on; plot(t,y,'r-'); Next... consider dx/dt = a*x - b*x*y dy/dt = -c*y + d*x*y and play around with the parameters a,b,c, and d. Also, fix the parameters and play around with the initial data. >> diary off