| Copyright | (c) Raphael 'kena' Poss 2014 |
|---|---|
| License | Public domain (Unlicense) |
| Maintainer | knz@thaumogen.net |
| Stability | experimental |
| Portability | portable |
| Safe Haskell | Safe-Inferred |
| Language | Haskell98 |
Data.SpaceFillingCurves
Description
Generators of space-filling curves.
- hilbert :: (Eq n, Num n, Fractional f, Alternative p) => n -> f -> f -> f -> f -> f -> f -> p (f, f)
- moore :: (Eq n, Num n, Fractional f, Alternative p) => n -> f -> f -> f -> f -> f -> f -> p (f, f)
Documentation
hilbert :: (Eq n, Num n, Fractional f, Alternative p) => n -> f -> f -> f -> f -> f -> f -> p (f, f) Source
Generate a Hilbert space-filling curve. (open curve)
The function generates 4^n points, shifted from the origin
by (x0, y0). The pair (xi, yi) determines the planar
coordinates of the I vector ("X axis") and the pair (xj, yj)
the coordinates of the J vector ("Y axis").
moore :: (Eq n, Num n, Fractional f, Alternative p) => n -> f -> f -> f -> f -> f -> f -> p (f, f) Source
Generate a Moore space-filling curve. (closed curve)
The function generates 4^n points, shifted from the origin
by (x0, y0). The pair (xi, yi) determines the planar
coordinates of the I vector ("X axis") and the pair (xj, yj)
the coordinates of the J vector ("Y axis").