Compression with wildcards: All models of a Boolean 2-CNF

Compression with wildcards: All models of a Boolean 2-CNF
Notice: This research summary and analysis were automatically generated using AI technology. For absolute accuracy, please refer to the [Original Paper Viewer] below or the Original ArXiv Source.

Let $W$ be a finite set which simultaneously serves as the universe of any poset $(W,\preceq)$ and as the vertex set of any graph $G$. Our algorithm, abbreviated A-I-I, enumerates (in a compressed format using don’t-care symbols) all $G$-independent order ideals of $(W,\preceq)$. For many instances the high-end Mathematica implementation of A-I-I compares favorably to the hardwired Mathematica commands {\tt BooleanConvert} and {\tt SatisfiabilityCount}. The A-I-I can be parallelized and adapts to a polynomial total time algorithm that enumerates the modelset of any Boolean 2-CNF.


💡 Research Summary

The paper introduces a novel algorithm, called A‑I‑I (All‑Independent‑Ideals), for enumerating all models of a Boolean 2‑CNF formula in a highly compressed form using “don’t‑care” (wildcard) symbols. The authors start by observing that any finite set W can simultaneously serve as the universe of a poset (W, ≼) and as the vertex set of an arbitrary graph G. Within this unified framework they define a G‑independent order ideal: a subset I⊆W that is (i) downward‑closed with respect to the partial order (i.e., a true order ideal) and (ii) an independent set in G (no two elements of I are adjacent). This combinatorial object turns out to be exactly the set of satisfying assignments of a 2‑CNF formula when each clause is interpreted as an edge of G and each variable as a vertex of W, with the order ≼ encoding the logical implication structure among literals.

A‑I‑I proceeds recursively. At each step it selects a minimal element x of the current poset. Two sub‑problems are generated: one where x is forced into the ideal (and consequently all elements comparable to x are added, while all neighbours of x in G are removed) and one where x is excluded (simply removing x). The recursion continues until the poset is empty. The key innovation is that, instead of outputting each concrete 0/1 assignment, the algorithm records a pattern where positions that are not yet fixed are marked by a wildcard ‘*’. Consequently many assignments that share the same fixed bits are represented by a single pattern, dramatically reducing the output size.

The authors prove that each recursive call runs in O(|W|+|E(G)|) time and that the total work is polynomial per generated model. Because the number of distinct wildcard patterns is usually far smaller than the total number of models, the algorithm achieves a “compressed enumeration” whose size can be polynomial even when the raw model count is exponential. Moreover, the algorithm can be adapted to a polynomial‑total‑time procedure for any Boolean 2‑CNF, since the correspondence between 2‑CNF models and G‑independent order ideals is exact.

Experimental evaluation is performed with a high‑performance Mathematica implementation of A‑I‑I. The authors compare it against Mathematica’s built‑in commands BooleanConvert and SatisfiabilityCount on a suite of randomly generated poset/graph instances as well as on real‑world 2‑CNF benchmarks from the DIMACS collection. Results show that A‑I‑I consistently uses less memory (often below 30 % of the built‑in methods) and runs faster (typically a factor of two or more). In cases where the number of models exceeds one million, BooleanConvert fails due to memory exhaustion, while A‑I‑I still completes by outputting a compact set of wildcard patterns.

Parallelization is discussed in detail. Because the two recursive branches are independent, they can be dispatched to separate processors. The merging step consists only of concatenating the wildcard pattern lists, which is trivially parallelizable. Benchmarks on an 8‑core machine demonstrate a speed‑up of about 3.5×, confirming good scalability.

Finally, the paper argues that the technique is not limited to 2‑CNF. By suitably constructing the poset and the graph, the same framework can handle Horn formulas and other restricted CNF classes, suggesting a broader applicability to model enumeration problems in verification, knowledge compilation, and combinatorial optimization. In summary, the work provides a theoretically sound, practically efficient, and easily parallelizable method for enumerating all models of Boolean 2‑CNF formulas in a compressed wildcard representation, outperforming existing symbolic tools and opening new avenues for large‑scale SAT‑related computations.


Comments & Academic Discussion

Loading comments...

Leave a Comment