# Turing instability ch6-turing.ode # See Chapters 6.3.2 and 8.6.1 in our textbook for information about the Turing instability. x1'=sigma*x1^2/(1+y1)-x1 y1'=rho*(x1^2-y1)+D*(y2-y1) x2'=sigma*x2^2/(1+y2)-x2 y2'=rho*(x2^2-y2)+D*(y1-y2) # Set the default values of the parameters: # Don't put spaces between the parameter name, the equal sign, and the parameter value! par D=0.1,rho=2.5,sigma=2.5 # Set the default initial conditions: init x1=1.5 y1=4 x2=2 y2=4 # Set the default axes to project the solution trajectory onto the x2 versus x1 plane: @ xplot=x1, yplot=x2 # Set the default stopping time and time step @ total=20, dt=0.01 # Set the default viewing window @ xlo=0.0,xhi=3,ylo=0.0,yhi=3 done