Next: Hilbert Space-Filling Curve, Previous: Space-Filling Curves, Up: Space-Filling Curves [Contents][Index]
The algorithms and cell properties are described in http://people.csail.mit.edu/jaffer/Geometry/RMDSFF.pdf
type must be the symbol diagonal, adjacent, or
centered. rank must be an integer larger than 1. side, if
present, must be an even integer larger than 1 if type is
adjacent or an odd integer larger than 2 otherwise; side
defaults to the smallest value. precession, if present, must be an integer
between 0 and side^rank-1; it is relevant only when type is
diagonal or centered.
type must be a vector of side^rank lists of rank of integers encoding the coordinate positions of a Hamiltonian path on the rank-dimensional grid of points starting and ending on corners of the grid. The starting corner must be the origin (all-zero coordinates). If the side-length is even, then the ending corner must be non-zero in only one coordinate; otherwise, the ending corner must be the furthest diagonally opposite corner from the origin.
make-cell returns a data object suitable for passing as the
first argument to integer->coordinates or
coordinates->integer.
Hilbert, Peano, and centered Peano cells are generated respectively by:
(make-cell 'adjacent rank 2) ; Hilbert (make-cell 'diagonal rank 3) ; Peano (make-cell 'centered rank 3) ; centered Peano
In the conversion procedures, if the cell is diagonal or
adjacent, then the coordinates and scalar must be nonnegative
integers. If centered, then the integers can be negative.
integer->coordinates converts the integer u to a list of coordinates according to cell.
coordinates->integer converts the list of coordinates v to an integer according to cell.
coordinates->integer and integer->coordinates are inverse functions when passed the same cell argument.
Next: Hilbert Space-Filling Curve, Previous: Space-Filling Curves, Up: Space-Filling Curves [Contents][Index]