Generalized Optimization Modulo Theories

Nestan Tsiskaridze, Clark W. Barrett, Cesare Tinelli

Abstract

Optimization Modulo Theories (OMT) has emerged as an important extension of the highly successful Satisfiability Modulo Theories (SMT) paradigm. The OMT problem requires solving an SMT problem with the restriction that the solution must be optimal with respect to a given objective function. We introduce a generalization of the OMT problem where, in particular, objective functions can range over partially ordered sets. We provide a formalization of and an abstract calculus for the Generalized OMT problem and prove their key correctness properties. Generalized OMT extends previous work on OMT in several ways. First, in contrast to many current OMT solvers, our calculus is theory-agnostic, enabling the optimization of queries over any theories or combinations thereof. Second, our formalization unifies both single- and multi-objective optimization problems, allowing us to study them both in a single framework and facilitating the use of objective functions that are not supported by existing OMT approaches. Finally, our calculus is sufficiently general to fully capture a wide variety of current OMT approaches (each of which can be realized as a specific strategy for rule application in the calculus) and to support the exploration of new search strategies. Much like the original abstract DPLL(T) calculus for SMT, our Generalized OMT calculus is designed to establish a theoretical foundation for understanding and research and to serve as a framework for studying variations of and extensions to existing OMT methodologies.

Introduction

Satisfiability Modulo Theories (SMT) has revolutionized formal verification and automated reasoning by providing efficient methods to determine the satisfiability of formulas in various first-order theories. Optimization Modulo Theories (OMT) extends this capability by seeking not just any satisfying assignment, but one that is optimal according to a specified objective function.

Despite its success, current OMT implementations face two significant hurdles. First, they typically require a total ordering of the objective space (e.g., minimizing a single numerical value), which complicates multi-objective optimization scenarios like Pareto optimization where solutions may be incomparable. Second, most solvers are tightly coupled to specific theories, such as linear arithmetic, lacking a general, theory-agnostic framework. This paper introduces Generalized Optimization Modulo Theories (GOMT) to address these limitations by formalizing OMT for partial orders and providing a theory-independent abstract calculus.

The GOMT Calculus

The core of this work is the GOMT Calculus, a formal system of derivation rules designed to navigate the solution space. Similar to how the DPLL(T) calculus provides a foundation for SMT solvers, the GOMT calculus offers a blueprint for optimization. A state in this calculus tracks the best solution found so far, the remaining unexplored search space, and a sequence of formulas that partition the search space into branches.

The search process is governed by three primary rules:

  1. F-Split: This rule divides the search space into smaller sub-branches, facilitating strategies like binary search.
  2. F-Sat: This rule invokes an underlying SMT solver to find an improved solution within a specific branch. If a better solution is found, the "best so far" is updated and the search space is pruned.
  3. F-Close: This rule discards a branch once the solver proves that no better solutions can be found within it.

Theory Agnosticism and Expressiveness

A defining feature of GOMT is its theory-agnostic nature. It treats the underlying SMT solver as a "black box" and the optimization criteria as a generic "Better" function. This allows the framework to handle complex queries across a wide array of theories, including integers, reals, bitvectors, and strings.

Syntax and semantics for various theories supported by the Generalized OMT framework.

By shifting from total orders to partial orders, GOMT unifies various optimization paradigms—such as single-objective, lexicographic, Pareto, and "boxed" optimization—into a single framework. This expressiveness enables the optimization of problems that mix theories, such as finding a string that is both minimal in length (Integer theory) and satisfies specific substring constraints (String theory).

Theoretical Foundations and Results

The paper establishes the mathematical rigor of the GOMT framework through several key proofs:

  • Soundness: When the calculus reaches a saturated state where no further rules can be applied, the current solution is guaranteed to be optimal.
  • Termination: The search is guaranteed to terminate provided the optimization order is well-founded (no infinite chains of improvement) and the search strategy is progressive.
  • Completeness: A progressive search strategy is guaranteed to find an optimal solution if one exists.

Additionally, the calculus supports "anytime" properties, meaning it can be halted at any point to provide the best solution discovered thus far—a crucial feature for time-sensitive industrial applications.

Discussion and Future Work

While GOMT provides a robust theoretical foundation, certain challenges remain. The framework may diverge if the objective function allows for "Zeno-style" infinite improvements (e.g., seeking the smallest positive real number). Furthermore, as a theoretical contribution, this work does not yet include empirical performance benchmarks against specialized solvers like OptiMathSAT or z3.

Future research will focus on implementing the GOMT calculus within state-of-the-art SMT solvers to evaluate its practical efficiency. The authors also intend to explore "All-OMT" problems, which involve identifying the complete set of optimal solutions in a partially ordered space.

Summary updated

BibTeX
@inproceedings{tsiskaridze2024generalized,
  author = {Nestan Tsiskaridze and Clark W. Barrett and Cesare Tinelli},
  title = {{Generalized Optimization Modulo Theories}},
  booktitle = {IJCAR},
  year = {2024},
  url = {https://openreview.net/forum?id=Ynql8gxhxs},
}
Figure