Symbolic termination analysis of solvable loops

Termination is an essential part of program correctness. For a class of regular programs, both automatically proving termination and constructing witnesses of nontermination are significant in theoretical computer science. Many traditional theorem-proving methods for analyzing termination are based on Presburger arithmetic or linear programming, so they are valid only for restricted linear problems. On the contrary, some newly-emerged algebraic methods are suitable for polynomial problems, and are promising in deciding termination of polynomial programs. In this paper, we investigate a large class of imperative programs, called solvable loops, whose guards are general polynomials and assignments are special polynomial mappings. We then propose some sufficient criteria for proving termination and nontermination of such loops in parallel. These criteria can further be translated to the quantifier elimination problem over the reals, and hence are computable. Finally, feasible sample points in the process for inferring nontermination are eventually nonterminating inputs, which can be used to generate witnesses of nontermination. Our decision procedure uses symbolic computation and is mechanically implementable in spite of considerably high complexity. Thereby a series of strong and exact results are established in analyzing termination of loops.

[1]  Bican Xia,et al.  Symbolic decision procedure for termination of linear programs , 2009, Formal Aspects of Computing.

[2]  Mark Braverman,et al.  Termination of Integer Linear Programs , 2006, CAV.

[3]  Zhenbing Zeng,et al.  Real Root Isolation of Multi-Exponential Polynomials with Application , 2010, WALCOM.

[4]  Christopher W. Brown QEPCAD B: a program for computing with semi-algebraic sets using CADs , 2003, SIGS.

[5]  Andreas Podelski,et al.  Terminator: Beyond Safety , 2006, CAV.

[6]  Volker Weispfenning,et al.  Deciding polynomial-exponential problems , 2008, ISSAC '08.

[7]  Moshe Y. Vardi Verification of Concurrent Programs: The Automata-Theoretic Framework , 1991, Ann. Pure Appl. Log..

[8]  Patrick Cousot,et al.  Proving Program Invariance and Termination by Parametric Abstraction, Lagrangian Relaxation and Semidefinite Programming , 2005, VMCAI.

[9]  A. Tarski A Decision Method for Elementary Algebra and Geometry , 2023 .

[10]  Zhenbing Zeng,et al.  Termination Analysis of Linear Loops , 2010, Int. J. Found. Comput. Sci..

[11]  Deepak Kapur,et al.  A Quantifier-Elimination Based Heuristic for Automatically Generating Inductive Assertions for Programs , 2006, J. Syst. Sci. Complex..

[12]  Laura Kovács,et al.  Reasoning Algebraically About P-Solvable Loops , 2008, TACAS.

[13]  Martin Davis,et al.  The Undecidable: Basic Papers on Undecidable Propositions, Unsolvable Problems and Computable Functions , 2004 .

[14]  Enric Rodríguez-Carbonell,et al.  Generating all polynomial invariants in simple loops , 2007, J. Symb. Comput..

[15]  C. A. R. Hoare,et al.  An axiomatic basis for computer programming , 1969, CACM.

[16]  George E. Collins,et al.  Partial Cylindrical Algebraic Decomposition for Quantifier Elimination , 1991, J. Symb. Comput..

[17]  Patrick Cousot,et al.  Abstract interpretation: a unified lattice model for static analysis of programs by construction or approximation of fixpoints , 1977, POPL.

[18]  Chaochen Zhou,et al.  Discovering Non-linear Ranking Functions by Solving Semi-algebraic Systems , 2007, ICTAC.

[19]  Enric Rodríguez-Carbonell,et al.  Automatic Generation of Polynomial Loop Invariants: Algebraic Foundations , 2004, ISSAC '04.

[20]  Henny B. Sipma,et al.  Synthesis of Linear Ranking Functions , 2001, TACAS.

[21]  Deepak Kapur,et al.  Program Analysis Using Quantifier-Elimination Heuristics - (Extended Abstract) , 2012, TAMC.

[22]  Edsger W. Dijkstra,et al.  Structured programming , 1972, A.P.I.C. Studies in data processing.

[23]  Daniel Richardson,et al.  Towards computing non algebraic cylindrical decompositions , 1991, ISSAC '91.

[24]  Henny B. Sipma,et al.  The Polyranking Principle , 2005, ICALP.

[25]  E. Wright,et al.  An Introduction to the Theory of Numbers , 1939 .

[26]  George E. Collins,et al.  Quantifier elimination for real closed fields by cylindrical algebraic decomposition , 1975 .

[27]  Albert Baker,et al.  Linear forms in the logarithms of algebraic numbers I - IV Mathematika 13 , 1967 .

[28]  Michel Waldschmidt,et al.  A lower bound for linear forms in logarithms , 1980 .

[29]  A. Rybalchenko,et al.  Transition invariants , 2004, LICS 2004.

[30]  Ashish Tiwari,et al.  Termination of Linear Programs , 2004, CAV.

[31]  Kwangkeun Yi,et al.  Termination Analysis with Algorithmic Learning , 2012, CAV.

[32]  R. Guy Unsolved Problems in Number Theory , 1981 .

[33]  George E. Collins,et al.  Hauptvortrag: Quantifier elimination for real closed fields by cylindrical algebraic decomposition , 1975, Automata Theory and Formal Languages.

[34]  Bican Xia,et al.  Termination of linear programs with nonlinear constraints , 2010, J. Symb. Comput..