paper

Optimal Encodings for Range Majority Queries

arXiv:1404.2677

Abstract

We study the problem of designing a data structure that reports the positions of the distinct -majorities within any range of an array , without storing . A -majority in a range , for , is an element that occurs more than times in . We show that bits are necessary for any data structure able just to count the number of distinct -majorities in any range. Then, we design a structure using bits that returns one position of each -majority of in time, on a RAM machine with word size (it can output any further position where each -majority occurs in additional time). Finally, we show how to remove a factor from the time by adding bits of space to the structure.

References in corpus (1)

Optimal Encodings for Range Majority Queries · wovepaper