Abstract
Narrowing extends rewriting with logic capabilities by allowing logic variables in terms and by replacing matching with unification. Narrowing has been widely used in different contexts, ranging from theorem proving (e.g., protocol verification) to language design (e.g., it forms the basis of functional logic languages). Surprisingly, the termination of narrowing has been mostly overlooked. In this work, we present a novel approach for analyzing the termination of narrowing in left-linear constructor systems—a widely accepted class of systems—that allows us to reuse existing methods in the literature on termination of rewriting.
Similar content being viewed by others
Explore related subjects
Discover the latest articles, news and stories from top researchers in related subjects.References
Albert E., Vidal G.: The narrowing-driven approach to functional logic program specialization. New Generation Comput. 20(1), 3–26 (2002)
Alpuente, M., Escobar, S., Iborra, J.: Termination of narrowing using dependency pairs. In: de la Banda M.G., Pontelli E. (eds.) Proceedings of the 24th International Conference on Logic Programming (ICLP 2008), LNCS 5366, pp. 317–331. Springer, Berlin (2008)
Alpuente, M., Falaschi, M., Ramis, M.J., Vidal, G.: Narrowing approximations as an optimization for equational logic programs. In: Proceedings of the 5th International Symposium on Programming Language Implementation and Logic Programming (PLILP’93), LNCS 714, pp. 391–409. Springer, Berlin (1993)
Alpuente M., Hanus M., Lucas S., Vidal G.: Specialization of functional logic programs based on needed narrowing. Theory Pract. Logic Program. 5(3), 273–303 (2005)
Antoy, S.: Definitional trees. In: Proceedings of the 3rd International Conference on Algebraic and Logic Programming (ALP’92), LNCS 632, pp. 143–157. Springer, Berlin (1992)
Antoy, S.: Optimal non-deterministic functional logic computations. In: Proceedings of the International Conference on Algebraic and Logic Programming (ALP’97), LNCS 1298, pp. 16–30. Springer, Berlin (1997)
Antoy, S., Ariola, Z.: Narrowing the narrowing space. In: Proceedings of the 9th International Symposium on Programming Languages: Implementations, Logics, and Programs (PLILP’97), LNCS 1292, pp. 1–15. Springer, Berlin (1997)
Antoy S., Echahed R., Hanus M.: A needed narrowing strategy. J. ACM 47(4), 776–822 (2000)
Antoy, S., Hanus, M.: Overlapping rules and logic variables in functional logic programs. In: Proceedings of the 22nd International Conference on Logic Programming (ICLP’06), LNCS 4079, pp. 87–101. Springer, Berlin (2006)
Arroyo, G., Ramos, J.G., Silva, J., Vidal, G.: Improving offline narrowing-driven partial evaluation using size-change graphs. In: Logic-Based Program Synthesis and Transformation, Revised and Selected Papers from LOPSTR’06, LNCS 4407, pp. 60–76. Springer, Berlin (2007)
Arts T., Giesl J.: Termination of term rewriting using dependency pairs. Theor. Comput. Sci. 236(1-2), 133–178 (2000)
Arts, T., Zantema, H.: Termination of logic programs using semantic unification. In: Proceedings of the 5th International Workshop on Logic Programming Synthesis and Transformation (LOPSTR’95), LNCS 1048, pp. 219–233. Springer, Berlin (1996)
Baader F., Nipkow T.: Term Rewriting and All That. Cambridge University Press, Cambridge, MA (1998)
Baader, F., Snyder, W.: Unification theory. In: Handbook of Automated Reasoning, pp. 445–532. Elsevier and MIT Press (2001)
Bert, D., Echahed, R.: Design and implementation of a generic, logic and functional programming language. In: Proceedings of the 1st European Symposium on Programming (ESOP’86), LNCS 213, pp. 119–132. Springer, Berlin (1986)
Chabin, J., Réty, P.: Narrowing directed by a graph of terms. In: Proceedings of the 4th International Conference on Rewriting Techniques and Applications (RTA’91), LNCS 488, pp. 112–123. Springer, Berlin (1991)
Christian, J.: Some termination criteria for narrowing and e-narrowing. In: Proceedings of the 11th International Conference on Automated Deduction (CADE-11), LNCS 607, pp. 582–588. Springer, Berlin (1992)
Codish M., Taboch C.: A semantic basis for the termination analysis of logic programs. J. Logic Program. 41(1), 103–123 (1999)
Comon-Lundh, H., Delaune, S.: The finite variant property: how to get rid of some algebraic properties. In: Proceedings of the 16th International Conference on Term Rewriting and Applications (RTA’05), LNCS 3467, pp. 294–307. Springer, Berlin (2005)
Darlington, J., Guo, Y.: Narrowing and unification in functional programming: an evaluation mechanism for absolute set abstraction. In: Proceedings of the 3rd International Conference on Rewriting Techniques and Applications (RTA’89), LNCS 355, pp. 92–108. Springer, Berlin (1989)
de Dios-Castro, J., López-Fraguas, F.: Extra variables can be eliminated from functional logic programs. In: Proceedings of the 6th Spanish Conference on Programming and Languages (PROLE’06), ENTCS 188, pp. 3–19. (2007)
De Schreye D., Decorte S.: Termination of logic programs: the never-ending story. J. Logic Program. 19(20), 199–260 (1994)
Debray S., Warren D.S.: Automatic mode inference for logic programs. J. Logic Program. 5, 207–230 (1988)
Dershowitz N.: Termination of rewriting. J. Symb. Comput. 3(1&2), 69–115 (1987)
Dershowitz, N.: Goal solving as operational semantics. In: Proceedings of ILPS’95, pp. 3–17. The MIT Press, Cambridge, MA (1995)
Dershowitz, N., Sivakumar, G.: Goal-directed equation solving. In: Proceedings of 7th National Conference on Artificial Intelligence, pp. 166–170. Morgan Kaufmann (1988)
Hanus, M. (ed.): Curry: an Integrated Functional Logic Language. Available at: http://www.informatik.uni-kiel.de/~mh/curry/
Endrullis J., Waldmann J., Zantema H.: Matrix interpretations for proving termination of term rewriting. J. Autom. Reason. 40(2-3), 195–220 (2008)
Escobar S., Meadows C., Meseguer J.: A rewriting-based inference system for the NRL protocol analyzer and its meta-logical properties. Theor. Comput. Sci. 367(1-2), 162–202 (2006)
Escobar, S., Meseguer, J.: Symbolic model checking of infinite-state systems using narrowing. In: Proceedings of 18th International Conference on Rewriting Techniques and Applications (RTA’07), LNCS 4533, pp. 153–168. Springer, Berlin (2007)
Fribourg, L.: SLOG: a logic programming language interpreter based on clausal superposition and rewriting. In: Proceedings of the Symposium on Logic Programming (SLP’85), pp. 172–185. IEEE Press (1985)
Giesl, J., Schneider-Kamp, P., Thiemann, R.: AProVE 1.2: automatic termination proofs in the dependency pair framework. In: Proceedings of the International Joint Conference on Automated Reasoning (IJCAR’06), LNCS 4130, pp. 281–286. Springer, Berlin (2006)
Giesl J., Swiderski S., Schneider-Kamp P., Thiemann R.: Automated termination analysis for haskell: from term rewriting to programming languages. In: Pfenning, F. (eds) Proceedings of the 17th International Conference on Term Rewriting and Applications (RTA 2006), LNCS 4098, pp. 297–312. Springer, Berlin (2006)
Giesl, J., Thiemann, R., Schneider-Kamp, P.: The dependency pair framework: combining techniques for automated termination proofs. In: Proceedings of the 11th International Conference on Logic for Programming, Artificial Intelligence, and Reasoning (LPAR’04), LNCS 3452, pp. 301–331. Springer, Berlin (2005)
Giesl J., Thiemann R., Schneider-Kamp P., Falke S.: Mechanizing and improving dependency pairs. J. Autom. Reason. 37(3), 155–203 (2006)
Hanus, M.: Compiling logic programs with equality. In: Proceedings of the 2nd International Workshop on Programming Language Implementation and Logic Programming (PLILP’90), LNCS 456, pp. 387–401. Springer, Berlin (1990)
Hanus M.: The integration of functions into logic programming: from theory to practice. J. Logic Program. 19–20, 583–628 (1994)
Hanus, M.: Multi-paradigm declarative languages. In: Proceedings of the International Conference on Logic Programming (ICLP 2007), LNCS 4670, pp. 45–75. Springer, Berlin (2007)
Hölldobler S.: Foundations of Equational Logic Programming, LNAI 353. Springer, Berlin (1989)
Huet, G., Lévy, J.J.: Computations in orthogonal rewriting systems, Part I + II. In: Lassez, J.L., Plotkin, G.D. (eds.) Computational Logic—Essays in Honor of Alan Robinson. pp. 395–443 (1992)
Hullot, J.M.: Canonical forms and unification. In: Proceedings of the 5th International Conference on Automated Deduction, LNCS 87, pp. 318–334. Springer, Berlin (1980)
Iborra J., Nishida, N., Vidal, G.: Goal-directed and relative dependency pairs for proving the termination of narrowing. In: De Schreye D. (ed.) Proceedings of the 19th International Symposium on Logic-based Program Synthesis and Transformation (LOPSTR 2009). Springer, Berlin, LNCS (to appear) (2010)
Jacquemard, F., Rusinowitch, M., Vigneron, L.: Compiling and verifying security protocols. In: Proceedings of the 7th International Conference on Logic for Programming and Automated Reasoning (LPAR’00), LNAI 1955, pp. 131–160. Springer, Berlin (2000)
Jones N.D., Gomard C.K., Sestoft P.: Partial Evaluation and Automatic Program Generation. Prentice-Hall, Englewood Cliffs, NJ (1993)
Klop J.W.: Term rewriting systems: a tutorial. Bull. Eur. Assoc. Theor. Comput. Sci. 32, 143–183 (1987)
Koprowski A.: TPA: Termination proved automatically. In: Pfenning, F. (eds) Proceedings of the 17th International Conference on Term Rewriting and Applications (RTA 2006), LNCS 4098, pp. 257–266. Springer, Berlin (2006)
Kusakari, K., Nakamura, M., Toyama, Y.: Argument filtering transformation. In: Proceedings of the International Conference on Principles and Practice of Declarative Programming (PPDP’99), LNCS 1702, pp. 48–62. Springer, Berlin (1999)
Lindenstrauss N., Sagiv Y., Serebrenik A.: Proving termination for logic programs by the query-mapping pairs approach. In: Bruynooghe, M., Lau, K.-K. (eds) Program Development in Computational Logic, LNCS 3049, pp. 453–498. Springer, Berlin (2004)
Lloyd J.W.: Foundations of Logic Programming. 2nd edn. Springer, Berlin (1987)
López-Fraguas, F., Sánchez-Hernández, J.: TOY: a multiparadigm declarative system. In: Proceedings of the 10th International Conference on Rewriting Techniques and Applications (RTA’99), LNCS 1631, pp. 244–247. Springer, Berlin (1999)
Martelli A., Montanari U.: An efficient unification algorithm. ACM Trans. Program. Lang. Syst. 4, 258–282 (1982)
Meseguer J., Thati P.: Symbolic reachability analysis using narrowing and its application to verification of cryptographic protocols. Electron. Notes Theor. Comput. Sci. 117, 153–182 (2005)
Middeldorp A., Hamoen E.: Completeness results for basic narrowing. Appl. Algebra Eng. Commun. Comput. 5, 213–253 (1994)
Moreno-Navarro, J.J., Kuchen, H., Loogen, R., Rodriguez-Artalejo, M.: Lazy narrowing in a graph machine. In: Proceedings of the 2nd International Conference on Algebraic and Logic Programming (ALP’90), LNCS 463, pp. 298–317. Springer, Berlin (1990)
Moreno-Navarro J.J., Rodríguez-Artalejo M.: Logic programming with functions and predicates: the language babel. J. Logic Program. 12(3), 191–224 (1992)
Nishida, N., Miura, K.: Dependency graph method for proving termination of narrowing. In: Proceedings of the 8th International Workshop on Termination (WST’06), pp. 12–16. (2006)
Nishida, N., Sakai, M., Sakabe, T.: Narrowing-based simulation of term rewriting systems with extra variables, ENTCS 86(3). (2003)
Ramos, J.G., Silva, J., Vidal, G.: Fast narrowing-driven partial evaluation for inductively sequential systems. In: Proceedings of the 10th ACM SIGPLAN International Conference on Functional Programming (ICFP’05), pp. 228–239. ACM Press (2005)
Reddy, U.S.: Narrowing as the operational semantics of functional languages. In: Proceedings of the Symposium on Logic Programming (SLP’85) pp. 138–151. IEEE Press (1985)
Schneider-Kamp P., Giesl J., Serebrenik A., Thiemann R.: Automated termination proofs for logic programs by term rewriting. ACM Trans. Program. Lang. 11(1), 1–52 (2009)
Sheard, T.: Type-level computation using narrowing in Ωmega. In: Proceedings of the Workshop on Programming Languages meets Program Verification (PLPV’06), ENTCS 174, pp. 105–128. (2007)
Slagle J.R.: Automated theorem-proving for theories with simplifiers, commutativity and associativity. J. ACM 21(4), 622–642 (1974)
Steinbach J.: Simplification orderings: histrory of results. Fundam. Inf. 24(1/2), 47–87 (1995)
Verbaeten S., Sagonas K., De Schreye D.: Termination proofs for logic programs with tabling. ACM Trans. Comput. Logic 2(1), 57–92 (2001)
Vidal G.: Termination of narrowing in left-linear constructor systems. In: Garrigue, J., Hermenegildo, M. (eds) Proceedings of the 9th International Symposium on Functional and Logic Languages (FLOPS 2008), LNCS 4989, pp. 113–129. Springer, Berlin (2008)
Author information
Authors and Affiliations
Corresponding author
Additional information
A preliminary short version of this paper appeared in the Proceedings of FLOPS 2008 [65].
This work has been partially supported by the Spanish Ministerio de Ciencia e Innovación under grant TIN2008-06622-C03-02, by Generalitat Valenciana under grant ACOMP/2009/017, and by UPV (programs PAID-05-08 and PAID-06-08).
Rights and permissions
About this article
Cite this article
Nishida, N., Vidal, G. Termination of narrowing via termination of rewriting. AAECC 21, 177–225 (2010). https://doi.org/10.1007/s00200-010-0122-4
Received:
Revised:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s00200-010-0122-4