Nathan Sturtevant FOL

Similar documents
Nathan Sturtevant FOL

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

First Order Logic (FOL)

Chapter 8 First Order Logic

CSCI-495 Artificial Intelligence. Lecture 17

First-order logic. Chapter 8. Chapter 8 1

Lecture Overview [ ] Introduction to Artificial Intelligence COMP 3501 / COMP Lecture 6. Motivation. Logical Agents

First Order Logic (FOL)

ITS336 Lecture 6 First-Order Logic

Reasoning. Inference. Knowledge Representation 4/6/2018. User

First-Order Logic Chap8 1. Pros and Cons of Prop. Logic

CS 771 Artificial Intelligence. First order Logic

Knowledge Based Systems: Logic and Deduction

First-order logic. First-order logic. Logics in general. Outline. Syntax of FOL: Basic elements. Pros and cons of propositional logic

Math.3336: Discrete Mathematics. Nested Quantifiers

CS 380: ARTIFICIAL INTELLIGENCE FIRST ORDER LOGIC. Santiago Ontañón

Lecture 8: (Predicate) First Order Logic

First order logic (FOL) Chapters 8 & 9

Outline First-order logic. First-order Logic. Introduction. Recall: 4-Queens problem. First-order Logic. First-order Logic Syntax.

CS 730/730W/830: Intro AI

CS 380: ARTIFICIAL INTELLIGENCE INFERENCE IN PROPOSITIONAL LOGIC

First Order Logic. Philipp Koehn. 8 October 2015

CS 4700: Artificial Intelligence

CS560 Knowledge Discovery and Management. CS560 - Lecture 3 1

First Order Logic (FOL) and Inference

Logic Overview, I. and T T T T F F F T F F F F

7.5.2 Proof by Resolution

LIN1032 Formal Foundations for Linguistics

Mat 243 Exam 1 Review

How to determine if a statement is true or false. Fuzzy logic deal with statements that are somewhat vague, such as: this paint is grey.

Reasoning Under Uncertainty: Introduction to Probability

Today s Lecture. ICS 6B Boolean Algebra & Logic. Predicates. Chapter 1: Section 1.3. Propositions. For Example. Socrates is Mortal

Propositional Logic Part 1

Propositional Logic Not Enough

CS 730/830: Intro AI. 3 handouts: slides, asst 6, asst 7. Wheeler Ruml (UNH) Lecture 12, CS / 16. Reasoning.

First-order logic. Chapter 8. Chapter 8 1

A Little Deductive Logic

Logic. Stephen G. Ware CSCI 4525 / 5525

INF3170 Logikk Spring Homework #8 For Friday, March 18

Section Summary. Section 1.5 9/9/2014

Discrete Structures for Computer Science

Lecture 4. Predicate logic

Predicate Logic. CSE 191, Class Note 02: Predicate Logic Computer Sci & Eng Dept SUNY Buffalo

A Little Deductive Logic

CS 1571 Introduction to AI Lecture 14. First-order logic. CS 1571 Intro to AI. Midterm

Introduction to Sets and Logic (MATH 1190)

CS:4420 Artificial Intelligence

cse 311: foundations of computing Fall 2015 Lecture 6: Predicate Logic, Logical Inference

Section 2.1: Introduction to the Logic of Quantified Statements

Stanford University CS103: Math for Computer Science Handout LN9 Luca Trevisan April 25, 2014

THE LOGIC OF QUANTIFIED STATEMENTS

Logical Structures in Natural Language: First order Logic (FoL)

Logic and Reasoning. Foundations of Computing Science. Pallab Dasgupta Professor, Dept. of Computer Sc & Engg INDIAN INSTITUTE OF TECHNOLOGY KHARAGPUR

Logic: First Order Logic (Part I)

CS 220: Discrete Structures and their Applications. Predicate Logic Section in zybooks

COMP9414: Artificial Intelligence Propositional Logic: Automated Reasoning

22c:145 Artificial Intelligence. First-Order Logic. Readings: Chapter 8 of Russell & Norvig.

First-Order Logic. Announcements. General Logic. PL Review: Truth Tables. First-Order Logic. PL Review: Inference Rules

Section 2.3: Statements Containing Multiple Quantifiers

Unit 6 Logic Math 116

Knowledge Representation and Reasoning

Logic. (Propositional Logic)

KR: First Order Logic - Intro

Discrete Mathematical Structures. Chapter 1 The Foundation: Logic

CS1021. Why logic? Logic about inference or argument. Start from assumptions or axioms. Make deductions according to rules of reasoning.

Logic III. Introduction to Artificial Intelligence CSE 150

COMP4418: Knowledge Representation and Reasoning First-Order Logic

Mathematical Logic Part Three

3. The Logic of Quantified Statements Summary. Aaron Tan August 2017

Propositional Logic: Review

Discrete Structures Lecture 5

First Order Logic: Syntax and Semantics

First Order Logic Semantics (3A) Young W. Lim 8/9/17

Recall that the expression x > 3 is not a proposition. Why?

Logic Programming (PLP 11) Predicate Calculus, Horn Clauses, Clocksin-Mellish Procedure

Predicate Logic & Quantification

First Order Logic Semantics (3A) Young W. Lim 9/17/17

Propositional Logic: Semantics and an Example

Discrete Mathematics and Its Applications

n logical not (negation) n logical or (disjunction) n logical and (conjunction) n logical exclusive or n logical implication (conditional)

COMP Intro to Logic for Computer Scientists. Lecture 11

Inference in first-order logic

A Short Introduction to Propositional Logic and First-Order Logic

473 Topics. Knowledge Representation III First-Order Logic. Logic-Based KR. Propositional. Logic vs. First Order

Announcements. CS311H: Discrete Mathematics. Introduction to First-Order Logic. A Motivating Example. Why First-Order Logic?

Propositions. c D. Poole and A. Mackworth 2010 Artificial Intelligence, Lecture 5.1, Page 1

Logic Propositional logic; First order/predicate logic

Reasoning Under Uncertainty: Introduction to Probability

Predicates, Quantifiers and Nested Quantifiers

CS 4700: Artificial Intelligence

First Order Logic: Syntax and Semantics

Outline. First-order logic. Atomic sentences. Intelligent Systems and HCI D7023E. Syntax of FOL: Basic elements. Pros and cons of propositional logic

THE LOGIC OF QUANTIFIED STATEMENTS. Predicates and Quantified Statements I. Predicates and Quantified Statements I CHAPTER 3 SECTION 3.

Predicate Logic. Andreas Klappenecker

Propositional natural deduction

Mathematical Reasoning. The Foundation of Algorithmics

SYMBOLIC LOGIC UNIT 10: SINGULAR SENTENCES

CSC242: Intro to AI. Lecture 13. Thursday, February 28, 13

Artificial Intelligence Knowledge Representation I

3/29/2017. Logic. Propositions and logical operations. Main concepts: propositions truth values propositional variables logical operations

Transcription:

Lecture Overview COMP 3501 / COMP 4704-4 Lecture 8 First order logic (FOL) Inference in FOL Prof. JGH 318 First Order Logic FOL is closer to natural languages that prop. logic FOL contains: Objects (Constants): FOL Propositional logic reduces everything to true or false In FOL relations between objects are true or false (do or do not hold) people, locations, etc Relations (between objects): next to(c11, C12), older(a, b), father(a, b) Functions (relation which returns object): father_of(b), plus(one, two), leader(usa)

Prop. Logic Syntax Sentence AtomicSentence ComplexSentence AtomicSentence True False P Q R Complex Sentence (Sentence) [Sentence] Sentence Sentence Sentence Sentence Sentence Sentence Sentence FOL syntax Sentence AtomicSentence ComplexSentence Predicate Predicate(Term ) AtomicSentence True False P Q R Term = Term Complex Sentence (Sentence) [Sentence] Sentence Sentence Sentence Sentence Sentence Sentence Sentence Sentence Sentence Sentence Sentence QuantifierVariable, Sentence Operator precedence:,,,, Operator precedence:,,,, FOL syntax FOL semantics Term Function(Term, ) Constant Variable Quantifier Constant A P1 Fred Variable a x s Predicate True False After Loves Raining Function Mother LeftLeg Semantics are somewhat flexible In C++ you can overload the + operator to be * Similarly, we can define objects in a way that is nonsensical in the real world Intended Interpretation is when objects represent the names they have in the real world

FOL Models crown A model in propositional had the truth value of each variable A model in FOL has: on head king All objects The relations between objects Functions on objects R $ J FOL Models A model contains one set of interpretations What about all models? Not only all interpretations on a fixed set of objects Also all numbers of objects and all interpretations of relations between them Sentences Atomic sentences state facts Married(Father(Richard), Mother(John)) The sentence is true in a model if the relations hold in the model Complex sentences work like prop. logic King(Richard) King(John)

Universal Quantifier ( ) Quantifiers let us solve the problem of making general statements about the world All kings are s x King(x) Person(x) Universal Quantifier ( ) Formally, when quantifying a variable we need to look at all the extended interpretations of that variable eg x, what are all things that x can be? x King(x) Person(x) crown For all x, if x is a king, then x is a Lower case letters are variables This is true if it is true for all interpretations of x R $ J on head king Universal Quantifier ( ) Existential quantifier ( ) Richard is a king Richard is a John is a king John is a Richard s is a king Richard s is a John s is a king John s is a The crown is a king The crown is a Note that this works because of our definition of R $ J on head crown king Universal quantifiers make statements about all objects Existential quantifiers claim that at least one object has a given property is the natural connector to use with Why is x King(x) Person(x) wrong?

Existential quantifier ( ) x Crown(x) OnHead(x, John) Richard is a crown Richard is on John s head John is a crown John is on John s head Richard s is a crown Richard s is on John s head John s is a crown John s is on John s head The crown is a crown The crown is on John s head Why is x Crown(x) OnHead(x, John) wrong? Nested quantifiers Can nest multiple quantifiers together x, y (x, y) (y, x) With the same quantifier, order doesn t matter What is the difference? x y loves(x, y) x y loves(x, y) Avoid re-using variables in quantifiers Negating quantifiers Negating quantifiers How do we write everyone likes ice cream? De Morgan s rules for quantification: x P x P x P x P x P x P x P x P

Equality Equality indicates that two terms refer to the same objects Father(John) = Henry Often used with multiple existential variables: x, y Sibling(x, Nathan) Sibling(y, Nathan) x, y Sibling(x, Nathan) Sibling(y, Nathan) (x = y) First-Order Logic Examples All cows eat grass. x cow(x) eat(x, grass) Some cows don t eat grass x cow(x) eat(x, grass) Every good boy deserves fudge. x good(x) boy(x) deserves(x, fudge) My dog likes popcorn. x dog(x) owns(me, x) likes(x, popcorn) Homework: 8.24