mlsanityData to 14 Oct 2026

A Machine Learning-based Approach for Solving Recurrence Relations and its use in Cost Analysis of Logic Programs

arXiv 2405.06972 ↗First posted 11 May 2024cs.PL cs.AIcited by 0

Not on the map. Why?

Abstract (arXiv)

Automatic static cost analysis infers information about the resources used by programs without actually running them with concrete data, and presents such information as functions of input data sizes. Most of the analysis tools for logic programs (and many for other languages), as CiaoPP, are based on setting up recurrence relations representing (bounds on) the computational cost of predicates, and solving them to find closed-form functions. Such recurrence solving is a bottleneck in current tools: many of the recurrences that arise during the analysis cannot be solved with state-of-the-art solvers, including Computer Algebra Systems (CASs), so that specific methods for different classes of recurrences need to be developed. We address such a challenge by developing a novel, general approach for solving arbitrary, constrained recurrence relations, that uses machine-learning (sparse-linear and symbolic) regression techniques to guess a candidate closed-form function, and a combination of an SMT-solver and a CAS to check if it is actually a solution of the recurrence. Our prototype implementation and its experimental evaluation within the context of the CiaoPP system show quite promising results. Overall, for the considered benchmarks, our approach outperforms state-of-the-art cost analyzers and recurrence solvers, and solves recurrences that cannot be solved by them. Under consideration in Theory and Practice of Logic Programming (TPLP).

Key facts. No citing papers in the map yet (data through 14 Oct 2026). Builds on 13 of its 91 references that are in the map. First posted on arXiv 11 May 2024.

Builds on

13 of 91 references.

References · 13

  1. 2018Interval-based Resource Usage Verification by Translation into Horn Clauses and an Application to Energy Consumptioncited by 3
  2. 2014Resource Usage Analysis of Logic Programs via Abstract Interpretation Using Sized Typescited by 2
  3. 2018Invariant Generation for Multi-Path Loops with Polynomial Assignmentscited by 2
  4. 2019Using Dynamic Analysis to Generate Disjunctive Invariantscited by 1
  5. 2020Exponential Automatic Amortized Resource Analysiscited by 1
  6. 2020Templates and Recurrences: Better Togethercited by 1
  7. 2022Improving Automatic Complexity Analysis of Integer Programscited by 1
  8. 2022Proving Non-Termination and Lower Runtime Bounds with LoAT (System Description)cited by 1
  9. 2022Solving Invariant Generation for Unsolvable Loopscited by 1
  10. 2022When Less Is More: Consequence-Finding in a Weak Theory of Arithmeticcited by 1
  11. 2023(Un)Solvable Loop Analysiscited by 1
  12. 2023Targeting Completeness: Using Closed Forms for Size Bounds of Integer Programscited by 1
1 more
  1. 2023Solving Recurrence Relations using Machine Learning, with Application to Cost Analysiscited by 1

Built on by

Not cited yet.