Skip to main content

Incremental Answer Completion in the SLG-WAM

  • Conference paper
Logic Programming (ICLP 2009)

Part of the book series: Lecture Notes in Computer Science ((LNPSE,volume 5649))

Included in the following conference series:

Abstract

The SLG-WAM of XSB Prolog soundly implements the Well-Founded Semantics (WFS) for logic programs, but in a few pathological cases its engine treats atoms as undefined that are true or false in WFS. The reason for this is that the XSB does not implement the SLG Answer Completion operation in its engine, the SLG-WAM – rather Answer Completion must be performed by post-processing the table. This engine-level omission has not proven significant for applications so far, but the need for Answer Completion is becoming important as XSB is more often used to produce well-founded residues of highly non-stratified programs. However, due to its complexity, care must be taken when adding Answer Completion to an engine. In the worst case, the cost of each Answer Completion operation is proportional to the size of a program P, so that the operation must be invoked as rarely as possible, and when invoked the operation must traverse as small a fragment as possible of P. We examine the complexity of Answer Completion; and then describe its implementation and performance in XSB’s SLG-WAM such that the invocations of the operation are restricted, and which is limited in scope to Strongly Connected Components within a tabled evaluation’s Subgoal Dependency Graph.

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 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.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. Chen, W., Warren, D.S.: Tabled Evaluation with Delaying for General Logic Programs. JACM 43, 20–74 (1996)

    Article  MathSciNet  MATH  Google Scholar 

  2. Pereira, L.M.: G Lopes. Prospective logic agents. In: Neves, J., Santos, M.F., Machado, J.M. (eds.) EPIA 2007. LNCS (LNAI), vol. 4874, pp. 73–86. Springer, Heidelberg (2007)

    Chapter  Google Scholar 

  3. Sagonas, K., Swift, T.: An abstract machine for tabled execution of fixed-order stratified logic programs. TOPLAS 20(3), 586–635 (1998)

    Article  Google Scholar 

  4. Sagonas, K., Swift, T., Warren, D.S.: The limits of fixed-order computation. Theoretical Computer Science 254(1-2), 465–499 (2000)

    Article  MathSciNet  MATH  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2009 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Swift, T., Pinto, A.M., Moniz Pereira, L. (2009). Incremental Answer Completion in the SLG-WAM. In: Hill, P.M., Warren, D.S. (eds) Logic Programming. ICLP 2009. Lecture Notes in Computer Science, vol 5649. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-02846-5_46

Download citation

  • DOI: https://doi.org/10.1007/978-3-642-02846-5_46

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-642-02845-8

  • Online ISBN: 978-3-642-02846-5

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics