# Counting models for 2SAT and 3SAT formulae

```@article{Dahllf2005CountingMF,
title={Counting models for 2SAT and 3SAT formulae},
author={Vilhelm Dahll{\"o}f and P. Jonsson and Magnus Wahlstr{\"o}m},
journal={Theor. Comput. Sci.},
year={2005},
volume={332},
pages={265-291}
}```
• Published 2005
• Computer Science, Mathematics
• Theor. Comput. Sci.
We here present algorithms for counting models and max-weight models for 2SAT and 3SAT formulae. They use polynomial space and run in O(1.2561n) and O(1.6737n) time, respectively, where n is the number of variables. This is faster than the previously best algorithms for counting nonweighted models for 2SAT and 3SAT, which run in O(1.3247n) and O(1.6894n) time, respectively. In order to prove these time bounds, we develop new measures of formula complexity, allowing us to conveniently analyze… Expand

#### Tables and Topics from this paper

Improved Bounds for Exact Counting of Satisfiability Solutions ∗
An algorithm is presented for exactly solving (in fact, counting) the number of maximum weight satisfying assignments of a 2-SAT formula. The worst case running time of O(1.2461) for formulas with nExpand
An Algorithm for the SAT Problem for Formulae of Linear Length
The algorithm that decides the satisfiability of a CNF formula where every variable occurs at most k times in time is presented, and its bound is the best upper bound for an exact algorithm for a 3sat formula with up to six occurrences per variable. Expand
A Tighter Bound for Counting Max-Weight Solutions to 2SAT Instances
An algorithm for counting the number of max-weight solutions to a 2SAT formula is given, and the bound on its running time is improved, a refinement of the method of analysis, where the concept of compound measures to multivariate measures is extended, also allowing the optimal parameters for the measure to be found automatically. Expand
Model Counting for 2SAT Based on Graphs by Matrix Operators
• Mathematics, Computer Science
• Eng. Lett.
• 2007
An efficient algorithm is obtained such that the input is a Boolean formula Σ in 2-CNF and the output can be either a charged Boolean formulaΣ′ simpler than Σ or the number of models of Σ. Expand
The computation of #2SAT by a fixed-parameter tractable algorithm
• Computer Science
• LANMR
• 2018
If GF has entwined cycles (set of cycles with common edges), this work has designed a deterministic fixed-parameter algorithm for #2SAT, that is, an algorithm whose time complexity is O(2 · poly(|F |)), where poly( |F |) is a polynomial function on the size of F. Expand
Faster Graph Coloring in Polynomial Space
• Mathematics, Computer Science
• COCOON
• 2017
We present a polynomial-space algorithm that computes the number independent sets of any input graph in time \$O(1.1387^n)\$ for graphs with maximum degree 3 and in time \$O(1.2355^n)\$ for generalExpand
Faster Exponential-time Algorithms for Approximately Counting Independent Sets
• Mathematics, Computer Science
• ArXiv
• 2020
An exponential-time approximation scheme for counting independent sets on graphs with no vertices with degree at least 6 whose neighbours' degrees sum to 27 or more is given, which is faster than the best known algorithm for the exact problem. Expand
Computing #2SAT and #2UNSAT by Binary Patterns
• Mathematics, Computer Science
• MCPR
• 2012
It is shown that, by considering the constrained graph GF of F, if GF represents an acyclic graph then, #UNSAT(F) can be computed in polynomial time. Expand
A Note for Parametric Complexity of #2SAT
• Mathematics, Computer Science
• LA-NMR
• 2011
We present some results about the parametric complexity for counting the number of truth assignments for two Conjunctive Forms (2CF’s), such problem is denoted as #2SAT. It is common to analyze theExpand
Counting independent sets via Divide Measure and Conquer method
• Mathematics, Computer Science
• ArXiv
• 2015
In this paper we give an algorithm for counting the number of all independent sets in a given graph which works in time \$O^*(1.1394^n)\$ for subcubic graphs and in time \$O^*(1.2369^n)\$ for generalExpand

#### References

SHOWING 1-10 OF 29 REFERENCES
Improved Algorithms for Counting Solutions in Constraint Satisfaction Problems
• Mathematics, Computer Science
• CP
• 2003
A new algorithm is provided for counting the number of solutions to binary Csp s which has a time complexity ranging from O((d/4·α4)n) to O((α+α5+[d/ 4-1]· α4) n) depending on the domain size d ≥ 3. Expand
Counting Models Using Connected Components
• Computer Science
• AAAI/IAAI
• 2000
A new extension of the DavisPutnam procedure, based on recursively identifying connected constraint-graph components, is presented that substantially improves counting performance on random 3-SAT instances as well as benchmark instances from the SATLIB and Beijing suites. Expand
Counting Satisfying Assignments in 2-SAT and 3-SAT
• Mathematics, Computer Science
• COCOON
• 2002
We present an O(1.3247n) algorithm for counting the number of satisfying assignments for instances of 2-SAT and an O(1.6894n) algorithm for instances of 3-SAT. This is an improvement compared to theExpand
New Methods for 3-SAT Decision and Worst-case Analysis
• O. Kullmann
• Computer Science, Mathematics
• Theor. Comput. Sci.
• 1999
Abstract We prove the worst-case upper bound 1.5045..n for the time complexity of 3-SAT decision, where n is the number of variables in the input formula, introducing new methods for the analysis asExpand
Number of Models and Satisfiability of Sets of Clauses
• Wenhui Zhang
• Computer Science, Mathematics
• Theor. Comput. Sci.
• 1996
This work presents a way of calculating the number of models of propositional formulas represented by sets of clauses, and applies the theory on satisfiability problems, especially on the 3-SAT problems. Expand
The Complexity of Counting in Sparse, Regular, and Planar Graphs
• Computer Science, Mathematics
• SIAM J. Comput.
• 2001
It is proved that the problems of counting matchings, vertex covers, independent sets, and extremal variants of these all remain hard when restricted to planar bipartite graphs of bounded degree or regular graphs of constant degree. Expand
Counting H-colorings of partial k-trees
• Computer Science, Mathematics
• Theor. Comput. Sci.
• 2002
The problem of counting all H-colorings of a graph G with n vertices is considered. While the problem is, in general, #P-complete, we give linear time algorithms that solve the main variants of thisExpand
A separator theorem for graphs with an excluded minor and its applications
• Mathematics, Computer Science
• STOC '90
• 1990
It follows that for any fixed graph H, given a graph G with n vertices and with no H-minor one can approximate the size of the maximum independent set of G up to a relative error of 1/ √ log n in polynomial time, find that size exactly and solve any sparse system of n linear equations in n unknowns in time O(n). Expand
An algorithm for counting maximum weighted independent sets and its applications
• Mathematics, Computer Science
• SODA '02
• 2002
We present an O(1.3247n) algorithm for counting the number of independent sets with maximum weight in graphs. We show how this algorithm can be used solving a number of different counting problems:Expand
The Complexity of Enumeration and Reliability Problems
• L. Valiant
• Mathematics, Computer Science
• SIAM J. Comput.
• 1979
For a large number of natural counting problems for which there was no previous indication of intractability, that they belong to the class of computationally eqivalent counting problems that are at least as difficult as the NP-complete problems. Expand