In the first example below, the domain specified by vectors x
and y
are transformed into two arrays which can be used to evaluate functions of two
variables and three-dimensional surface plots. The rows of the output array
x
are copies of the vector x
; columns of the output array y
are copies of the vector y
.
The second example below is syntactic sugar for specifying
meshgrid(x, x)
.
The third example below produces three-dimensional arrays used to evaluate
functions of three variables and three-dimensional volumetric plots.