The Complexity of Weighted Boolean #CSP with Mixed Signs

The Complexity of Weighted Boolean #CSP with Mixed Signs
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.

We give a complexity dichotomy for the problem of computing the partition function of a weighted Boolean constraint satisfaction problem. Such a problem is parameterized by a set of rational-valued functions, which generalize constraints. Each function assigns a weight to every assignment to a set of Boolean variables. Our dichotomy extends previous work in which the weight functions were restricted to being non-negative. We represent a weight function as a product of the form (-1)^s g, where the polynomial s determines the sign of the weight and the non-negative function g determines its magnitude. We show that the problem of computing the partition function (the sum of the weights of all possible variable assignments) is in polynomial time if either every weight function can be defined by a “pure affine” magnitude with a quadratic sign polynomial or every function can be defined by a magnitude of “product type” with a linear sign polynomial. In all other cases, computing the partition function is FP^#P-complete.


💡 Research Summary

This paper establishes a complete complexity dichotomy for the computation of partition functions in weighted Boolean constraint satisfaction problems (#CSP) when the weight functions may assume both positive and negative rational values. The authors model each weight function f as a product (-1)^{s(x)}·g(x), where s(x) is an integer‑valued polynomial that determines the sign of the weight and g(x) ≥ 0 is a non‑negative function that determines its magnitude. This representation cleanly separates the sign component from the magnitude component, allowing the authors to analyse their influence on computational difficulty independently.

The main result identifies exactly two families of weight functions for which the partition function can be computed in polynomial time; all other families lead to FP^{#P}‑completeness.

  1. Pure‑affine magnitude with quadratic sign

    • Magnitude: g is a product of indicator functions of affine linear equations over GF(2). Concretely, g(x)=∏_{i}δ(A_i·x=b_i), where each δ is 1 if the linear equation holds and 0 otherwise. This “pure affine” structure forces the variables to satisfy a system of linear constraints, but no higher‑order interactions.
    • Sign: s(x) is a polynomial of degree at most two, i.e., s(x)=c+∑i a_i x_i+∑{i<j} b_{ij} x_i x_j. The sign may depend on individual variables and on pairwise products, but not on higher‑order monomials.
    • Algorithm: By performing Gaussian elimination on the affine system one reduces the problem to a set of free variables. The contribution of the quadratic sign polynomial can then be summed over all 2^{free} assignments using standard inclusion‑exclusion or Walsh‑Hadamard transform techniques, yielding a deterministic polynomial‑time algorithm.
  2. Product‑type magnitude with linear sign

    • Magnitude: g factorises completely across variables: g(x)=∏_{i}h_i(x_i), where each h_i maps {0,1} to a non‑negative rational weight. This “product type” means there are no interactions between different variables in the magnitude.
    • Sign: s(x) is linear, i.e., s(x)=c+∑_i a_i x_i. The sign depends only on the individual variables, never on their products.
    • Algorithm: Because the magnitude is already a product of unary terms, the overall partition function is simply the product over i of (h_i(0)+(-1)^{a_i}h_i(1)). Computing each factor takes constant time, so the whole computation is O(n).

For any set of weight functions that does not fall entirely within one of these two families, the authors prove that computing the partition function is FP^{#P}‑complete. The hardness proof proceeds by reductions from known #P‑hard problems (e.g., #3‑SAT, #ExactCover) while carefully embedding the required sign structure. If the sign polynomial has degree three or higher, or if the magnitude function is neither pure‑affine nor product‑type (or mixes the two), the reduction can simulate arbitrary counting problems, establishing the full hardness.

The technical contributions are severalfold. First, the sign‑magnitude decomposition provides a clean analytical lens that was unavailable in prior work, which only considered non‑negative weights. Second, the identification of the two tractable classes mirrors the classic dichotomies for non‑negative weighted CSPs (affine vs. product) but now incorporates the additional dimension of sign degree. Third, the paper delivers a rigorous proof that the boundary between tractability and intractability is exactly characterised by the degree of the sign polynomial (quadratic vs. linear) together with the structural form of the magnitude.

Beyond the theoretical classification, the results have practical implications for areas where negative weights naturally arise, such as spin‑glass models in statistical physics, certain quantum circuit simulations, and signed graph homomorphisms. In these domains, the paper’s algorithmic criteria can be used to quickly assess whether a given model admits an efficient exact counting algorithm or whether one should resort to approximation or heuristic methods.

Finally, the authors discuss future directions: extending the dichotomy to non‑Boolean domains, exploring approximation schemes (FPRAS) for the hard cases, and investigating dynamic or online versions of weighted CSPs where the sign polynomial may evolve over time. The work thus not only settles a long‑standing open question about the complexity of signed weighted Boolean CSPs but also opens a rich avenue for further research at the intersection of counting complexity, algebraic combinatorics, and statistical physics.


Comments & Academic Discussion

Loading comments...

Leave a Comment