# Towards a clean amalgamation of logic programs with external procedures

Functional Programming And Logic Programming

First Online:

## Abstract

The paper presents a clean approach to the amalgamation of logic programming with external functional procedures. Both the logical semantics and the operational semantics of the amalgamated language are outlined. The operational semantics is based on an incomplete ɛ-unification algorithm which we call S-unification. It is suggested to use abstract interpretation techniques in order to identify classes of goals for which the approach is complete. For this purpose a domain of abstract substitutions is defined, and an abstract unification algorithm used for a compile-time check is developed.

## Keywords

Logic Program Logic Programming Operational Semantic Error Message Abstract Interpretation
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

## Preview

Unable to display preview. Download preview PDF.

## References

- [1]H. Aït-Kaci, P. Lincoln and R. Nasr, Le Fun: Logic, Equations and Functions, in:
*Proc. 1987 Symposium on Logic Programming*, pp. 17–23, San Francisco, California, (1987).Google Scholar - [2]R. Barbuti, M. Bellia, G. Levi and M. Martelli, LEAF: a language which integrates Logic, Equations and Functions, in: D. DeGroot and G. Lindstrom ed.,
*Logic Programming, Functions, Relations and Equations*, (Prentice-Hall, 1986) pp. 201–238.Google Scholar - [3]M. Bellia and G. Levi, The Relation between Logic and Functional Languages: A Survey,
*J. Logic Programming*,**3**(1986), pp. 217–236.Google Scholar - [4]M. Bruynooghe, A Framework for the Abstract Interpretation of Logic Programs, Report, CW 62, Katholieke Universiteit, Leuven (1987).Google Scholar
- [5]S. Cohen, The APPLOG Language, in: D. DeGroot and G. Lindstrom ed.,
*Logic Programming, Functions, Relations and Equations*, (Prentice-Hall 1986) pp. 239–276.Google Scholar - [6]D. DeGroot and G. Lindstrom ed., Logic Programming, Functions, Relations and Equations, (Prentice-Hall, Englewood Cliffs, NJ, 1986)Google Scholar
- [7]P. Deransart and J. Małuszyński, Logic Programs and Attribute Grammars,
*J. Logic Programming*,**2**(1985), pp. 119–155.Google Scholar - [8]J. Goguen and J. Meseguer, EQLOG: Equality, Types and Generic Modules for Logic Programming, in: D. DeGroot and G. Lindstrom ed.,
*Logic Programming, Functions, Relations and Equations*, (Prentice-Hall, 1986) pp. 295–363.Google Scholar - [9]J. Goguen and J. Meseguer, Models and Equality for Logical Programming, in:
*Proc. TAPSOFT' 87*, Pisa, Italy, (1987).Google Scholar - [10]J-M. Hullot, Canonical Forms and Unification, in:
*Proc. CADE-5*, pp. 318–334, (1980).Google Scholar - [11]J. Jaffar, J-L. Lassez and M-J. Maher, A Theory of Complete Logic Programs with Equality,
*J. Logic Programming*,**3**(1984), pp. 211–223.Google Scholar - [12]J. Jaffar and S Michaylov, Methodology and Implementation of a CLP system, in:
*Proc. 4:th Int. Conf. on Logic Programming*, Melbourne, Australia, (1987).Google Scholar - [13]N. Jones and H. Søndergaard, A Semantics-based Framework for the Abstract Interpretation of PROLOG, in: Abramsky and Hankin ed.,
*Abstract Interpretation of Declarative Languages*, (Ellis Horwood, 1987).Google Scholar - [14]J. Komorowski, QLOG — The Programming Environment for PROLOG in LISP, in: K. Clark and S-Å Tärnlund ed.,
*Logic Programming*, (Prentice-Hall, 1982).Google Scholar - [15]J. Leszczylowski, S. Bonnier and J. Małuszyński, Logic Programming with External Procedures: Introducing S-Unification, Report, R-88-01, Dep. of Comp. and Inf. Sc., Linköping University, Linköping, Sweden, a shortened version also in:
*Information Processing Letters*,**27**(1988), pp. 159–165.Google Scholar - [16]J. Leszczylowski and J. Małuszyński, Logic Programming with External Procedures: Introducing S-Unification, Report, TR-86-21, Dep. of Comp Sc., Iowa State University, Ames (1986).Google Scholar
- [17]C-S. Mellish, Abstract Interpretation of PROLOG Programs, in: Abramsky and Hankin ed.,
*Abstract Interpretation of Declarative Languages*, (Ellis Horwood, 1987).Google Scholar - [18]C-S. Mellish and S. Hardy, Integrating PROLOG in POPLOG Environment, in: J. Campbell ed.,
*Implementations of PROLOG*, (Ellis Horwood, 1984.)Google Scholar - [19]U. Nilsson, Inferring Restricted AND-Parallelism in Logic Programs using Abstract Interpretation, Report, R-88-02, Dep. of Comp. and Inf. Sc., Linköping University, Linköping, Sweden (1988).Google Scholar
- [20]J-A. Robinson, A Machine-Oriented Logic Based on the Resolution Principle,
*JACM, 12*(1965), pp. 32–41.Google Scholar - [21]J. Robinson and E. Sibert, LOGLISP: Motivation, Design and Implementation, in: K. Clark and S-Å Tärnlund ed.,
*Logic Programming*, (Prentice-Hall, 1982).Google Scholar - [22]P. Subrahmanyam and J-H. You, FUNLOG: A Computational Model Integrating Logic Programming and Functional Programming, in: D. DeGroot and G. Lindstrom ed.,
*Logic Programming, Functions, Relations and Equations*, (Prentice-Hall, 1986) pp. 157–198.Google Scholar

## Copyright information

© Springer-Verlag Berlin Heidelberg 1989