signicant in view of the fact that in many applications existential queries are of main interest. It also plays an important role in the problem of nd

Similar documents
Splitting a Default Theory. Hudson Turner. University of Texas at Austin.

(A 3 ) (A 1 ) (1) COMPUTING CIRCUMSCRIPTION. Vladimir Lifschitz. Department of Computer Science Stanford University Stanford, CA

Minimal belief and negation as failure. A feasible approach. Antje Beringer and Torsten Schaub. FG Intellektik, TH Darmstadt, Alexanderstrae 10,

Generalized Closed World Assumption is ng-complete*

Combining explicit Negation and. Negation by Failure via Belnap's Logic. Francois FAGES. Paul RUET. Laboratoire d'informatique, URA 1327 du CNRS

A Preference Semantics. for Ground Nonmonotonic Modal Logics. logics, a family of nonmonotonic modal logics obtained by means of a

On 3-valued paraconsistent Logic Programming

An assumption-based framework for. Programming Systems Institute, Russian Academy of Sciences

Chapter 7. Negation: Declarative Interpretation

The non-logical symbols determine a specific F OL language and consists of the following sets. Σ = {Σ n } n<ω

Compositionality in SLD-derivations and their abstractions Marco Comini, Giorgio Levi and Maria Chiara Meo Dipartimento di Informatica, Universita di

Loop Formulas for Circumscription

Guarded resolution for Answer Set Programming

Applications of the Situation Calculus To Formalizing. Control and Strategic Information: The Prolog Cut Operator. Fangzhen Lin

Yet Another Proof of the Strong Equivalence Between Propositional Theories and Logic Programs

This second-order avor of default logic makes it especially useful in knowledge representation. An important question is, then, to characterize those

1 Introduction A general problem that arises in dierent areas of computer science is the following combination problem: given two structures or theori

is a model, supported model or stable model, respectively, of P. The check can be implemented to run in linear time in the size of the program. Since

From Constructibility and Absoluteness to Computability and Domain Independence

Computing the acceptability semantics. London SW7 2BZ, UK, Nicosia P.O. Box 537, Cyprus,

2 Z. Lonc and M. Truszczynski investigations, we use the framework of the xed-parameter complexity introduced by Downey and Fellows [Downey and Fellow

SOCLP: A Set Oriented Calculus for Logic Programming

Nested Epistemic Logic Programs

Definite Logic Programs

Propositional and Predicate Logic - V


Logic Part I: Classical Logic and Its Semantics

Extremal problems in logic programming and stable model computation Pawe l Cholewinski and Miros law Truszczynski Computer Science Department Universi

Boolean Algebra and Propositional Logic


Lloyd-Topor Completion and General Stable Models

Introduction to Logic in Computer Science: Autumn 2006

Logic Part II: Intuitionistic Logic and Natural Deduction

atoms should became false, i.e., should be deleted. However, our updates are far more expressive than a mere insertion and deletion of facts. They can

Duality in Logic Programming

Logic Programming Theory Lecture 7: Negation as Failure

( V ametavariable) P P true. even in E)

Loop Formulas for Disjunctive Logic Programs

Joxan Jaffar*, Jean-Louis Lassez'

INDEPENDENCE OF THE CONTINUUM HYPOTHESIS

Intelligent Agents. First Order Logic. Ute Schmid. Cognitive Systems, Applied Computer Science, Bamberg University. last change: 19.

Level mapping characterizations for quantitative and disjunctive logic programs

Boolean Algebra and Propositional Logic

COMP9414: Artificial Intelligence Propositional Logic: Automated Reasoning

Bottom-up Evaluation and Query Optimization of Well-Founded. Models. Abstract

Equivalence for the G 3-stable models semantics

Negation. Logic and Deductive Databases. Xuegang Wang. School of Computer Studies. The University of Leeds

WHAT REASONABLE FIRST-ORDER QUERIES ARE PERMITTED BY TRAKHTENBROT'S THEOREM? Arnon Avron and Joram Hirschfeld. Raymond and Beverly Sackler

Transformation Rules for Locally Stratied Constraint Logic Programs

First-Order Logic. Chapter Overview Syntax

Přednáška 12. Důkazové kalkuly Kalkul Hilbertova typu. 11/29/2006 Hilbertův kalkul 1

SLD-Resolution And Logic Programming (PROLOG)

1 Introduction We study classical rst-order logic with equality but without any other relation symbols. The letters ' and are reserved for quantier-fr

[36] K.A. Ross. A procedural semantics for well founded negation in logic programs. In ACM

Advanced Topics in LP and FP

System f2lp Computing Answer Sets of First-Order Formulas

3. Only sequences that were formed by using finitely many applications of rules 1 and 2, are propositional formulas.

CS632 Notes on Relational Query Languages I

Reasoning: From Basic Entailments. to Plausible Relations. Department of Computer Science. School of Mathematical Sciences. Tel-Aviv University

On the Stable Model Semantics for Intensional Functions

Halting and Equivalence of Program Schemes in Models of Arbitrary Theories

Strong AI vs. Weak AI Automated Reasoning

Logic: Propositional Logic (Part I)

Design of abstract domains using first-order logic

Reduction of abductive logic programs. In this paper we study a form of abductive logic programming which combines

Seminaar Abstrakte Wiskunde Seminar in Abstract Mathematics Lecture notes in progress (27 March 2010)

Two New Definitions of Stable Models of Logic Programs with Generalized Quantifiers

Completeness in the Monadic Predicate Calculus. We have a system of eight rules of proof. Let's list them:

A Proof-Theoretic Approach to Irrelevance: Richard E. Fikes. KSL, Stanford University. et al., 1994b].

Preservation Properties in Deductive Data Bases

rules strictly includes the class of extended disjunctive programs. Interestingly, once not appears positively as above, the principle of minimality d

arxiv: v1 [cs.lo] 8 Jan 2013

A note on fuzzy predicate logic. Petr H jek 1. Academy of Sciences of the Czech Republic

Restricted truth predicates in first-order logic

CS411 Notes 3 Induction and Recursion

Computational Logic Fundamentals (of Definite Programs): Syntax and Semantics

Syntactical characterization of a subset of Domain. Independent Formulas ONERA-CERT Toulouse FRANCE.

From Logic Programming Semantics to the Consistency of Syntactical Treatments of Knowledge and Belief

COMP 182 Algorithmic Thinking. Proofs. Luay Nakhleh Computer Science Rice University

2 Transition Systems Denition 1 An action signature consists of three nonempty sets: a set V of value names, a set F of uent names, and a set A of act

Subclasses of Quantied Boolean Formulas. Andreas Flogel. University of Duisburg Duisburg 1. Marek Karpinski. University of Bonn.

arxiv:cs/ v1 [cs.lo] 25 Jan 2005

Description Logics. Foundations of Propositional Logic. franconi. Enrico Franconi

Knowledge Discovery. Zbigniew W. Ras. Polish Academy of Sciences, Dept. of Comp. Science, Warsaw, Poland

Two-Valued Logic Programs

CHAPTER 2. FIRST ORDER LOGIC

2 1. INTRODUCTION We study algebraic foundations of semantics of nonmonotonic knowledge representation formalisms. The algebraic framework we use is t

Model Generation and State Generation for Disjunctive Logic. Programs. University of Tubingen. Sand 13, D { Tubingen, Germany

Closed Book Examination. Two hours UNIVERSITY OF MANCHESTER SCHOOL OF COMPUTER SCIENCE. M.Sc. in Advanced Computer Science

Trichotomy Results on the Complexity of Reasoning with Disjunctive Logic Programs

Preduction: A Common Form of Induction and Analogy

model semantics of [5] can be faithfully embedded in fuzzy logic programs under our stable semantics. 2 Preliminaries A predicate logic signature = hr

Syntactic Characterisations in Model Theory

Solvability of Word Equations Modulo Finite Special And. Conuent String-Rewriting Systems Is Undecidable In General.

Foundations of Mathematics MATH 220 FALL 2017 Lecture Notes

The Intensional Implementation Technique for Chain. Datalog Programs. P.O. BOX 1186, Ioannina, Greece, A. Paraskevi Attikis, Greece

Propositional Logic Language

A Brief Introduction to Nonmonotonic Reasoning

denition is that the space X enters the picture only through its poset of open subsets and the notion of a cover. Grothendieck's second basic observat

2 SUMMARISING APPROXIMATE ENTAILMENT In this section we will summarise the work in (Schaerf and Cadoli 995), which denes the approximate entailment re

Transcription:

On the Relationship Between CWA, Minimal Model and Minimal Herbrand Model Semantics Michael Gelfond Halina Przymusinska Teodor Przymusinski March 3, 1995 Abstract The purpose of this paper is to compare three types of non-monotonic semantics: (a) proof-theoretic semantics based on the closed world assumption, (b) model-theoretic semantics based on the notion of a minimal model and (c) model-theoretic semantics based on the notion of a minimal Herbrand model. All of these semantics capture the non-monotonicity of common sense reasoning, i.e. the ability to withdraw conclusions after some new information is added to the original theories, and proved to be powerful enough to handle most examples of such reasoning presented in the literature. However, since these formalizations are based on dierent intuitions and often produce dierent results, the problem of understanding the relationship between them is especially important. In the rst part of the paper we concentrate on the class of positive logic programs, also called denite theories. Although the three semantics usually dier for universal sentences, our main result shows that they always coincide for existential queries. This result is particularly The extended abstract of this paper appeared in the Proceedings of the Third International Symposium on Methodologies for Intelligent Systems, Torino, Italy, October 1988. 1

signicant in view of the fact that in many applications existential queries are of main interest. It also plays an important role in the problem of nding a suitable declarative semantics for logic programs. In the second part we investigate arbitrary universal theories and we show that subtle dierences exist between the three approaches and therefore no straightforward generalization of the results from the rst part can be obtained. 1 Introduction A non-monotonic declarative semantics of a given theory T { whether it is a logic program or a deductive database { can be dened in several dierent ways, among which the following two are most common. One that can be called proof-theoretic, associates with T a rst order theory COMP(T) called a completion of T and declares that a given sentence F is true i it is logically implied by COMP(T), i.e. if COMP (T ) j= F. An important example of such a denition is Reiter's Closed World Assumption CWA(T) [21], obtained by adding to T negations of all ground atoms not provable from T. Like its more broadly applicable generalizations { such as GCWA(T) and ECWA(T) [17, 26, 6, 7, 8] { it is based on the idea of adding to the theory a suitably selected set of ground formulae, which are not derivable from the theory itself. Another approach, that can be called model-theoretic, associates with T a set MOD(T) of one or more models of T and declares that a given sentence F is true i it is satised in all models from MOD(T). Important examples of such an approach are the minimal model semantics based on the set MIN(T) of all minimal models of the theory [15, 17, 2, 19] and the least model semantics based on the least Herbrand model M T of the theory [25, 1]. The semantics of circumscription CIRC(T) and domain circumscription DCIRC(T) [15, 16, 10] allow powerful generalizations of these two semantics, by using more specialized classes of minimal (or minimal Herbrand) models. The purpose of our paper is to compare three of the above discussed types of semantics: I. The proof-theoretic semantics based on the closed world assumption; II. The model-theoretic semantics based on the notion of a minimal model; 2

III. The model-theoretic semantics based on the notion of a minimal Herbrand model. In general, these approaches lead to essentially dierent semantics. Since semantics of type I are obtained by adding negations of only ground formulae and semantics of type III use only Herbrand models, they tend to handle formulae with variables dierently from the way they are handled by semantics of type II. Semantics of type I and III do not coincide either, because Herbrand model semantics imply the Domain Closure Axiom, while semantics based on the closed world assumption do not. All of these semantics capture the non-monotonicity of common sense reasoning, i.e. the ability to withdraw conclusions after some new information is added to the original theories and proved to be powerful enough to handle most examples of such reasoning presented in the literature. However, since these formalizations are based on dierent intuitions and often produce different results, the problem of understanding the relationship between them is especially important. Throughout the paper we assume a suitable form of the Unique Names Assumption, namely the so called Clark`s Equality Theory CET. We rst concentrate on the important class of positive logic programs P, also called denite theories. We compare Reiter's Closed World Assumption CWA(P), the minimal model semantics MIN(P) and the least model semantics M P. Although these semantics usually dier for universal sentences, our main result shows that they always coincide for existential sentences. This shows that for an important class of queries { namely existential { the results produced by any one of these semantics are exactly identical. This result is not only important in the context of non-monotonic reasoning, but it also plays an important role in the problem of nding a proper declarative semantics for logic programs [18, 19, 20]. It is also signicant in view of the fact that in many applications existential queries are of main interest. In the second part of the paper we discuss the relationship between semantics of types I { III mentioned above for arbitrary universal theories T. The most general formalization of the semantics of type I is called the Extended Closed World Assumption ECWA(T) and was introduced and investigated in [7, 8]. It generalizes Minker's GCWA(T) [17]. On the other hand, general forms of semantics of type II and III were captured by the notions of McCarthy's Parallel Circumscription CIRC(T) and Domain Circumscription 3

DCIRC(T) [15, 16, 10]. We give a semantic characterization of ECWA and use it to compare the deductive powers of ECWA, Parallel Circumscription and Domain Circumscription. We show that subtle dierences exist between these semantics and therefore no straightforward generalization of the results from the rst part can be obtained. We prove, however, several results relating the three semantics for ground queries. The work presented in this paper can be viewed as a continuation of the work started in [6, 7, 8] (see also [11]), where it was shown that, for a theory T without function symbols, with nite number of constants and the Domain Closure Assumption (DCA) [22], the Extended Closed World Assumption ECWA(T), Parallel Circumscription CIRC(T) and Domain Circumscription DCIRC(T) are all equivalent. However, the assumption that a theory T has no function symbols, only a nite number of constants and satises the DCA is very strong and eectively restricts us to propositional theories, which are clearly inadequate for many applications. Throughout this paper we allow functional symbols and innitely many constants and we do not make any domain closure assumptions. 2 Notation and denitions By a positive logic program we mean a nite set of universally quantied clauses of the form A A 1 ; :::; A m where m 0 and A and A i are atoms. The alphabet of a program P consists of all the constant, predicate and function symbols that appear in P, a countably innite set of variable symbols and the usual punctuation symbols, connectives (^; _; :) and quantiers (9; 8). We assume that equality predicate = does not occur in P and if there are no constants in P, we add one to the alphabet. The language of P consists of all the well-formed formulae of the so obtained rst order theory. Names of variables are capitalized and functions, constants and predicates are written in lower case. Constants are identied with functions of arity zero. A formula is called positive if it does not contain the negation symbol :. For a formula F, by 9F and 8F we denote its existential or universal closure, respectively. Unless stated otherwise, all formulae are universally quantied. 4

By an existential (resp. universal) formula we mean a formula F of the form F = 9G (resp. F = 8G), where G is a quantier-free formula. By Clark's Equational Theory of P (CET(P)) [9], we mean the theory P augmented with the equality predicate = and the following set of axioms, called CET axioms: CET1. X = X ; CET2. X = Y ) Y = X ; CET3. X = Y ^ Y = Z ) X = Z; CET4. X 1 = Y 1 ^ ::: ^ X m = Y m ) f(x 1 ; :::; X m ) = f(y 1 ; :::; Y m ); for any function f; CET5. X 1 = Y 1 ^ ::: ^ X m = Y m ) (p(x 1 ; :::; X m ) ) p(y 1 ; :::; Y m )); for predicate p; CET6. f(x 1 ; :::; X m ) 6= g(y 1 ; :::; Y n ); for any two dierent function symbols f and g; CET7. f(x 1 ; :::; X m ) = f(y 1 ; :::; Y m ) ) X 1 = Y 1 ^ ::: ^ X m = Y m ; for any function f; CET8. t[x] 6= X; for any term t[x] dierent from X, but containing X. The rst ve axioms describe the usual equality axioms and the remaining three axioms are called unique names axioms or freeness axioms. The signicance of these axioms to logic programming is widely recognized [13, 23, 24, 14, 9]. Consequently, instead of talking about the theory P we will talk about the theory CET (P ) = P + CET. The equality axioms (CET1) { (CET5) ensure that we can always assume that the equality predicate = is interpreted as identity in all models of CET(P). Consequently, models of CET(P) can be identied with precisely those models of P in which the equality predicate { when interpreted as identity { satises the unique names axioms (CET6) { (CET8). This means that models of CET(P) can simply be viewed as a subclass of the class of all models of P. We do not assume any domain closure axioms and we consider all { not necessarily Herbrand { models of the theory CET(P). Since the unique names 5

axioms are automatically satised in Herbrand models, Hebrand models of CET(P) can be identied with Herbrand models of P, in which equality is interpreted as identity. Herbrand models of P are as usual considered to be subsets of the Herbrand base of P, i.e. the set of all ground atoms of the theory P. If M and N are two models of CET(P) with the same universe and the same interpretation of functions (and constants) then we say that M N, if the extension of every predicate in M is contained in its extension in N. A model N of CET(P) is called minimal if there is no model M of CET(P) such that M N and M 6= N. It is well-known that for every model M of CET(P) there is a minimal model N such that N M [2]. It is easy to see that a model M is a minimal model of CET(P) i it is a model of CET(P) and a minimal model of P. It is also well-known that every positive logic program P has exactly one minimal Herbrand model M P, which is called the least Herbrand model of P [25, 1]. This model { with equality = interpreted as identity { can be thought of as the least Herbrand model of CET(P). By MIN(P) we denote the set of all minimal { not necessarily Herbrand { models of CET(P). By a minimal model semantics of P we mean the semantics induced by the set MIN(P). Under this semantics a formula F of the language of P is considered to be true i F is satised in all minimal models from MIN(P). In this case we write MIN(P ) j= F. By the least model semantics of a positive program P we mean the semantics induced by the model M P. Under this semantics a formula F of the language of P is considered to be true i F is satised in M P, i.e. if M P j= F. By the CWA-semantics of a positive program P [21] we mean the semantics induced by the completion CWA(P) of P dened by CW A(P ) = P [ CET [ f:a: A is a ground atom and P 6j= Ag. Under this semantics a formula F of the language of P is considered to be true i CW A(P ) j= F. Note, that all formulae are supposed to belong to the language of P and therefore they do not contain the equality predicate. Suppose that M is any model of CET(P) with universe U and equality = interpreted as identity. For every tuple (u 1 ; : : : ; u n ) of elements of U and an n-ary function f we denote by b f the interpretation b f : U n 7?! U of f in M and therefore b f(u 1 ; : : : ; u n ) 2 U denotes the image of (u 1 ; : : : ; u n ) under bf. Constants are considered to be functions of arity 0. Similarly, by b A we denote the interpretation b A : U n 7?! f>;?g of a predicate symbol A. By T erms(x) we denote the set of all terms of the language whose variables 6

belong to the set X. 3 Technical Lemmas In the next section the following two technical lemmas will play a crucial role. Their proofs are fairly complex and therefore they were included in a separate section. Lemma 3.1 Suppose that M is a model of CET(P) with universe U and X and Y are nite sets of variables. Suppose also that, for i n, i : X 7?! T erms(y ) is a substitution and : Y 7?! U is a U-instantiation such that for every i; j n: i = j : Then, there exists a unication : Y 7?! T erms(y ) such that for every i; j n: i = j and = : Proof: We will prove the lemma for n=2. The general case can then be obtained by easy induction. Let us suppose therefore that X = fx 1 ; : : : ; x m g and let i (x j ) = t ij. We have 8 j m t 1j = t 2j : (1) We will show that the standard unication algorithm { applied consecutively to pairs of terms ft 1i ; t 2i g { always succeeds and therefore produces the desired unication. For a more detailed description of the unication algorithm, see [4]. Let us start with an empty substitution, take the rst pair of terms T 1 = ft 11 ; t 21 g and try to nd the rst disagreement set of T, i.e. a pair fs 1 ; s 2 g of subterms of terms t 11 and t 21, respectively, located by nding the rst symbol at which terms t 11 and t 21 disagree and then extracting the terms beginning with those symbols. If such a disagreement set cannot be found, then the terms t 11 and t 21 are already identical and we can move to the next pair T 2 = ft 12 ; t 22 g and continue in the same fashion. Otherwise, observe that from formula (1) and axiom (CET7) it follows that s 1 = s 2 : (2) 7

Consequently { in view of axiom (CET6) { these two terms cannot dier by having dierent principal function symbols and therefore at least one of them, say s 1 must be a variable, say, y. It follows from axiom (CET8) and formula (2) that the variable y does not occur in the term s 2. Therefore, we add the substitution fyjs 2 g of the term s 2 for the variable y to our substitution and replace variable y by s 2 in all the terms t i;j. Now, we try to nd the rst disagreement set in the newly obtained, substituted terms t 0 11 and t 0 21 and continue the algorithm. It is well-known that the unication algorithm always terminates and since it never fails, from the Unication Theorem (see [4]) it follows that it produces the desired unication. The equality = follows immediately from formula (2). 2 Lemma 3.2 Suppose that M is a minimal model of CET(P) with universe U. Suppose that A(t 1 ; : : : ; t n ) is an atom, whose variables belong to the nite set X and : X 7?! U is a U-instantiation such that A(t1 b ; : : : ; t n ) = >. Then there exists a set Y of variables, a substitution : X 7?! T erms(y ) and a U- instantiation : Y 7?! U such that: Proof: We will call the set P j= (8)A(t 1 ; : : : ; t n ) and = : B = fa(u 1 ; : : : ; u n ) : A is a predicate symbol, u 1 ; : : : ; u n 2 Ug of formal terms A(u 1 ; : : : ; u n ) the base of M. It is clear that { assuming xed universe U and xed interpretation of functions { we can identify the model M with the following subset M of B: M = fa(u 1 ; : : : ; u n ) 2 B : b A(u1 ; : : : ; u n ) = >g: We will now dene an increasing innite sequence B i ; i = 1; 2; : : : of subsets of B such that M = [ B i : 8

Let B 0 = ; and having dened B m let us dene B m+1 as follows: B m+1 = B m [ fa(t 1 ; : : : ; t n ) : there is a clause in P A(t 1 ; : : : ; t n ) A 1 (t 11 ; : : : ; t n1 ); : : : ; A k (t 1k ; : : : ; t nk ); k 0; and a U-instantiation such that 8i A i (t 1i ; : : : ; t ni ) 2 B m g: Now we show that M = N ; where N = [ i<1 B i: It follows easily from the fact that M is a model of P that M N : Since M is a minimal model of CET(P), in order to show that M N it suces to show that the unique interpretation N of CET(P) determined by the set N is a model of CET(P). Suppose that A(t 1 ; : : : ; t n ) A 1 (t 11 ; : : : ; t n1 ); : : : ; A k (t 1k ; : : : ; t nk ) is a clause in P. In order to show that the above clause is satised in N we have to show that for every U-instantiation either b A(t 1 ; : : : ; t n ) = > in N or there is an i such that b A i (t 1i ; : : : ; t ni ) =? in N. Suppose therefore that for every i we have b A i (t 1i ; : : : ; t ni ) = > in N or { in other words { suppose that for every i we have: A i (t 1i ; : : : ; t ni ) 2 N : There exists therefore an m such that for all i we have: A i (t 1i ; : : : ; t ni ) 2 B m : From the denition of B m+1 it follows now that A(t 1 ; : : : ; t n ) 2 B m+1 N and therefore A(t b 1 ; : : : ; t n ) = > in N, which shows that M = N. Now we can complete the proof of Lemma 3.2. Suppose that A(t 1 ; : : : ; t n ) is an atom, whose variables belong to the nite set X and : X 7?! U is a U-instantiation such that A(t b 1 ; : : : ; t n ) = > in M. This means that E = A(t 1 ; : : : ; t n ) 2 M = S B i and therefore E 2 B m, for some m. We 9

have to show that there exists a substitution : X 7?! T erms(y ) and a U-instantiation : Y 7?! U such that: P j= (8)A(t 1 ; : : : ; t n ) and = : (3) The proof is by induction on m. If m=0, then { since B 0 = ; { there is nothing to prove. Suppose now that the above fact has been proven for E 2 B m. We will prove it for E 2 B m+1. By denition, there exists in P a clause A(s 1 ; : : : ; s n ) A 1 (s 11 ; : : : ; s n1 ); : : : ; A k (s 1k ; : : : ; s nk ); k 0 whose variables belong to a nite set X 0 and a U-instantiation 0 : X 0 7?! U such that 8i A i (s 1i ; : : : ; s ni ) 0 2 B m and A(t 1 ; : : : ; t n ) = A(s 1 ; : : : ; s n ) 0 : (4) Consequently, 8i t i = s i 0 : (5) First of all, we will show that there exists a substitution! 0 : X 0 7?! T erms(y 0 ) and a U-instantiation 0 : Y 0 7?! U such that: P j= (8)A(s 1 ; : : : ; s n )! 0 and! 0 0 = 0 : (6) From formula (4) and the inductive assumption it follows that for every i ) and a U-instantiation 7?! U such that: i there exists a substitution 0 i : X 0 7?! T erms(y 0 0 i : Y 0 i P j= (8)A i (s 1i ; : : : ; s ni ) 0 i and 0 i 0 i = 0 : (7) We can clearly assume that the sets Y 0 i are mutually disjoint and disjoint from X (otherwise, we can use renaming substitutions) and let Y 0 = S Y 0 i. Dene 0 : Y 0 7?! U as a combination (union) of instantiations i. 0 Then for every i; j k we have: 00 i = 0 0 j = 0 : By Lemma 3.1 there exists a substitution 0 : Y 0 7?! T erms(y 0 ) such that for every i; j n: 0 i 0 = 0 j 0 =! 0 10

and 0 0 = 0 and hence! 0 0 = 0 i 0 0 = 0 i 0 = 0 : By formula (7) P j= (8)A i (s 1i ; : : : ; s ni ) 0 i and therefore also P j= (8)A i (s 1i ; : : : ; s ni ) 0 i 0 and thus 8i we have that P j= (8)A i (s 1i ; : : : ; s ni )! 0 and therefore P j= (8)A(s 1 ; : : : ; s n )! 0 ; which proves claim (6). Now, to complete the proof we dene v i = s i! 0 and observe that from formulae (5) and (6) it follows that for all i v i 0 = s i! 0 0 = s i 0 = t i : (8) Let W = fw 1 ; : : : ; w n g be any set of n variables disjoint from Y, where Y = X [Y 0 (recall, that X and Y 0 are disjoint sets). Dene two substitutions 1 : W 7?! T erms(x) and 2 : W 7?! T erms(y 0 ) as follows: 1 (w i ) = t i ; 2 (w i ) = v i = s i! 0 and let : Y 7?! U be a combination (union) of U-instantiations and 0. Then by formula (8) we have: 1 = 1 = 2 0 = 2 and therefore by Lemma 3.1 there exists a substitution 0 : Y 7?! T erms(y ) such that: 1 0 = 2 0 =! and 0 = : Since by formula (6) P j= (8)A(s 1 ; : : : ; s n )! 0 we therefore also have that P j= (8)A(s 1 ; : : : ; s n )! 0 0 and therefore since s i! 0 0 = t i 0 we have: P j= (8)A(t 1 ; : : : ; t n ) 0 : Dene : X 7?! T erms(y ) to be the restriction of 0 to the set X. Then from the previous formula and the fact that by denition the restriction of to X is equal to we get: P j= (8)A(t 1 ; : : : ; t n ) and = = ; which shows that formula (3) holds and thus completes the proof of the lemma. 2 11

4 Minimal Model Semantics, Least Model Semantics and CWA for Positive Logic Programs Throughout this section we assume that P is a positive logic program. Our rst theorem states that the minimal model semantics MIN(P ) for P is categorical for positive existential formulae F, in the sense that either P j= F and then obviously also MIN(P ) j= F, or otherwise MIN(P ) j= :F. Theorem 4.1 Suppose that F is a positive existential formula. Then P 6j= F () MIN(P ) j= :F: Proof: Suppose that F is a positive existential formula and suppose that MIN(P ) 6j= :F. We have to show that P j= F. Without loss of generality, is represented we may assume that F = (9)G, where G = G 1 ^ : : : ^ G m as a conjunction of positive clauses G i and let X be the set of all variables occurring in G. There must exist a minimal model M of P with universe U such that M j= F. Consequently, there is a U-instantiation : X 7?! U such that G is true in M. For every i m we can therefore nd an atom A i (t 1i ; : : : ; t ni ) belonging to G i and such that ca i (t 1i ; : : : ; t ni ) = >: By Lemma 3.2, for every i there exists a substitution i : X 7?! T erms(y i ) and a U-instantiation i : Y i 7?! U such that: P j= (8)A i (t 1i ; : : : ; t ni ) i and i i = : We can clearly assume that the sets Y i are disjoint (otherwise, we can use renaming substitutions) and let Y = S Y i. Let : Y 7?! U be a combination of U-instantiations i. By Lemma 3.1 there exists a substitution : Y 7?! T erms(y ) such that for every i; j n: i = j =!: Since P j= (8)A i (t 1i ; : : : ; t ni ) i therefore also P j= (8)A i (t 1i ; : : : ; t ni ) i and thus for all i we have that P j= (8)A i (t 1i ; : : : ; t ni )! and therefore P j= (8)G!, 12

which implies that P j= (9)G and therefore P j= F, which completes the proof. 2 The following example illustrates the assumptions used. Example 4.1 1. The assumption that F is positive is essential. Indeed, if P is given by a single clause p(a) and F = 9x:p(x), then P 6j= F and yet MIN(P ) 6j= :F. 2. The assumption that F is existential is also essential. Indeed, if P is as above and F = 8xp(x), then P 6j= F and yet MIN(P ) 6j= :F. 3. The assumption that P is a positive logic program is essential. Indeed, if P consists of clauses p(a) and q(a) : p(x) and F is a positive ground formula q(a), then P 6j= F and yet MIN(P ) 6j= :F. 4. The assumption that only models of CET(P) are considered is also essential. Indeed, if P consists of clauses p(a) and q(a) p(f(x)) and F is a positive ground formula q(a), then P 6j= F and yet there exist minimal models of P in which F holds, because in some minimal models of P we may have e.g. a = f(a): 2 The following corollary shows that for positive existential formulae F the minimal model semantics MIN(P) of P is equivalent to the least model semantics M P and that both are fully determined by the provability or nonprovability of F from P itself. Corollary 4.2 Suppose that F is a positive existential formula. Then P j= F () MIN(P ) j= F () M P j= F and P 6j= F () MIN(P ) j= :F () M P j= :F: Proof: This is an easy consequence of Theorem 4.1. 2 Example 4.1 shows that all assumptions in the above Corollary are essential. Our main result shows that for all existential { positive or negative { formulae F all three semantics { the minimal model semantics MIN(P), 13

the least Herbrand model semantics M P and the CWA-semantics CWA(P) { are equivalent. As shown by Example 4.1, though, they may no longer be determined simply by the provability or non-provability of F from P. Theorem 4.3 (Main) Suppose that F is an existential formula. Then MIN(P ) j= F () M P j= F () CW A(P ) j= F: Proof: Let F = 9~xG and let G be represented as a conjunction of clauses G i ; i n. Clearly, if MIN(P ) j= F then M P j= F. Suppose now that M P j= F. Since M P represents a unique model, there must exist a ground substitution such that M P j= G. For every i n there exist literals l i in G i such that M P j= l i. If l i is positive, then { by Corollary 4.2 { MIN(P ) j= l i. If l i is negative, then l i = :A i, where A i is an atom and M P j= :A i. Again { by Corollary 4.2 { it follows that MIN(P ) j= :A i and therefore MIN(P ) j= l i, for all i's. Consequently, MIN(P ) j= G and therefore MIN(P ) j= F. If CW A(P ) j= F, then clearly M P j= F, because M P is a model of CWA(P). On the other hand, if M P j= F then there is a ground substitution such that M P j= F and therefore CW A(P ) j= F. 2. Notice, that the above proof shows that for an existential formula F we have that MIN(P ) j= F i there is a ground substitution such that MIN(P ) j= F. Corollary 4.4 Suppose that F is a ground formula. Then MIN(P ) j= F () M P j= F () CW A(P ) j= F and MIN(P ) j= :F () M P j= :F () CW A(P ) j= :F: 2 The above two results are important, because they conrm that, as far as ground or existential information is concerned, using CWA(P), all minimal models or just the unique least Herbrand model produces exactly the same results. On the other hand, it is easy to see that for universal formulae the three approaches are no longer equivalent (cf. Example 4.1). 14

5 Circumscription, Domain Circumscription and ECWA for Universal Theories Throughout this section we will consider an arbitrary universal theory T augmented by the axioms CET1 { CET8 from Section 2. Such theories will be called CET theories. Suppose that T is a CET theory and P = fp 1 ; :::; p m g and Z = fz 1 ; :::; z n g are disjoint lists of predicate symbols from the language of T. The predicate symbols from Z are called variables. Literals with predicate symbols not in Z [ P and positive literals with predicate symbols from P will be called marked literals. Denition 5.1 Let K be an arbitrary ground formula not containing predicate symbols from Z. K is called free for negation in T if there exists no disjunction B = B 1 _ ::: _ B n, consisting of marked literals, such that (i) T j= K _ B; (ii) T 6j= B. 2 Denition 5.2 The Extended Closed World Assumption of T w.r.t. P and Z is the theory ECWA(T;P;Z) dened as follows: ECWA(T;P;Z) = T [CET [ f:k : K is free for negation in Tg. 2 Whenever it does not lead to a confusion we will use ECWA instead of ECWA(T;P;Z). To clarify the above denitions let us consider the following example. Example 5.1 Let T be a CET theory consisting of the following statements: Block(A 1 ); Block(A 2 ); Block(A 3 ) Hot(A 1 ; S 0 ) _ Hot(A 2 ; S 0 ) Hot(x; s) :Hot(x; s)! Hot(x; result(move; x; s))! M oved(x; result(move; x; s)) These axioms describe a system of blocks A 1 ; A 2 ; A 3. The second axiom says that in the initial situation S 0, at least one of the blocks A 1 and A 2 is believed to be hot, the third axiom states that movement of blocks has 15

no impact on their temperature, while the fourth axiom guarantees that if a block x is not hot in a situation s then the operation of moving x will be successful (here result(move,x,s) is a situation term denoting the situation in which the system will nd itself after the operation move is performed on x). We would like to assume that a block x is not hot unless we have some evidence to the contrary. This informal assumption will allow us to conclude that statement :Hot(A 3 ; s) is true while preventing us from making any conclusions about the temperature of the remaining blocks. It is easy to see that if P = fhotg and Z=fMovedg then for any situation term S, Hot(A 3 ; S) is free for negation in T while Hot(A 1 ; S); Hot(A 2 ; S) are not. Consequently, unlike :Hot(A 1 ; S) and :Hot(A 2 ; S); :Hot(A 3 ; S) belongs to ECWA(T;P;Z). Consider now a statement Hot(A 1 ) ^ Hot(A 2 ). It is easy to see that it is also free for negation in T, hence its negation is in ECWA. This shows that ECWA turns an inclusive disjunction in the second axiom of T into an exclusive one. 2 To review the notion of Circumscription let us recall the following definitions. By p M we denote the extension of the predicate p in the model M. Denition 5.3 ([16, 10, 5]) For any two models M and N of T we write M N modulo (P,Z) if models M and N dier only in how they interpret predicates from P and Z and if for every predicate p from P, p M p N. 2 Denition 5.4 A model M of T is (P,Z)-minimal if there is no model N such that N < M (i.e. such that N M but not M N). 2 Denition 5.5 A second order theory CIRC(T;P;Z) is called a Circumscription (resp. Domain Circumscription) of T with P minimized and Z varied if a structure (resp. Herbrand structure) M is a model of CIRC(T;P;Z) (resp. DCIRC(T;P;Z)) i M is a (P,Z)-minimal model (resp. Herbrand model) of T. 2 For more detailed discussion see [10]. The following theorem relates a syntactic denition of ECWA to the notion of a (P,Z)-minimal model of T. Theorem 5.1 For any ground formula F not containing predicates from Z, F is free for negation in T i :F is true in all (P;Z)-minimal Herbrand models of T. 16

Proof: ( ) Let us assume that F is not free for negation and therefore there exists a disjunction B = B 1 _ :::_B n consisting of marked literals, such that T j= F _ B and T 6j= B. We will show that this implies the existence of a (P,Z)-minimal Herbrand model for the theory T in which F is true. Since T 6j= B and the theory T is universal, in virtue of Lemma 3.3 in [6] there exists a Herbrand model N for T in which :B is satised. Let M be any (P,Z)-minimal Herbrand model of T such that M N modulo (P,Z). The existence of such an M is guaranteed by Theorem 4.2 in [12]. Since :B contains only marked literals and M is (P,Z) minimal the sentence :B also has to be satised in M. Our assumption that T j= F _ B now implies that M j= F. (!) We assume now that there is a (P,Z)-minimal Herbrand model M 0 of T such that M 0 j= F and we will show that this assumption implies that F is not free for negation. First we show that for an arbitrary Herbrand model N for T such that N 6j= F we can nd a marked literal B N such that N j= B N and M 0 6j= B N. If for every predicate symbol not in Z its extensions in N and in M 0 are identical, then N j= F because no predicates from Z are in F. Since this is impossible by the denition of N, there is a predicate symbol A not in Z, whose extensions in N and M 0 are not equal. Consider two cases. If we can nd such an A which does not belong to P then we can nd a literal B N, whose predicate symbol does not belong to P [ Z and such that N j= B N and M 0 6j= B N. Otherwise, we can nd such an A in P and in this case for each predicate symbol not in P [ Z its extensions in N and M 0 are identical. Since M 0 is (P,Z)-minimal, there must exist a positive literal B N with predicate symbol in P, such that N j= B N and M 0 6j= B N. If this were not the case then we would have N M 0 and since M 0 is a (P,Z)-minimal model, this would imply that N and M have the same extensions for all predicate symbols not belonging to Z. Let B = fb N : N is a model of T such that N 6j= Fg and let L be a possibly innite disjunction of all literals in B. Clearly, for every Herbrand model N of T, F _ L holds in N and therefore by Lemma 3.4 in [6] there is a nite subdisjunction E of L such that T j= F _ E. If E is empty then F is true in all Herbrand models and therefore in all models of T and can not be free for negation. On the other hand, if E is not empty then T 6j= E, because M 0 j= :E. This shows that F is not free for negation and completes the proof. 2 17

As the following example shows the assumption that there are no predicates from Z in F is essential. Example 5.2 Consider a theory T = fp(x) _ p(f(x)); p(x) _ q(a)g, where p belongs to P, q belongs to Z and F is :q(a). It is easy to see that for any ground term t, there is a disjunction B = p(t) _ p(f(t)) which satises the conditions from Denition 5.1 and therefore p(t) is not free for negation in T and hence ECW A 6j= q(a). On the other hand any (P,Z)-minimal model M of T contains q(a), since otherwise for all ground terms t, p(t) would belong to M which contradicts (P,Z)-minimality of M. Therefore :F is true in all minimal (P,Z) models of T. 2 Now we will discuss the relationship between ECWA, CIRC and DCIRC for CET theories. We will start with CIRC and DCIRC. By denition, for every formula F if CIRC j= F then DCIRC j= F. The following example shows that even for ground formulas DCIRC is essentially stronger than CIRC. Example 5.3 Let T = fp(a); p(x) _ r(a)g, where both p and r belong to P. It is easy to see that DCIRC j= :r(a), while CIRC 6j= :r(a). To see why the latter is true let us consider the universe U = fa,wg and a structure M such that p M = fag and r M = fag. This structure is a minimal model of T and therefore CIRC 6j= :r(a). Next, we discuss the relationship between ECWA and DCIRC. The following theorem shows that for ground formulae DCIRC is always stronger than ECWA. Theorem 5.2 For any ground formula F, if ECW A j= F then DCIRC j= F. Proof: Let F be an arbitrary ground formula such that ECW A j= F. It follows from the Denition 4.2 that F is true in any Herbrand model of T in which all free for negation formulas are false. In virtue of Theorem 4.1, all free for negation formulas are false in all (P,Z)-minimal Herbrand models of T and therefore DCIRC j= F. 2 Example 5.2 shows that in the above Theorem the implication in the opposite direction does not always hold. 18

However, the following result shows that ECWA and DCIRC coincide for ground formulae not containing predicates from Z. Theorem 5.3 ECWA and DCIRC coincide for ground formulae not containing predicates from Z. Proof: Implication in one direction follows from Theorem 4.2. We have to show that for an arbitrary ground formula F not containing predicates from Z if DCIRC j= F then ECW A j= F. However, by Theorem 4.1, if DCIRC j= F then :F is free for negation and therefore ECW A j= F. 2 Finally, we compare ECWA to CIRC. Corollary 4.3 shows that for denite theories with empty Q and Z, ECWA and CIRC coincide on ground formulae. Examples given in this section and in Section 3 show that, in general, this is not the case, i.e. there are ground formulae which are implied by ECWA, but not by CIRC and vice versa. 6 Conclusion The determination of the existing relationships between dierent formalizations of non-monotonic reasoning not only claries relative power of dierent approaches and makes their semantics clearer, but it also may provide us with insights necessary to discover more general, unifying principles of nonmonotonic reasoning. In this paper we compared the deductive power of three non-monotonic formalisms: circumscription (CIRC), domain circumscription (DCIRC) and the extended closed world assumption (ECWA). The following table summarizes the positive results proved in the paper, while the examples presented above indicate that these results cannot be signicantly strengthened. Observe, that for any denite theory T (i.e., for any positive logic program T) and for any sentence F we have: CW A(T ) j= F ECW A(T ) j= F (9) MIN(T ) j= F CIRC(T ) j= F (10) M T j= F DCIRC(T ) j= F: (11) Also, note that any relationship that holds for all existential sentences automatically applies to ground sentences. 19

Theory T Sentence F Relationship Denite Positive Existential P j= F CIRC j= F DCIRC j= F Denite Positive Existential P 6j= F CIRC j= :F DCIRC j= :F Denite Existential ECW A j= F CIRC j= F DCIRC j= F Universal Arbitrary CIRC j= F ) DCIRC j= F Universal Ground ECW A j= F ) DCIRC j= F Universal Ground (no Z's) ECW A j= F DCIRC j= F The paper demonstrates subtle, and sometimes unexpected, dierences between the corresponding formalisms. It also indicates the extent to which inference engines based on one of them can be applied to answering queries in systems based on the others. We believe that future work will discover areas of applicability for each of these formalisms. References [1] Apt, K. and Van Emden, M., \Contributions to the Theory of Logic Programming", JACM 29(1982), 841-862. [2] Bossu, G. and Siegel, P., \Saturation, Non-monotonic Reasoning and the Closed World Assumption", Articial Intelligence 25(1985), 13-63. [3] Clark, K.L., \Negation as Failure", in: Logic and Data Bases (H.Gallaire and J.Minker, Eds.), Plenum Press, New York 1978, 293-322. [4] Chang, C., Lee R.C., Symbolic Logic and Mechanical Theorem Proving, Academic Press, New York 1973. [5] Etherington, D., \Reasoning with Incomplete Information. Investigations of Non-Monotonic Reasoning", PhD Thesis, Dept. of Computer Science, University of British Columbia, 1986. [6] Gelfond, M. and Przymusinska, H., \Negation as Failure: Careful Closure Procedure", Articial Intelligence 30(1986), 273-287. 20

[7] Gelfond, M., Przymusinska, H. and Przymusinski, T., \The Extended Closed World Assumption and its Relationship to Parallel Circumscription", Proceedings ACM SIGACT-SIGMOD Symposium on Principles of Database Systems, Cambridge, Mass., March 1986, 133-139. [8] Gelfond, M., Przymusinska, H. and Przymusinski, T., \On the Relationship between Circumscription and Negation as Failure", Articial Intelligence 38(1989),75-94. [9] Kunen, K., \Negation in Logic Programming", J. of Logic Programming 3(1986). [10] Lifschitz, V., \Computing Circumscription", Proceedings IJCAI-85, Los Angeles 1985, 121-127. [11] Lifschitz, V., \Closed World Data Bases and Circumscription", Articial Intelligence 27(1985), 229-235. [12] Lifschitz, V., \On the Satisability of Circumscription", Articial Intelligence 28(1986), 17-27. [13] Lloyd, J.W., Foundations of Logic Programming, Springer-Verlag 1984. [14] Lloyd, J.W. and Topor, R.W., \Making Prolog More Expressive", Journ. of Logic Programming 1(1984), 225-240. [15] McCarthy, J., \Circumscription - a Form of Non-Monotonic Reasoning", Articial Intelligence 13(1980), 27-39. [16] McCarthy, J., \Applications of Circumscription to Formalizing Common Sense Knowledge", J. Articial Intelligence 28(1986), 89-116. [17] Minker, J., \On Indenite Data Bases and the Closed World Assumption", Proc. 6-th Conference on Automated Deduction, Springer Verlag, 1982, 292-308. [18] Przymusinski, T., \On the Declarative Semantics of Stratied Deductive Databases and Logic Programs", in: Foundations of Deductive Databases and Logic Programming (ed. J.Minker), Morgan Kaufmann 1988, 193-216. 21

[19] Przymusinski, T., \Perfect Model Semantics", Proceedings of the Fourth International Conference on Logic Programming, Seattle, Wash., August 1988, pp. 1081-1096. [20] Przymusinski, T. \On the Relationship Between Logic Programming and Non-Monotonic Reasoning", Proceedings of the Seventh National Conference on Articial Intelligence AAAI'88, St. Paul, Minn., August 1988, pp. 444-448. [21] Reiter, R., \On Closed-World Data Bases", in: Logic and Data Bases (H.Gallaire and J.Minker, Eds.), Plenum Press, New York 1978, 55-76. [22] Reiter, R., \Towards a Logical Reconstruction of Relational Database Theory", in: On Conceptual Modeling (M.Brodie et al., Eds.), Springer Verlag, 1984, 191-233. [23] Shepherdson, J., \Negation as Failure", J. Logic Programming 2(1985), 185-202. [24] Shepherdson, J., \Negation in Logic Programming", in: Foundations of Deductive Databases and Logic Programming (ed. J.Minker), Morgan Kaufmann 1988, 19-88. paper. [25] Van Emden, M.H. and Kowalski, R.A., \The Semantics of Predicate Logic as a Programming Language", Journ. ACM 3 (4) (1976),733-742. [26] Yahya, A. and Henschen, L., \Deduction in Non-Horn Databases", Journal of Automated Reasoning 1(2)(1985),141-160. 22