First-Order Logic
Goals for a KR language
- Unambiguous and independent of context
- Efficient and effective inference procedure
First-Order Logic
- The most studied and well understood KR language
- It can express anything that can be programmed
Ontological commitments
- Represents the world in terms of:
- objects: people, houses, games, places ...
- properties (of objects): yellow, big, hard, far-away, ...
- relations (among objects): part-of, brother-of has-color, ...
- functions (from one object to another): father-of, left-leg-of, ...
Syntax of FOPL
Syntax continued
- Terms (represent objects)
- If x is a variable or a constant, x is a term
- If x1, ..., xn are all terms and fun is a n-ary function, then
fun(x1, ..., xn) is a term
Syntax continued
Syntax continued
- Difference between functions and predicates:
- a function is used to build terms out of other terms; E.g.: father-of(bill)
- a predicate is used to define sentences (which are true or false), E.g.: father-of(bill, david)
- = (the equality symbol) is a predicate that is almost always part
of FOPL; states that 2 terms refer to the same object
Syntax continued
Syntax continued
- Some terminology
- atomic sentence --- a sentence with no connectives or quantifiers
- literal --- an atomic sentence or its negation
- ground term --- a literal without variables
Semantics of FOPL
- Interpretation: mapping between elements of the language and the entities in the world/model
- Begin with an interpretation function that maps predicates, functions and constants to their “meanings” in some world/model
- Basically 2 elements:
- objects referred to by terms
- claims about objects (their properties, relations); these are
expressed by sentences (wff)
Semantics continued
Semantics continued
Semantics continued
- sentences/claims about objects
- atomic sentences are relations with arguments where the arguments are specified by terms
- examples:
- color-of(chair, blue)
- mother-of(bill, mary)
- usual interpretation: T or F (true or false in the world)
Functions versus predicates revisited
- father(john) --- {<john, bill>, <sue,david>, ...}
- father(john,bill) --- {<john, bill>, <sue,david>, ...}
- function expression correspond to terms; they denote objects in the world/model
- predicate expressions correspond to sentences; they are true or false in the world/model
Semantics continued
- Complex sentences: atomic sentences and connectives
- compositional semantics
- the same as proposition logic
Semantics continued
Semantics continued