diff options
author | Bryan Newbold <bnewbold@robocracy.org> | 2017-02-20 00:05:29 -0800 |
---|---|---|
committer | Bryan Newbold <bnewbold@robocracy.org> | 2017-02-20 00:05:29 -0800 |
commit | 8466d8cfa486fb30d1755c4261b781135083787b (patch) | |
tree | c8c12c67246f543c3cc4f64d1c07e003cb1d45ae /phil-spc.txi | |
parent | 87b82b5822ca54228cfa6df29be3ad9d4bc47d16 (diff) | |
download | slib-8466d8cfa486fb30d1755c4261b781135083787b.tar.gz slib-8466d8cfa486fb30d1755c4261b781135083787b.zip |
Import Upstream version 3a1upstream/3a1
Diffstat (limited to 'phil-spc.txi')
-rw-r--r-- | phil-spc.txi | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/phil-spc.txi b/phil-spc.txi new file mode 100644 index 0000000..1193c6c --- /dev/null +++ b/phil-spc.txi @@ -0,0 +1,38 @@ +@code{(require 'hilbert-fill)} +@ftindex hilbert-fill + +@noindent +@cindex Peano +@cindex Hilbert +@cindex Space-Filling +The @dfn{Peano-Hilbert Space-Filling Curve} is a one-to-one mapping +@cindex Peano-Hilbert Space-Filling Curve +between a unit line segment and an @var{n}-dimensional unit cube. + +@noindent +The integer procedures map the non-negative integers to an +arbitrarily large @var{n}-dimensional cube with its corner at the +origin and all coordinates are non-negative. + +@noindent +For any exact nonnegative integers @var{scalar} and @var{rank}, + +@example +(= @var{scalar} (hilbert-coordinates->integer + (integer->hilbert-coordinates @var{scalar} @var{rank}))) + @result{} #t +@end example + + +@defun integer->hilbert-coordinates scalar rank + +Returns a list of @var{rank} integer coordinates corresponding to exact +non-negative integer @var{scalar}. The lists returned by @code{integer->hilbert-coordinates} for @var{scalar} arguments +0 and 1 will differ in the first element. +@end defun + +@defun hilbert-coordinates->integer coords + +Returns an exact non-negative integer corresponding to @var{coords}, a list +of non-negative integer coordinates. +@end defun |