Skip to main content

A Logical Operational Semantics of Full Prolog: Part III. Built-In Predicates for Files, Terms, Arithmetic and Input-Output

  • Conference paper
Logic from Computer Science

Part of the book series: Mathematical Sciences Research Institute Publications ((MSRI,volume 21))

Abstract

Y. Gurevich recently proposed a framework for semantics of programming concepts which directly reflects the dynamic and resource-bounded aspects of computation. This approach is based on (essentially first-order) structures that evolve over time and are finite in the same way as real computers are (so-called “dynamic algebras”).

We use dynamic algebras to give an operational semantics for Prolog which, far from being hopelessly complicated, unnatural or machine-dependent, is simple, natural and abstract and in particular supports the process oriented understanding of programs by programmers. In spite of its abstractness, our semantics is machine executable. It is designed for extensibility and as a result of the inherent extensibility of dynamic algebra semantics, we are able to proceed by stepwise refinement.

We give this semantics for the full language of Prolog including all the usual non-logical built-in predicates. We hope to contribute in this way to reducing the “mismatch between theory and practice… that much of the theory of logic programming only apply to pure subsets of Prolog, whereas the extra-logical facilities of the language appear essential for it to be practical” (Lloyd 1989). Our specific aim is to provide a mathematically precise but simple logical framework in which standards can be defined rigorously and in which different implementations may be compared and judged. This work is in applied logic and suggests several interesting new classes of problems in model theory.

Part I deals with the core of Prolog which governs the selection mechanism of clauses for goal satisfaction including backtracking and cut and closely related built-in control predicates. In Part II the database built-in predicates are treated. In the present Part III we deal with the remaining built-in predicates for manipulation of files, terms, input/output and arithmetic.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 84.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 109.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  • Arbab, B. & Berry, D. M. 1987, Operational and denotational semantics of Prolog, J. Logic Programming 4, 309–329.

    Article  MATH  Google Scholar 

  • Blakley, R. 1991, Ph.D. thesis, University of Michigan (in preparation).

    Google Scholar 

  • Börger, E. 1990, A logical operational semantics of full Prolog. Part I. Selection core and control, CSL ’89. 3rd Workshop on Computer Science Logic, (Eds. E. Börger, H. Kleine Büning, M. Richter), Springer LNCS 440, pp. 36–64.

    Google Scholar 

  • Börger, E. 1990, A logical operational semantics of full Prolog. Part II. Built-in predicates for database manipulations, MFCS ’90. Proc. of the International Symposium on Mathematical Foundations of Computer Science, (Ed. B. Rovan), Springer LNCS 452, pp. 1–14.

    Google Scholar 

  • Börger, E. & Rosenzweig, D. 1991, From prolog algebras towards WAM—A mathematical study of implementation, CSL ’90. 4th Workshop on Computer Science Logic, (Eds. E. Borger, H. Kleine Büning, M. Richter, W. Schönfeld), Springer LNCS (to appear).

    Google Scholar 

  • Börger, E. & Rosenzweig, D. 1991, WAM algebras—A mathematical study of implementation, Part II, (submitted).

    Google Scholar 

  • Deransart, P. & Ferrand, G. 1987, An operational formal definition of Prolog, INRIA RR763 (revised version of the abstract in Proc. 4th Symposium on Logic Programming, San Francisco (1987), 162–172).

    Google Scholar 

  • Debray, S. K. & Mishra, P. 1988, Denotational and operational semantics for Prolog, J. Logic Programming 5, 61–91.

    Article  MathSciNet  MATH  Google Scholar 

  • DFPS 1989: Deransart, P., Folkjaer, P., Pique, J.-F., Scowen, R. S., Prolog. Draft for Working Draft 2.0, ISO/IEC YTCl SC22 WG17 No. 40, VI + 96.

    Google Scholar 

  • DFPS 1990: Deransart, P., Folkjaer, P., Pique, J.-F., Scowen, R. S., Prolog. Draft for Working Draft 3.0, ISO/IEC YTCl SC22 WG17 No. 53, IV + 77.

    Google Scholar 

  • Gurevich, Y. 1988, Logic and the challenge of computer science, Trends in Theoretical Computer Science, (E. Borger, ed.), Computer Science Press, 1988, pp. 1–57.

    Google Scholar 

  • Gurevich, Y. 1988, Algorithms in the world of bounded resources, , The Universal Turing Machine—a Half-Century Story, (Ed. R. Herken), Oxford University Press, pp. 407–416.

    Google Scholar 

  • Gurevich, Y . 1991, Evolving algebras. A tutorial introduction, EATCS Bulletin 43 (February 1991).

    Google Scholar 

  • Gurevich, Y. &; Morris, J. M. 1988, Algebraic operational semantics and Modula-2, CSL ’87. 1st Workshop on Computer Science Logic, (Eds. E. Börger, H. Kleine Büning, M. Richter), Springer LNCS 329, pp. 81–101.

    Google Scholar 

  • Gurevich, Y. Sz Moss, L. S. 1990, Algebraic operational semantics and Occam, (Eds. E. Börger, H. Kleine Büning, M. Richter), Springer LNCS.

    Google Scholar 

  • Jones, N. D. Sz Mycroft, A. 1984, Stepwise development of operational and denotational semantics for Prolog, Proc. Int. Symp. on Logic Programming 2/84, Atlantic City, IEEE, pp. 289–298.

    Google Scholar 

  • Kappel, A. 1990, Implementation of dynamic algebras with an application to Prolog, Diploma Thesis, University of Dortmund, Fed. Rep. of Germany.

    Google Scholar 

  • Lloyd, J. 1989, Current theoretical issues in logic programming, Abstract. EATCS-Bul-letin 39, 211.

    MathSciNet  Google Scholar 

  • LPA 1988: Johns, N. & Spenser, C, LP A Mac Prolog 2.5, Reference Manual, Logic Programming Associates, London.

    Google Scholar 

  • North, N. 1988, A denotational definition of Prolog, NPL Report DITC 106/88, National Physical Lab, Teddington, Middlesex.

    Google Scholar 

  • Quintus 1987, Quintus Prolog Reference Manual, Version 10, February, 1987, Quintus Computer Systems, Mt. View, CA.

    Google Scholar 

  • VM 1985, VM/Programming in Logic, Program Description and Operations Manual (July, 1985), IBM, 1st ed.

    Google Scholar 

Download references

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 1992 Springer-Verlag New York, Inc.

About this paper

Cite this paper

Börger, E. (1992). A Logical Operational Semantics of Full Prolog: Part III. Built-In Predicates for Files, Terms, Arithmetic and Input-Output. In: Moschovakis, Y.N. (eds) Logic from Computer Science. Mathematical Sciences Research Institute Publications, vol 21. Springer, New York, NY. https://doi.org/10.1007/978-1-4612-2822-6_2

Download citation

  • DOI: https://doi.org/10.1007/978-1-4612-2822-6_2

  • Publisher Name: Springer, New York, NY

  • Print ISBN: 978-1-4612-7685-2

  • Online ISBN: 978-1-4612-2822-6

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics