60 likes | 74 Views
This tutorial discusses general unifiers and logical representations using first-order language. It also demonstrates how to translate sentences and proves statements using axioms and facts.
E N D
Artificial Intelligence Tutorials Tutorial # 7
Q1: Give the most general unifier if it exists • P(A,B,B) and P(x,y,z): {x/A, y/B, z/B} • Q(y,G(A,B)) and Q(G(x,x),y): No unifier (x cannot bind to both A and B). • Older(Father(y),y) and older(Father(x),Ali): {y/Ali, x/Ali} • Knows(Father(y),y) and Knows(x,x): No unifier.
Q2: Write down logical representations suitable for use with GMP • Horses, cows and pigs are mammals: Horse(x) Mammal(x) Cow(x) Mammal(x) Pig(x) Mammal(x) • An offspring of a horse is a horse: Offspring(x,y) Horse(y) Horse(x) • Bluebeard is a horse: Horse (BlueBread) • Bluebeard is Charlie’s parent: Parent (BlueBread, Charlie) • Offspring and parent are inverse relations: Offspring(y, x) Parent (x,y) Parent (x,y) Offspring(y, x) • Every mammal has a parent: Mammal(x) Parent(G(x), x) where G is Skolem function
Q3: Two sentences in the language of first order language. • Translate: • For every natural number there is some other natural number that is smaller than or equal to it. • There is a particular natural number that is smaller than or equal to any natural number. • Yes. • Yes. • No, (A) does not logically entail (B) (A B). • Yes, (B) logically entails (A) (B A).
Q4. Considering axioms • Translate into WFF: • All hounds howl at night: h (Hound(h) Howl(h)) • Anyone who has any cats will not have any mice: x c z: Has(x, c) Cat(c) (Has(x,z) Mice(z)) • Light sleepers do not have anything which howls at night: x h LS(x) (Has(x,h) Howl(h)) • Ali has either a cat or a hound: (Has(Ali, C) Cat(C)) (Has(Ali, C) Hound(C))
Q4. Considering axioms, Cont... • Axiom • A: h (Hound(h) Howl(h)) • B: x c z: Has(x, c) Cat(c) (Has(x,z) Mice(z)) • C: x h LS(x) (Has(x,h) Howl(h)) • D: (Has(Ali, C) Cat(C)) (Has(Ali, C) Hound(C)) • Fact • F1: LS(Ali) • Prove ((Have(Ali, z) ^ Mice(z))) • C, F1 gives *R1: LS(Ali) (Has(Ali,h) Howl(h)) • F1, R1 and GMP gives R2: (Has(Ali, h) ^ Howl(h)) • A, R2 and resolution gives R3: (Has(Ali, h) ^ Hound(h)) • D, R3 and resolution gives R4: Has(Ali, C) ^ Cat(C) • B, R4 and GMP gives ** (Has(Ali,z) ^ Mice(z)) (i.e. Ali does not have a mice).