|
ADS
Algorithms and Data Structures
|
The FM-index on the wavelet tree shaped by the code of Huffman, i.e., the succinct suffix array of Mäkinen and Navarro (beyond the book): the transform \( L \) of Burrows and Wheeler of a text \( s \) of \( n \) bytes as a HuffmanWaveletTree [see HuffmanWaveletTree.h], in \( n ( H_0 + 1 ) ( 1 + o( 1 ) ) \) bits, with the same operations as the FM-index of chapter 14, Block-Sorting Compression, of Ferragina's book [see FMIndex.h], which keeps \( L \) as it is with counts every \( b \) places, \( 8 n + 32 \sigma n / b \) bits. More...
#include "ADS/Contract.h"#include "ADS/compression/BurrowsWheeler.h"#include "ADS/external/MappedFile.h"#include "ADS/succinct/BitVector.h"#include "ADS/succinct/HuffmanWaveletTree.h"#include <algorithm>#include <array>#include <bit>#include <cstddef>#include <cstdint>#include <string>#include <string_view>#include <utility>#include <vector>#include "ADS/compression/impl/HuffmanFMIndex.tpp"Go to the source code of this file.
Classes | |
| class | ADS::HuffmanFMIndex< RS > |
| the FM-index of a text on the wavelet tree of Huffman of its transform, with the places of the suffixes at the multiples of \( \mu \) More... | |
Namespaces | |
| namespace | ADS |
The FM-index on the wavelet tree shaped by the code of Huffman, i.e., the succinct suffix array of Mäkinen and Navarro (beyond the book): the transform \( L \) of Burrows and Wheeler of a text \( s \) of \( n \) bytes as a HuffmanWaveletTree [see HuffmanWaveletTree.h], in \( n ( H_0 + 1 ) ( 1 + o( 1 ) ) \) bits, with the same operations as the FM-index of chapter 14, Block-Sorting Compression, of Ferragina's book [see FMIndex.h], which keeps \( L \) as it is with counts every \( b \) places, \( 8 n + 32 \sigma n / b \) bits.
The symbols of \( L \) are the bytes plus 1, the end of the text being 0. The backward search takes the two ranks of a step by one descent of the tree, as they meet the same nodes. The samples are \( \lceil n / \mu \rceil \) places and as many rows of \( \lceil \log_2 ( n + 1 ) \rceil \) bits each, and the marks are \( n + 1 \) bits with the compact rank of CompactRankSelect [see CompactRankSelect.h], since a step of locate() tests the bit alone and the rank is needed once per occurrence; the parameter RS is the rank and select of the tree, RankSelect or CompactRankSelect. The transform comes from the suffix array of SA-IS [see BurrowsWheeler.h], in \( O( n ) \) time.
The contracts [see Contract.h]: \( \mu > 0 \), \( n < 2^{32} \), a pattern is not empty, \( i \le j \le n \); each place found by locate() is an occurrence, an audit. The functions are defined in HuffmanFMIndex.tpp.