# Integrating Cardinality Constraints into Constraint Logic Programming with Sets

@article{Cristia2021IntegratingCC, title={Integrating Cardinality Constraints into Constraint Logic Programming with Sets}, author={Maximiliano Cristi'a and Gianfranco Rossi}, journal={ArXiv}, year={2021}, volume={abs/2102.05422} }

Formal reasoning about finite sets and cardinality is important for many applications, including software verification, where very often one needs to reason about the size of a given data structure. The Constraint Logic Programming tool
$$\{ log\} $$
provides a decision procedure for deciding the satisfiability of formulas involving very general forms of finite sets, although it does not provide cardinality constraints. In this paper we adapt and integrate a decision procedure for…

## 5 Citations

A Typechecker for a Set-Based Constraint Logic Programming Language

- Computer ScienceArXiv
- 2022

The type system is proved to be safe (sound) by adapting the functional programming formulation of type safety to the CLP context and the typechecker is applied to a real-world case study from the aeronautic domain.

A Decision Procedure for a Theory of Finite Sets with Finite Integer Intervals

- MathematicsArXiv
- 2021

By providing a decision procedure for L[ ] it is possible to automatically reason about a new class of quantifier-free formulas and a case study based on the elevator algorithm showing that {log} can automatically discharge all its invariance lemmas some of which involve intervals.

An Automatically Verified Prototype of a Landing Gear System

- Computer ScienceArXiv
- 2021

A Constraint Logic Programming (CLP) language based on set theory is used as an automated verifier for B specifications to provide empirical evidence on how CLP and set theory can be used in tandem as a vehicle for program verification.

Complexity assessments for decidable fragments of Set Theory. III: A quadratic reduction of constraints over nested sets to Boolean formulae

- MathematicsArXiv
- 2021

Besides reflecting a simple and natural semantics, which ensures satisfiability-preservation, the proposed translation has quadratic algorithmic time-complexity, and bridges two languages both of which are known to have an NP-complete satisfiability problem.

log: Set Formulas as Programs

- Computer ScienceArXiv
- 2021

This paper shows the development methodology of {log}, a programming language at the intersection of Constraint Logic Programming, set programming and declarative programming, which can write abstract programs using all the power of set theory and binary relations.

## References

SHOWING 1-10 OF 50 REFERENCES

Efficient Automated Reasoning About Sets and Multisets with Cardinality Constraints

- Computer Science, MathematicsIJCAR
- 2020

This presentation outlines an efficient decision procedure for reasoning about multisets with cardinality constraints and describes how to translate constraints to constraints in an extension of quantifier-free linear integer arithmetic, which is called LIA*.

Rewrite rules for a solver for sets, binary relations and partial functions

- 2019

A pearl on SAT and SMT solving in Prolog

- Computer ScienceTheor. Comput. Sci.
- 2012

Decision Procedures for Multisets with Cardinality Constraints

- Computer Science, MathematicsVMCAI
- 2008

A polynomial-space algorithm for deciding expressive quantifier-free constraints on multisets with cardinality operators and a proof that adding quantifiers to a constraint language containing subset and cardinality Operators yields undecidable constraints.

Combining Multisets with Integers

- MathematicsCADE
- 2002

This work presents a decision procedure for a constraint language combining multisets of ur-elements, the integers, and an arbitrary first-order theory T of the ur- elements using the Nelson-Oppen combination method.

Combining Sets with Integers

- MathematicsFroCoS
- 2002

We present a decision procedure for a constraint language combining stratified sets of ur-elements with integers in the presence of a cardinality operator. Our decision procedure is an extension of…

Logics for Sizes with Union or Intersection

- Computer Science, PhilosophyAAAI
- 2020

This paper presents the most basic logics for reasoning about the sizes of sets that admit either the union of terms or the intersection of terms, and presents a sound, complete, and polynomial-time decidable proof system for these logics.

Deciding Boolean Algebra with Presburger Arithmetic

- Computer ScienceJournal of Automated Reasoning
- 2006

An algorithm for deciding the first-order multisorted theory BAPA, which combines Boolean algebras of sets of uninterpreted elements (BA) and Presburger arithmetic operations (PA), is described and it is shown that it has optimal alternating time complexity and that it matches the complexity of PA.

OFAI clp(Q,R) Manual

- Computer Science
- 1995

This Manual documents a Prolog implementation of clp(Q,R), based on SICStus featuring extensible uniication via attributed variables, at least as complete as other existingclp(R) implementations.