Abstract
This chapter is concerned with the declarative and procedural semantics of definite programs. First, we introduce the concept of the least Herbrand model of a definite program and prove various important properties of such models. Next, we define correct answers, which provide a declarative description of the desired output from a program and a goal. The procedural counterpart of a correct answer is a computed answer, which is defined using SLD-resolution. We prove that every computed answer is correct and that every correct answer is an instance of a computed answer. This establishes the soundness and completeness of SLD-resolution, that is, shows that SLD-resolution produces only and all correct answers. Other important results established are the independence of the computation rule and the fact that any computable function can be computed by a definite program. Two pragmatic aspects of PROLOG implementations are also discussed. These are the omission of the occur check from the unification algorithm and the control facility, cut.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Author information
Authors and Affiliations
Rights and permissions
Copyright information
© 1987 J. W. Lloyd
About this chapter
Cite this chapter
Lloyd, J.W. (1987). Definite Programs. In: Foundations of Logic Programming. Symbolic Computation. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-83189-8_2
Download citation
DOI: https://doi.org/10.1007/978-3-642-83189-8_2
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-642-83191-1
Online ISBN: 978-3-642-83189-8
eBook Packages: Springer Book Archive