plot a Matrix - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.
Our website is currently undergoing maintenance, which may result in occasional errors while browsing. We apologize for any inconvenience this may cause and are working swiftly to restore full functionality. Thank you for your patience.

Online Help

All Products    Maple    MapleSim


plots

  

matrixplot

  

3-D plot with z values determined by a matrix

 

Calling Sequence

Parameters

Options

Description

Examples

Compatibility

Calling Sequence

matrixplot(A, options)

Parameters

A

-

Matrix

options

-

(optional) equations of the form option=value where option is one of dimension, cellstyle, gap, color, colorbar, or other plot options

Options

• 

The remaining arguments are options specified as equations of the form option = value.  The matrixplot specific options are:

  

dimension=d

  

Where d is 2 or 3, and defaults to 3

  

cellstyle=s

  

Where s is either discrete or continuous, the default in three dimensions is continuous and in two dimensions is discrete. The older syntax heights=histogram is equivalent to cellstyle=discrete.

  

gap=r

  

The value of r is a real number between 0 and 1 and is only used for discrete style plots.

  

color=F

  

The color of the plot is given by F,  where F is a color specification as described in the plot/color help page. F can also be a two-argument procedure returning a single real value to be interpreted as a hue rather than RGB value.

  

colorbar=c

  

where c is true, false or a list of color bar options. The default is true for two-dimensional plots, and false for three dimensions. The options supported are described in plot/colorbar.

  

Other options are treated as general plot options. These include axes, view, title, labels, style, projection, and orientation.  See plot3d/option and plot/option.

Description

• 

The matrixplot function defines a three-dimensional graph where the x and y coordinates represent the row and column indices of A, respectively. The z values are the corresponding entries of A.

• 

The result of a call to matrixplot is a plot structure which can be rendered by the plotting device. You can assign a plot to a variable, save it in a file, then read it back in for redisplay.  See plot3d/structure for more information.

Examples

withplots:

withLinearAlgebra:

AHilbertMatrix8:BToeplitzMatrix1,2,3,4,4,3,2,1,symmetric:

matrixplotA·B

matrixplotA·B,dimension=2

matrixplotA+B,cellstyle=discrete,axes=boxed

matrixplotA+B,cellstyle=discrete,gap=0.25,axes=frame

matrixplotA+B,dimension=2,cellstyle=continuous

Fx,ysinyx:

matrixplotA+B,cellstyle=discrete,gap=0.25,color=F,axes=frame

LHilbertMatrix4,5

L112131415121314151613141516171415161718

(1)

matrixplotL

YMatrix20,3,i,jevalf1+sinijπ,datatype=float8:

plots:-matrixplotY,cellstyle=discrete,gap=0.5,`=`color,x,y1.2y3,orientation=55,55,0,labels=,,

The command to create the plot from the Plotting Guide is

matrixplotA

Compatibility

• 

The plots[matrixplot] command was updated in Maple 2024.

• 

The dimension, cellstyle and colorbar options were introduced in Maple 2024.

• 

For more information on Maple 2024 changes, see Updates in Maple 2024.

See Also

LinearAlgebra

LinearAlgebra:-HilbertMatrix

LinearAlgebra:-ToeplitzMatrix

Matrix

plot/color

plot/option

plot3d

plot3d/option

plot3d/structure

plots:-listcontplot

plots:-listcontplot3d

plots:-sparsematrixplot

read

save

 


Download Help Document