What are HHCodes and what are they used for?

HHCODEs (Helical Hyperspatial Codes) is an encoding technique developed by the Canadian Hydrographic Service for combining data of two or more dimensions into a single value. This value represents the intersection of all of the desired dimensions. HHCODEs makes it easy to store multidimensional data in a database.

In Oracle, a HHCODE is a datatype used for both spatial indexing and partitioned point data.

More technical:

HHCodes are in effect Peano Codes, an implementation of Space Filling Curves. The multidimensionality aspect is the use of the Riemannian hypercube in conjunction with the space filling curve. What in effect has happened is that the Riemannian tensor matrix has been mapped by the space filling curve. This gives mathemetical credence to HHCodes and a lot more functionality then just data access. One more thing the HHcode encoding is not just Euclidean, Curvilinear and linear coordinates such as Lat, Lon, depth and time can also be mapped together. This creates Time varying voxels, (I suppose one can call them toxels).

Contributed: