Skip to main content

Comparison-efficient and write-optimal searching and sorting

  • Conference paper
  • First Online:
ISA'91 Algorithms (ISA 1991)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 557))

Included in the following conference series:

Abstract

We consider the problem of updating a binary search tree in O(log n) amortized time while using as few comparisons as possible. We show that a tree of height [log(n + 1) + 1/√log(n + 1)] can be maintained in O(log n) amortized time such that the difference between the longest and shortest paths from the root to an external node is at most 2.

We also study the problem of sorting and searching in the slow write model of computation, where we have a constant size cache of fast memory and a large amount of memory with a much slower writing time than reading time. In such a model, it is important to sort using only θ(n) writes into the slower memory. We say that such algorithms are write optimal, and we introduce a O(n log n) time, write-optimal sorting algorithm that requires only n log n + O(n) comparisons in the worst case. No previous sorting algorithm that performs n log n + o(n log n) comparisons in the worst case had previously been shown to be write optimal.

The above results are based on a class of trees called k-stratum trees, which can be viewed as a generalization of stratified search trees.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. A. Andersson. Efficient Search Trees. Ph. D. Thesis, Lund University, Sweden, 1990.

    Google Scholar 

  2. R. Bayer and E. M. McCreight. Organization and maintenance of large ordered indices. Acta Informatica, 1:173–189, 1972.

    Google Scholar 

  3. D. E. Knuth. The Art of Computer Programming, volume 3: Sorting and Searching. Addison-Wesley, 1973.

    Google Scholar 

  4. T. W. Lai. Efficient maintenance of binary search trees. PhD thesis, University of Waterloo, 1990.

    Google Scholar 

  5. J. I. Munro and V. Raman. Sorting with minimum data movement (preliminary draft). In Proceedings of the 1st Annual Workshop on Algorithms and Data Structures, pages 552–562, 1989.

    Google Scholar 

  6. H. J. Olivie. A new class of balanced search trees: Half-balanced binary search trees. R.A.I.R.O. Informatique Theoretique, 16:51–71, 1982.

    Google Scholar 

  7. J. van Leeuwen and M. H. Overmars. Stratified balanced search trees. Acta Informatica, 18:345–359, 1983.

    Google Scholar 

  8. I. Wegener. The worst case complexity of McDiarmid and Reed's variant of the bottom-up-heap sort in less than n log n + 1.1n. In Proceedings of the 8th Annual Symposium on Theoretical Aspects of Computer Science, pages 137–147, 1991.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Wen-Lian Hsu R. C. T. Lee

Rights and permissions

Reprints and permissions

Copyright information

© 1991 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Andersson, A., Lai, T.W. (1991). Comparison-efficient and write-optimal searching and sorting. In: Hsu, WL., Lee, R.C.T. (eds) ISA'91 Algorithms. ISA 1991. Lecture Notes in Computer Science, vol 557. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-54945-5_71

Download citation

  • DOI: https://doi.org/10.1007/3-540-54945-5_71

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-54945-1

  • Online ISBN: 978-3-540-46600-0

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics