SDSL 3.0.3
Succinct Data Structure Library
|
A class to encode and decode between Elias-
#include <coder_elias_gamma.hpp>
Classes | |
struct | impl |
Public Types | |
typedef uint64_t | size_type |
Static Public Member Functions | |
static uint8_t | encoding_length (uint64_t) |
template<bool t_sumup, bool t_inc, class t_iter> | |
static uint64_t | decode (uint64_t const *data, const size_type start_idx, size_type n, t_iter it=(t_iter) nullptr) |
Decode n Elias-delta encoded bits beginning at start_idx in the bitstring "data". | |
static uint64_t | decode_prefix_sum (uint64_t const *d, const size_type start_idx, size_type n) |
Decode n Elias gamma encoded integers beginning at start_idx in the bitstring "data" and return the sum of these values. | |
static uint64_t | decode_prefix_sum (uint64_t const *d, const size_type start_idx, const size_type end_idx, size_type n) |
template<class int_vector> | |
static bool | encode (int_vector const &v, int_vector &z) |
template<class int_vector> | |
static bool | decode (int_vector const &z, int_vector &v) |
static void | encode (uint64_t x, uint64_t *&z, uint8_t &offset) |
Encode one positive integer x to an int_vector at bit position start_idx. | |
template<class int_vector> | |
static uint64_t * | raw_data (int_vector &v) |
Static Public Attributes | |
static struct sdsl::coder::elias_gamma::impl | data |
static const uint8_t | min_codeword_length = 1 |
A class to encode and decode between Elias-
Definition at line 24 of file coder_elias_gamma.hpp.
typedef uint64_t sdsl::coder::elias_gamma< T >::size_type |
Definition at line 27 of file coder_elias_gamma.hpp.
|
inlinestatic |
Definition at line 245 of file coder_elias_gamma.hpp.
|
inlinestatic |
Decode n Elias-delta encoded bits beginning at start_idx in the bitstring "data".
Definition at line 268 of file coder_elias_gamma.hpp.
|
inlinestatic |
Definition at line 296 of file coder_elias_gamma.hpp.
|
inlinestatic |
Decode n Elias gamma encoded integers beginning at start_idx in the bitstring "data" and return the sum of these values.
data | Pointer to the beginning of the Elias gamma encoded bitstring. |
start_idx | Index of the first bit to endcode the values from. |
n | Number of values to decode from the bitstring. Attention: There have to be at least n encoded values in the bitstring. |
Definition at line 472 of file coder_elias_gamma.hpp.
|
inlinestatic |
Definition at line 170 of file coder_elias_gamma.hpp.
|
inlinestatic |
Encode one positive integer x to an int_vector at bit position start_idx.
Definition at line 223 of file coder_elias_gamma.hpp.
|
inlinestatic |
Definition at line 162 of file coder_elias_gamma.hpp.
|
inlinestatic |
Definition at line 154 of file coder_elias_gamma.hpp.
|
static |
|
static |
Definition at line 119 of file coder_elias_gamma.hpp.