arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 1310.8568cs.LO
收藏

依赖类型λ演算中的规范转换为谓词逻辑形式

Translating Specifications in a Dependently Typed Lambda Calculus into a Predicate Logic Form

Mary Southern, Gopalan Nadathur

摘要:

依赖类型的lambda演算(英语:Lambda calculi),如Edinburgh逻辑框架(英语:Edinburgh Logical Framework)(LF),是一种流行的方式,用于编码关于正式语法对象的基于规则的规范。在这些框架中,通过使用类型的依赖结构,自然地捕获了表示形式对象的术语上的关系。我们在这里考虑在简单类型的λ-项上将以这种风格编写的规范保持意义地翻译成谓词逻辑。这样的翻译可以为高效的实现和推理规范的复杂能力提供基础。我们开始与先前描述的翻译LF规范的公式在逻辑的高阶遗传Harrop(hohh)公式。我们展示了如何通过识别和消除其中包含的冗余类型检查信息来改进这种翻译。这既有利于翻译公式的清晰度,又减少了执行过程中必须花费在类型检查上的精力。为了允许这种翻译被用来执行LF规范,我们描述了一个逆变换从hohh项LF表达式,因此可以使用翻译的形式进行计算,然后可以将结果导出回LF。基于LF规范的执行还可能涉及某些形式的类型重构。我们讨论的可能性,支持这样的能力,使用翻译的结构规范的一些合理的限制。

英文摘要:

Dependently typed lambda calculi such as the Edinburgh Logical Framework (LF) are a popular means for encoding rule-based specifications concerning formal syntactic objects. In these frameworks, relations over terms representing formal objects are naturally captured by making use of the dependent structure of types. We consider here the meaning-preserving translation of specifications written in this style into a predicate logic over simply typed λ-terms. Such a translation can provide the basis for efficient implementation and sophisticated capabilities for reasoning about specifications. We start with a previously described translation of LF specifications to formulas in the logic of higher-order hereditary Harrop (hohh) formulas. We show how this translation can be improved by recognizing and eliminating redundant type checking information contained in it. This benefits both the clarity of translated formulas, and reduces the effort which must be spent on type checking during execution. To allow this translation to be used to execute LF specifications, we describe an inverse transformation from hohh terms to LF expressions; thus computations can be carried out using the translated form and the results can then be exported back into LF. Execution based on LF specifications may also involve some forms of type reconstruction. We discuss the possibility of supporting such a capability using the translation under some reasonable restrictions on the structure of specifications.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑