plottools - Maple Programming Help

# Online Help

###### All Products    Maple    MapleSim

Home : Support : Online Help : Graphics : Packages : Plot Tools : plottools/scale

plottools

 scale
 scale PLOT and PLOT3D data structures

 Calling Sequence scale(p, a, b, pt_2d) scale(q, a, b, c, pt_3d)

Parameters

 p - PLOT data structure q - PLOT3D data structure a, b, c - real numbers; scale factors in the x, y and z directions pt_2d - (optional) list of two real numbers specifying the center of the scale (for the 2-D case) pt_3d - (optional) list of three real numbers specifying the center of the scale (for the 3-D case)

Description

 • The scale command takes a plot structure and produces a new plot structure scaled by the specified values with respect to the center (pt_2d for the 2-D case or pt_3d for the 3-D case). If pt_2d or pt_3d is not specified, the default center is at the origin.
 • The inputs p or q must be two- or three-dimensional plot data structures or objects, while a, b, and c are real numbers representing the scale factors in the x, y and z directions.
 • The result of a call to scale is a PLOT or PLOT3D data structure or object containing information to render the plot. You can assign the data structure to a variable, save it in a file, then read it back in for redisplay.  For more information about plot data structures, see plot/structure or plot3d/structure.
 • Several commands in the plottools package can transform plots. For a list, see the plottools help page.  The plots[changecoords] and plots[display] commands can also be used to transform plots.

Examples

 > $\mathrm{with}\left(\mathrm{plottools}\right):$
 > $\mathrm{with}\left(\mathrm{plots}\right):$
 > $p≔\mathrm{plot}\left(\left[\mathrm{sin}\left(x\right),x,x=0..2\mathrm{π}\right]\right):$
 > $s≔\mathrm{scale}\left(p,2,3\right):$
 > $\mathrm{display}\left(p,s\right)$
 > $q≔\mathrm{plot3d}\left(\mathrm{sin}\left(x+y\right),x=-1..2\mathrm{π},y=0..\mathrm{π}\right):$
 > $s≔\mathrm{scale}\left(q,3,1,\frac{1}{2}\right):$
 > $\mathrm{display}\left(q,s,\mathrm{axes}=\mathrm{frame},\mathrm{lightmodel}=\mathrm{light2},\mathrm{orientation}=\left[-100,65\right],\mathrm{shading}=\mathrm{zgrayscale},\mathrm{style}=\mathrm{patchnogrid}\right)$
 > $c≔\mathrm{circle}\left(\left[0,0\right],2\right):$
 > $\mathrm{display}\left(c,\mathrm{scale}\left(c,\frac{1}{3},\frac{1}{3}\right),\mathrm{color}=\mathrm{blue},\mathrm{scaling}=\mathrm{constrained}\right)$

 See Also

## Was this information helpful?

 Please add your Comment (Optional) E-mail Address (Optional) What is ? This question helps us to combat spam