532 research outputs found
Logic Programming for Describing and Solving Planning Problems
A logic programming paradigm which expresses solutions to problems as stable
models has recently been promoted as a declarative approach to solving various
combinatorial and search problems, including planning problems. In this
paradigm, all program rules are considered as constraints and solutions are
stable models of the rule set. This is a rather radical departure from the
standard paradigm of logic programming. In this paper we revisit abductive
logic programming and argue that it allows a programming style which is as
declarative as programming based on stable models. However, within abductive
logic programming, one has two kinds of rules. On the one hand predicate
definitions (which may depend on the abducibles) which are nothing else than
standard logic programs (with their non-monotonic semantics when containing
with negation); on the other hand rules which constrain the models for the
abducibles. In this sense abductive logic programming is a smooth extension of
the standard paradigm of logic programming, not a radical departure.Comment: 8 pages, no figures, Eighth International Workshop on Nonmonotonic
Reasoning, special track on Representing Actions and Plannin
Enhancing a Search Algorithm to Perform Intelligent Backtracking
This paper illustrates how a Prolog program, using chronological backtracking
to find a solution in some search space, can be enhanced to perform intelligent
backtracking. The enhancement crucially relies on the impurity of Prolog that
allows a program to store information when a dead end is reached. To illustrate
the technique, a simple search program is enhanced.
To appear in Theory and Practice of Logic Programming.
Keywords: intelligent backtracking, dependency-directed backtracking,
backjumping, conflict-directed backjumping, nogood sets, look-back.Comment: To appear in Theory and Practice of Logic Programmin
A Polyvariant Binding-Time Analysis for Off-line Partial Deduction
We study the notion of binding-time analysis for logic programs. We formalise
the unfolding aspect of an on-line partial deduction system as a Prolog
program. Using abstract interpretation, we collect information about the
run-time behaviour of the program. We use this information to make the control
decisions about the unfolding at analysis time and to turn the on-line system
into an off-line system. We report on some initial experiments.Comment: 19 pages (including appendix) Paper (without appendix) appeared in
Programming Languages and Systems, Proceedings of the European Symposium on
Programming (ESOP'98), Part of ETAPS'98 (Chris Hankin, eds.), LNCS, vol.
1381, 1998, pp. 27-4
Offline Specialisation in Prolog Using a Hand-Written Compiler Generator
The so called "cogen approach" to program specialisation, writing a compiler generator instead of a specialiser, has been used with considerable success in partial evaluation of both functional and imperative languages. This paper demonstrates that the "cogen" approach is also applicable to the specialisation of logic programs (called partial deduction when applied to pure logic programs) and leads to effective specialisers. Moreover, using good binding-time annotations, the speed-ups of the specialised programs are comparable to the speed-ups obtained with online specialisers. The paper first develops a generic approach to offline partial deduction and then a specific offline partial deduction method, leading to the offline system LIX for pure logic programs. While this is a usable specialiser by itself, its specialisation strategy is used to develop the "cogen" system LOGEN. Given a program, a specification of what inputs will be static, and an annotation specifying which calls should be unfolded, LOGEN generates a specialised specialiser for the program at hand. Running this specialiser with particular values for the static inputs results in the specialised program. While this requires two steps instead of one, the efficiency of the specialisation process is improved in situations where the same program is specialised multiple times. The paper also presents and evaluates an automatic binding-time analysis that is able to derive the annotations. While the derived annotations are still suboptimal compared to hand-crafted ones, they enable non-expert users to use the LOGEN system in a fully automated way Finally, LOGEN is extended so as to directly support a large part of Prolog's declarative and non-declarative features and so as to be able to perform so called mixline specialisations. In mixline specialisation some unfolding decisions depend on the outcome of tests performed at specialisation time instead of being hardwired into the specialiser
Towards modular binding-time analysis for first-order Mercury
AbstractIn this paper, we describe work in progress on binding-time analysis (BTA) for a first-order subset of Mercury. BTA is the core part of any off-line specialisation system. We formulate BTA by constraint normalisation, enabling the analysis to be performed efficiently and in a modular way.The authors wish to thank Danny De Schreye and Karel De Vlaminck for their continuous interest in this work. They also wish to thank anonymous referees for valuable comments which helped to improve the current paper
- ā¦