The termination behavior of probabilistic programs depends on the outcomes of random assignments. Almost sure termination (AST) is concerned with the question whether a program terminates with probability one on all possible inputs. Positive almost sure termination (PAST) focuses on termination in a finite expected number of steps. This paper presents a fully automated approach to the termination analysis of probabilistic while-programs whose guards and expressions are polynomial expressions. As proving (positive) AST is undecidable in general, existing proof rules typically provide sufficient conditions. These conditions mostly involve constraints on supermartingales. We consider four proof rules from the literature and extend these with generalizations of existing proof rules for (P)AST. We automate the resulting set of proof rules by effectively computing asymptotic bounds on polynomials over the program variables. These bounds are used to decide the sufficient conditions - including the constraints on supermartingales - of a proof rule. Our software tool Amber can thus check AST, PAST, as well as their negations for a large class of polynomial probabilistic programs, while carrying out the termination reasoning fully with polynomial witnesses. Experimental results show the merits of our generalized proof rules and demonstrate that Amber can handle probabilistic programs that are out of reach for other state-of-the-art tools.
翻译:概率性程序的终止行为取决于随机任务的结果。 几乎可以肯定终止( AST) 关系到一个程序是否以概率终止的问题, 在所有可能的输入中, 概率性( AST) 是否终止。 几乎几乎肯定终止( PAST) 侧重于在一定的预期步骤中终止终止。 本文展示了一种完全自动化的方法, 用于分析保镖和表达表达方式为多元表达式的概率性和程序。 证明( 阳性) AST 通常无法验证, 现有证据规则通常提供足够条件。 这些条件大多涉及对超婚的限制。 我们考虑文献中的四项证据规则, 并将这些规则扩展为( P) AST 现有证据规则的概括化。 我们通过有效计算对程序变量的多元性约束和表达方式的终止性约束, 将由此产生的一套证据规则自动化。 这些界限被用来决定证据规则的足够条件, 包括超婚姻限制。 我们的软件工具可以检查 AST, PAST, 以及它们用来反驳一大批多类的多元性概率性概率性规则。 我们的实验性实验性规则可以展示其他的结束性规则, 并且展示其他的实验性实验性实验性实验性实验性实验性结果, 能够展示其他的实验性实验性实验性结果, 。