Abstract
We revisit the random-access-machine model in which the input is given on a read-only random-access media, the output is to be produced to a write-only sequential-access media, and in addition there is a limited random-access workspace. The length of the input is N elements, the length of the output is limited by the computation itself, and the capacity of the workspace is O(S + w) bits, where S is a parameter specified by the user and w is the number of bits per machine word. We present a state-of-the-art priority queue—called an adjustable navigation pile—for this model. Under some reasonable assumptions, our priority queue supports minimum and insert in O(1) worst-case time and extract in \(O(N/S + \lg S)\) worst-case time, where \(\lg N \leq S \leq N/\lg N\). We also show how to use this data structure to simplify the existing optimal \(O(N^2/S + N \lg S)\)-time sorting algorithm for this model.
Access provided by Autonomous University of Puebla. Download to read the full chapter text
Chapter PDF
Similar content being viewed by others
Keywords
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.
References
Alstrup, S., Husfeldt, T., Rauhe, T., Thorup, M.: Black box for constant-time insertion in priority queues. ACM Trans. Algorithms 1(1), 102–106 (2005)
Asano, T., Buchin, K., Buchin, M., Korman, M., Mulzer, W., Rote, G., Schulz, A.: Memory-constrained algorithms for simple polygons. E-print arXiv:1112.5904, arXiv.org, Ithaca (2011)
Barba, L., Korman, M., Langerman, S., Sadakane, K., Silveira, R.: Space-time trade-offs for stack-based algorithms. E-print arXiv:1208.3663, arXiv.org, Ithaca (2012)
Beame, P.: A general sequential time-space tradeoff for finding unique elements. SIAM J. Comput. 20(2), 270–277 (1991)
Carlsson, S., Munro, J.I., Poblete, P.V.: An implicit binomial queue with constant insertion time. In: Karlsson, R., Lingas, A. (eds.) SWAT 1988. LNCS, vol. 318, pp. 1–13. Springer, Heidelberg (1988)
Chan, T.M.: Comparison-based time-space lower bounds for selection. ACM Trans. Algorithms 6(2), 26:1–26:16 (2010)
De, M., Nandy, S.C., Roy, S.: Convex hull and linear programming in read-only setup with limited work-space. E-print arXiv:1212.5353, arXiv.org, Ithaca (2012)
Edelkamp, S., Elmasry, A., Katajainen, J.: Weak heaps engineered (submitted for publication)
Elmasry, A.: Three sorting algorithms using priority queues. In: Ibaraki, T., Katoh, N., Ono, H. (eds.) ISAAC 2003. LNCS, vol. 2906, pp. 209–220. Springer, Heidelberg (2003)
Elmasry, A., He, M., Munro, J.I., Nicholson, P.K.: Dynamic range majority data structures. In: Asano, T., Nakano, S.-i., Okamoto, Y., Watanabe, O. (eds.) ISAAC 2011. LNCS, vol. 7074, pp. 150–159. Springer, Heidelberg (2011)
Elmasry, A., Juhl, D.D., Katajainen, J., Satti, S.R.: Selection from read-only memory with limited workspace. In: Du, D.Z., Zhang, G. (eds.) COCOON 2013. LNCS. Springer, Heidelberg (2013)
Frederickson, G.N.: Upper bounds for time-space trade-offs in sorting and selection. J. Comput. System Sci. 34(1), 19–26 (1987)
Grossi, R., Gupta, A., Vitter, J.S.: High-order entropy-compressed text indexes. In: SODA 2003, pp. 841–850. SIAM, Philadelphia (2003)
Hagerup, T.: Sorting and searching on the word RAM. In: Morvan, M., Meinel, C., Krob, D. (eds.) STACS 1998. LNCS, vol. 1373, pp. 366–398. Springer, Heidelberg (1998)
Jensen, C., Katajainen, J.: An experimental evaluation of navigation piles. CPH STL Report 2006-3, Department of Computer Science, University of Copenhagen, Copenhagen (2006)
Katajainen, J., Vitale, F.: Navigation piles with applications to sorting, priority queues, and priority deques. Nordic J. Comput. 10(3), 238–262 (2003)
Kernighan, B.W., Ritchie, D.M.: The C Programming Language, 2nd edn. Prentice Hall, Englewood Cliffs (1988)
Knuth, D.E.: Sorting and Searching, The Art of Computer Programming, 2nd edn., vol. 3. Addison-Wesley, Reading (1998)
Knuth, D.E.: Combinatorial Algorithms: Part 1, The Art of Computer Programming, vol. 4A. Addison-Wesley, Boston (2011)
Munro, J.I., Paterson, M.S.: Selection and sorting with limited storage. Theoret. Comput. Sci. 12(3), 315–323 (1980)
Navarro, G., Providel, E.: Fast, small, simple rank/select on bitmaps. In: Klasing, R. (ed.) SEA 2012. LNCS, vol. 7276, pp. 295–306. Springer, Heidelberg (2012)
Navarro, G.: Wavelet trees for all. In: Kärkkäinen, J., Stoye, J. (eds.) CPM 2012. LNCS, vol. 7354, pp. 2–26. Springer, Heidelberg (2012)
Overmars, M.H.: The Design of Dynamic Data Structures. LNCS, vol. 156. Springer, Heidelberg (1983)
Pagter, J., Rauhe, T.: Optimal time-space trade-offs for sorting. In: FOCS 1998, pp. 264–268. IEEE Computer Society, Los Alamitos (1998)
Savage, J.E.: Models of Computation: Exploring the Power of Computing (2008), http://cs.brown.edu/~jes/book/home.html ; the book is released in electronic form under a CC-BY-NC-ND-3.0-US license
Williams, J.W.J.: Algorithm 232: Heapsort. Commun. ACM 7(6), 347–348 (1964)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2013 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Asano, T., Elmasry, A., Katajainen, J. (2013). Priority Queues and Sorting for Read-Only Data. In: Chan, TH.H., Lau, L.C., Trevisan, L. (eds) Theory and Applications of Models of Computation. TAMC 2013. Lecture Notes in Computer Science, vol 7876. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-38236-9_4
Download citation
DOI: https://doi.org/10.1007/978-3-642-38236-9_4
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-642-38235-2
Online ISBN: 978-3-642-38236-9
eBook Packages: Computer ScienceComputer Science (R0)