Presentation is loading. Please wait.

Presentation is loading. Please wait.

9/18/2000copyright Brian Williams1 Propositional Logic Brian C. Williams 16.412J/6.834J October 10, 2001.

Similar presentations


Presentation on theme: "9/18/2000copyright Brian Williams1 Propositional Logic Brian C. Williams 16.412J/6.834J October 10, 2001."— Presentation transcript:

1 9/18/2000copyright Brian Williams1 Propositional Logic Brian C. Williams 16.412J/6.834J October 10, 2001

2 9/18/2000copyright Brian Williams2 Assignments Readings: Chapter 6 of AIMA “Generating hard satisfiability problems” by Selman, Mitchell and Levesque. Optional Advanced: “Finding Hard Instances of the Satisfiability Problem: A Survey” by Cook and Mitchell. Handout: Guidelines for Project

3 9/18/2000copyright Brian Williams3 Assignment Homework: Project proposal due Wed, October 17 th. Complete draft of lecture slides Wed, Oct. 17 th and pass to another team for feedback. Sign up for presentation time.

4 9/18/2000copyright Brian Williams4 Outline Why propositional inference? Propositional logic Satisfiability by enumeration Summary

5 Monitors Autonomous Agents: What is missing? Command dispatch Fault protection Attitude control Mission Goal Scenario Self-commandingSelf-diagnosingSelf-repairing RECOVERY PLANNING EXECUTION

6 9/18/2000copyright Brian Williams6 sense P(s) WORLD observations actions AGENT Diagnostic Agent: Monitors & Diagnoses Repairs & Avoids Probes and Tests Plant act Reasons about hidden state

7 9/18/2000copyright Brian Williams7 What is Fault Diagnosis? Given a system with symptomatic behavior, find diagnoses that eliminate symptoms. 6 6 12 Symptom M1 M2 M3 A1 A2 A B C D E 3 2 2 3 3 F G X Y Z 10 12 Constraint Suspension

8 9/18/2000copyright Brian Williams8 AI Conventional Wisdom “[For reactive systems] proving theorems is out of the question” [Agre & Chapman 87]

9 9/18/2000copyright Brian Williams9 Propositional Satisfiability In recent years, we’ve seen substantial progress in propositional reasoning and search methods. Boolean satisfiability testing: 1990: 100 variables / 200 clauses (constraints) 1998: 10,000 - 100,000 vars / 10^6 clauses Novel applications: e.g. diagnosis, planning, software / circuit testing, machine learning, and protein folding

10 9/18/2000copyright Brian Williams10 Methodology for Fast Inference Combinatorial Task Propositional Propositional Logic Encoding Satisfiability Solver Decode Results Shift work to “encoding phase’’, use fast, off-the-shelf SAT solver and tools.

11 9/18/2000copyright Brian Williams11 Outline Why propositional inference? Propositional logic Satisfiability by enumeration Summary

12 9/18/2000copyright Brian Williams12 Logic in General Logics formal languages for representing information such that conclusions can be drawn. Syntax defines the sentences in the language. Semantics define the “meaning” of sentences; i.e., truth of a sentence in a world.

13 9/18/2000copyright Brian Williams13 Propositional Logic: Syntax Proposition Statement that is true or false (valve v1) (= voltage high) Propositional sentence (S) S ::= proposition | (NOT S) | (OR S1... Sn) | (AND S1... Sn) Defined Constructs (implies S1 S2) => ((not S1) OR S2) (IFF S1 S2) => (AND (IMPLIES S1 S2)(IMPLIES S2 S1))...

14 9/18/2000copyright Brian Williams14 Engine Example: propositional logic model (mode(E1) = ok implies (thrust(E1) = on exactly when flow(V1) = on and flow(V2) = on)) and (mode(E1) = ok or mode(E1) = unknown) and not (mode(E1) = ok and mode(E1) = unknown) E1 V1V2

15 9/18/2000copyright Brian Williams15 Propositional Logic: Semantics A model assigns true/false to every proposition symbol P i A = True, B = False, C = False Truth determined by applying boolean operators to model: Not S is True iff S is False S 1 and S 2 is True iff S 1 is True and S 2 is True S 1 or S 2 is True iff S 1 is True or S 2 is True S 1 implies S 2 is True iff S 1 is False or S 2 is True S 1 iff S 2 is True iff S 1 implies S 2 is True or S 2 implies S 1 is True

16 9/18/2000copyright Brian Williams16 Entailment and Models Given knowledge base KB, and sentence  KB entails  iff  is true in all models where KB is true Example KB = “Giants won”, “Reds won”  = “Either the Giants won or the Reds won”

17 9/18/2000copyright Brian Williams17 Models and Entailment m is a model of sentence  if  is true given m. M(  ) denotes the set of all models of sentence  Entailment KB entails  iff M(KB) subset M(  ) M(  ) M(KB)

18 9/18/2000copyright Brian Williams18 Outline Why propositional inference? Propositional logic Satisfiability by enumeration Summary

19 9/18/2000copyright Brian Williams19 Propositional Inference: Enumeration Method KB = (A or C) and (B or not C)  = A or B Does KB entail  ? ABCA or CB or not CKB  False True FalseTrueFalse True False TrueFalseTrue False True

20 9/18/2000copyright Brian Williams20 Propositional Inference: Enumeration Method KB = (A or C) and (B or not C)  = A or B Does KB entail  ? ABCA or CB or not CKB  False TrueFalse True False TrueFalse TrueFalseTrue FalseTrue False True FalseTrue False True FalseTrue

21 9/18/2000copyright Brian Williams21 Propositional Satisfiability by Enumeration Assign true or false to an unassigned proposition. Backtrack as soon as a clause is violated. Example: C1: Not A or B C2: Not C or A C3: Not B or C A FT B FT C FT C FT B FT CC FTFT

22 9/18/2000copyright Brian Williams22 Backtrack Search Procedure BT(phi,A) Input: A cnf theory phi, an assignment A to propositions in phi Output: A decision of whether phi is satisfiable. 1. If a clause is violated return(false); 2. Else if all propositions are assigned return(true); 3. ElseQ = some unassigned proposition in phi; 4.Return (BT(phi, A[Q = True]) or 5. BT(phi, A[Q = False])

23 9/18/2000copyright Brian Williams23 Validity and Satisfiability A sentence is valid if it is true in all models. A sentence is satisfiable if it is true in some model. A sentence is unsatisfiable if it is true in no model. Validity connects to entailment by the Deduction Theorem: KB entails  iff “KB implies  ” is valid Satisfiability connects to entailment by Reductio Ad Absurdum: KB entails  iff “KB and not  ” is unsatisfiable.

24 9/18/2000copyright Brian Williams24 Types of Logic Logics are characterized by their primitives Ontological commitment: – what exists? facts, objects, time, beliefs Epistemological commitment: - states of knowledge? True, false, unknown … LanguageOntological Commitment Epistemological Commitment Propositional LogicfactsTrue/false/unknown First-order LogicFacts,objects,relationsTrue/false/unknown Temporal logicFacts,objects,relations, times True/false/unknown Probability theoryfactsDegree of belief 0…1 Fuzzy logicDegree of truthDegree of belief 0…1

25 9/18/2000copyright Brian Williams25 Logic Example: Arithmetic Syntax – legal sentences X + 2 > Y is a sentence. X 2 + Y > is not a sentence. Semantics - truth in world X + 2 > Y is true iff the number x + 2 is not less than or equal to the number y X + 2 > Y is true in a world where X = 7, Y = 1 X + 2 > Y is false in a world where X = 0, Y = 6

26 9/18/2000copyright Brian Williams26 Outline Why propositional inference? Propositional logic Satisfiability by enumeration Summary

27 9/18/2000copyright Brian Williams27 Summary Logical agents apply inference to a knowledge base to derive new information and make decisions. Basic concepts in logic Syntax: formal structure of sentences. Semantics: truth of sentence wrt models. Entailment: necessary truth of a sentence given another. Inference: deriving sentences from others. Soundness: derivations produce only entailed sentences. Completeness: derivations can produce all entailed sentences. Enumeration method is sound and complete for propositional logic.

28 9/18/2000copyright Brian Williams28 Models and Truth A model assigns true/false to every proposition symbol The truth of a sentence wrt a model. is determined by applying boolean operators (and, or, not) to the model. A sentence is valid if it is true in all models. A sentence is satisfiable if it is true in some model. A sentence is unsatisfiable if it is true in no model.

29 9/18/2000copyright Brian Williams29 Propositional Satisfiability by Depth First Search Assign true or false to an unassigned proposition. Backtrack as soon as a clause is violated. Satisfiable if assignment is complete. Example: C1: Not A or B C2: Not C or A C3: Not B or C A FT B FT C FT C FT B FT CC FTFT

30 9/18/2000copyright Brian Williams30 Entailment KB entails  iff  is true in all models where KB is true. Proving Entailment: KB entails  iff (KB implies  ) is valid KB entails  iff (KB and not  ) is unsatisfiable. M(  ) M(KB)


Download ppt "9/18/2000copyright Brian Williams1 Propositional Logic Brian C. Williams 16.412J/6.834J October 10, 2001."

Similar presentations


Ads by Google