Download presentation
Presentation is loading. Please wait.
1
First Order Logic
2
First Order Logic (AKA-Predicate Calculus) vs (Propositional Logic)
Propositional Logic we talk about atomic facts Propositional logic has no objects. Because it has no objects it also has no relationships between objects, or functions that names objects FOL- Stronger ontological commitment Objects (with individual identities) Objects have properties Relations between objects FOL is very well understood
3
First Order Logic Syntax
ForAll | ThereExists
5
First order logic has SENTENCES that represent Boolean facts
TERMS which represent objects CONSTANTS and VARIABLES which represent objects PREDICATE which given an object (I.e. TERM) it returns true or false FUNCTIONS which given an object will return another object
6
Details Informally: Objects like ColinPowell, Mars, Austrailia
Variables: general use lower case letters Constants: Use uppercase, or starting with uppercase Formally Speaking a predicate is a set of tuples BrotherHoodPredicate={<KingJohn, RichardTheLionHeart> < RichardTheLionHeart, KingJohn> }
7
Atomic Sentence Brother(Richard,John)
Married(FatherOf(Richard),MotherOf(John)) An atomic sentence is true iff the relation referred to by the predicate holds between the objects referred to by the arguments
8
Complex Sentences And, OR, Implies and Not
Mother(Anne,Neil) ^ Mother(Anne,Eileen) AtWar(USA) v AtPeace(USA) Mother(Anne,Neil)Older(Anne,Neil) ¬Mother(Anne,GeorgeBush)
11
Universal Quantification
<variables> <sentence> All students at WPI are smart. s at(s,WPI)=> smart(s) What does this mean? s at(s,WPI) ^ smart(s) All objects are at WPI and all objects are smart
12
Existential Quantification
<variables> <sentence> There exist a student at MIT that is smart s at(s,MIT) ^ smart(s) What does this mean? s at(s,MIT) => smart(s) If there is an object that is not at MIT then this statement will be true
16
Formally Speaking
17
Equality Anne = Mother(Neil)
How would you say that “Neil has at least two sisters” Neil has at least 3 sisters. Define Sibling
18
ForAll x,y Sibling(x,y) not(x=y) AND
ForAll x,y Sibling(x,y) not(x=y) AND [ThereExists p Parent(p,x) AND Parent(p,y)]
19
Formally Speaking about Equality
Equality is the identify relation { <Neil, Neil> <Tom, Tom> <grape1, grape1> … >
20
Practice Squares neighboring the Wumpus are smelly
ForAll s1,s2 at(s1,Wumpus) ^ neighbor(s1,s2)=>smelly(s2)
23
Practice with the Kinship Domain
Sibling ForAll x,y Sibling(x,y) not(x=y) AND [ThereExists p Parent(p,x) AND Parent(p,y)] Assume we have those on Page 198 Define Brother(x,y) Sister(x,y) Aunt(a,c) BrotherInLaw(b,x) Grandchild GreatGrandParent Do Exercise 7.2, 7.3 and 7.4 for more practice
Similar presentations
© 2024 SlidePlayer.com Inc.
All rights reserved.