## Synthesis And Transformation Of Logic Programs Using Unfold/Fold Proofs (1999)

### Cached

### Download Links

- [www.iasi.rm.cnr.it]
- [ftp.iasi.rm.cnr.it]
- DBLP

### Other Repositories/Bibliography

Venue: | Journal of Logic Programming |

Citations: | 29 - 11 self |

### BibTeX

@ARTICLE{Pettorossi99synthesisand,

author = {Alberto Pettorossi and Maurizio Proietti},

title = {Synthesis And Transformation Of Logic Programs Using Unfold/Fold Proofs},

journal = {Journal of Logic Programming},

year = {1999},

volume = {41}

}

### Years of Citing Articles

### OpenURL

### Abstract

We present a method for proving properties of definite logic programs. This method is called unfold/fold proof method because it is based on the unfold/fold transformation rules...

### Citations

1855 |
Foundations of Logic Programming
- Lloyd
- 1987
(Show Context)
Citation Context ...lding rule may be used to replace n clauses, with n 1, by a single clause (in [28] n is 1). In this paper we consider denite programs and for the notions not explicitly introduced here we refer to [2=-=0]. W-=-e assume that a goal is a conjunction of n ( 0) atoms dened as follows: goal ::= true j atom j goal ; goal where the conjunction operator \," is associative and it has true as neutral element (in... |

620 |
The Art of Prolog
- Sterling, Shapiro
- 1986
(Show Context)
Citation Context ..., we can express the predicate queue in terms of di q as follows: queue(S)sdi q(S; LnL) This clause, together with the clauses of the set Eureka (see Step 5.3), is analogous to the program given in [2=-=7]-=-, except for the inequality occurring in the body of one of oursnal clauses. As the reader may verify, that inequality is necessary for establishing Equiv3. 2 218 7. A TRANSFORMATION STRATEGY FOR AVOI... |

570 | A Transformation System for Developing Recursive Programs
- Burstall, Darlington
- 1976
(Show Context)
Citation Context ...ons. / 1. INTRODUCTION The unfold/fold transformation rules were originally introduced for deriving correct and ecient programs from initial program versions whose correctness could easily be veried [=-=8, 24, 28-=-]. These rules can also be used for other purposes, such as program analysis, synthesis, specialization, and verication. Indeed, for instance, in [19] we cansnd a method based on unfold/fold rules, fo... |

537 | The role of abduction in logic programming
- Kakas, Kowalski, et al.
- 1998
(Show Context)
Citation Context ...p, such that M(P [ Eureka) j= Equiv2. The reader who is familiar with the abduction theory, may realize that the task of generating the set Eureka can be viewed as an instance of an abduction problem =-=[17]-=-, where Equiv2 is the observed formula and Eureka is a set of abductive explanations to be added to P for justifying the formula Equiv 2. We will now present our synthesis method by looking, at the sa... |

239 |
Partial evaluation in logic programming
- Lloyd, Shepherdson
- 1991
(Show Context)
Citation Context ...ents of concat are lists. 2 215 Before closing the section let us remark that our specialization technique based on the synthesis method from implicit denitions is an extension of partial evaluations[=-=21]-=-. Indeed, partial evaluation corresponds to the case where program specialization is applied using a predicate input(X) of the form: X = t, for some (possibly non-ground) term t. 6. SYNTHESIS OF PROGR... |

213 |
Unfold/fold transformations of logic programs
- Tamaki, Sato
- 1984
(Show Context)
Citation Context ...ons. / 1. INTRODUCTION The unfold/fold transformation rules were originally introduced for deriving correct and ecient programs from initial program versions whose correctness could easily be veried [=-=8, 24, 28-=-]. These rules can also be used for other purposes, such as program analysis, synthesis, specialization, and verication. Indeed, for instance, in [19] we cansnd a method based on unfold/fold rules, fo... |

168 | The concept of a supercompiler
- Turchin
- 1986
(Show Context)
Citation Context ...e may symbolically generate and examine the set of the SLD-derivations starting from a given goal. (Symbolic evaluation is a standard analysis technique used in various program transformation methods =-=[6, 8, 30]-=-.) In particular, by constructing asnite upper portion of the SLD-tree starting from the goal of interest, we maysnd equal subgoals which have to be evaluated along distinct branches of that SLD-tree,... |

154 |
A deductive approach to program synthesis
- Manna, Waldinger
- 1980
(Show Context)
Citation Context ...he specication of the predicate newp. The unfold/fold rules can indeed be viewed as derivation rules in these synthesis methods. Our synthesis method is also related to the proofs-as-programs method [=-=1, 7, 12, 23]-=- whereby the constructive proof of a property of the form 8X 9Y spec(X; Y ) can be used for synthesizing a program which, for any input X , computes an output Y such that spec(X; Y ) holds. The main d... |

139 | Transformation of logic programs: Foundations and techniques
- Pettorossi, Proietti
- 1994
(Show Context)
Citation Context ...ons. / 1. INTRODUCTION The unfold/fold transformation rules were originally introduced for deriving correct and ecient programs from initial program versions whose correctness could easily be veried [=-=8, 24, 28-=-]. These rules can also be used for other purposes, such as program analysis, synthesis, specialization, and verication. Indeed, for instance, in [19] we cansnd a method based on unfold/fold rules, fo... |

121 |
Essentials of Logic Programming
- Hogger
- 1990
(Show Context)
Citation Context ... for the derivation of more ecient logic programs by avoiding unnecessary nondeterminism. Our synthesis method is related to the traditional methods for synthesizing logic programs (see, for instance =-=[16-=-] and also [11] for a survey) from initial specications of the form: 8X (spec(X) $ newp(X)), where newp is the predicate for which we want to synthesize a program and spec is any formula of thesrst or... |

101 |
Proofs as programs
- Bates, Constable
- 1985
(Show Context)
Citation Context ...he specication of the predicate newp. The unfold/fold rules can indeed be viewed as derivation rules in these synthesis methods. Our synthesis method is also related to the proofs-as-programs method [=-=1, 7, 12, 23]-=- whereby the constructive proof of a property of the form 8X 9Y spec(X; Y ) can be used for synthesizing a program which, for any input X , computes an output Y such that spec(X; Y ) holds. The main d... |

73 | Automatic Mode Inference for Logic Programs
- Debray, Warren
- 1988
(Show Context)
Citation Context ...some steps of our strategy we make use of the method of program synthesis from implicit denitions described in Section 4. A well known technique for avoiding nondeterminism is based on clause fusions[=-=10-=-]. It consists in replacing two clauses of the form: HsI ; F HsI ; G by the clauses HsI ; B BsF BsG where B is an atom with a new predicate symbol, say newp. Thus, clause fusion can be viewed as a den... |

38 | Logic program synthesis. The
- DeVille, Lau
- 1994
(Show Context)
Citation Context ...ation of more ecient logic programs by avoiding unnecessary nondeterminism. Our synthesis method is related to the traditional methods for synthesizing logic programs (see, for instance [16] and also =-=[11-=-] for a survey) from initial specications of the form: 8X (spec(X) $ newp(X)), where newp is the predicate for which we want to synthesize a program and spec is any formula of thesrst order predicate ... |

35 |
A First Order Theory of Data and Programs
- Clark, Tarnlund
- 1977
(Show Context)
Citation Context ...n this section we denote by the basic predicate app(X; Y; Z). A dierence-list can be thought of as a pair of lists, denoted by LnR, such that there exists a third list Y for which app(Y; R; L) holds [=-=-=-9]. In that case we say that Y is represented by the dierence-list LnR. Obviously, a single list can be represented by many dierence-lists. Programs that use lists are often simpler to write and under... |

34 |
Compiling Control
- Bruynooghe, Schreye, et al.
- 1989
(Show Context)
Citation Context ...e may symbolically generate and examine the set of the SLD-derivations starting from a given goal. (Symbolic evaluation is a standard analysis technique used in various program transformation methods =-=[6, 8, 30]-=-.) In particular, by constructing asnite upper portion of the SLD-tree starting from the goal of interest, we maysnd equal subgoals which have to be evaluated along distinct branches of that SLD-tree,... |

30 |
A Method for Specializing Logic Programs
- Bossi, N, et al.
- 1990
(Show Context)
Citation Context ... in a natural way by using the unfold/fold transformations of [28]. Some modied versions of the rules should be used instead, like, for instance, the unfold/fold rules with constraints introduced by [=-=3-=-] for specializing logic programs, or the inverse denition and the data structure mapping introduced by [31]. Our last example on the avoidance of nondeterminism shows that the unfold/fold transformat... |

29 |
The synthesis of logic programs from inductive proofs
- Bundy, Smaill, et al.
- 1990
(Show Context)
Citation Context ...he specication of the predicate newp. The unfold/fold rules can indeed be viewed as derivation rules in these synthesis methods. Our synthesis method is also related to the proofs-as-programs method [=-=1, 7, 12, 23]-=- whereby the constructive proof of a property of the form 8X 9Y spec(X; Y ) can be used for synthesizing a program which, for any input X , computes an output Y such that spec(X; Y ) holds. The main d... |

25 |
Preserving Universal Termination through Unfold/Fold
- Bossi, Cocco
- 1994
(Show Context)
Citation Context ...est, and thus, since they refer tosnite objects, they have a more constructive nature w.r.t. other techniques, such as those based on consistency with weight tuple measures [29] or non-increasingness =-=[-=-2], which rely on the verication of properties of possibly innite sets of SLD-derivations. We have also presented a method for synthesizing programs from unfold/fold proofs of program properties. Alth... |

25 | Reducing nondeterminism while specializing logic programs
- Pettorossi, Proietti, et al.
- 1997
(Show Context)
Citation Context ... derivation itself. Thus, the synthesis method we propose may also be useful to enhance 226 other unfold/fold-based techniques for avoiding nondeterminism which do not use lemmas (like, for instance, =-=[25]-=-). We would like to stress the point that the program specialization method presented here as an application of our synthesis method, is strictly more general than the usual partial evaluation methods... |

23 |
Extracting logic programs from proofs that use extended Prolog execution and induction
- Fribourg
- 1990
(Show Context)
Citation Context |

21 | Correctness of a Logic Program Transformation System
- Maher
- 1987
(Show Context)
Citation Context ...the least Herbrand model semantics. These rules are similar to the ones presented in [28], with the exception of the rules for denition introduction and for folding, which are similar to the ones in [=-=14, 2-=-2]. In contrast to [28], the denition introduction rule considered here may be used to introduce a new predicate by means of n clauses, with n 1 (in [28] n is 1), and the folding rule may be used to ... |

17 |
A Generalized Correctness Proof of the Unfold/Fold Logic Program Transformation
- Tamaki, Sato
- 1986
(Show Context)
Citation Context ...t A ) B ) C i where B is derived from A by unfolding, and () all goal replacements are non-ascending. Then M(P 0 [ Def k )=M(P k ). Proof. It is an extension of the correctness results reported in [1=-=4, 29]-=-. The total correctness of the rules R1{R6 presented above is proved in [29] (see Theorem 3.7), with the restriction that the folding rule is allowed only in the case where the number of folded clause... |

17 | Unfold/fold transformations for definite clause programs
- Gergatsoulis, Katzouraki
- 1994
(Show Context)
Citation Context ...he least Herbrand model semantics. These rules are similar to the ones presented in [28], with the exception of the rules for definition introduction and for folding, which are similar to the ones in =-=[14, 22]-=-. In contrast to [28], the definition introduction rule considered here may be used to introduce a new predicate by means of n clauses, with ns1 (in [28] n is 1), and the folding rule may be used to r... |

13 |
Deriving Unfold/Fold Transformations of Logic Programs Using Extended OLDT-based Abstract Interpretation
- Boulanger, Bruynooghe
- 1993
(Show Context)
Citation Context ...tion. Indeed, for instance, in [19] we cansnd a method based on unfold/fold rules, for proving the equivalence of functional expressions. This method can also be adapted to the case of logic programs =-=[4, 26]-=- for proving equivalences of goals, that is, equivalences of conjunctions of atoms. In this paper, which builds upon [26], we formalize this method, called unfold/fold proof method, for the case of de... |

12 |
C.J.: “Grammar-Related Transformations of Logic Programs
- Brough, Hogger
- 1991
(Show Context)
Citation Context ... which, instead, is left-recursive and evaluates the goal reach(X) in a backward-chaining fashion. 2 A similar transformation of left-recursive programs into right-recursive programs was presented in =-=[5]-=- where, however, the transformation of P 0 into P 5 is presented in one `big step' as a schema-based transformation, which is validated by an ad-hoc inductive proof. We believe that our approach based... |

9 |
Program Transformation by Data Structure Mapping” Logic Programming
- Hansson, Tärnlund
- 1982
(Show Context)
Citation Context ...interested in providing techniques for transforming in an automatic way programs which use lists, into programs which use dierence-lists. Several such techniques have been proposed in the literature [=-=15, 31-=-]. We will show that by applying our program synthesis method we can automatically perform the transformation which introduces dierence-lists. Our method is very general and it can be used also to per... |

9 |
Synthesis of Programs from Unfold/Fold Proofs” to be published
- Proietti, Pettorossi
- 1993
(Show Context)
Citation Context ...tion. Indeed, for instance, in [19] we cansnd a method based on unfold/fold rules, for proving the equivalence of functional expressions. This method can also be adapted to the case of logic programs =-=[4, 26]-=- for proving equivalences of goals, that is, equivalences of conjunctions of atoms. In this paper, which builds upon [26], we formalize this method, called unfold/fold proof method, for the case of de... |

8 |
Unfold/fold transformations for de clause programs
- Gergatsoulis, Katzouraki
- 1994
(Show Context)
Citation Context ...the least Herbrand model semantics. These rules are similar to the ones presented in [28], with the exception of the rules for denition introduction and for folding, which are similar to the ones in [=-=14, 2-=-2]. In contrast to [28], the denition introduction rule considered here may be used to introduce a new predicate by means of n clauses, with n 1 (in [28] n is 1), and the folding rule may be used to ... |

7 |
The McCarthy's induction principle: `oldy' but `goody
- Kott
- 1982
(Show Context)
Citation Context ... whose correctness could easily be veried [8, 24, 28]. These rules can also be used for other purposes, such as program analysis, synthesis, specialization, and verication. Indeed, for instance, in [1=-=9]-=- we cansnd a method based on unfold/fold rules, for proving the equivalence of functional expressions. This method can also be adapted to the case of logic programs [4, 26] for proving equivalences of... |

6 |
Deletion of redundant unary type predicates from logic programs
- Gallagher, Waal
- 1992
(Show Context)
Citation Context ...wing program LConcat for concatenating lists: concat([ ]; Ys; Ys)slist(Ys) concat([X jXs]; Ys; [X jZs])slist(Xs); list(Ys); list(Zs); concat(Xs ; Ys; Zs) list([ ])slist([X jXs])slist(Xs) Similarly to =-=[13]-=-, we would like to specialize our predicate concat(Xs ; Ys; Zs) w.r.t. the set of triples (Xs ; Ys; Zs) in the Herbrand universe such that the conjunction list(Xs); list(Ys); list(Zs) holds. Thus, we ... |

6 |
Derivation of Logic Programs from Implicit Definition
- Kanamori, Maeji
- 1986
(Show Context)
Citation Context ...e new predicate newp is specied by the formula: 8X (9Y F (X; Y ) $ newp(X)) which is a less general formula than the ones we have considered in this paper. Implicit denitions are also considered in [1=-=-=-8], where some modications of the unfolding and folding rules are introduced to deal with generalized denitions of the form: (H(X); newp(X))sF (X; Y ) for some goal H(X) and F (X; Y ). In our method w... |

1 |
An automatic d{list transformation algorithm for Prolog programs
- Zhang
- 1987
(Show Context)
Citation Context ...interested in providing techniques for transforming in an automatic way programs which use lists, into programs which use dierence-lists. Several such techniques have been proposed in the literature [=-=15, 31-=-]. We will show that by applying our program synthesis method we can automatically perform the transformation which introduces dierence-lists. Our method is very general and it can be used also to per... |