Abstract
In this paper we design a new static data structure for batched predecessor queries. In particular, our data structure supports \(O(\sqrt{{\rm log}n})\) queries in O(1) time per query and requires \(O(n^{\epsilon\sqrt{{\rm log}n}})\) space for any ε > 0. This is the first o(N) space and O(1) amortized time data structure for arbitrary \(N = \Omega(n^{\epsilon\sqrt{{\rm log}n}})\) where N is the size of the universe. We also present a data structure that answers O(log log N) predecessor queries in O(1) time per query and requires \(O(n^{\epsilon{\rm log log} {\it N}})\) space for any ε > 0. The method of solution relies on a certain way of searching for predecessors of all elements of the query in parallel.
In a general case, our approach leads to a data structure that supports p(n) queries in \(O(\sqrt{{\rm log} n}/p(n))\) time per query and requires O(n \(^{p({\it n})}\)) space for any \(p(n) =O(\sqrt{{\rm log}n})\), and a data structure that supports p(N) queries in O(log log N/p(N)) time per query and requires O(n \(^{p({\it N})}\)) space for any p(N)=O(log log N).
Preview
Unable to display preview. Download preview PDF.
Similar content being viewed by others
References
Adelson-Velskii, G.M., Landis, E.M.: An algorithm for the organization of information. Dokladi Akademii Nauk SSSR 146(2), 1259–1262 (1962)
Ajtai, M., Fredman, M.L., Komlòs, J.: Hash Functions for Priority Queues. Information and Control 63(3), 217–225 (1984)
Alstrup, S., Brodal, G.S., Rauhe, T.: Optimal static range reporting in one dimension. In: STOC 2001, pp. 476–482 (2001)
Andersson, A.: Sublogarithmic Searching without Multiplications. In: FOCS 1995, pp. 655–663 (1995)
Andersson, A.: Faster Deterministic Sorting and Searching in Linear Space. In: FOCS 1996, pp. 135–141 (1996)
Andersson, A., Hagerup, T., Nilsson, S., Raman, R.: Sorting in linear time? In: STOC 1995, pp. 427–436 (1995)
Andersson, A., Thorup, M.: Tight(er) worst-case bounds on dynamic searching and priority queues. In: STOC 2000, pp. 335–342 (2000)
Andersson, A., Thorup, M.: Dynamic Ordered Sets with Exponential Search Trees, The Computing Research Repository (CoRR), cs.DS/0210006: (2002), Available at http://arxiv.org/abs/cs.DS/0210006
Beame, P., Fich, F.E.: Optimal Bounds for the Predecessor Problem and Related Problems. J. Comput. Syst. Sci. 65(1), 38–72 (2002)
Brodnik, A., Carlsson, S., Karlsson, J., Munro, J.I.: Worst case constant time priority queue. In: SODA 2001, pp. 523–528 (2001)
Carter, L., Wegman, M.N.: Universal Classes of Hash Functions. J. Comput. Syst. Sci. 18(2), 143–154 (1979)
van Emde Boas, P.: Preserving Order in a Forest in Less Than Logarithmic Time and Linear Space. Inf. Process. Lett. 6(3), 80–82 (1977)
van Emde Boas, P., Kaas, R., Zijlstra, E.: Design and Implementation of an Efficient Priority Queue. Mathematical Systems Theory 10, 99–127 (1977)
Fredman, M.L., Willard, D.E.: Trans-Dichotomous Algorithms for Minimum Spanning Trees and Shortest Paths. J. Comput. Syst. Sci. 48(3), 533–551 (1994)
Hagerup, T.: Sorting and Searching on the Word RAM. In: STACS 1998, pp. 366–398 (1998)
Han, Y.: Deterministic sorting in O(n log log n) time and linear space. In: STOC 2002, pp. 602–608 (2002)
Gum, B., Lipton, R.: Cheaper by the Dozen: Batched Algorithms. In: 1st SIAM International Conference on Data Mining (2001), Available at http://www.math.grin.edu/~gum/papers/batched/
Mehlhorn, K.: Data Structures and Algorithms 1: Sorting and Searching. Springer, Heidelberg (1984)
Paul, W.J., Simon, S.: Decision Trees and Random Access Machines. In: International Symposium on Logik and Algorithmic, Zürich, pp. 331–340 (1980)
Willard, D.E.: Log-Logarithmic Worst-Case Range Queries are Possible in Space Theta(N). Inf. Process. Lett. 17(2), 81–84 (1983)
Willard, D.E.: New Trie Data Structures Which Support Very Fast Search Operations. J. Comput. Syst. Sci. 28(3), 379–394 (1984)
Yao, A.C.-C.: Should Tables Be Sorted? J. ACM 28(3), 615–628 (1981)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2005 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Karpinski, M., Nekrich, Y. (2005). Predecessor Queries in Constant Time?. In: Brodal, G.S., Leonardi, S. (eds) Algorithms – ESA 2005. ESA 2005. Lecture Notes in Computer Science, vol 3669. Springer, Berlin, Heidelberg. https://doi.org/10.1007/11561071_23
Download citation
DOI: https://doi.org/10.1007/11561071_23
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-29118-3
Online ISBN: 978-3-540-31951-1
eBook Packages: Computer ScienceComputer Science (R0)