Formal reasoning about finite sets and cardinality is an important tool for many applications, including software verification, where very often one needs to reason about the size of a given data structure and not only about what its elements are. The Constraint Logic Programming tool {log} provides a decision procedure for deciding the satisfiability of formulas involving very general forms of finite sets, without cardinality. In this paper we adapt and integrate a decision procedure for a theory of finite sets with cardinality into {log}. The proposed solver is proved to be a decision procedure for its formulas. Besides, the new CLP instance is implemented as part of the {log} tool. In turn, the implementation uses Howe and King's Prolog SAT solver and Prolog's CLP(Q) library, as an integer linear programming solver. The empirical evaluation of this implementation based on +250 real verification conditions shows that it can be useful in practice.
翻译:有关有限数据集和基本功能的正式推理是许多应用程序的一个重要工具,包括软件核查,其中人们往往需要说明特定数据结构的大小,而不仅仅是其要素是什么。 限制逻辑编程工具 {log} 提供了一个决定程序,用于确定包含非常一般形式的有限数据集的公式的可视性,而没有基本特征。 在本文件中,我们调整并整合了一种决定程序,以将具有基本特性的有限数据集理论纳入 {log} 。 拟议的解析器被证明是其公式的决定程序。 此外,新的CLP实例作为 {log} 工具的一部分实施。 而执行程序则使用 Howe 和 King 的 Prolog SAT 解析器和 Prolog CLP(Q) 图书馆作为整形线性编程解算器。基于 +250 实际核查条件对执行情况进行的经验评估表明,这种做法在实践中是有用的。