gtm_rctg

Produces a 2D grid with points arranged in a rectangular lattice.

The grid is centered on the origin and scaled so the dimension (X or Y) with largest number of points ranges from -1 to 1.

Synopsis

grid = gtm_rctg(xDim, yDim)

Arguments

xDim, yDim - number of points along the X and Y dimensions, respectively; must be >=2.

Return

grid - a (xDim*yDim)-by-2 matrix of grid points with the first point being the top-left corner and subsequent points following column-wise.

See also

gtm_hxg


The GTM Toolbox: Contents