Economics Dynamics Problems 209

Economics Dynamics Problems 209 - Systems of first-order...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Systems of first-order differential equations In a two-equation system, the programme will produce a direction field plot by default if the system is a set of autonomous equations. Since we require only the solution curves, then we include an option that indicates no arrows. To illustrate the points just made, consider the Van der Pol model, equation (4.28), a simple set of instructions to produce a Maple plot similar to figure 4.30 is phaseportrait( [D(x)(t)=y(t), D(y)(t)=(1-x(t)^2)*y(t)-x(t)], [x(t),y(t)], t=0..10, [ [x(0)=0.5,y(0)=0.5],[x(0)=0.5,y(0)=4] ], stepsize=.05 linecolour=blue, arrows=none, thickness=1); Producing more solution curves in Maple is just a simple case of specifying more initial conditions. For instance, a Maple version of figure 4.36(b) can be produced with the following instructions: with(DEtools): phaseportrait( [D(x)(t)=1-y(t),D(y)(t)=x(t)^2+y(t)^2], [x(t),y(t)], t=0..3, [[x(0)=-2,y(0)=-1],[x(0)=-1.75,y(0)=-1], [x(0)=1.5,y(0)=-1],[x(0)=-1,y(0)=0], [x(0)=-1,y(0)=-1], [x(0)=-0.5,y(0)=-1], [x(0)=0,y(0)=-1], [x(0)=-1.25,y(0)=0], [x(0)=0.5,y(0)=-1, [x(0)=1,y(0)=-1]], x=-2..2, y=-1..3, stepsize=.05, linecolour=blue, arrows=none, thickness=1); Trajectories for three-dimensional plots are also possible with Maple. Consider once again the Lorenz curve, given in equation (4.34), with parameter values σ = 10, r = 28 and b = 8/3. We can construct a three-dimensional trajectory from the initial point (x0, y0, z0) = (5, 0, 0) using the following input instructions: with(DEtools): DEplot3d( [diff(x(t),t)=10*(y(t)-x(t)), diff(y(t),t)=28*x(t)-y(t)-x(t)*z(t), diff(z(t),t)=x(t)*y(t)-(8/3)*z(t)], [x(t),y(t),z(t)], t=0..30, [[x(0)=5,y(0)=0,z(0)=0]], stepsize=.01, linecolour=BLACK, thickness=1); 193 ...
View Full Document

Ask a homework question - tutors are online