Skip to main content

Objective: In Minimum Context

  • Conference paper
Logic Programming (ICLP 2003)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 2916))

Included in the following conference series:

Abstract

The current proposals for the inclusion of modules in the ISO Prolog standard are not very consensual. Since a program-structuring feature is required for a production programming language, several alternatives have been explored over the years.

In this article we recall and expand on the concepts of Contextual Logic Programming, a powerful and simple mechanism which addresses the general issue of modularity in Logic Programs. We claim that unit arguments are an essential addition to this programming model, illustrate the claim with examples and draw parallels with Object-Oriented programming. We argue that Contextual Logic Programming is an interesting and effective tool for the development of large-scale programs built upon the Contextual Logic Programming paradigm and argue that contexts with arguments actually provide a powerful, expressive and very convenient means of structuring large applications upon a Prolog basis. We substantiate our claims with examples taken mostly from a “real world” application, Universidade de Évora’s Academic Information System, which is currently being developed using the prototype implementation described in this article.

We sketch the most relevant aspects of a new implementation of Contextual Logic Programming, GNU Prolog/CX, focusing on the impact on performance of the features which were added to a regular Prolog system, highlighting the low overhead which is incurred in case these extensions are not used.

  • Categories:. D.2.2–Modules and interfaces, D.1.6–Logic Programming, D.1.5–Object-oriented Programming.

  • General Terms:. Contextual Logic Programming.

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 99.00
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 129.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

  1. Abreu, S.: A Logic-based Information System. In: Pontelli, E., Santos Costa, V. (eds.) PADL 2000. LNCS, vol. 1753, pp. 141–153. Springer, Heidelberg (2000)

    Chapter  Google Scholar 

  2. Abreu, S.: Isco: A practical language for heterogeneous information system construction. In: INAP 2001. INAP (2001)

    Google Scholar 

  3. Bugliesi, M.: A declarative view of inheritance in logic programming. In: Apt, K. (ed.) Proceedings of the Joint International Conference and Symposium on Logic Programming, Washington, USA, pp. 113–127. The MIT Press, Cambridge (1992)

    Google Scholar 

  4. Bugliesi, M., Ciampolini, A., Lamma, E., Mello, P.: Optimizing modular logic languages. ACM Computing Surveys (CSUR) 30(3es), 10 (1998)

    Article  Google Scholar 

  5. Bugliesi, M., Lamma, E., Mello, P.: Modularity in Logic Programming. Journal of Logic Programming 19(20), 443–502 (1994)

    Article  MathSciNet  Google Scholar 

  6. Cabeza, D., Hermenegildo, M.: A New Module System for Prolog. In: Palamidessi, C., Moniz Pereira, L., Lloyd, J.W., Dahl, V., Furbach, U., Kerber, M., Lau, K.-K., Sagiv, Y., Stuckey, P.J. (eds.) CL 2000. LNCS (LNAI), vol. 1861, pp. 131–148. Springer, Heidelberg (2000)

    Chapter  Google Scholar 

  7. Denti, E., Lamma, E., Mello, P., Natali, A., Omicini, A.: Techniques for implementing contexts in Logic Programming. In: Lamma, E., Mello, P. (eds.) ELP 1992. LNCS, vol. 660, pp. 339–358. Springer, Heidelberg (1993)

    Google Scholar 

  8. Diaz, D., Codognet, P.: Design and implementation of the gnu prolog system. Journal of Functional and Logic Programming 2001(6) (October 2001)

    Google Scholar 

  9. Hill, P., Lloyd, J.: The Goedel Programming Language. MIT Press, Cambridge (1994) ISBN 0-262-08229-2

    MATH  Google Scholar 

  10. Lamma, E., Mello, P., Natali, A.: The design of an abstract machine for efficient implementation of contexts in logic programming. In: Levi, G., Martelli, M. (eds.) Proceedings of the Sixth International Conference on Logic Programming, Lisbon, pp. 303–317. The MIT Press, Cambridge (1989)

    Google Scholar 

  11. McCabe, F.G.: Logic and Objects. Prentice-Hall, Englewood Cliffs (1992)

    MATH  Google Scholar 

  12. Miller, D.: A logical analysis of modules in logic programming. The Journal of Logic Programming 6(1,2), 79–108 (1989)

    Article  MATH  Google Scholar 

  13. Monteiro, L., Porto, A.: A Language for Contextual Logic Programming. In: Apt, K.R., de Bakker, J.W., Rutten, J.J.M.M. (eds.) Logic Programming Languages: Constraints, Functions and Objects, pp. 115–147. MIT Press, Cambridge (1993)

    Google Scholar 

  14. Moura, P.: Logtalk web site, http://www.logtalk.org/

  15. Moura, P.: Logtalk 2.6 Documentation. Technical Report DMI 2000/1, University of Beira Interior, Portugal (2000)

    Google Scholar 

  16. Natali, A., Omicini, A.: Objects with State in Contextual Logic Programming. In: Penjam, J., Bruynooghe, M. (eds.) PLILP 1993. LNCS, vol. 714, pp. 220–234. Springer, Heidelberg (1993)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2003 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Abreu, S., Diaz, D. (2003). Objective: In Minimum Context. In: Palamidessi, C. (eds) Logic Programming. ICLP 2003. Lecture Notes in Computer Science, vol 2916. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-24599-5_10

Download citation

  • DOI: https://doi.org/10.1007/978-3-540-24599-5_10

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-20642-2

  • Online ISBN: 978-3-540-24599-5

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics