GRID
Random Points on a Uniform Grid


GRID is a C++ library, using double precision arithmetic, to randomly select N points on a uniform grid in the unit hypercube in M-dimensional space.

Note that, unless N is an Mth power of an integer, the program must generate a regular grid with too many points, and then omit some. Choosing which points to omit is done with a random number generator, whose actions are controlled by SEED.

The actual placement of the grid within the unit hypercube leaves some options for the use. It is easiest to describe the options in the 1 dimensional case, and in terms of where the first and last grid point are. Assuming we have N evenly spaced points to place between 0 and 1, the centering options are

Related Data and Programs:

CLENSHAW_CURTIS is a C++ library which can set up a Clenshaw Curtis quadrature grid in multiple dimensions.

CVT is a C++ library of routines for computing points in a Centroidal Voronoi Tessellation.

FAURE is a C++ library of routines for computing Faure sequences.

GRID is also available in a FORTRAN90 version and a MATLAB version.

HALTON is a C++ library of routines for computing Halton sequences.

HAMMERSLEY is a C++ library of routines for computing Hammersley sequences.

HEX_GRID is a C++ library of routines for computing sets of points in a 2D hexagonal grid.

HEX_GRID_ANGLE is a FORTRAN90 library which computes elements of an angled hexagonal grid dataset.

IHS is a C++ library of routines for computing sets of points in an improved distributed Hypercube dataset.

LATIN_CENTER is a C++ library of routines for computing Latin square data choosing the center value.

LATIN_EDGE is a C++ library of routines for computing Latin square data choosing the edge value.

LATIN_RANDOM is a C++ library of routines for computing Latin square data choosing a random value in the square.

LCVT is a C++ library which computes a latinized Centroidal Voronoi Tessellation.

NIEDERREITER2 is a C++ library of routines for computing Niederreiter sequences with base 2.

NORMAL is a C++ library which computes elements of a sequence of pseudorandom normally distributed values.

SOBOL is a C++ library of routines for computing Sobol sequences.

UNIFORM is a C++ library of routines for computing uniform random values.

VAN_DER_CORPUT is a C++ library of routines for computing van der Corput sequences.

Source Code:

Examples and Tests:

List of Routines:

You can go up one level to the C++ source codes.


Last revised on 31 August 2005.