SDSL 3.0.3
Succinct Data Structure Library
Loading...
Searching...
No Matches
sdsl::k2_tree_ns Namespace Reference

Namespace for the k2_tree. More...

Typedefs

typedef int_vector ::size_type idx_type
typedef int_vector ::size_type size_type

Functions

template<typename t_bv = bit_vector>
int _build_from_matrix (std::vector< std::vector< int > > const &matrix, const uint8_t k, int n, int const height, int l, int p, int q, std::vector< std::deque< t_bv > > &acc)
uint16_t get_chunk_idx (idx_type v, idx_type u, idx_type c_0, idx_type r_0, size_type l, uint8_t k)
 Get the chunk index ([0, k^2[) of a submatrix point.
template<typename t_bv = bit_vector>
void build_template_vector (bit_vector &k_t_, bit_vector &k_l_, t_bv &k_t, t_bv &k_l)
template<>
void build_template_vector< bit_vector > (bit_vector &k_t_, bit_vector &k_l_, bit_vector &k_t, bit_vector &k_l)

Detailed Description

Namespace for the k2_tree.

Typedef Documentation

◆ idx_type

◆ size_type

Definition at line 28 of file k2_tree_helper.hpp.

Function Documentation

◆ _build_from_matrix()

template<typename t_bv = bit_vector>
int sdsl::k2_tree_ns::_build_from_matrix ( std::vector< std::vector< int > > const & matrix,
const uint8_t k,
int n,
int const height,
int l,
int p,
int q,
std::vector< std::deque< t_bv > > & acc )

Definition at line 31 of file k2_tree_helper.hpp.

◆ build_template_vector()

template<typename t_bv = bit_vector>
void sdsl::k2_tree_ns::build_template_vector ( bit_vector & k_t_,
bit_vector & k_l_,
t_bv & k_t,
t_bv & k_l )

Definition at line 89 of file k2_tree_helper.hpp.

◆ build_template_vector< bit_vector >()

template<>
void sdsl::k2_tree_ns::build_template_vector< bit_vector > ( bit_vector & k_t_,
bit_vector & k_l_,
bit_vector & k_t,
bit_vector & k_l )
inline

Definition at line 96 of file k2_tree_helper.hpp.

◆ get_chunk_idx()

uint16_t sdsl::k2_tree_ns::get_chunk_idx ( idx_type v,
idx_type u,
idx_type c_0,
idx_type r_0,
size_type l,
uint8_t k )
inline

Get the chunk index ([0, k^2[) of a submatrix point.

Gets a point in the global matrix and returns its corresponding chunk in the submatrix specified.

Parameters
vRow of the point in the global matrix.
uColumn of the point in the global matrix.
c_0Column offset of the submatix in the global matrix.
r_0Row offset of the submatrix in the global matrix.
lsize of the chunk at the submatrix.
kthe k parameter from the k^2 tree.
Returns
the index of the chunk containing the point at the submatrix.

Definition at line 83 of file k2_tree_helper.hpp.