Comparator networks for binary heap construction

  • Gerth Stølting Brodal
  • M. Cristina Pinotti
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 1432)


Comparator networks for constructing binary heaps of size n are presented which have size O(n log log n) and depth O(log n). A lower bound of n log log nO(n) for the size of any heap construction network is also proven, implying that the networks presented are within a constant factor of optimal. We give a tight relation between the leading constants in the size of selection networks and in the size of heap construction networks.


Binary Tree Selection Network Output Line Sorting Network Comparator Network 
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.


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. 1.
    Miklós Ajtai, János Komlós, and Endre Szemerédi. Sorting in c log n parallel steps. Combinatorica, 3:1–19, 1983.MathSciNetzbMATHGoogle Scholar
  2. 2.
    Vladimir Evgen'evich Alekseev. Sorting algorithms with minimum memory. Kibernetika, 5(5):99–103, 1969.Google Scholar
  3. 3.
    Samuel W. Bent and John W. John. Finding the median requires 2n comparisons. In Proc. 17th Ann. ACM Symp. on Theory of Computing (STOC), pages 213–216, 1985.Google Scholar
  4. 4.
    Manuel Blum, Robert W. Floyd, Vaughan Pratt, Ronald L. Rivest, and Robert Endre Tarjan. Time bounds for selection. Journal of Computer and System Sciences, 7:448–461, 1973.MathSciNetCrossRefzbMATHGoogle Scholar
  5. 5.
    Paul F. Dietz. Heap construction in the parallel comparison tree model. In Proc. 3rd Scandinavian Workshop on Algorithm Theory (SWAT), volume 621 of Lecture Notes in Computer Science, pages 140–150. Springer Verlag, Berlin, 1992.Google Scholar
  6. 6.
    Paul F. Dietz and Rajeev Raman. Very fast optimal parallel algorithms for heap construction. In Proc. 6th Symposium on Parallel and Distributed Processing, pages 514–521, 1994.Google Scholar
  7. 7.
    Dorit Dor and Uri Zwick. Selecting the median. In Proc. 6th ACM-SIAM Symposium on Discrete Algorithms (SODA), pages 28–37, 1995.Google Scholar
  8. 8.
    Dorit Dor and Uri Zwick. Finding the alpha n-th largest element. Combinatorial, 16:41–58, 1996.CrossRefMathSciNetzbMATHGoogle Scholar
  9. 9.
    Dorit Dor and Uri Zwick. Median selection requires (2 + ε)n comparisons. In Proc. 37th Ann. Symp. on Foundations of Computer Science (FOCS), pages 125–134, 1996.Google Scholar
  10. 10.
    Robert W. Floyd. Algorithm 245: Treesort3. Communications of the ACM, 7(12):701, 1964.CrossRefGoogle Scholar
  11. 11.
    Shuji Jimbo and Akira Maruoka. A method of constructing selection networks with O(log n) depth. SIAM Journal of Computing, 25(4):709–739, 1996.CrossRefMathSciNetzbMATHGoogle Scholar
  12. 12.
    Donald E. Knuth. The Art of Computer Programming, Volume III: Sorting and Searching. Addison-Wesley, Reading, MA, 1973.Google Scholar
  13. 13.
    Peter Bro Miltersen, Mike Paterson, and Jun Tarui. The asymptotic complexity of merging networks. Journal of the ACM, 43(1):147–165, 1996.CrossRefMathSciNetzbMATHGoogle Scholar
  14. 14.
    Stephan Olariu and Zhaofang Wen. Optimal parallel initialization algorithms for a class of priority queues. IEEE Transactions on Parallel and Distributed Systems, 2:423–429, 1991.CrossRefGoogle Scholar
  15. 15.
    Nicholas Pippenger. Selection networks. SIAM Journal of Computing, 20(5):878–887, 1991.zbMATHCrossRefMathSciNetGoogle Scholar
  16. 16.
    Arnold Schönhage, Michael S. Paterson, and Nicholas Pippenger. Finding the median. Journal of Computer and System Sciences, 13:184–199, 1976.MathSciNetzbMATHGoogle Scholar
  17. 17.
    John William Joseph Williams. Algorithm 232: Heapsort. Communications of the ACM, 7(6):347–348, 1964.Google Scholar
  18. 18.
    Andrew C. Yao and Frances F. Yao. Lower bounds on merging networks. Journal of the ACM, 23:566–571, 1976.CrossRefzbMATHGoogle Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 1998

Authors and Affiliations

  • Gerth Stølting Brodal
    • 1
  • M. Cristina Pinotti
    • 2
  1. 1.Im StadtwaldMax-Planck-Institut für InformatikSaarbrückenGermany
  2. 2.Istituto di Elaborazione della InformazioneCNRPisaItaly

Personalised recommendations