{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/algorithmic-counting-of-nonequivalent-compact","title":"Algorithmic counting of nonequivalent compact Huffman codes","arxiv_id":"1901.11343","date":"2019-01-31","proceeding":null,"authors":["Christian Elsholtz","Clemens Heuberger","Daniel Krenn"],"abstract":"It is known that the following five counting problems lead to the same integer sequence~$f_t(n)$: the number of nonequivalent compact Huffman codes of length~$n$ over an alphabet of $t$ letters, the number of `nonequivalent' canonical rooted $t$-ary trees (level-greedy trees) with $n$~leaves, the number of `proper' words, the number of bounded degree sequences, and the number of ways of writing $1= \\frac{1}{t^{x_1}}+ \\dots + \\frac{1}{t^{x_n}}$ with integers $0 \\leq x_1 \\leq x_2 \\leq \\dots \\leq x_n$. In this work, we show that one can compute this sequence for \\textbf{all} $n<N$ with essentially one power series division. In total we need at most $N^{1+\\varepsilon}$ additions and multiplications of integers of $cN$ bits, $c<1$, or $N^{2+\\varepsilon}$ bit operations, respectively. This improves an earlier bound by Even and Lempel who needed $O(N^3)$ operations in the integer ring or $O(N^4)$ bit operations, respectively.","url_abs":"https://arxiv.org/abs/1901.11343v4","url_pdf":"https://arxiv.org/pdf/1901.11343v4.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"links_only","authors_date_abstract":"arXiv metadata, CC0 1.0 (https://info.arxiv.org/help/license), from the Kaggle arXiv metadata snapshot of 2026-09-12"},"code_links":[{"paper_slug":"algorithmic-counting-of-nonequivalent-compact","repo_url":"https://gitlab.com/dakrenn/count-nonequivalent-compact-huffman-codes","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"none","reach":null}],"tasks":[],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":null,"mcp":null,"developers":"https://syntology.ai/developers"},"arxiv_metadata":null,"syntology_extracted_results":null}