Skip to main content
Log in

An improvement of the binary merge algorithm

  • Part I Computer Science
  • Published:
BIT Numerical Mathematics Aims and scope Submit manuscript

Abstract

In this paper, we are concerned with the merging of two linearly-ordered listsA andB consisting of elements:a 1<a 2<...<b n . The Hwang-Lin merging algorithm was considered very efficient for merging two lists of arbitrary sizes. Recently, Manacher was able to develop methods which reduce the number of pairwise comparisons required in the Hwang-Lin algorithm by a factor 31/336m. We develop in this paper a new method which further improves this factor to 52/336m. It is possible that even larger improvements could be achieved.

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

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Similar content being viewed by others

References

  1. R. L. Graham,On sorting by comparisons, Computers in Number Theory, A. O. L. Atkin and B. J. Birch, Eds., Academic Press, London, (1971), pp. 263–269.

    Google Scholar 

  2. F. K. Hwang,Optimal merging of 3 elements with n elements, SIAM J. Computing, 9 (1980), pp. 298–320.

    Google Scholar 

  3. F. K. Hwang and S. Lin,Optimal merging of 2 elements with n elements, Acta Informatica, 1 (1971), pp. 145–158.

    Google Scholar 

  4. F. K. Hwang and S. Lin,A simple algorithm for merging two disjoint linearly-ordered sets, SIAM J. Computing, 1 (1972), pp. 31–39.

    Google Scholar 

  5. D. E. Knuth,The Art of Computer Programming, Vol. 3, Sorting and Searching, Addison-Wesley, Reading, MA, (1973).

    Google Scholar 

  6. G. K. Manacher,Significant improvements to the Hwang-Lin merging algorithm, J. ACM, 26 (1979), pp. 434–440.

    Google Scholar 

  7. P. K. Stockmeyer and F. F. Yao,On the optimality of linear merge, SIAM J. Computing, 9 (1980), pp. 85–90.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints and permissions

About this article

Cite this article

Thanh, M., Bui, T.D. An improvement of the binary merge algorithm. BIT 22, 454–462 (1982). https://doi.org/10.1007/BF01934409

Download citation

  • Received:

  • Revised:

  • Issue Date:

  • DOI: https://doi.org/10.1007/BF01934409

Keywords

C. R. Categories

Navigation