plot the 3-D solutions to a system of DEs
DEplot3d(deqns, vars, trange, inits, options)
DEplot3d(deqns, vars, trange, inits, xrange, yrange, zrange, options)
DEplot3d(deqns, vars, trange, xrange, yrange, zrange, options)
list or set of ordinary differential equations
list or set of dependent variables
range of the independent variable
set or lists of lists; initial conditions for solution curves
range of the first dependent variable
range of the second dependent variable
range of the third dependent variable
(optional) equations of the form keyword=value
Given a system of differential equations and a list of initial conditions, specified by inits, DEplot3d produces a three-dimensional representation of the solution curves of the system. There can be only one independent variable.
Direction fields, as found in DEplot, can also be plotted for autonomous systems with at most 3 first-order dependent variables, or non-autonomous systems with at most 2 first-order dependent variables, by specifying the arrows option.
The default method of integration is method=rkf45. Other methods can be specified in the optional equations. Note that because numerical methods are used to generate plots, the output is subject to the characteristics of the numerical method in use. In particular, unusual output may occur when dealing with asymptotes of solution curves. This also means that the initial conditions of the problem must be given in standard form, that is, the function values and all derivatives up to one less than the differential order of the differential equation at the same point.
Three of the dependent variables are plotted, or the independent variable and two dependent variables (for a 2-system). Other views can be specified using the scene option.
By default, plots are produced with boxed axes.
The inits parameter must take the form of
inits is a list (or set) of lists, each sublist specifying one group of initial conditions (for one solution curve).
The xrange, yrange and zrange parameters must be specified as follows.
x⁡t=x1..x2, y⁡t=y1..y2, z⁡t=z1..z2 or
x=x1..x2, y=y1..y2, z=z1..z2
By default, integration along a solution curve stops one mesh point after the specified range is exceeded. This may be overridden by the obsrange option.
The optional equations, options, consist of the following, as well as a restricted set of plot3d and dsolve[numeric] options.
animatecurves = true or false (default=false)
animatecurves creates an animation of the evolving solution curve from the specified initial value(s) with respect to time. The default number of animation frames is 25, which can be changed with the numframes option. dsolve[numeric] is used to compute the solution curves for all specified initial values at different times. Note that if numpoints is provided, and the number of intervals (numpoints−1) does not divide evenly by the number of frame intervals (numframes−1), then a warning is produced, and numpoints is modified to be numpoints−1numframes−1⁢numframes−1+1.
animatefield = true or false (default = false)
animatefield creates an animation of the direction field with respect to time (that is, the arrows describing the direction field move as a solution with respect to time). The default number of animation frames is 25, which can be changed with the numframes option. dsolve[numeric,rkf45] is used to compute the trajectory of each arrow.
animate = true or false (default = false)
animate is a shortcut that can be used to specify that both animatefield (if applicable) and animatecurves (if applicable) be used.
arrows = arrowtype
arrowtype consists of 'cheap', 'hex', 'hybrid', or 'none'
The arrowtype indicates the type of arrow to be used in a direction field. The default is 'none', which suppresses the calculation and display of any direction fields.
color, colour = arrowcolor
arrowcolor can take many forms: 1) a plot[color] name; 2) COLOR('HUE', realcons); 3) COLOR('RGB', realcons, realcons, realcons); 4) the literal 'magnitude'; 5) magnitude[plot[color] name, plot[color] name]; 6) an expression in three variables; 7) a procedure in three variables; 8) a three-element list of expressions in three variables; or 9) a three-element list of procedures in three variables.
In case 4), the color of the arrows is determined by the magnitude of the field, where blue is used for the lowest magnitude, and red is used for the highest. Case 5) is identical to case 4), but the low and high magnitude colors are specified as the indices of magnitude (for example, magnitude is equivalent to magnitude[blue,red]). In cases 6) and 7), coordinates of the arrows in the plane are passed to the expression or procedure. The resulting values are then normalized on the range [0,1] and used as 'HUE' values. In cases 8) and 9), the resulting values are normalized on [0,1] and used as RGB values. Note that 6) and 8) must contain expressions of the plotted variables. This form of color handling is useful in differentiating features of the direction field.
The default arrow color is red.
dirfield = [posint,posint,posint], posint, or [[float,float,float],[float,float,float],...]
If [posint,posint,posint] is used, it specifies a grid on which to place the arrows. If posint is used, it specifies the number of randomly positioned arrows to use for the direction field. If [[float,float,float],[float,float,float],...] is used, each sublist describes a point at which an arrow is to be drawn.
iterations = integer
iterations indicates the number of steps to be taken, of size stepsize, between stored points. This is useful in gaining a higher accuracy of plotted points by a small stepsize, without storing and plotting a large number of points.
linecolor, linecolour = color_info
color_info may take one of five forms: 1) a plot[color] name; 2) COLOR('HUE', realcons); 3) COLOR('RGB', realcons, realcons, realcons); 4) an expression of the independent variable; or 5) a procedure of the independent variable.
In the case of 4) and 5), values of the independent variable are passed to the expression or procedure. The resulting values are then normalized on 0,1 and applied as 'HUE' values. This color handling is useful in displaying how the solution curve varies with the independent variable.
In addition, forms 1) to 5) can be combined into a list, one element for each of the solution curves considered. Each list element is then applied to a corresponding solution curve.
Default coloring is handled internally by the Maple plotting routines.
numframes = posint
numframes specifies the number of frames used for animations, using any of the animate, animatefield, or animatecurves options.
obsrange = true or false
obsrange indicates whether the integrator should stop once the solution curve has passed outside the specified range. It also specifies that any arrows that pass completely outside the viewing area should be removed (for an arrow-based animation). This is useful in the plotting of functions with asymptotic behavior. The default is true.
scene = [name, name, name]
scene specifies the plot to be viewed. For example, scene = [x, y, z] indicates that the plot of x versus y versus z is to be plotted, with t implicit, while scene = [t, y, z] plots t versus y versus z (t explicit). This option can also be used to change the order in which to plot the variables. If vars is entered as a set, there is no default ordering; if entered as a list, the given ordering is used.
size = float or magnitude
When size=magnitude, the size of the arrows is proportional to the magnitude of the direction field. When size is specified as a positive floating-point value, then this value is used to modify the size of all arrows in the direction field. The default value is size=1.0.
stepsize = realcons
stepsize specifies the distance between mesh points to be used in generating the graph. For trange=a..b, the default stepsize value is b−a20. If the stepsize specified is too large, the default is used.
Note that the solution curves are plotted with a default line thickness of 3, but this can be changed with the thickness plot option.
There are many other optional equations, as supplied in plot3d and dsolve[numeric]. For more information, see plot3d[options] and the individual dsolve[numeric] help files.
Example with an animated direction field
r := .7*sqrt(x(t)^2+y(t)^2+z(t)^2):
LimCyc := [diff(x(t), t) = sin(r)*x(t)+y(t),
diff(y(t), t) = sin(r)*y(t)-z(t),
diff(z(t), t) = sin(r)*z(t)+x(t)]:
DEplot3d(LimCyc, [x(t),y(t),z(t)], t=0..10, [[x(0)=50, y(0)=20, z(0)=25],
[x(0)=20, y(0)=10, z(0)=15], [x(0)=15, y(0)=5, z(0)=5]], dirfield=50,
numpoints=300, color=[blue,red], axes=box, arrows=hybrid,
animatefield=true, numframes=75, orientation=[60, 55], obsrange=false);
The command to create the plot from the Plotting Guide is
The zrange parameter was introduced in Maple 15.
The animatecurves, animatefield, animate, arrows, color, dirfield, numframes and size options were introduced in Maple 15.
For more information on Maple 15 changes, see Updates in Maple 15.
Download Help Document
What kind of issue would you like to report? (Optional)