Resolution for Predicate Logic

Similar documents

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

Propositional Logic: Models and Proofs

Propositional and Predicate Logic - V

Propositional Logic Language

Resolution for Predicate Logic

4 Predicate / First Order Logic

Advanced Topics in LP and FP

Automated Reasoning in First-Order Logic

Logic and Computation

Deductive Systems. Lecture - 3

COMP9414: Artificial Intelligence Propositional Logic: Automated Reasoning

Part 1: Propositional Logic

Resolution for mixed Post logic

Knowledge base (KB) = set of sentences in a formal language Declarative approach to building an agent (or other system):

INF3170 / INF4171 Notes on Resolution

Inference in first-order logic

Inference in Propositional Logic

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

Herbrand Theorem, Equality, and Compactness

Convert to clause form:

Rewrite-Based Equational Theorem Proving With Selection and Simplification. Leo Bachmair Harald Ganzinger

Outline. Logic. Definition. Theorem (Gödel s Completeness Theorem) Summary of Previous Week. Undecidability. Unification

1 Introduction to Predicate Resolution

Introduction to Logic in Computer Science: Autumn 2007

Syntax of FOL. Introduction to Logic in Computer Science: Autumn Tableaux for First-order Logic. Syntax of FOL (2)

First-Order Logic. Resolution

Hierarchic Superposition: Completeness without Compactness

Handout Proof Methods in Computer Science

CTL-RP: A Computational Tree Logic Resolution Prover

A Tableau Calculus for Minimal Modal Model Generation

Technische Universität München Summer term 2011 Theoretische Informatik Prof. Dr. Dr. h.c J. Esparza / M. Luttenberger / R.

Superposition for Fixed Domains. Matthias Horbach and Christoph Weidenbach

Lecture 12 September 26, 2007

Computational Logic. Davide Martinenghi. Spring Free University of Bozen-Bolzano. Computational Logic Davide Martinenghi (1/30)

CogSysI Lecture 8: Automated Theorem Proving

Logic: Propositional Logic (Part I)

2.5.2 Basic CNF/DNF Transformation

Logic. Knowledge Representation & Reasoning Mechanisms. Logic. Propositional Logic Predicate Logic (predicate Calculus) Automated Reasoning

Resolution: Motivation

Logic and Inferences

SLD-Resolution And Logic Programming (PROLOG)

KE/Tableaux. What is it for?

Propositional Reasoning

The Model Evolution Calculus with Equality

Artificial Intelligence

LOGIC. Mathematics. Computer Science. Stanley N. Burris

Exercises 1 - Solutions

MODELLING AND VERIFICATION ANALYSIS OF A TWO SPECIES ECOSYSTEM VIA A FIRST ORDER LOGIC APPROACH

Warm-Up Problem. Is the following true or false? 1/35

T -resolution: Refinements and Model Elimination

Two hours. Examination definition sheet is available at the back of the examination. UNIVERSITY OF MANCHESTER SCHOOL OF COMPUTER SCIENCE

Inf2D 13: Resolution-Based Inference

7 LOGICAL AGENTS. OHJ-2556 Artificial Intelligence, Spring OHJ-2556 Artificial Intelligence, Spring

Knowledge based Agents

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

Reasoning in Description Logics with a Concrete Domain in the Framework of Resolution

Computational Logic Automated Deduction Fundamentals

Automated Reasoning in First-Order Logic

Propositional logic II.

The Model Evolution Calculus as a First-Order DPLL Method

Automated Reasoning (in First Order Logic) Andrei Voronkov. University of Manchester

Qualifying Exam Logic August 2005

7.5.2 Proof by Resolution

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

Inference in first-order logic

Propositional Logic. Testing, Quality Assurance, and Maintenance Winter Prof. Arie Gurfinkel

Lecture overview. Knowledge-based systems in Bioinformatics, 1MB602. Reasoning. Reasoning cont. Inference in propositional logic.

Logic as a Tool Chapter 4: Deductive Reasoning in First-Order Logic 4.4 Prenex normal form. Skolemization. Clausal form.

Reducing SHIQ Description Logic to Disjunctive Datalog Programs

First-order resolution for CTL

Propositional Logic: Review

COMP4418: Knowledge Representation and Reasoning First-Order Logic

Cooperation of Background Reasoners in Theory Reasoning by Residue Sharing

Description Logics. Deduction in Propositional Logic. franconi. Enrico Franconi

arxiv: v1 [cs.lo] 1 Sep 2017

Some Rewriting Systems as a Background of Proving Methods

Propositional and Predicate Logic - II

Mathematical Logic Propositional Logic - Tableaux*

First-Order Theorem Proving and Vampire

Language of Propositional Logic

Cooperation of Background Reasoners in Theory Reasoning by Residue Sharing

arxiv: v2 [cs.lo] 22 Nov 2017

Introduction to Logic in Computer Science: Autumn 2006

Syntax. Notation Throughout, and when not otherwise said, we assume a vocabulary V = C F P.

Part 1: Propositional Logic

07 Equational Logic and Algebraic Reasoning

Combining Instance Generation and Resolution

Lecture 9: The Splitting Method for SAT

Learning Goals of CS245 Logic and Computation

On the complexity of equational problems in CNF

Propositional Resolution

Foundations of Artificial Intelligence

Lifted Inference: Exact Search Based Algorithms

A simple proof that super-consistency implies cut elimination

Artificial Intelligence Chapter 9: Inference in First-Order Logic

CS 380: ARTIFICIAL INTELLIGENCE

CSC242: Intro to AI. Lecture 11. Tuesday, February 26, 13

Normal Forms of Propositional Logic

Transcription:

Resolution for Predicate Logic The connection between general satisfiability and Herbrand satisfiability provides the basis for a refutational approach to first-order theorem proving. Validity of a first-order sentence φ can be checked as follows. 1. First convert the negated formula φ into a prenex form Q 1 x 1... Q n x n ψ. 2. Next skolemize to obtain a universal formula of the form x 1... x n ψ. 3. Then convert ψ into conjunctive form, ψ... ψ, where each formula ψ is a disjunction of literals. The formula x 1... x n ψ is equivalent to ( x 1... x n ψ 1 )... ( x 1... x n ψ m ). 4. Finally, apply suitable resolution inferences to ψ 1,..., ψ m, interpreting each formula ψ as a clause. If a contradiction is derived, then φ is unsatisfiable, which implies that φ is valid.

Renaming A substitution is said to be a renaming if it is a one-toone and onto function on the set of variables. For example, the substitution σ = [x y, y x] is a renaming (in this case of the variables x and y). We also call a substitution ρ a renaming for a formula φ if ρ(x) and ρ(y) are different variables, whenever x and y are different variables in φ. If C is a clause and ρ a renaming for C, then C and Cρ obviously have the same ground instances. Thus the Herbrand semantics of a clause does not change under renaming. We will employ renaming substitutions, as well as (most general) unifiers, in defining inferences on clauses.

Binary Resolution The following inference rule provides a strating point for a refutational theorem proving method for clauses. Binary Resolution C A D B Cρσ Dσ where ρ is a renaming substitution, such that the renamed first premise has no variables in common with the second premise, and σ is a most general unifier of Aρ and B. For example, P (fx, x) P (x, fy) P (x, z) P (ffy, z) is a binary resolution inference.

Example Resolution Consider the set of the following clauses: P (x, y) P (y, x) (1) P (x, y) P (y, z) P (x, z) (2) P (x, fx) (3) P (a, a) (4) We use resolution to show that this set is unsatisfiable. From clauses (3) and (1) we obtain whereas from (3) and (2) we get P (fx 1, x 1 ) (5) P (fx 2, z) P (x 2, z) (6) Resolving clauses (5) and (6) yields P (x 3, x 3 ) (7) which can be resolved with (4) to yield a contradiction.

Factoring Binary resolution by itself is not sufficient to obtain a contradiction from every unsatisfiable set of clauses, but needs to be supplemented by the following rule. Positive Factoring C A B Cσ Aσ if σ is a most general unifier of the positive literals A and B. The following inference rule is not necessary (for refutational completeness), but can also be used. Negative Factoring C A B Cσ Aσ if σ is a most general unifier of A and B.

Resolution Factoring can also be integrated into resolution inferences. General Resolution C A 1 A k D B 1 B l Cρσ Dσ where ρ is a renaming substitution for the first premise such that the renamed clause has no variables in common with the second premise, and σ is a most general unifier of {A 1 ρ,..., A k ρ, B 1,..., B l }. For example, R(ffx, x) R(y, z) R(fy, fz) R(fffx, fx) is a resolution inference. In this example, no renaming is necessary (and hence ρ may be the identity function) and the atoms to be unified are R(ffx, x) and R(y, z), which have most general unifier σ = [y ffx, z x].

Another Example Recursively define terms f n (x) by: (i) f 1 (x) = f(x) and (ii) f n (x) = f(f n 1 (x)), if n > 1. Let S n denote the set of two clauses, P (x) P (f(x)) P (y) P (f n (y)) For example, S 1 consists of these clauses: P (x) P (f(x)) P (y) P (fy) This set is satisfiable, as there is a Herbrand interpretation in which all ground instances of both clauses are true. (Consider a language with a single constant a. the Herbrand universe consists of the terms Then a, fa, ffa,... Define P I in such a way that P I (t) is true if, and only if, t is a term f n (a), for which n is an odd number. This Herbrand model I satisfies S 1.)

Next take the set S 2 : Example (cont.) Resolving (1) and (2) yields From (3) and (2) we obtain Resolving (3) and (4) yields From (1) and (5) we obtain P (x) P (f(x)) (1) P (y) P (fy) (2) P (x) P (f(x)) (3) P (x) P (f(x)) (4) P (x) P (x) (5) P (x) (6) Clauses (5) and (6) yield a contradiction, which implies that the set S 2 is unsatisfiable. (Resolvents have been consistently renamed so as to simplify the presentation.)

Example (cont.) The set S 6, it turns out, is also unsatisfiable. Here is a refutation by resolution. P (x) P (f(x)) (1) P (x) P (f 6 (x)) (2) P (x) P (f 5 (x)) (1), (2) : (3) P (x) P (f(x)) (2), (3) : (4) P (x) P (x) (1), (4) : (5) P (x) P (f 4 (x)) (3), (4) : (6) P (x) P (f 3 (x)) (1), (6) : (7) P (x) P (f(x)) (3), (6) : (8) P (x) P (f 3 (x)) (2), (7) : (9) P (x) P (f 2 (x)) (4), (7) : (10) P (x) P (f(x)) (6), (7) : (11) P (x) P (f 2 (x)) (1), (9) : (12) P (x) P (f 2 (x)) (3), (9) : (13) P (x) (7), (9) : (14) P (x) (1), (14) : (15) (14), (15) : (16)

Soundness of Resolution The inferences we have described above binary and general resolution and factoring are logically sound. Theorem [Soundness] The conclusion of a resolution or factoring inference is true in every Herbrand model that satisfies the premises of the inference.

Instances of Inferences An instance of a resolution inference C D C ρσ D σ is any inference Cρστ Dστ C ρστ D στ Similarly, by an instance of a factoring inference we mean any inference C L L Cσ Lσ Cστ Lστ L στ Cστ Lστ If neither premises nor conclusion contain any variables, we speak of a ground instance. Note that instances of a resolution inference need not themselves be resolution inferences (as inferences employ only most general unifiers).

Projection The connection between (a) ground instances of inferences from arbitrary clauses and (b) inferences from ground instances of clauses, forms the basis of the refutational completeness of resolution plus factoring. Lifting Lemma Let C and D be two clauses with no variables in common and Cτ and Dτ be corresponding ground instances. (i) If E is the conclusion of a resolution inference with premises Cτ and Dτ, then E is a ground instance of a clause E that is the conclusion of a resolution inference with premises C and D. (ii) If E is the conclusion of a factoring inference with premise Cτ, then E is a ground instance of a clause E that is the conclusion of a factoring inference with premise C.

Refutational Completeness A set of clauses N is saturated (with respect to given inference rules) if N contains the conclusion of every inference, the premises of which are elements of N. The following lemma follows from the Lifting Lemma. Lemma If a set of clauses N is saturated with respect to resolution and factoring, then the set of all ground instances of clauses in N is saturated with respect to ground resolution and factoring. Observing that the empty clause is an instance of itself, but of no other clause, we obtain: Corollary [Refutation Completeness] A set of clauses is unsatisfiable if and only if the empty clause can be derived from it by resolution and factoring.

Subsumption Some clauses may be redundant in the sense that they are not needed for deriving a contradiction. We say that a clause C subsumes another clause D if D can be written as Cσ or Cσ C, for same substitution σ. For example, the ground clause P Q subsumes P Q R, and P (x) subsumes P (f(y)) Q(y). A clause C is redundant with respect to a set N if N contains a(nother) clause that subsumes C. Redundant clauses may be ignored in derivations.