Quantitative reasoning provides a flexible approach capable to deal with the uncertainty and imprecision that affects modern software systems due to their complexity. Its distinguishing feature is the use of distances, instead of equivalence relations, so that one can measure how much two objects are similar, rather than just saying whether they are equivalent or not. In this paper we aim at providing a solid logical ground to quantitative reasoning, using the categorical language of Lawvere's hyperdoctrines. The key idea is to see distances as equality predicates in Linear Logic. Adding equality to Linear Logic, however, is not as trivial as it might appear. The linear version of the usual rules for equality, asserting that it is reflexive and substitutive, has the consequence that equality collapses to an equivalence relation, as it can be used an arbitrary number of times. To overcome this issue, we consider the extension of Linear Logic with graded modalities and use them to write a resource sensitive substitution rule that keeps equality quantitative. We introduce a deductive calculus for (Graded) Linear Logic with quantitative equality and the notion of Lipschitz doctrine to give semantics to it. Main examples are based on metric spaces and Lipschitz maps and on quantitative realisability.
翻译:定量推理提供了一种灵活的方法,能够处理由于复杂而影响现代软件系统的不确定性和不精确性,其显著特征是使用距离而不是等同关系,这样人们就可以衡量两个对象的相似程度,而不是仅仅说它们是否等同。在本文件中,我们的目标是利用劳维尔的超理论的绝对语言,为定量推理提供坚实的逻辑依据。关键思想是将距离视为线性逻辑中的平等前提。但是,在线性逻辑中增加平等并不象看起来那样微不足道。通常的平等规则的线性版本,声称它具有反射性和代位性,其结果是平等崩溃到一种等同关系,因为它可以任意地使用一些时间。为了克服这一问题,我们考虑将线性逻辑扩展到分级模式,并用它们来写一个资源敏感的替代规则,以保持平等定量。我们为(Graded)线性逻辑添加了一种推算性分级的分级数值,而利普西茨理论的理论概念是以定量和真实性模型为基础,使利普西茨理论的模型和定量性模型成为了它的基础。