Adding equations to NUProlog
 Lee Naish
 … show all 1 hide
Abstract
This paper describes an extension to NUProlog which allows evaluable functions to be defined using equations. We consider it to be the most pragmatic way of combining functional and relational programming. The implementation consists of several hundred lines of Prolog code and the underlying Prolog implementation was not modified at all. However, the system is reasonably efficient and supports coroutining, optional lazy evaluation, higher order functions and parallel execution. Efficiency is gained in several ways. First, we use some new implementation techniques. Second, we exploit some of the unique features of NUProlog, though these features are not essential to the implementation. Third, the language is designed so that we can take advantage of implicit mode and determinism information. Although we have not concentrated on the semantics of the language, we believe that our language design decisions and implementation techniques will be useful in the next generation of combined functional and relational languages.
 P.G. Bosco, C. Cecchi, and C. Moiso. Exploiting the full power of logic plus functional programming. In Kenneth A. Bowen and Robert A. Kowalski, editors, Proceedings of the Fifth International Conference/Symposium on Logic Programming, pages 3–17, Seattle, Washington, August 1988.
 P.G. Bosco, C. Cecchi, C. Moiso, M. Porta, and G. Sofi. Logic and functional programming on distributed memory architectures. In Proceedings of the Seventh International Conference on Logic Programming, Jerusalem, Israel, June 1990.
 M.H.M. Cheng, M.H. van Emden, and B.E. Richards. On warren's method for functional programming in logic. In Proceedings of the Seventh International Conference on Logic Programming, Jerusalem, Israel, June 1990.
 J. Darlington, A.J. Field, and H. Pull. The unification of functional and logic languages. In Doug DeGroot and Gary Lindstrom, editors, Logic programming: relations, functions, and equations, pages 37–70. PrenticeHall, 1985.
 Saumya K. Debray and David S. Warren. Detection and optimisation of functional computations in prolog. In Ehud Shapiro, editor, Proceedings of the Third International Conference on Logic Programming, pages 490–504, London, England, July 1986. published as Lecture Notes in Computer Science 225 by SpringerVerlag.
 Laurent Fribourg. SLOG: a logic programming language interpreter based on clausal superposition and rewriting. In Proceedings of the Second IEEE Symposium on Logic Programming, pages 172–184, Boston, Massachusetts, July 1985.
 Joseph A. Goguen and Jose Meseguer. EQLOG: equality, types, and generic modules for logic programming. In Doug DeGroot and Gary Lindstrom, editors, Logic programming: relations, functions, and equations, pages 295–363. PrenticeHall, 1985.
 Gregory, S. (1987) Parallel logic programming in parlog. AddisonWesley, Wokingham, England
 Alan Josephson and Nachum Dershowitz. An implementation of narrowing the RITE way. In Proceedings of the Third IEEE Symposium on Logic Programming, pages 187–197, Salt Lake City, Utah, September 1986.
 Jones, S. P. (1987) The implementation of functional programming languages. Prentice Hall, London
 Naish, L. (1986) Negation and control in Prolog. SpringerVerlag, New York
 Lee Naish. Parallelizing NUProlog. In Kenneth A. Bowen and Robert A. Kowalski, editors, Proceedings of the Fifth International Conference/Symposium on Logic Programming, pages 1546–1564, Seattle, Washington, August 1988.
 Naish, L. (1990) Adding equations to NUprolog. Department of Computer Science, University of Melbourne, Melbourne, Australia
 Narain, S. (1986) A technique for doing lazy evaluation in logic. Journal of Logic Programming 3: pp. 259276
 Narain, S. (1988) LOG(F): An optimal combination of logic programming, rewriting and lazy evaluation. Dept. of computer science, UCLA, Los Angeles, CA
 Uday S. Reddy. Narrowing as the operational semantics of functional languages. In Proceedings of the Second IEEE Symposium on Logic Programming, pages 138–151, Boston, Massachusetts, July 1985.
 YehHeng Sheng. HIFUNLOG: logic programming with higherorder relational functions. In Proceedings of the Seventh International Conference on Logic Programming, Jerusalem, Israel, June 1990.
 P.A. Subrahmanyam and JiaHuai You. FUNLOG: a computational model integrating logic programming and functional programming. In Doug DeGroot and Gary Lindstrom, editors, Logic programming: relations, functions, and equations, pages 157–198. PrenticeHall, 1985.
 Warren, D. H. Higherorder extensions to prolog: are they needed?. In: Hayes, J.E., Michie, D., Pao, YH. eds. (1982) Machine Intelligence 10. Ellis Horwood Ltd., Chicester, England, pp. 441454
 Warren, D. H. (1983) An abstract Prolog instruction set. SRI International, Menlo Park, California
 Title
 Adding equations to NUProlog
 Book Title
 Programming Language Implementation and Logic Programming
 Book Subtitle
 3rd International Symposium, PLILP '91 Passau, Germany, August 26–28, 1991 Proceedings
 Pages
 pp 1526
 Copyright
 1991
 DOI
 10.1007/3540544445_84
 Print ISBN
 9783540544449
 Online ISBN
 9783540383628
 Series Title
 Lecture Notes in Computer Science
 Series Volume
 528
 Series ISSN
 03029743
 Publisher
 Springer Berlin Heidelberg
 Copyright Holder
 SpringerVerlag
 Additional Links
 Topics
 Industry Sectors
 eBook Packages
 Editors
 Authors

 Lee Naish ^{(1)}
 Author Affiliations

 1. Department of Computer Science, University of Melbourne, 3052, Parkville, Australia
Continue reading...
To view the rest of this content please follow the download PDF link above.