SEM: a System for Enumerating Models

Jian Zhang, Hantao ZhangIJCAI 1995

Introduction

Finding finite models for first-order logic theories is a fundamental task in automated reasoning. This paper introduces SEM (System for Enumerating Models), a high-performance tool developed by Jian Zhang and Hantao Zhang. SEM is designed to find concrete mathematical structures—such as groups or lattices—that satisfy a given set of logical axioms. By combining efficient constraint propagation with a powerful symmetry-breaking heuristic, SEM significantly outperforms contemporary state-of-the-art solvers.

The Challenge of Model Generation

Model generation is essentially a large-scale Constraint Satisfaction Problem (CSP). Two primary bottlenecks hinder performance in existing systems:

  1. Constraint Propagation Efficiency: Determining if a partial assignment violates complex logical formulas often involves costly memory operations.
  2. Isomorphism (Symmetry): Solvers frequently waste time exploring search branches that are structurally identical to previously checked ones, simply because element names are permuted.

Methodology

SEM addresses these bottlenecks through two core architectural pillars:

Efficient Constraint Propagation

Unlike SAT-based solvers that convert problems into propositional logic—often leading to a "clause explosion"—SEM operates directly on first-order ground clauses. It utilizes a tree-based data structure with internal counters to track unassigned literals. This design allows for rapid constraint propagation with virtually zero dynamic memory allocation during the search, maximizing raw performance.

The Least Number Heuristic (LNH)

The "secret sauce" of SEM is the Least Number Heuristic. When assigning a value to a cell in a multiplication table, the solver only considers values already present in the partial model, plus exactly one new value. This simple yet effective rule prunes millions of redundant, isomorphic search paths, collapsing the search space dramatically.

Performance and Benchmarks

The authors evaluated SEM against systems like FALCON, FINDER, SATO, and MACE across various benchmarks, including the Pigeonhole Problem and complex equational theories.

Scalability on the Pigeonhole Problem

On the standard Pigeonhole Problem benchmark, SEM demonstrates exceptional scalability. While older algorithms struggle as the number of "pigeons" increases, SEM maintains high efficiency.

Performance of SEM on the Pigeonhole Problem (n=14 to 30).

As shown in the data, SEM can handle a 30-pigeon instance in approximately 2.11 seconds (combining creation and search time), illustrating its robustness for large CSP instances compared to standard backtracking systems.

Equational Problems and Speedups

In head-to-head comparisons on equational problems like non-commutative groups (NCG) and rings with unit (RU), SEM frequently achieves speedups of an order of magnitude or more over its competitors.

Comparison of SEM against FINDER and MACE on equational benchmarks.

Comparative testing highlights that for complex instances like NCG.7, SEM is significantly faster than FINDER and MACE. In several cases where other solvers timed out (indicated by asterisks or "> 1000"), SEM successfully found models in seconds.

Conclusion

SEM demonstrates that high-performance model generation requires both theoretical innovation and careful implementation. By prioritizing symmetry breaking via the Least Number Heuristic and optimizing low-level constraint propagation, SEM has proven to be a powerful tool for discovering new mathematical structures and verifying logical consistency. Future work aims to incorporate non-exhaustive search methods to tackle even larger domains.

Summary updated

BibTeX
@inproceedings{zhang1995sem,
  author = {Jian Zhang and Hantao Zhang},
  title = {{SEM: a System for Enumerating Models}},
  booktitle = {International Joint Conference on Artificial Intelligence},
  year = {1995},
}
Figure