Advertisement

Acta Informatica

, Volume 36, Issue 9–10, pp 721–734 | Cite as

Minimal Huffman trees

  • Gunnar Forst
  • Anders Thorup
Original articles

Abstract.

For a given set of real weights, Huffman trees minimize the weighted external path length. Over the years, several algorithms have been proposed for constructing Huffman trees that minimize additional natural cost functions such as the external path length, the variance and, more generally, the central moments. We show that all these cost functions are minimized on exactly the same class of Huffman trees, and we characterize the class: it consists of all Huffman trees of minimal level set. It follows that a Huffman tree minimizing one of the cost functions in fact minimizes all of them, and has the minimal level set; in particular, it has minimum height. We show that the unique Huffman tree produced by the simplest construction method, the bottom-merge algorithm of Schwartz, belongs to the class. Finally, we prove that several natural variants of Huffman's algorithm, that appear to be nondeterministic, in fact all lead to the single Huffman tree obtained by Schwartz's algorithm.

Keywords

Cost Function Path Length Minimal Level Natural Variant Construction Method 
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.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

Copyright information

© Springer-Verlag Berlin Heidelberg 2000

Authors and Affiliations

  • Gunnar Forst
    • 1
  • Anders Thorup
    • 1
  1. 1.Matematisk Afdeling, Københavns Universitet, Universitetsparken 5, DK-2100 København, Denmark (e-mail: forst@math.ku.dk, thorup@math.ku.dk) DK

Personalised recommendations