@hackage variety0.3.0.0
integer arithmetic codes
Installation
Tested Compilers
Dependencies (4)
- base >=4.17.2 && <4.22
- bytestring >=0.11.5 && <0.13
- containers >=0.6.7 && <0.9
- exact-combinatorics >=0.2.0 && <0.3 Show all…
Dependents (0)
The Variety module provides functions to optimally encode and decode sequences of value-base pairs assuming uniform probability.
If codes get too large and slow to process, Variety.Bounded provides a similar interface with a precision parameter at small cost to code length.
The Combinatorics module provides functions to optimally encode and decode (rank and unrank) common combinatorial objects.
The Elias module provides entirely non-parametric encoding and decoding of positive integers. The usual definition doesn't allow for an encoding of 0, so a mapping is baked into the functions in Elias.Natural that shifts the number line by 1.