【24h】

Continuity Analysis of Programs

机译:计划的连续性分析

获取原文

摘要

We present an analysis to automatically determine if a program represents a continuous function, or equivalently, if infinitesimal changes to its inputs can only cause infinitesimal changes to its outputs. The analysis can be used to verify the robustness of programs whose inputs can have small amounts of error and uncertainty-e.g., embedded controllers processing slightly unreliable sensor data, or handheld devices using slightly stale satellite data. Continuity is a fundamental notion in mathematics. However, it is difficult to apply continuity proofs from real analysis to functions that are coded as imperative programs, especially when they use diverse data types and features such as assignments, branches, and loops. We associate data types with metric spaces as opposed to just sets of values, and continuity of typed programs is phrased in terms of these spaces. Our analysis reduces questions about continuity to verification conditions that do not refer to infinitesimal changes and can be discharged using off-the-shelf SMT solvers. Challenges arise in proving continuity of programs with branches and loops, as a small perturbation in the value of a variable often leads to divergent control-flow that can lead to large changes in values of variables. Our proof rules identify appropriate "synchronization points" between executions and their perturbed counterparts, and establish that values of certain variables converge back to the original results in spite of temporary divergence. We prove our analysis sound with respect to the traditional e-5 definition of continuity. We demonstrate the precision of our analysis by applying it to a range of classic algorithms, including algorithms for array sorting, shortest paths in graphs, minimum spanning trees, and combinatorial optimization. A prototype implementation based on the Z3 SMT-solver is also presented.
机译:我们提出了一个分析,以自动确定程序是否表示连续函数,或等效,如果对其输入的无穷大的变化只能导致其输出的无限变化。分析可用于验证输入的程序的稳健性,其输入可以具有少量误差和不确定性-e.g。,嵌入式控制器处理稍可靠的传感器数据,或使用略微陈旧的卫星数据的手持设备。连续性是数学的基本概念。但是,很难将Real Instual的连续性证据应用于编码为势在必行计划的函数,特别是当它们使用不同的数据类型和分配,分支和循环等功能时。我们将数据类型与度量空间相关联,而不是仅仅是值集,而键入的程序的连续性在这些空间中是针对这些空间的。我们的分析减少了关于不参考无限变化的验证条件的连续性的问题,可以使用现成的SMT求解器来排出。在证明具有分支和循环的程序的连续性时出现挑战,因为变量的值中的小扰动通常导致不同的控制流动,这可能导致变量值的大变化。我们的证明规则确定执行之间的适当的“同步点”及其扰动的对应物,并且尽管有临时发散,确定某些变量的值会收敛回原始结果。我们对传统的E-5连续性定义证明了我们的分析声音。我们通过将其应用于一系列经典算法来展示我们分析的精度,包括用于阵列排序的算法,图表中的最短路径,最小的跨越树以及组合优化。还提出了基于Z3 SMT-求解器的原型实现。

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号