arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2003.10623cs.LO
收藏

四种区间算术运算符的计算机辅助验证

Computer-Assisted Verification of Four Interval Arithmetic Operators

Daisuke Ishii, Tomohito Yabu

摘要:

区间算术库为以浮点数为界的操作数区间提供了四个基本算术运算符。实际的实现需要进行大的案例分析,例如,所有参数边界对之间的大小关系,参数和零之间的位置关系,以及特殊值,无穷大和NaN的处理。它们的正确性并不明显,因为它们是由人手实现的,这对可靠性至关重要。本工作提供了一个机械验证的区间算术库。为此,我们利用Why 3平台配备了一个规约语言的注释程序和后端定理证明。我们对目标代码的三个属性中的每一个进行了几个证明任务:有效性,可靠性和紧密性;零划分异常处理也验证了划分代码。为了完成证明,我们提出了几种技术规范/验证。首先,我们指定额外的引理,支持后端SMT求解器进行的推导,这使得在包含非线性项的浮点运算中能够履行证明义务。其次,我们研究了紧密性的注释,这需要假设计算可能导致NaN;为此,我们提出了特定的极值算子。在实验中,将这些技术与Alt-Ergo SMT求解器和Coq证明助手结合使用,证明了整个代码。

英文摘要:

Interval arithmetic libraries provide the four elementary arithmetic operators for operand intervals bounded by floating-point numbers. Actual implementations need to make a large case analysis that considers, e.g., magnitude relations between all pairs of argument bounds, positional relations between the arguments and zero, and handling of the special values, infinities and NaN. Their correctness is not obvious as they are implemented by human hands, which comes to be critical for the reliability. This work provides a mechanically-verified interval arithmetic library. For this purpose, we utilize the Why3 platform equipped with a specification language for annotated programs and back-end theorem provers. We conduct several proof tasks for each of three properties of the target code: validity, soundness, and tightness; zero division exception handling is also verified for the division code. To accomplish the proof, we propose several techniques for specification/verification. First, we specify additional lemmas that support deductions made by back-end SMT solvers, which enable to discharge proof obligations in floating-point arithmetic containing nonlinear terms. Second, we examine the annotation of tightness, which requires to assume that a computation may result in NaN; we propose specific extremum operators for this purpose. In the experiments, applying the techniques in conjunction with the Alt-Ergo SMT solver and the Coq proof assistant proved the entire code.

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

↑