1Foundations of Artificial IntelligenceFirst-Order LogicCS472 – Fall 2007Thorsten JoachimsFirst-Order Logic•Idea:–Don’t treat propositions as “atomic” entities.•First-Order Logic:–Objects: cs472, fred, ph219, emptylist …–Relations/Predicates: is_Man(fred), Located(cs472, ph219) …•Note: Relations typically correspond to verbs–Functions: Pair(search,Pair(learning,Pair(kbsystems, emptylist)))– Connectives: ∧, ∨, ¬, ⇒, ⇔– Quantifiers: • Universal: ∀x: ( is_Man(x) ⇒is_Mortal(x) )• Existential: ∃y: ( is_Father(y, fred) ) Example: Representing Facts in First-Order Logic1.Lucy* is a professor2.All professors are people.3.Fuchs is the dean.4.Deans are professors.5.All professors consider the dean a friend or don’t know him.6.Everyone is a friend of someone.7.People only criticize people that are not their friends. 8.Lucy criticized Fuchs. * Name changed for privacy reasons.Example: ProofKnowledge base:•is-prof(lucy)•∀x ( is-prof(x) →is-person(x) )•is-dean(fuchs)•∀x (is-dean(x) Æis-prof(x))•∀x (∀y ( is-prof(x) ∧is-dean(y) →is-friend-of(y,x) ∨¬knows(x, y) ) )•∀x (∃y ( is-friend-of (y, x) ) )•∀x (Vy (is-person(x) ∧is-person(y) ∧criticize (x,y) →¬is-friend-of (y,x)))•criticize(lucy,fuchs)Question: Is Fuchs no friend of Lucy?¬is-friend-of(fuchs,lucy)Knowledge Engineering1.Identify the task. 2.Assemble the relevant knowledge.3.Decide on a vocabulary of predicates, functions, and constants. 4.Encode general knowledge about the domain.5.Encode a description of the specific problem instance. 6.Pose queries to the inference procedure and get answers. 7.Debug the knowledge base. Inference Procedures: Theoretical Results•There exist complete and sound proof procedures for propositional and FOL. –Propositional logic•Use the definition of entailment directly. Proof procedure is exponential in n, the number of symbols. •In practice, can be much faster…•Polynomial-time inference procedure exists when KB is expressed as Horn clauses: where the Piand Qare non-negated atoms. –First-Order logic•Godel’s completeness theorem showed that a proof procedure exists…•But none was demonstrated until Robinson’s 1965 resolution algorithm. •Entailment in first-order logic is semidecidable.
has intentionally blurred sections.
Sign up to view the full version.