Papers
Topics
Authors
Recent
Search
2000 character limit reached

Top ZDDs: Compressed ZDD Structures

Updated 31 March 2026
  • Top ZDDs are advanced compressed Zero-suppressed Binary Decision Diagrams that merge identical subgraphs across varied heights using top-tree compression.
  • They are constructed by extracting a spanning tree and forming a binary top tree that is then compressed into a top DAG for efficient navigation and membership queries.
  • Empirical results demonstrate that Top ZDDs can reduce space from exponential to linear in some cases, though with a 2–5× slower traversal compared to traditional methods.

A Top ZDD is an advanced, compressed form of Zero-suppressed Binary Decision Diagram (ZDD), optimized for memory efficiency via top-tree-based compression of directed acyclic graphs (DAGs). Top ZDDs facilitate compact representation and polylogarithmic-time navigation for large and highly repetitive set families, extending the core structural benefits of traditional ZDDs. Their utility and variants are particularly relevant in combinatorial set representation and symbolic model checking, especially for large, sparse, and asymmetric boolean functions and Kripke structures (Miedema et al., 2023, Matsuda et al., 2020).

1. Foundations: ZDDs and Their Compression Limits

Zero-suppressed Binary Decision Diagrams (ZDDs) are reduced, ordered decision diagrams over a finite variable set VV, represented as DAGs with internal nodes labeled by xVx\in V. Each node nn has "else" (low) and "then" (high) children, following a fixed variable order. Classical ZDD reduction rules replace the symmetric BDD "identical children" elimination with the zero-suppression rule: any node nn where high(n)=0\text{high}(n)=0 is removed, with incoming arcs redirected to low(n)\text{low}(n). This succinctly encodes itemsets where variables are usually absent, making ZDDs efficient for sparse families (Miedema et al., 2023, Matsuda et al., 2020).

However, for large or extremely regular set families (e.g., the power set), even ZDDs can require exponential space because standard compression only merges isomorphic subtrees at the same height and cannot exploit deeper repetition, leading to impractically large diagrams (Matsuda et al., 2020).

2. Top ZDDs: Definition and Construction

Top ZDDs apply the top-tree compression paradigm to ZDDs by recognizing and merging identical subgraphs across different heights in the DAG. Construction proceeds as follows:

  1. Spanning Tree Extraction: A spanning tree TT is extracted from the branching-node subgraph of the original ZDD, ignoring 0/1 distinction. Non-tree edges are termed complement edges.
  2. Top Tree Formation: A binary top tree T\mathcal{T} is constructed on TT via merges (vertical/horizontal) that produce clusters—subtrees with shared boundaries. A greedy bottom-up method yields O(logn)O(\log n) height.
  3. DAG Compression: The minimal DAG of T\mathcal{T} (top DAG) is produced by identifying isomorphic subtrees.
  4. Complement Edge Integration: Complement edges are attached at appropriate clusters, storing local-preorder and delta-label information.
  5. Final Top ZDD: The result is a labeled DAG where each node represents a possibly repeated cluster, with succinct navigation structures (balanced parentheses, bit-vectors, rank/select for fast access).

A Top ZDD thus consists of:

  • A succinctly encoded top DAG.
  • For each node: type bits, local label-differences, and complement-edge data.
  • Navigation methods supporting (x)\ell(x) in O(logn)O(\log n) and zero(x),one(x)\text{zero}(x), \text{one}(x) in O(log2n)O(\log^2 n).

For certain set families, including the power-set of [m][m], Top ZDDs can reduce the representation size from O(2m)O(2^m) ZDD nodes to O(m)O(m) Top ZDD nodes (Matsuda et al., 2020).

3. ZDD Variants and Suppression Rules for Model Checking

In symbolic model checking and knowledge compilation, the choice of ZDD suppression rule affects representation size and efficiency:

  • Classic ZDD (T0): Then-0 suppression; node nn with high(n)=0\text{high}(n)=0 is removed.
  • E0/T1/E1 Variants: Defined via generalized rules:
    • T1:(1,s)sT1: (1,s)\Rightarrow s
    • E0:(s,0)sE0: (s,0)\Rightarrow s
    • E1:(s,1)sE1: (s,1)\Rightarrow s
    • EQEQ: BDD-style, symmetric elimination.

Other practical variants (simulated via edge/leaf-flip transformations on T0T0 or its negations), provide a toolkit for matching ZDD structure to Boolean function asymmetries. Canonical-ness and interrelations among these variants hold as established (Miedema et al., 2023).

Suppression Rule Patterns

Variant Suppression Condition Typical Advantage Scenario
T0 high(n)=0(n) = 0 Highly sparse models, dead 1-branches
E0 low(n)=0(n) = 0 Dually sparse, dead 0-branches
T1 high(n)=1(n) = 1 Large disjunctions (OR)
E1 low(n)=1(n) = 1 Large conjunctions (AND)
EQ low(n)=high(n) = high(n)$</td> <td>Balanced/symmetric</td> </tr> </tbody></table></div><h2 class='paper-heading' id='empirical-memory-efficiency-and-use-cases'>4. Empirical Memory Efficiency and Use Cases</h2> <p>Top ZDD and ZDD variant effectiveness is demonstrated empirically in model checking of Dynamic Epistemic Logic (DEL) puzzles and large itemset datasets:</p> <ul> <li><strong>Model Checking Benchmarks</strong> (<a href="/papers/2307.05067" title="" rel="nofollow" data-turbo="false" class="assistant-link" x-data x-tooltip.raw="">Miedema et al., 2023</a>): <ul> <li><strong>Sum &amp; Product Puzzle</strong>: T0/E0 can shrink node count to 40–60% of standard BDD. Gains arise from very sparse models where most high-order bits are 0.</li> <li><strong>Dining Cryptographers</strong>: With sparsity 0.25–0.0625, T0/E0 outperform BDDs by 3–5%.</li> <li><strong>Muddy Children</strong>: Choice of variant depends on the state-law; T1/E0 excel at extremal rounds (large disjunction/conjunction), collapsing diagrams to a single node.</li> <li><strong>Intermediate Cases</strong>: BDDc (complement-edge BDD) often captures most of the symmetry benefit; ZDDs yield further improvement with careful asymmetry matching.</li> </ul></li> <li><strong>Set Family Compression Benchmarks</strong> (<a href="/papers/2004.04586" title="" rel="nofollow" data-turbo="false" class="assistant-link" x-data x-tooltip.raw="">Matsuda et al., 2020</a>): <ul> <li><strong>Power Sets</strong>: Top ZDD achieves exponential compression—$O(m)nodesfor nodes for 2^msets.</li><li><strong>Knapsack,Paths,Itemsets</strong>:TopZDDsconsistentlyuse5070</ul></li></ul><h4class=paperheadingid=representativememoryuse>RepresentativeMemoryUse</h4><divclass=overflowxautomaxwfullmy4><tableclass=tablebordercollapsewfullstyle=tablelayout:fixed><thead><tr><th>Task</th><th>TopZDD(bytes)</th><th>DenseZDD(bytes)</th><th>NaiveZDD(bytes)</th></tr></thead><tbody><tr><td>Powerset sets.</li> <li><strong>Knapsack, Paths, Itemsets</strong>: Top ZDDs consistently use 50–70% of the memory of DenseZDD or naïve ZDDs, at the expense of 2×–5× slower navigation.</li> </ul></li> </ul> <h4 class='paper-heading' id='representative-memory-use'>Representative Memory Use</h4><div class='overflow-x-auto max-w-full my-4'><table class='table border-collapse w-full' style='table-layout: fixed'><thead><tr> <th>Task</th> <th>Top ZDD (bytes)</th> <th>DenseZDD (bytes)</th> <th>Naive ZDD (bytes)</th> </tr> </thead><tbody><tr> <td>Power-set A=1000</td><td>2,297</td><td>4,185</td><td>3,750</td></tr><tr><td>Knapsack</td> <td>2,297</td> <td>4,185</td> <td>3,750</td> </tr> <tr> <td>Knapsack A=1000</td><td>565,740</td><td>656,728</td><td>1,056,907</td></tr><tr><td></td> <td>565,740</td> <td>656,728</td> <td>1,056,907</td> </tr> <tr> <td>ngridpaths-grid paths n=9</td><td>503,265</td><td>1,465,984</td><td>2,141,955</td></tr></tbody></table></div><p>MembershiptestnavigationforTopZDDis</td> <td>503,265</td> <td>1,465,984</td> <td>2,141,955</td> </tr> </tbody></table></div> <p>Membership test navigation for Top ZDD is O(c\,\log^2 n)forauniverseofsize for a universe of size c.</p><h2class=paperheadingid=practicalguidelinesforapplyingtopzddsandzddvariants>5.PracticalGuidelinesforApplyingTopZDDsandZDDVariants</h2><ul><li>DiagnosethedominantasymmetryintheBooleanstatelaw.Ifdeadbranchespredominateon1edges,useT0/E0suppression.Forlawsnaturallyexpressedaslargeconjunctionsordisjunctions,employE0orT1,respectively(<ahref="/papers/2307.05067"title=""rel="nofollow"dataturbo="false"class="assistantlink"xdataxtooltip.raw="">Miedemaetal.,2023</a>).</li><li>Forhighlysparsemodels,T0(classicZDD)isthedefault.</li><li>Formoderatelysparseorbalancedmodels,complementedgeBDDs(BDDc)areoftensufficient;useZDDvariantsonlyifafewpercentgainjustifiestheconversion.</li><li>Inpractice,<ahref="https://www.emergentmind.com/topics/curriculumdatasetdistillationcudd"title=""rel="nofollow"dataturbo="false"class="assistantlink"xdataxtooltip.raw="">CUDD</a>(thereferencelibrary)onlynativelyimplementsT0;othersaresimulatedvialeaf/edgeflipsontheT0ZDDoritsnegation.</li></ul><p>TopZDDisrecommendedwhentheZDDrepresentationitselfbecomesbottleneckedbysizeespeciallyforhighlyregularorrepetitivesetfamilies.</p><h2class=paperheadingid=algorithmicpropertiesandcomplexity>6.AlgorithmicPropertiesandComplexity</h2><ul><li><strong>Construction</strong>:AgreedybottomupmergeonthespanningtreeyieldsacompacttopDAGofsize.</p> <h2 class='paper-heading' id='practical-guidelines-for-applying-top-zdds-and-zdd-variants'>5. Practical Guidelines for Applying Top ZDDs and ZDD Variants</h2> <ul> <li>Diagnose the dominant asymmetry in the Boolean state law. If dead branches predominate on 1-edges, use T0/E0 suppression. For laws naturally expressed as large conjunctions or disjunctions, employ E0 or T1, respectively (<a href="/papers/2307.05067" title="" rel="nofollow" data-turbo="false" class="assistant-link" x-data x-tooltip.raw="">Miedema et al., 2023</a>).</li> <li>For highly sparse models, T0 (classic ZDD) is the default.</li> <li>For moderately sparse or balanced models, complement-edge BDDs (BDDc) are often sufficient; use ZDD variants only if a few percent gain justifies the conversion.</li> <li>In practice, <a href="https://www.emergentmind.com/topics/curriculum-dataset-distillation-cudd" title="" rel="nofollow" data-turbo="false" class="assistant-link" x-data x-tooltip.raw="">CUDD</a> (the reference library) only natively implements T0; others are simulated via leaf/edge flips on the T0 ZDD or its negation.</li> </ul> <p>Top ZDD is recommended when the ZDD representation itself becomes bottlenecked by size—especially for highly regular or repetitive set families.</p> <h2 class='paper-heading' id='algorithmic-properties-and-complexity'>6. Algorithmic Properties and Complexity</h2> <ul> <li><strong>Construction</strong>: A greedy bottom-up merge on the spanning tree yields a compact top DAG of size O(n_T/\log n_T\,\log\log n_T),where, where n_Tisthenumberoftreenodes.</li><li><strong>NavigationandQueries</strong>:Accesstolabels,zeroandonechildrenissupportedin is the number of tree nodes.</li> <li><strong>Navigation and Queries</strong>: Access to labels, zero and one children is supported in O(\log n)and and O(\log^2 n),respectively;membershiptestsin, respectively; membership tests in O(c\cdot \log^2 n)$.
  • Set Operations: Polylogarithmic-time support for operations like parent, child, and subtree-size on the underlying tree is available; extensions to full set-family operations (union, intersection, min-weight) remain open research problems (Matsuda et al., 2020).
  • Size Lower Bounds: For families such as power-sets or highly regular itemsets, Top ZDDs achieve exponential compression over both BDDs and conventional ZDDs by sharing repeated subpaths across distinct heights (Matsuda et al., 2020).
  • 7. Limitations and Open Directions

    Although Top ZDDs compress highly repetitive families exponentially and maintain polylogarithmic-time navigability, they incur navigation overhead (2–5× slower traversal than DenseZDD), and compression efficacy depends strongly on the redundancy exploitable by spanning-tree selection. Finding optimal or improved spanning trees and extending top-DAG-based compression to broader classes of Boolean or DAG-encoded structures are characterized as substantive open problems. Further research is needed to support advanced operations (beyond membership and navigation) in polylogarithmic time (Matsuda et al., 2020).

    A plausible implication is that for applications prioritizing maximal compression over traversal speed—such as static storage, canonical set-family enumeration, or massively combinatorial symbolic model checking—Top ZDDs are preferable. For dynamic or access-latency-critical scenarios, trade-off analyses may be required.


    Cited Papers:

    (Miedema et al., 2023) Exploiting Asymmetry in Logic Puzzles: Using ZDDs for Symbolic Model Checking Dynamic Epistemic Logic (Matsuda et al., 2020) Storing Set Families More Compactly with Top ZDDs

    Definition Search Book Streamline Icon: https://streamlinehq.com
    References (2)

    Topic to Video (Beta)

    No one has generated a video about this topic yet.

    Whiteboard

    No one has generated a whiteboard explanation for this topic yet.

    Follow Topic

    Get notified by email when new papers are published related to Top ZDDs.