---
title: 'FourierSAT: Algebraic SAT and Hybrid Solver'
url: https://www.emergentmind.com/topics/fouriersat
type: topic
---

# FourierSAT: Algebraic SAT and Hybrid Solver

FourierSAT is an algebraic framework for Boolean satisfiability (SAT) and hybrid constraint solving that encodes Boolean and cardinality constraints as polynomials via the Walsh–Fourier expansion, reducing SAT to continuous optimization over a high-dimensional cube. Unlike traditional SAT approaches tied to conjunctive normal form (CNF), FourierSAT accommodates rich, non-CNF constraint types—such as parity (XOR), cardinality (CARD), and not-all-equal (NAE)—with direct and closed-form polynomial encodings. This formulation enables the application of gradient-based optimization (typically projected gradient descent, PGD), facilitating an incomplete but highly flexible and empirically robust approach for solving hybrid Boolean constraint problems [1912.01032].

## 1. Walsh–Fourier Expansion and Constraint Encoding

The core mathematical device in FourierSAT is the Walsh–Fourier transform of Boolean functions. For $f:\{\pm1\}^n\rightarrow \mathbb{R}$, the unique multilinear expansion is
\[
f(x) = \sum_{S\subseteq [n]} \widehat{f}(S) \prod_{i\in S} x_i,
\]
where the coefficients are
\[
\widehat{f}(S) = \mathbb{E}_{x\sim\{\pm1\}^n}\left[ f(x) \prod_{i\in S} x_i \right] = \frac{1}{2^n}\sum_{x} f(x) \prod_{i\in S} x_i.
\]
For SAT, each constraint type—CNF, XOR, CARD, NAE—admits a compact Fourier expansion. For example:
- CNF clause $x_1\vee x_2$:
  \[
  FE_{x_1\vee x_2}(x) = -\frac12 + \frac12 x_1 + \frac12 x_2 + \frac12 x_1x_2
  \]
- XOR clause $x_1\oplus x_2\oplus x_3$:
  \[
  FE_{x_1\oplus x_2\oplus x_3}(x) = x_1x_2x_3
  \]
- Cardinality constraint $\sum_{i=1}^3 x_i \geq 2$:
  \[
  FE_{D^{\geq2}(\{x_1,x_2,x_3\})}(x) = \frac12(x_1+x_2+x_3) - \frac12 x_1 x_2 x_3
  \]
These closed-form expressions yield a single aggregate polynomial for the whole problem by summing over all constraint polynomials:
\[
F_f(x) = \sum_{j=1}^{m} FE_{c_j}(x).
\]
The constraint is satisfied if and only if $F_f(x)$ attains its global minimum value $-m$ on $x\in \{\pm1\}^n$ [1912.01032].

## 2. Continuous Relaxation and Optimization Landscape

FourierSAT converts the Boolean SAT search into a continuous optimization problem over the cube $[-1,1]^n$. The main theoretical result is:
- $f$ is satisfiable if and only if $\min_{x\in[-1,1]^n} F_f(x) = -m$, and any minimizer can be rounded (coordinate-wise) to a Boolean assignment without increasing $F_f(x)$.
- The gradient and Hessian of $F_f$ are efficiently computable because $FE_{c_j}$ polynomials are of bounded degree.

Key properties:
- All nonconstant interior critical points are saddles; all local minima correspond to “frozen” feasible Boolean assignments on the boundary (i.e., $x_i = \pm 1$) [1912.01032].
- The expected number of satisfied clauses by a randomized rounding of $x$ is directly determined by $F_f(x)$:
  \[
  \mathbb{E}[\# \text{ clauses satisfied}] = \frac{m - F_f(x)}{2}.
  \]
This quantitative correspondence links the objective's descent to solution quality.

## 3. Projected Gradient Descent and Solver Architecture

FourierSAT’s main algorithm is projected gradient descent (PGD) with subroutines for escaping saddle points:
- At each step, compute $x' = x - \eta \nabla F_f(x)$ and project coordinate-wise onto $[-1,1]^n$.
- When the norm of the "gradient mapping" $G(x)$ is small, perform saddle-point detection:
  - If $x$ is feasible (integer on all active coordinates), check second-order conditions or try to escape by following a direction of negative curvature.
  - If not feasible, perturb along a direction that decreases $F_f$.

PGD has the following theoretical properties:
- $F_f$ is $(m\sqrt n)$–Lipschitz and its gradient is $(mn)$–Lipschitz.
- Convergence to an $\varepsilon$–critical point is achieved in $O(n m^2 / \varepsilon^2)$ iterations.
- Hyperparameters: step size $\eta\approx 1/(nm)$, tolerance $\varepsilon\sim 10^{-6}$, random restarts for robustness, and clause weighting to avoid vanishing gradients on long clauses.

These features guarantee robust descent, principled escaping of flat regions, and reliable rounding to feasible solutions [1912.01032].

## 4. Extensions, Variants, and FFT–SAT Connections

The algebraic framework extends naturally to hybrid SAT settings beyond CNF, including parity formulas, global cardinalities, and not-all-equal constraints. Later research has built upon FourierSAT with several notable extensions:
- FastFourierSAT accelerates the critical ESP-based gradient calculations using FFT-inspired DFT convolution and massive GPU parallelization, reducing the gradient step for symmetric polynomial clauses from $O(k^3)$ to $O(k^2)$ sequentially, and $O(\log k)$ parallel depth. This unlocks effective parallel hybrid-SAT solving for very large arities [2308.15020].
- The Fourier analysis approach has also been adopted for quantum-inspired SAT solvers (AmplificationSAT) based on sparse low-degree Fourier approximations, iterative projection, and decimation-based bias sampling [2212.04016].
- The method generalizes to non-Boolean, finite-domain CSPs (e.g., FourierCSP) via Walsh–Fourier expansions of indicator functions for arbitrary discrete variables, enabling multilinear relaxation and PGD on a larger class of CSPs [2510.04480].
- A distinct field of application relates to SAT-based FFT algorithm discovery, termed “FourierSAT” in the FFT/DFT literature, where SAT/SMT is used to search for FFT flowgraph parameters achieving minimal FLOP counts. The name overlap is coincidental but reflects similar algebraic/Boolean-solver technology [1103.5740].

## 5. Empirical Behavior and Benchmark Results

FourierSAT and its derivatives have been benchmarked on diverse problem types:
- On random hybrid constraints (mixtures of CNF, XOR, CARD): FourierSAT achieves solve rates substantially above local search and is competitive or superior to CryptoMinisat (for XOR) and MiniCARD/MonoSAT (for cardinality). For instance, on approximate vertex cover problems (random cubic graphs), FourierSAT solved 472 out of 500 instances, outperforming MonoSAT (420/500) and MiniCARD (261/500).
- Performance on parity learning with error: FourierSAT solved all 300 tested instances (error rate 25%), versus 79/300 by WalkSAT.
- On large random hybrid formulas: FourierSAT solved 2957/4800, best WalkSAT variant solved 2452, and CryptoMinisat ≈3600 [1912.01032].
- In highly symmetric or XOR-rich cases (especially large-k or global constraints), FastFourierSAT demonstrated $100\times$–$150\times$ faster clause-gradient steps and superior scalability versus discrete or sequential CLS solvers [2308.15020].
- On pure random 3-SAT or industrial SATLIB/competition CNFs, traditional CDCL solvers remain dominant; FourierSAT lags by an order of magnitude, highlighting its complementary profile: strong on global/symmetric/hybrid constraints, limited on asymmetric and proof-reduction–intensive instances [2510.04480].

## 6. Theoretical Limitations and Prospects

FourierSAT is incomplete: it cannot certify unsatisfiability; it only finds solutions if one exists. This limitation suggests directions such as algebraic certificate integration (e.g., via Nullstellensatz or Gröbner bases). The reliance on first-order methods means that high-dimensional saddles can induce stagnation, though stochastic restarts and noise can partially alleviate this. Per-iteration complexity for very long clauses may be mitigated with low-degree truncation/approximation or by using FFT-based convolution as in FastFourierSAT [1912.01032,2308.15020].

Despite these caveats, the algebraic/continuous perspective introduced by FourierSAT broadens the reach of efficient SAT methods into hybrid and nonstandard constraint domains not tractable via traditional CNF search paradigms.

---

**Summary Table: Key Properties of FourierSAT**

| Property                         | Description                                                      | Source         |
|-----------------------------------|------------------------------------------------------------------|----------------|
| Clause encoding                   | Explicit multilinear Walsh–Fourier expansions for CNF/XOR/CARD   | [1912.01032]   |
| Optimization domain               | Continuous box $x\in [-1,1]^n$                                   | [1912.01032]   |
| Main algorithm                    | Projected gradient descent + saddle escape/feasibility subroutines| [1912.01032]   |
| Critical point landscape          | Interior points are saddles; minima on boundary correspond to solutions | [1912.01032]   |
| Empirical strengths               | Robust on hybrid constraints, global/cardinality/XOR, scalable    | [1912.01032]   |
| Limitations                       | Incomplete (no UNSAT certificate), weaker on industrial CNF       | [1912.01032]   |

For implementation, the explicit multilinear forms, gradient and projection steps, and convergence criteria detailed above suffice to construct a functional and theoretically justified FourierSAT solver; further, FFT-based parallelizations extend its reach to large-scale instances and hybrid-SAT/CSP models [1912.01032,2308.15020,2510.04480].

Source: https://www.emergentmind.com/topics/fouriersat