
Plotting Trigonometric Functions


•

Tickmarks in multiples of $\mathrm{\pi}$ are now added to plots generated by the plot and plot3d commands when $\mathrm{\pi}$ is detected in the range arguments.

>

plot3d(cos(x)*sin(y), x=Pi..Pi, y=Pi..Pi, 'axes'='boxed');

•

The range argument for the plot command is optional. When this is omitted, the default range is now set to 2*Pi..2*Pi instead of 10..10 when a trigonometric function is detected in the expression to be plotted.

>

plot([cos(x), sin(x)]);

•

Plots created using the Plot Builder or through the context menu also set the default range to 2*Pi..2*Pi when a trigonometric function is detected.

•

When specifying $\mathrm{\pi}$ tickmarks with the tickmarks or axis option, you can now use the name piticks instead of the spacing suboption. Similarly, if you want to remove $\mathrm{\pi}$ tickmarks that were automatically added, you can use the decimalticks value for the tickmarks option.

>

plot(sin(x), x = 0 .. 2*Pi, tickmarks = [decimalticks, piticks]);



Improved Captions for Plots and Tutors


•

Visualization plots and tutors in the Student packages have improved captions, including formatted 2D mathematics describing the graph.



Extracting Data from Plots


•

The new getdata command in the plottools package retrieves data from a 2D or 3D plot and returns it in the form of a Matrix or Array, along with the ranges of the data. More details are available in the plottools[getdata] help page.

>

plottools[getdata](plot([sin(x), x^22*x], x = 2 .. 2));



More Control over Plots of 3D Solutions to a System of DEs


•

The DEplot3d command in the DEtools package has been enhanced, with the addition of 3d field arrows, and the ability to animate either curves, arrows, or both.


Example of a command to plot field arrows:

>

with(DEtools,DEplot3d):

>

DEplot3d({diff(x(t),t)=y(t),diff(y(t),t)=sin(x(t))},[x(t),y(t)],t=0..10,
[[x(0)=0,y(0)=.5],[x(0)=0,y(0)=1],[x(0)=0,y(0)=1.8],[x(0)=2*Pi,y(0)=1],
[x(0)=2*Pi,y(0)=.5],[x(0)=2*Pi,y(0)=2.1],[x(0)=2*Pi,y(0)=2.1]],
orientation=[5,85],linecolor=sin(t)t,arrows=cheap);


Same system animating the solution curves:

>

DEplot3d({diff(x(t),t)=y(t),diff(y(t),t)=sin(x(t))},[x(t),y(t)],t=0..10,
[[x(0)=0,y(0)=.5],[x(0)=0,y(0)=1],[x(0)=0,y(0)=1.8],[x(0)=2*Pi,y(0)=1],
[x(0)=2*Pi,y(0)=.5],[x(0)=2*Pi,y(0)=2.1],[x(0)=2*Pi,y(0)=2.1]],
orientation=[5,85],linecolor=sin(t)t,animate=true);



Improved Options for Animations


•

The background and trace options for the animate command in the plots package have been improved. For more information, see the plots[animate] help page.

•

The background option now accepts a list of plots in addition to a single plot. The plots are automatically combined with the plots[display] command to form a single background plot.


Note: To run animations, rightclick ( Commandclick, Macintosh) the plot, and select Animation > Play.

>

plots[animate](plot, [t*x^2, x=1..1], t=0..1, 'background'=[plot(.5, 1..1, 'color'="Blue"), plots[pointplot]([0, 0], 'symbol'='solidbox', 'color'="Green", 'symbolsize'=30)]);

•

The trace option now allows you to specify a list of the frames to be traced during the animation, as an alternative to having a number of equally spaced frames.

>

plots[animate](plot, [t*x^2, x = 1..1], t=0..1, 'trace'=[1, 2, 3, 23, 24, 25]);



