[Paper Review] Recurrence with affine level mappings is P-time decidable for CLP(R)
This paper presents a polynomial-time decidable criterion for recurrence in CLP(ℝ) programs using affine level mappings. It proves that determining whether a binary CLP(ℝ) program can be shown terminating via such mappings is decidable in polynomial time, offering a sound and efficient termination analysis technique for a non-trivial subclass of constraint logic programs over the reals and rationals.
In this paper we introduce a class of constraint logic programs such that their termination can be proved by using affine level mappings. We show that membership to this class is decidable in polynomial time.
Motivation & Objective
- To identify a decidable subclass of CLP(ℝ) programs where termination can be proven using affine level mappings.
- To establish that membership in this subclass is decidable in polynomial time.
- To provide a practical decision procedure for recurrence that can be used as a termination proof technique.
- To extend the applicability of level mapping techniques beyond integer domains to real and rational constraint domains.
- To offer a scalable alternative to undecidable general termination analysis in constraint logic programming.
Proposed method
- The paper defines a class of binary CLP(ℝ) programs where recurrence can be proven using affine level mappings, which map program states to real numbers such that the level strictly decreases along any computation.
- It introduces a decision procedure based on linear programming to check whether a given program admits such an affine level mapping.
- The method involves encoding the conditions for a valid affine level mapping as a system of linear inequalities over the program's constraints and rules.
- The feasibility of this system is checked using the Simplex algorithm, ensuring polynomial-time complexity.
- The approach is extended to CLP(ℕ) by leveraging the fact that recurrence over ℚ implies recurrence over ℕ, preserving soundness.
- A prototype implementation in SICStus Prolog uses the Simplex algorithm and Fourier-based projection to validate the method manually.
Experimental results
Research questions
- RQ1Can the existence of an affine level mapping for a binary CLP(ℝ) program be decided in polynomial time?
- RQ2Is there a decidable subclass of CLP(ℝ) programs for which termination can be proven via affine level mappings?
- RQ3Can this decision procedure be used as a sound and efficient termination proof technique for programs over ℚ and ℕ?
- RQ4How does this approach compare in expressiveness and complexity to prior methods that restrict loops to non-nested, non-branching forms?
- RQ5What is the complexity of determining recurrence for programs with polynomial constraints over real-closed fields?
Key findings
- Membership in the class of CLP(ℝ) programs amenable to termination proof via affine level mappings is decidable in polynomial time.
- The decision procedure is based on linear programming and can be implemented efficiently using standard solvers like the Simplex algorithm.
- The method is sound for CLP(ℕ) programs, as recurrence over ℚ implies recurrence over ℕ.
- The approach is more expressive than prior work such as Sohn and Van Gelder (1991), which fails on certain programs with negative coefficients.
- The method successfully handles programs with nested loops and internal branching—features that render termination undecidable in general but decidable within this subclass.
- A prototype implementation in SICStus Prolog confirms the feasibility of the approach, though its complexity is not polynomial due to the use of Fourier-based projection.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.