skip to main content
article

Polytool: Polynomial interpretations as a basis for termination analysis of logic programs

Published: 01 January 2011 Publication History

Abstract

Our goal is to study the feasibility of porting termination analysis techniques developed for one programming paradigm to another paradigm. In this paper, we show how to adapt termination analysis techniques based on polynomial interpretations—very well known in the context of term rewrite systems—to obtain new (nontransformational) termination analysis techniques for definite logic programs (LPs). This leads to an approach that can be seen as a direct generalization of the traditional techniques in termination analysis of LPs, where linear norms and level mappings are used. Our extension generalizes these to arbitrary polynomials. We extend a number of standard concepts and results on termination analysis to the context of polynomial interpretations. We also propose a constraint-based approach for automatically generating polynomial interpretations that satisfy the termination conditions. Based on this approach, we implemented a new tool, called <monospace>Polytool</monospace>, for automatic termination analysis of LPs.

References

[1]
APT, K. R. 1990. Logic programming. In Handbook of Theoretical Computer Science, Vol. B, Ed. Jan van Leeuwen, MIT Press, 493-574.
[2]
ARTS, T. AND GIESL, J. 2000. Termination of term rewriting using dependency pairs. Theoretical Computer Science 236, 1-2, 133-178.
[3]
BORRALLERAS, C., LUCAS, S., NAVARRO-MARSET, R., RODRÍGUEZ-CARBONELL, E. AND RUBIO, A. 2009. Solving non-linear polynomial arithmetic via SAT modulo linear arithmetic. In Proc. CADE '09. Ed. Renate Schmidt, LNAI, Springer-Verlag, vol. 5663, 294-305.
[4]
BOSSI, A., COCCO, N. AND FABRIS, M. 1991 Proving termination of logic programs by exploiting term properties. In Proc. TAPSOFT '91. Eds. S. Abramsky and T. Maibaum, LNCS, Springer-Verlag, vol. 494, 153-180.
[5]
BRAUBURGER, J. AND GIESL, J. 1998 Termination analysis by inductive evaluation. In Proc. CADE '98. Eds. C. Kirchner and H. Kirchner, LNAI, Springer-Verlag, vol. 1421, 254-269.
[6]
BRUYNOOGHE, M., CODISH, M., GALLAGHER, J. P., GENAIM, S. AND VANHOOF, W. 2007. Termination analysis of logic programs through combination of type-based norms. ACM Transactions on Programming Languages and Systems 29, 2, 10-es.
[7]
BRUYNOOGHE, M., GALLAGHER, J. P. AND VAN HUMBEECK, W. 2005. Inference of well-typings for logic programs with application to termination analysis. In Proc. SAS '05. Eds. C. Hankin and I. Siveroni, LNCS, Springer-Verlag, vol. 3672, 35-51.
[8]
CODISH, M. AND TABOCH, C. 1999. A semantic basis for the termination analysis of logic programs. Journal of Logic Programming 41, 1, 103-123.
[9]
CONTEJEAN, E., MARCHÉ, C., TOMÁS, A. P. AND URBAIN, X. 2005. Mechanically proving termination using polynomial interpretations. Journal of Automated Reasoning 34, 4, 325- 363.
[10]
DECORTE, S., DE SCHREYE, D. AND FABRIS, M. 1993. Automatic inference of norms: A missing link in automatic termination analysis. In Proc. ILPS '93. Ed. D. Miller, MIT Press, 420-436.
[11]
DECORTE, S., DE SCHREYE, D. AND VANDECASTEELE, H. 1999. Constraint-based automatic termination analysis of logic programs. ACM Transactions on Programming Languages and Systems 21, 6, 1137-1195.
[12]
DERSHOWITZ, N. 1995. 33 examples of termination. In Proc. French Spring School in Theoretical Computer Science. Eds. H. Comon and J. Jouannaud, LNCS, Springer-Verlag, vol. 909, 16- 26.
[13]
DERSHOWITZ, N., LINDENSTRAUSS, N. AND SAGIV, Y. 1997. What norms are useful for logic programs? In Proc. WST '97. Transparencies available from URL: http://www.cs.huji. ac.il/~naomil/.
[14]
DE SCHREYE, D. AND SEREBRENIK, A. 2002. Acceptability with general orderings. In Computational Logic: Logic Programming and Beyond. Eds. A. Kakas and F. Sadri, LNCS, Springer-Verlag, vol. 2407, 187-210.
[15]
FUHS, C., GIESL, J., MIDDELDORP, A., SCHNEIDER-KAMP, P., THIEMANN, R. AND ZANKL, H. 2007. SAT solving for termination analysis with polynomial interpretations. In Proc. SAT '07. Eds. J. Marques-Silva, K. Sakallah, LNCS, Springer-Verlag, vol. 4501, 340-354.
[16]
FUHS, C., GIESL, J., MIDDELDORP, A., SCHNEIDER-KAMP, P., THIEMANN, R. AND ZANKL, H. 2008. Maximal termination. In Proc. RTA '08, 110-125.
[17]
GALLAGHER, J. P., HENRIKSEN, K. S. AND BANDA, G. 2005. Techniques for scaling up analyses based on pre-interpretations. In Proc. ICLP '05. Eds. M. Gabbrielli and G. Gupta, LNCS, Springer-Verlag, vol. 3668, 280-296.
[18]
GIESL, J., SCHNEIDER-KAMP, P. AND THIEMANN, R. 2006a. AProVE 1.2: Automatic termination proofs in the dependency pair framework. In Proc. IJCAR '06. Eds. U. Furbach and N. Shankar, LNAI, Springer-Verlag, vol. 4130, 281-286.
[19]
GIESL, J., THIEMANN, R., SCHNEIDER-KAMP, P. AND FALKE, S. 2006b. Mechanizing and improving dependency pairs. Journal of Automated Reasoning 37, 3, 155-203.
[20]
GIESL, J., THIEMANN, R., SWIDERSKI, S. AND SCHNEIDER-KAMP, P. 2007. Proving termination by bounded increase. In Proc. CADE '07. Ed. F. Pfenning, LNAI, Springer-Verlag, vol. 4603, 443-459.
[21]
HEATON, A., ABO-ZAED, M., CODISH, M. AND KING, A. 2000. A simple polynomial groundness analysis for logic programs. Journal of Logic Programming 45, 1-3, 143-156.
[22]
HIROKAWA, N. AND MIDDELDORP, A. 2005. Automating the dependency pair method. Information and Computation 199, 1-2, 172-199.
[23]
HONG, H. AND JAKU¿, D. 1998. Testing positiveness of polynomials. Journal of Automated Reasoning 21, 1, 23-38.
[24]
JANSSENS, G. AND BRUYNOOGHE, M. 1992. Deriving descriptions of possible values of program variables by means of abstract interpretation. Journal of Logic Programming 13, 2-3, 205- 258.
[25]
LANKFORD, D. S. 1979. On Proving Term Rewriting Systems are Noetherian. Tech. Rep., Mathematics Department, Louisiana Tech University, Ruston, LA.
[26]
LINDENSTRAUSS, N. 2000. TermiLog: Termination analyzer for logic programs. URL: http://www.cs.huji.ac.il/~naomil/termilog.php.
[27]
LINDENSTRAUSS, N. AND SAGIV, Y. 1997. Automatic termination analysis of logic programs. In Proc. ICLP '97. Ed. L. Naish, MIT Press, 63-77.
[28]
LINDENSTRAUSS, N., SAGIV, Y. AND SEREBRENIK, A. 2004. Proving termination for logic programs by the query-mapping pairs approach. In Program Development in Computational Logic. Eds. M. Bruynooghe and K. Lau, LNCS, Springer-Verlag, vol. 3049, 453-498.
[29]
LLOYD, J. W. 1987. Foundations of Logic Programming. Springer Verlag, Berlin.
[30]
MESNARD, F. AND BAGNARA, R. 2005. cTI: A constraint-based termination inference tool for ISO-Prolog. Theory and Practice of Logic Programming 5, 1-2, 243-257.
[31]
NGUYEN, M. T. 2009 Termination Analysis: Crossing Paradigm Borders. Ph.D. thesis, Department of Computer Science, K. U. Leuven, Belgium.
[32]
NGUYEN, M. T. AND DE SCHREYE, D. 2005. Polynomial interpretations as a basis for termination analysis of logic programs. In Proc. ICLP '05. Eds. M. Gabbrielli and G. Gupta, LNCS, Springer-Verlag, vol. 3668, 311-325. Extended version appeared as Technical report, Department of Computer Science, K. U. Leuven, Belgium, URL: http://www.cs.kuleuven.be/publicaties/rapporten/cw/CW412.pdf.
[33]
NGUYEN, M. T. AND DE SCHREYE, D. 2007. Polytool: Proving termination automatically based on polynomial interpretations. In Proc. LOPSTR '06. Ed. G. Puebla, LNCS, Springer-Verlag, vol. 4407, 210-218. Extended version appeared as Technical report, Department of Computer Science, K. U. Leuven, Belgium, URL: http://www.cs.kuleuven.be/~manh/ polytool/publications/tech-reports/reportCW442.pdf.
[34]
NGUYEN, M. T., GIESL, J., SCHNEIDER-KAMP, P. AND DE SCHREYE, D. 2008. Termination analysis of logic programs based on dependency graphs. In Proc. LOPSTR '07. Ed. A. King, LNCS, Springer-Verlag, vol. 4915, 8-22.
[35]
OHLEBUSCH, E., CLAVES, C. AND MARCHÉ, C. 2000. TALP: A tool for the termination analysis of logic programs. In Proc. RTA '00. Ed. L. Bachmair, LNCS, Springer-Verlag, vol. 1833, 270-273.
[36]
SCHNEIDER-KAMP, P., GIESL, J. AND NGUYEN, M. T. The dependency triple framework for termination of logic programs. In Proc. LOPSTR '09. LNCS. Forthcoming.
[37]
SCHNEIDER-KAMP, P., GIESL, J., SEREBRENIK, A. AND THIEMANN, R. 2009. Automated termination proofs for logic programs by term rewriting. ACM Transactions on Computational Logic 11, 1. Preliminary version appeared in Proc. LOPSTR '06, Ed. G. Puebla, LNCS, Springer-Verlag, vol. 4407, pp. 117-193, 2007.
[38]
SEREBRENIK, A. 2003. Termination Analysis of Logic Programs. Ph.D. thesis, Department of Computer Science, K. U. Leuven, Belgium. URL: http://www.cs.kuleuven.ac.be/ publicaties/doctoraten/cw/CW2003_02.abs.html.
[39]
SEREBRENIK, A. AND DE SCHREYE, D. 2003. Hasta-La-Vista: Termination analyser for logic programs. In Proc. WLPE '03. Eds. F. Mesnard and A. Serebrenik, 60-74.
[40]
STEINBACH, J. 1992. Proving polynomials positive. In Proc. FSTTCS '92. Ed. R. Shyamasundar, LNCS, Springer-Verlag, vol. 652, 18-20.
[41]
TABOCH, C., GENAIM, S. AND CODISH, M. 2002. TerminWeb: Semantics-based termination analyser for logic programs. URL: http://www.cs.bgu.ac.il/~mcodish/TerminWeb.
[42]
VERSCHAETSE, K. AND DE SCHREYE, D. 1991. Deriving termination proofs for logic programs, using abstract procedures. In Proc. ICLP '91. Ed. K. Furukawa, MIT Press, 301-315.

Cited By

View all

Recommendations

Comments

Information & Contributors

Information

Published In

cover image Theory and Practice of Logic Programming
Theory and Practice of Logic Programming  Volume 11, Issue 1
January 2011
138 pages

Publisher

Cambridge University Press

United States

Publication History

Published: 01 January 2011

Author Tags

  1. acceptability
  2. polynomial interpretations
  3. termination analysis

Qualifiers

  • Article

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)0
  • Downloads (Last 6 weeks)0
Reflects downloads up to 01 Jan 2025

Other Metrics

Citations

Cited By

View all

View Options

View options

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media