In this paper we investigate the relationship between the algebraic definition of graph grammars and logic programming. In particular, we show that the operational semantics of any logic program can be faithfully simulated by a particular context-free hypergraph grammar. In the process of doing that, we consider the issue of representing terms, formulas, and clauses as particular graphs or graph productions, by first evaluating the approaches already proposed for Term Rewriting Systems (TRS), and then by giving an original extension of those approaches, to be able to deal with the unique features of logic programming. Actually, not only does our representation of definite clauses by graph productions allow us to deal correctly with logical unification, but also it overcomes some of the problems encountered by other approaches for representing TRS's as graph grammars. The main result of the paper states the soundness and completeness of the representation of clauses by productions, and this correspondence is extended to entire computations, showing how a context-free grammar (over a suitable category of graphs) can be associated with a logic program. The converse holds as well, i.e. given any context-free graph grammar (over that category), a logic program can be extracted from it.

Graph Grammars and Logic Programming

CORRADINI, ANDREA;MONTANARI, UGO GIOVANNI ERASMO;
1991-01-01

Abstract

In this paper we investigate the relationship between the algebraic definition of graph grammars and logic programming. In particular, we show that the operational semantics of any logic program can be faithfully simulated by a particular context-free hypergraph grammar. In the process of doing that, we consider the issue of representing terms, formulas, and clauses as particular graphs or graph productions, by first evaluating the approaches already proposed for Term Rewriting Systems (TRS), and then by giving an original extension of those approaches, to be able to deal with the unique features of logic programming. Actually, not only does our representation of definite clauses by graph productions allow us to deal correctly with logical unification, but also it overcomes some of the problems encountered by other approaches for representing TRS's as graph grammars. The main result of the paper states the soundness and completeness of the representation of clauses by productions, and this correspondence is extended to entire computations, showing how a context-free grammar (over a suitable category of graphs) can be associated with a logic program. The converse holds as well, i.e. given any context-free graph grammar (over that category), a logic program can be extracted from it.
1991
354054478X
File in questo prodotto:
Non ci sono file associati a questo prodotto.

I documenti in IRIS sono protetti da copyright e tutti i diritti sono riservati, salvo diversa indicazione.

Utilizza questo identificativo per citare o creare un link a questo documento: https://hdl.handle.net/11568/16314
 Attenzione

Attenzione! I dati visualizzati non sono stati sottoposti a validazione da parte dell'ateneo

Citazioni
  • ???jsp.display-item.citation.pmc??? ND
  • Scopus 11
  • ???jsp.display-item.citation.isi??? 7
social impact