Certified MaxSAT Preprocessing

Hannes Ihalainen, Andy Oertel, Yong Kiam Tan, Jeremias Berg, Matti Järvisalo, Jakob NordströmarXiv 2024

TL;DR

This paper introduces the first practical toolchain for certified MaxSAT preprocessing, ensuring that complex problem reformulations don't accidentally change the optimal solution. By leveraging pseudo-Boolean proof logging and formally verified checkers, the authors provide a high-assurance way to verify that a preprocessed MaxSAT instance is "equioptimal" to the original input.

What Problem Does This Paper Address?

Maximum Satisfiability (MaxSAT) is a powerful framework for solving NP-hard optimization problems. However, modern MaxSAT solvers are incredibly complex, and history shows they aren't immune to bugs that lead to incorrect results.

While the SAT community has largely addressed this through "proof logging"—where solvers emit a machine-verifiable certificate of their reasoning—MaxSAT has lagged behind. Specifically, existing efforts have focused only on the core solving phase. This leaves a massive gap: preprocessing. Preprocessors aggressively rewrite, simplify, and eliminate variables from an input instance to speed up the solver. If a preprocessor has a bug, the solver might perfectly solve the wrong problem. This paper tackles the challenge of certifying that these drastic reformulations preserve the problem's optimal value.

Methods

The authors developed a certifying version of the popular preprocessor MaxPre and a corresponding verification pipeline. Their approach relies on several key components:

  1. Pseudo-Boolean (PB) Proof Logging: Instead of traditional clausal proofs (like DRAT in SAT), they use PB constraints (linear inequalities over Boolean variables). This is much more natural for reasoning about objective functions and costs.
  2. VeriPB & CakePB: They extended VeriPB, a tool for checking PB proofs, to support "reformulation guarantees." To achieve the highest level of trust, they also updated CakePB, a proof checker formally verified in the HOL4 theorem prover, to handle these new proofs.
  3. A 5-Stage Workflow: The preprocessor tracks changes across five distinct stages, moving from the initial Weighted Conjunctive Normal Form (WCNF) to an objective-centric PB representation, applying simplifications, and finally converting back to WCNF.
Overview of the five stages of certified MaxSAT preprocessing

The authors implemented proof logging for a wide array of techniques, including standard SAT-based rules (like Bounded Variable Elimination) and MaxSAT-specific ones (like Binary Core Removal and Label Matching).

Datasets

The approach was evaluated using the MaxSAT Evaluation 2023 benchmarks, consisting of:

  • 558 weighted instances
  • 572 unweighted instances

These represent a diverse set of real-world optimization problems used to test state-of-the-art solvers.

Key Insights and Ideas

  • Equioptimality is the Goal: Unlike SAT, where you just need to preserve satisfiability, MaxSAT requires preserving the minimum cost. The authors formalize this as "equioptimality" and provide the first practical tool to prove it for reformulated problems.
  • PB Reasoning as a Unified Foundation: The paper demonstrates that pseudo-Boolean reasoning is expressive enough to capture a vast range of disparate preprocessing techniques under a single proof format.
  • Verification at Scale: By optimizing the verified checker (using array-backed hash tables and lazy occurrence mapping), they proved that formal verification of complex preprocessing is feasible for large, real-world benchmarks, not just toy examples.

Key Results

  • Feasibility: Out of 1073 instances successfully simplified by the preprocessor, the toolchain successfully verified 991 instances (approx. 92%) within the resource limits.
  • Manageable Overhead: Adding proof logging to the preprocessor increased its running time by a geometric mean of only 46%. For 95% of instances, the overhead was less than 2x.
  • Checking Performance: The combined checking time (elaboration + verified checking) is significantly slower than preprocessing—about 113x slower on average. However, because preprocessing is usually very fast (often sub-second), the total time spent checking remains practical for many applications.
  • Verified Correctness: The use of CakePBwcnf ensures that if the checker says "Verified," there is a mathematically sound, machine-checked proof that the optimal values match.

Limitations and Future Work

  • Checking Bottleneck: The primary limitation is the performance of the proof checking pipeline, specifically the elaboration step in VeriPB. The authors suggest that adding "hints" (similar to the LRAT format in SAT) could drastically speed this up.
  • Solver Coverage: While this work covers preprocessing, and other recent work covers core-guided solving, there are still MaxSAT solving styles (like Implicit Hitting Set solvers) that do not yet have general pseudo-Boolean proof logging methods.
  • Memory Usage: The verified checker's occurrence mapping can be memory-intensive, leading to some memory-outs on the largest instances. Further algorithmic optimizations in the checker could improve this.

Summary updated

BibTeX
@misc{ihalainen2024certified,
  author = {Hannes Ihalainen and Andy Oertel and Yong Kiam Tan and Jeremias Berg and Matti Järvisalo and Jakob Nordström},
  title = {{Certified MaxSAT Preprocessing}},
  year = {2024},
  eprint = {2404.17316},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2404.17316},
}
Figure