Incremental Answer Completion in the SLG-WAM

  • Terrance Swift
  • Alexandre Miguel Pinto
  • Luís Moniz Pereira
Conference paper

DOI: 10.1007/978-3-642-02846-5_46

Part of the Lecture Notes in Computer Science book series (LNCS, volume 5649)
Cite this paper as:
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

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.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

Copyright information

© Springer-Verlag Berlin Heidelberg 2009

Authors and Affiliations

  • Terrance Swift
    • 1
  • Alexandre Miguel Pinto
    • 1
  • Luís Moniz Pereira
    • 1
  1. 1.Centro de Inteligência ArtificialUniversidade Nova de LisboaPortugal

Personalised recommendations