Compressed Range Minimum Queries

02/12/2019
by   Paweł Gawrychowski, et al.
0

Given a string S of n integers in [0,σ), a range minimum query RMQ(i, j) asks for the index of the smallest integer in S[i ... j]. It is well known that the problem can be solved with a succinct data structure of size 2n + o(n) and constant query-time. In this paper we show how to preprocess S into a compressed representation that allows fast range minimum queries. This allows for sublinear size data structures with logarithmic query time. The most natural approach is to use string compression and construct a data structure for answering range minimum queries directly on the compressed string. We investigate this approach using grammar compression. We then consider an alternative approach. Even if S is not compressible, its Cartesian tree necessarily is. Therefore, instead of compressing S using string compression, we compress the Cartesian tree of S using tree compression. We show that this approach can be exponentially better than the former, is never worse by more than an O(σ) factor (i.e. for constant alphabets it is never asymptotically worse), and can in fact be worse by an Ω(σ) factor.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
02/06/2019

Top Tree Compression of Tries

We present a compressed representation of tries based on top tree compre...
research
11/28/2017

Faster range minimum queries

Range Minimum Query (RMQ) is an important building brick of many compres...
research
09/26/2019

String Indexing with Compressed Patterns

Given a string S of length n, the classic string indexing problem is to ...
research
06/03/2021

Internal Shortest Absent Word Queries in Constant Time and Linear Space

Given a string T of length n over an alphabet Σ⊂{1,2,…,n^O(1)} of size σ...
research
02/18/2021

Range Minimum Queries in Minimal Space

We consider the problem of computing a sequence of range minimum queries...
research
05/26/2023

CARAMEL: A Succinct Read-Only Lookup Table via Compressed Static Functions

Lookup tables are a fundamental structure in many data processing and sy...
research
05/22/2020

Still Simpler Static Level Ancestors

A level-ancestor or LA query about a rooted tree T takes as arguments a ...

Please sign up or login with your details

Forgot password? Click here to reset