AI-Lec05-add-slides
AI-Lec05-add-slides
—
Artificial Intelligence
COSC2129
RMIT Classification: Trusted
Material
• Example 1: Represent in PL
– The table has three legs ➢ Properties of ONE
– The table is made of wood and glass object
– The table is expensive
• Example 2
– Table 1 is broken ➢ The same
– Table 2 is broken property of
difference objects
• Example 3
– Table 2 is next to Table 1 • ?
– Table 2 is smaller than Table 1
– The bag is on Table 2
RMIT Classification: Trusted
First-order logic
First-order logic
• Examples:
– Objects: Students, lectures, companies, cars ...
– Relations: Brother-of, bigger-than, outside, part-of, has-color,
occurs-after, owns, visits, precedes, ...
– Properties: blue, wood, oval, even, large, ...
– Functions: father-of, best-friend, second-half, one-more-than
...
RMIT Classification: Trusted
FOL: Syntax
FOL: Syntax
• Variable symbols
– E.g., x, y,…
• Connectives
– Same as in PL: not (), and (), or (), implies
(→), if and only if (biconditional )
• Quantifiers
– Universal x or (Ax)
– Existential x or (Ex)
• Equality: =
RMIT Classification: Trusted
FOL: Sentences
Examples:
Somebody likes Jane: ∃x : (likes (x, Jane)).
Somebody likes everybody: ∃x :(∀y : (likes (x, y)))
∀x : (even (x) ∧ prime (x) ⇒ (x = 2)) (a mathematical fact)
RMIT Classification: Trusted
Quantifiers
• Universal quantification
– (x)P(x) means that P holds for all values of x in
the domain associated with that variable
– E.g., (x) dolphin(x) → mammal(x)
• Existential quantification
– ( x)P(x) means that P holds for some value of x
in the domain associated with that variable
– E.g., ( x) study(x,AI) smart(x)
RMIT Classification: Trusted
Quantifiers
Semantics of FOL
Semantics of FOL
Inference in FOL
RMIT Classification: Trusted
• Universal instantiation
– x P(x) P(A)
• Universal generalization
– P(A) P(B) … x P(x)
• Existential instantiation
– x P(x) P(F) skolem constant F
• Existential generalization
– P(A) x P(x)
RMIT Classification: Trusted
GMP example
Unification
Example of Inference in F
Question?