Announcements. Assignment 5 due today Assignment 6 (smaller than others) available sometime today Midterm: 27 February.

Size: px
Start display at page:

Download "Announcements. Assignment 5 due today Assignment 6 (smaller than others) available sometime today Midterm: 27 February."

Transcription

1 Announcements Assignment 5 due today Assignment 6 (smaller than others) available sometime today Midterm: 27 February. You can bring in a letter sized sheet of paper with anything written in it. Exam will cover material up to Wednesday of this week It assumes what is covered in class as well as the content of the assignments. Practice midterm available this week We have been promised more reliable lecture recording. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 12 1 / 37

2 Review: Propositions and Inference KB = g (g is a logical consequence of KB) if and only if g is true in every model of KB. The bottom-up proof procedure computs all consequences of a knowledge base. Top-down proof procedure searches from the goal to find a proof for a query. Assumables are used in a proof by contradiction. A conflict is a set of assumables that, together with the knowledge base, implies false. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 12 2 / 37

3 Search Space for SLD Resolution The search space for a query?q given KB is defined by: nodes: answer clauses yes body neighbors of a node: select an atom in body there is a neighbor for every clause with that atom in the head neighbors are defined by SLD resolution start node: yes q. goal node: yes. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 12 3 / 37

4 Clicker Question Suppose the knowledge base includes: w y z p s t p w answer clause: yes w r atom w is selected which of the following is a possible next answer clause A yes w r B yes y z r C yes y z p D yes w r y z E none of the above c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 12 4 / 37

5 Clicker Question Suppose the knowledge base includes: w y z p s t p w answer clause: yes p r atom p is selected which of the following is the next answer clause A either yes w r or yes s t r B yes s t w r C either yes y z r or yes s t r D yes y z s t E none of the above c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 12 5 / 37

6 Learning Objectives assumption-based reasoning (continued) knowledge-based debugging representing actions c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 12 6 / 37

7 Questions and Answers in Horn KBs An assumable is an atom whose negation you are prepared to accept as part of a (disjunctive) answer. A conflict of KB is a set of assumables that, given KB imply false. A minimal conflict is a conflict such that no strict subset is also a conflict. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 12 7 / 37

8 Clicker Question {c, d, e, f, g, h} are the assumables false a b. a c. KB = a e. b d. b e. A {e} is a minimal conflict B {e} is a conflict but not a minimal conflict C {e} is a set of assumables that is not a conflict D {e} is not a set of assumables c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 12 8 / 37

9 Clicker Question {c, d, e, f, g, h} are the assumables false a b. a c. KB = a e. b d. b e. A {c, d, e} is a minimal conflict B {c, d, e} is a conflict but not a minimal conflict C {c, d, e} is a set of assumables that is not a conflict D {c, d, e} is not a set of assumables c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 12 9 / 37

10 Clicker Question {c, d, e, f, g, h} are the assumables false a b. a c. KB = a e. b d. b e. A {c, d} is a minimal conflict B {c, d} is a conflict but not a minimal conflict C {c, d} is a set of assumables that is not a conflict D {c, d} is not a set of assumables c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

11 Clicker Question {c, d, e, f, g, h} are the assumables false a b. a c. KB = a e. b d. b e. A {c, d, e, h} is a minimal conflict B {c, d, e, h} is a conflict but not a minimal conflict C {c, d, e, h} is a set of assumables that is not a conflict D {c, d, e, h} is not a set of assumables c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

12 Clicker Question {c, d, e, f, g, h} are the assumables false a b. a c. KB = a e. b d. b e. A {a, d} is a minimal conflict B {a, d} is a conflict but not a minimal conflict C {a, d} is a set of assumables that is not a conflict D {a, d} is not a set of assumables c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

13 Clicker Question {c, d, e, f, g, h} are the assumables false a b. a c. KB = a e. b d. b e. The set of all minimal conflicts is A {{e}} B {{e}, {c, d}} C {{e}, {c, d}, {e, d}, {c, e}} D {} E None of the above c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

14 Using Conflicts for Diagnosis Assume that the user is able to observe whether a light is lit or dark and whether a power outlet is dead or live. A light can t be both lit and dark. An outlet can t be both live and dead: false dark l 1 lit l 1. false dark l 2 lit l 2. false dead p 1 live p 2. Assume the individual components are working correctly: assumable ok l 1. assumable ok s Suppose switches s 1, s 2, and s 3 are all up: up s 1. up s 2. up s 3. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

15 Electrical Environment s 1 w 1 s 2 w 2 s 3 w 0 cb 1 w 3 w w 6 4 l 1 w 5 cb 2 outside power off circuit breaker switch on two-way switch l 2 p 2 light p 1 power outlet c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

16 Representing the Electrical Environment light l 1. light l 2. up s 1. up s 2. up s 3. live outside. lit l 1 live w 0 ok l 1. live w 0 live w 1 up s 2 ok s 2. live w 0 live w 2 down s 2 ok s 2. live w 1 live w 3 up s 1 ok s 1. live w 2 live w 3 down s 1 ok s 1. lit l 2 live w 4 ok l 2. live w 4 live w 3 up s 3 ok s 3. live p 1 live w 3. live w 3 live w 5 ok cb 1. live p 2 live w 6. live w 6 live w 5 ok cb 2. live w 5 live outside. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

17 If the user has observed l 1 and l 2 are both dark: dark l 1. dark l 2. There are two minimal conflicts: {ok cb 1, ok s 1, ok s 2, ok l 1 } and {ok cb 1, ok s 3, ok l 2 }. You can derive: ( ok cb 1 ok s 1 ok s 2 ok l 1 ) ( ok cb 1 ok s 3 ok l 2 ). Either cb 1 is broken or there is one of six double faults. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

18 Conflicts in AILog elect_cbd.ail Load into AILog and ask queries commented out at bottom. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

19 Diagnoses A consistency-based diagnosis is a set of assumables that has one element in each conflict. A minimal diagnosis is a diagnosis such that no subset is also a diagnosis. Intuitively, one of the minimal diagnoses must hold. A diagnosis holds if all of its elements are false. Example: For the proceeding example the conflicts imply ( ok cb 1 ok s 1 ok s 2 ok l 1 ) ( ok cb 1 ok s 3 ok l 2 ). This can be distributed into: ok cb 1 ( ok s 1 ok s 3 ) ( ok s 1 ok l 2 ) ( ok s 2 ok s 3 ) ( ok s 2 ok l 2 ) ( ok l 1 ok s 3 ) ( ok l 1 ok l 2 ) c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

20 Recall: top-down consequence finding To solve the query?q 1... q k : ac := yes q 1... q k repeat select atom a 1 from the body of ac choose clause C from KB with a 1 as head replace a 1 in the body of ac by the body of C until ac is an answer. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

21 Implementing conflict finding: top down Query is false. Don t select an atom that is assumable. Stop when all of the atoms in the body of the generalised query are assumable: This set of assumables is a conflict You may need to search to find minimal conflicts c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

22 Example false a. a b c. b d. b e. c f. c g. e h w. e g. w f. assumable d, f, g, h. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

23 Knowledge-Level Debugging There are four types of non-syntactic errors that can arise in rule-based systems: An incorrect answer is produced: an atom that is false in the intended interpretation was derived. Some answer wasn t produced: the proof failed when it should have succeeded. Some particular true atom wasn t derived. The program gets into an infinite loop. The system asks irrelevant questions. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

24 Debugging incorrect answers Suppose atom g was proved but is false in the intended interpretation. There must be a clause g a 1... a k in the knowledge base that was used to prove g. Either: one of the ai is false in the intended interpretation or all of the ai are true in the intended interpretation. Incorrect answers can be debugged by only answering yes/no questions. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

25 Electrical Environment cb1 outside power s1 w5 w0 l1 s2 w1 w2 w4 s3 w3 cb2 w6 p2 off circuit breaker switch on two-way switch l2 p1 light power outlet elect_bug.ail (no assumables or askables) c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

26 Missing Answers If atom g is true in the intended interpretation, but could not be proved, either: There is no appropriate clause for g. There is a rule g a 1... a k that should have succeeded. One of the ai is true in the interpretation and could not be proved. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

27 State-space Search deterministic or stochastic dynamics fully observable or partially observable explicit states or features or individuals and relations static or finite stage or indefinite stage or infinite stage goals or complex preferences perfect rationality or bounded rationality flat or modular or hierarchical single agent or multiple agents knowledge is given or knowledge is learned reason offline or reason while interacting with environment c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

28 Classical Planning deterministic or stochastic dynamics fully observable or partially observable explicit states or features or individuals and relations static or finite stage or indefinite stage or infinite stage goals or complex preferences perfect rationality or bounded rationality flat or modular or hierarchical single agent or multiple agents knowledge is given or knowledge is learned reason offline or reason while interacting with environment c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

29 Planning Planning is deciding what to do based on an agent s ability, its goals. and the state of the world. Planning is finding a sequence of actions to solve a goal. Initial assumptions: The world is deterministic. There are no exogenous events outside of the control of the robot that change the state of the world. The agent knows what state it is in. Time progresses discretely from one state to the next. Goals are predicates of states that need to be achieved. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

30 Actions A deterministic action is a partial function from states to states. The preconditions of an action specify when the action can be carried out. The effect of an action specifies the resulting state. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

31 Delivery Robot Example Coffee Shop (cs) Sam's Office (off ) Mail Room (mr ) Lab (lab) Features: RLoc Rob s location RHC Rob has coffee SWC Sam wants coffee MW Mail is waiting RHM Rob has mail Actions: mc move clockwise mcc move counterclockwise puc pickup coffee dc deliver coffee pum pickup mail dm deliver mail c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

32 Explicit State-space Representation State Action Resulting State lab, rhc, swc, mw, rhm mc mr, rhc, swc, mw, rhm lab, rhc, swc, mw, rhm mcc off, rhc, swc, mw, rhm off, rhc, swc, mw, rhm dm off, rhc, swc, mw, rhm off, rhc, swc, mw, rhm mcc cs, rhc, swc, mw, rhm off, rhc, swc, mw, rhm mc lab, rhc, swc, mw, rhm What happens when we also want to model its battery charge? c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

33 STRIPS Representation For each action specify: precondition: when the action can be carried out. effect: a set of assignments of values to features that are made true by this action. STRIPS assumption: every feature not mentioned in the effects is unaffected by the action. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

34 Example STRIPS representation Pick-up coffee (puc): precondition: [cs, rhc] effect: [rhc] Deliver coffee (dc): precondition: [off, rhc] effect: [ rhc, swc] c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

35 Planning Given: A description of the effects and preconditions of the actions A description of the initial state A goal to achieve find a sequence of actions that is possible and will result in a state satisfying the goal. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

36 Forward Planning Idea: search in the state-space graph. The nodes represent the states The arcs correspond to the actions: The arcs from a state s represent all of the actions that are legal in state s. A plan is a path from the state representing the initial state to a state that satisfies the goal. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

37 Example state-space graph Actions mc: move clockwise mac: move anticlockwise cs,rhc,swc,mw,rhm nm: no move puc puc: pick up coffee mc mac dc: deliver coffee pum: pick up mail dm: deliver mail cs,rhc,swc,mw,rhm mc off,rhc,swc,mw,rhm mc mr,rhc,swc,mw,rhm mac off,rhc,swc,mw,rhm mac lab,rhc,swc,mw,rhm cs,rhc,swc,mw,rhm dc off,rhc,swc,mw,rhm mc mac mac lab,rhc,swc,mw,rhm mr,rhc,swc,mw,rhm Locations: cs: coffee shop off: office lab: laboratory mr: mail room mr,rhc,swc,mw,rhm Feature values rhc: robot has coffee swc: Sam wants coffee mw: mail waiting rhm: robot has mail c D. Poole and A. Mackworth 2017 CPSC 322 Lecture / 37

Propositions. c D. Poole and A. Mackworth 2010 Artificial Intelligence, Lecture 5.1, Page 1

Propositions. c D. Poole and A. Mackworth 2010 Artificial Intelligence, Lecture 5.1, Page 1 Propositions An interpretation is an assignment of values to all variables. A model is an interpretation that satisfies the constraints. Often we don t want to just find a model, but want to know what

More information

Chapter 5: Propositions and Inference. c D. Poole, A. Mackworth 2010, W. Menzel 2015 Artificial Intelligence, Chapter 5, Page 1

Chapter 5: Propositions and Inference. c D. Poole, A. Mackworth 2010, W. Menzel 2015 Artificial Intelligence, Chapter 5, Page 1 Chapter 5: Propositions and Inference c D. Poole, A. Mackworth 2010, W. Menzel 2015 Artificial Intelligence, Chapter 5, Page 1 Propositions An interpretation is an assignment of values to all variables.

More information

Propositions. c D. Poole and A. Mackworth 2008 Artificial Intelligence, Lecture 5.1, Page 1

Propositions. c D. Poole and A. Mackworth 2008 Artificial Intelligence, Lecture 5.1, Page 1 Propositions An interpretation is an assignment of values to all variables. A model is an interpretation that satisfies the constraints. Often we don t want to just find a model, but want to know what

More information

Propositional Logic: Semantics and an Example

Propositional Logic: Semantics and an Example Propositional Logic: Semantics and an Example CPSC 322 Logic 2 Textbook 5.2 Propositional Logic: Semantics and an Example CPSC 322 Logic 2, Slide 1 Lecture Overview 1 Recap: Syntax 2 Propositional Definite

More information

Individuals and Relations

Individuals and Relations Individuals and Relations It is useful to view the world as consisting of individuals (objects, things) and relations among individuals. Often features are made from relations among individuals and functions

More information

Propositional Logic: Bottom-Up Proofs

Propositional Logic: Bottom-Up Proofs Propositional Logic: Bottom-Up Proofs CPSC 322 Logic 3 Textbook 5.2 Propositional Logic: Bottom-Up Proofs CPSC 322 Logic 3, Slide 1 Lecture Overview 1 Recap 2 Bottom-Up Proofs 3 Soundness of Bottom-Up

More information

Logic: Bottom-up & Top-down proof procedures

Logic: Bottom-up & Top-down proof procedures Logic: Bottom-up & Top-down proof procedures Alan Mackworth UBC CS 322 Logic 3 March 4, 2013 P & M Textbook 5.2 Lecture Overview Recap: Soundness, Completeness, Bottom-up proof procedure Bottom-up Proof

More information

Logic: Resolution Proofs; Datalog

Logic: Resolution Proofs; Datalog Logic: ; Datalog CPSC 322 Logic 5 Textbook 5.2; 12.2 Logic: ; Datalog CPSC 322 Logic 5, Slide 1 Lecture Overview 1 Recap 2 Logic: ; Datalog CPSC 322 Logic 5, Slide 2 Proofs A proof is a mechanically derivable

More information

Announcements. Solution to Assignment 3 is posted Assignment 4 is available. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 8 1 / 25

Announcements. Solution to Assignment 3 is posted Assignment 4 is available. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 8 1 / 25 Announcements Solution to Assignment 3 is posted Assignment 4 is available c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 8 1 / 25 Review: So far... Constraint satisfaction problems defined in terms

More information

Chapters 2&3: A Representation and Reasoning System

Chapters 2&3: A Representation and Reasoning System Computational Intelligence Chapter 2 Chapters 2&3: A Representation and Reasoning System Lecture 1 Representation and Reasoning Systems. Datalog. Lecture 2 Semantics. Lecture 3 Variables, queries and answers,

More information

Logic: Intro & Propositional Definite Clause Logic

Logic: Intro & Propositional Definite Clause Logic Logic: Intro & Propositional Definite Clause Logic Alan Mackworth UBC CS 322 Logic 1 February 27, 2013 P & M extbook 5.1 Lecture Overview Recap: CSP planning Intro to Logic Propositional Definite Clause

More information

Logic: Top-down proof procedure and Datalog

Logic: Top-down proof procedure and Datalog Logic: Top-down proof procedure and Datalog CPSC 322 Logic 4 Textbook 5.2 March 11, 2011 Lecture Overview Recap: Bottom-up proof procedure is sound and complete Top-down Proof Procedure Datalog 2 Logical

More information

Reasoning Under Uncertainty: Belief Network Inference

Reasoning Under Uncertainty: Belief Network Inference Reasoning Under Uncertainty: Belief Network Inference CPSC 322 Uncertainty 5 Textbook 10.4 Reasoning Under Uncertainty: Belief Network Inference CPSC 322 Uncertainty 5, Slide 1 Lecture Overview 1 Recap

More information

Contents Chapters 2 & 3

Contents Chapters 2 & 3 Contents Chapters 2 & 3 Chapters 2 & 3: A Representation and Reasoning System Lecture 1 Representation and Reasoning Systems. Datalog. Lecture 2 Semantics. Lecture 3 Variables, queries and answers, limitations.

More information

Chapter 1, Part I: Propositional Logic. With Question/Answer Animations

Chapter 1, Part I: Propositional Logic. With Question/Answer Animations Chapter 1, Part I: Propositional Logic With Question/Answer Animations Chapter Summary! Propositional Logic! The Language of Propositions! Applications! Logical Equivalences! Predicate Logic! The Language

More information

Artificial Intelligence Chapter 7: Logical Agents

Artificial Intelligence Chapter 7: Logical Agents Artificial Intelligence Chapter 7: Logical Agents Michael Scherger Department of Computer Science Kent State University February 20, 2006 AI: Chapter 7: Logical Agents 1 Contents Knowledge Based Agents

More information

Announcements. Project 1 underway... Second midterm Friday. discuss ideas with TAs check out wiki

Announcements. Project 1 underway... Second midterm Friday. discuss ideas with TAs check out wiki Announcements Project 1 underway... discuss ideas with TAs check out wiki Second midterm Friday You may bring on one letter-sized sheet of paper with anything written or drawn or... anywhere on it. It

More information

Outline. Logical Agents. Logical Reasoning. Knowledge Representation. Logical reasoning Propositional Logic Wumpus World Inference

Outline. Logical Agents. Logical Reasoning. Knowledge Representation. Logical reasoning Propositional Logic Wumpus World Inference Outline Logical Agents ECE57 Applied Artificial Intelligence Spring 007 Lecture #6 Logical reasoning Propositional Logic Wumpus World Inference Russell & Norvig, chapter 7 ECE57 Applied Artificial Intelligence

More information

CS 331: Artificial Intelligence Propositional Logic I. Knowledge-based Agents

CS 331: Artificial Intelligence Propositional Logic I. Knowledge-based Agents CS 331: Artificial Intelligence Propositional Logic I 1 Knowledge-based Agents Can represent knowledge And reason with this knowledge How is this different from the knowledge used by problem-specific agents?

More information

Knowledge-based Agents. CS 331: Artificial Intelligence Propositional Logic I. Knowledge-based Agents. Outline. Knowledge-based Agents

Knowledge-based Agents. CS 331: Artificial Intelligence Propositional Logic I. Knowledge-based Agents. Outline. Knowledge-based Agents Knowledge-based Agents CS 331: Artificial Intelligence Propositional Logic I Can represent knowledge And reason with this knowledge How is this different from the knowledge used by problem-specific agents?

More information

The Foundations: Logic and Proofs. Part I

The Foundations: Logic and Proofs. Part I The Foundations: Logic and Proofs Part I Chapter Summary Propositional Logic n The Language of Propositions n Applications n Logical Equivalences Predicate Logic n The Language of Quantifiers n Logical

More information

Propositional Logic 1

Propositional Logic 1 Propositional Logic 1 Section Summary Propositions Connectives Negation Conjunction Disjunction Implication; contrapositive, inverse, converse Biconditional Truth Tables 2 Propositions A proposition is

More information

Outline. Logical Agents. Logical Reasoning. Knowledge Representation. Logical reasoning Propositional Logic Wumpus World Inference

Outline. Logical Agents. Logical Reasoning. Knowledge Representation. Logical reasoning Propositional Logic Wumpus World Inference Outline Logical Agents ECE57 Applied Artificial Intelligence Spring 008 Lecture #6 Logical reasoning Propositional Logic Wumpus World Inference Russell & Norvig, chapter 7 ECE57 Applied Artificial Intelligence

More information

Logical Agent & Propositional Logic

Logical Agent & Propositional Logic Logical Agent & Propositional Logic Berlin Chen 2005 References: 1. S. Russell and P. Norvig. Artificial Intelligence: A Modern Approach. Chapter 7 2. S. Russell s teaching materials Introduction The representation

More information

Chapter 7 R&N ICS 271 Fall 2017 Kalev Kask

Chapter 7 R&N ICS 271 Fall 2017 Kalev Kask Set 6: Knowledge Representation: The Propositional Calculus Chapter 7 R&N ICS 271 Fall 2017 Kalev Kask Outline Representing knowledge using logic Agent that reason logically A knowledge based agent Representing

More information

COMP9414: Artificial Intelligence Propositional Logic: Automated Reasoning

COMP9414: Artificial Intelligence Propositional Logic: Automated Reasoning COMP9414, Monday 26 March, 2012 Propositional Logic 2 COMP9414: Artificial Intelligence Propositional Logic: Automated Reasoning Overview Proof systems (including soundness and completeness) Normal Forms

More information

Propositional Logic: Semantics

Propositional Logic: Semantics Propositional Logic: Semantics Alice Gao Lecture 4, September 19, 2017 Semantics 1/56 Announcements Semantics 2/56 The roadmap of propositional logic Semantics 3/56 FCC spectrum auction an application

More information

Price: $25 (incl. T-Shirt, morning tea and lunch) Visit:

Price: $25 (incl. T-Shirt, morning tea and lunch) Visit: Three days of interesting talks & workshops from industry experts across Australia Explore new computing topics Network with students & employers in Brisbane Price: $25 (incl. T-Shirt, morning tea and

More information

MIDTERM: CS 6375 INSTRUCTOR: VIBHAV GOGATE October,

MIDTERM: CS 6375 INSTRUCTOR: VIBHAV GOGATE October, MIDTERM: CS 6375 INSTRUCTOR: VIBHAV GOGATE October, 23 2013 The exam is closed book. You are allowed a one-page cheat sheet. Answer the questions in the spaces provided on the question sheets. If you run

More information

Solutions to Sample Problems for Midterm

Solutions to Sample Problems for Midterm Solutions to Sample Problems for Midterm Problem 1. The dual of a proposition is defined for which contains only,,. It is For a compound proposition that only uses,, as operators, we obtained the dual

More information

Guest Speaker. CS 416 Artificial Intelligence. First-order logic. Diagnostic Rules. Causal Rules. Causal Rules. Page 1

Guest Speaker. CS 416 Artificial Intelligence. First-order logic. Diagnostic Rules. Causal Rules. Causal Rules. Page 1 Page 1 Guest Speaker CS 416 Artificial Intelligence Lecture 13 First-Order Logic Chapter 8 Topics in Optimal Control, Minimax Control, and Game Theory March 28 th, 2 p.m. OLS 005 Onesimo Hernandez-Lerma

More information

Computer Science CPSC 322. Lecture 23 Planning Under Uncertainty and Decision Networks

Computer Science CPSC 322. Lecture 23 Planning Under Uncertainty and Decision Networks Computer Science CPSC 322 Lecture 23 Planning Under Uncertainty and Decision Networks 1 Announcements Final exam Mon, Dec. 18, 12noon Same general format as midterm Part short questions, part longer problems

More information

Intelligent Agents. Pınar Yolum Utrecht University

Intelligent Agents. Pınar Yolum Utrecht University Intelligent Agents Pınar Yolum p.yolum@uu.nl Utrecht University Logical Agents (Based mostly on the course slides from http://aima.cs.berkeley.edu/) Outline Knowledge-based agents Wumpus world Logic in

More information

CSC242: Intro to AI. Lecture 11. Tuesday, February 26, 13

CSC242: Intro to AI. Lecture 11. Tuesday, February 26, 13 CSC242: Intro to AI Lecture 11 Propositional Inference Propositional Inference Factored Representation Splits a state into variables (factors, attributes, features, things you know ) that can have values

More information

EE562 ARTIFICIAL INTELLIGENCE FOR ENGINEERS

EE562 ARTIFICIAL INTELLIGENCE FOR ENGINEERS EE562 ARTIFICIAL INTELLIGENCE FOR ENGINEERS Lecture 10, 5/9/2005 University of Washington, Department of Electrical Engineering Spring 2005 Instructor: Professor Jeff A. Bilmes Logical Agents Chapter 7

More information

AI Programming CS S-09 Knowledge Representation

AI Programming CS S-09 Knowledge Representation AI Programming CS662-2013S-09 Knowledge Representation David Galles Department of Computer Science University of San Francisco 09-0: Overview So far, we ve talked about search, which is a means of considering

More information

7. Propositional Logic. Wolfram Burgard and Bernhard Nebel

7. Propositional Logic. Wolfram Burgard and Bernhard Nebel Foundations of AI 7. Propositional Logic Rational Thinking, Logic, Resolution Wolfram Burgard and Bernhard Nebel Contents Agents that think rationally The wumpus world Propositional logic: syntax and semantics

More information

NP-Completeness Part II

NP-Completeness Part II NP-Completeness Part II Please evaluate this course on Axess. Your comments really do make a difference. Announcements Problem Set 8 due tomorrow at 12:50PM sharp with one late day. Problem Set 9 out,

More information

Foundations of Artificial Intelligence

Foundations of Artificial Intelligence Foundations of Artificial Intelligence 7. Propositional Logic Rational Thinking, Logic, Resolution Wolfram Burgard, Maren Bennewitz, and Marco Ragni Albert-Ludwigs-Universität Freiburg Contents 1 Agents

More information

Foundations of Artificial Intelligence

Foundations of Artificial Intelligence Foundations of Artificial Intelligence 7. Propositional Logic Rational Thinking, Logic, Resolution Joschka Boedecker and Wolfram Burgard and Bernhard Nebel Albert-Ludwigs-Universität Freiburg May 17, 2016

More information

Turing Machines Part III

Turing Machines Part III Turing Machines Part III Announcements Problem Set 6 due now. Problem Set 7 out, due Monday, March 4. Play around with Turing machines, their powers, and their limits. Some problems require Wednesday's

More information

Propositional Logic: Methods of Proof (Part II)

Propositional Logic: Methods of Proof (Part II) Propositional Logic: Methods of Proof (Part II) You will be expected to know Basic definitions Inference, derive, sound, complete Conjunctive Normal Form (CNF) Convert a Boolean formula to CNF Do a short

More information

Logical Agent & Propositional Logic

Logical Agent & Propositional Logic Logical Agent & Propositional Logic Berlin Chen Department of Computer Science & Information Engineering National Taiwan Normal University References: 1. S. Russell and P. Norvig. Artificial Intelligence:

More information

Proof Methods for Propositional Logic

Proof Methods for Propositional Logic Proof Methods for Propositional Logic Logical equivalence Two sentences are logically equivalent iff they are true in the same models: α ß iff α β and β α Russell and Norvig Chapter 7 CS440 Fall 2015 1

More information

CSE 20 DISCRETE MATH WINTER

CSE 20 DISCRETE MATH WINTER CSE 20 DISCRETE MATH WINTER 2016 http://cseweb.ucsd.edu/classes/wi16/cse20-ab/ Reminders Exam 1 in one week One note sheet ok Review sessions Saturday / Sunday Assigned seats: seat map on Piazza shortly

More information

Kecerdasan Buatan M. Ali Fauzi

Kecerdasan Buatan M. Ali Fauzi Kecerdasan Buatan M. Ali Fauzi Artificial Intelligence M. Ali Fauzi Logical Agents M. Ali Fauzi In which we design agents that can form representations of the would, use a process of inference to derive

More information

Propositional Logic: Methods of Proof (Part II)

Propositional Logic: Methods of Proof (Part II) Propositional Logic: Methods of Proof (Part II) This lecture topic: Propositional Logic (two lectures) Chapter 7.1-7.4 (previous lecture, Part I) Chapter 7.5 (this lecture, Part II) (optional: 7.6-7.8)

More information

Logical Agents. Chapter 7

Logical Agents. Chapter 7 Logical Agents Chapter 7 Outline Knowledge-based agents Wumpus world Logic in general - models and entailment Propositional (Boolean) logic Equivalence, validity, satisfiability Inference rules and theorem

More information

Intelligent Systems (AI-2)

Intelligent Systems (AI-2) Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 19 Oct, 23, 2015 Slide Sources Raymond J. Mooney University of Texas at Austin D. Koller, Stanford CS - Probabilistic Graphical Models D. Page,

More information

Logical Agents (I) Instructor: Tsung-Che Chiang

Logical Agents (I) Instructor: Tsung-Che Chiang Logical Agents (I) Instructor: Tsung-Che Chiang tcchiang@ieee.org Department of Computer Science and Information Engineering National Taiwan Normal University Artificial Intelligence, Spring, 2010 編譯有誤

More information

Final exam of ECE 457 Applied Artificial Intelligence for the Fall term 2007.

Final exam of ECE 457 Applied Artificial Intelligence for the Fall term 2007. Fall 2007 / Page 1 Final exam of ECE 457 Applied Artificial Intelligence for the Fall term 2007. Don t panic. Be sure to write your name and student ID number on every page of the exam. The only materials

More information

Chapter Finding parse trees

Chapter Finding parse trees Chapter 16 NP Some tasks definitely require exponential time. That is, we can not only display an exponential-time algorithm, but we can also prove that the problem cannot be solved in anything less than

More information

Knowledge Representation. Propositional logic

Knowledge Representation. Propositional logic CS 2710 Foundations of AI Lecture 10 Knowledge Representation. Propositional logic Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Knowledge-based agent Knowledge base Inference engine Knowledge

More information

Intelligent Systems (AI-2)

Intelligent Systems (AI-2) Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 19 Oct, 24, 2016 Slide Sources Raymond J. Mooney University of Texas at Austin D. Koller, Stanford CS - Probabilistic Graphical Models D. Page,

More information

Description Logics. Deduction in Propositional Logic. franconi. Enrico Franconi

Description Logics. Deduction in Propositional Logic.   franconi. Enrico Franconi (1/20) Description Logics Deduction in Propositional Logic Enrico Franconi franconi@cs.man.ac.uk http://www.cs.man.ac.uk/ franconi Department of Computer Science, University of Manchester (2/20) Decision

More information

Bayesian belief networks

Bayesian belief networks CS 2001 Lecture 1 Bayesian belief networks Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square 4-8845 Milos research interests Artificial Intelligence Planning, reasoning and optimization in the presence

More information

Propositional Resolution Introduction

Propositional Resolution Introduction Propositional Resolution Introduction (Nilsson Book Handout) Professor Anita Wasilewska CSE 352 Artificial Intelligence Propositional Resolution Part 1 SYNTAX dictionary Literal any propositional VARIABLE

More information

Deliberative Agents Knowledge Representation I. Deliberative Agents

Deliberative Agents Knowledge Representation I. Deliberative Agents Deliberative Agents Knowledge Representation I Vasant Honavar Bioinformatics and Computational Biology Program Center for Computational Intelligence, Learning, & Discovery honavar@cs.iastate.edu www.cs.iastate.edu/~honavar/

More information

Propositional Logic. Logic. Propositional Logic Syntax. Propositional Logic

Propositional Logic. Logic. Propositional Logic Syntax. Propositional Logic Propositional Logic Reading: Chapter 7.1, 7.3 7.5 [ased on slides from Jerry Zhu, Louis Oliphant and ndrew Moore] Logic If the rules of the world are presented formally, then a decision maker can use logical

More information

Chapter Finding parse trees

Chapter Finding parse trees Chapter 16 NP Some tasks definitely require exponential time. That is, we can not only display an exponential-time algorithm, but we can also prove that the problem cannot be solved in anything less than

More information

16.410: Principles of Autonomy and Decision Making Final Exam

16.410: Principles of Autonomy and Decision Making Final Exam 16.410: Principles of Autonomy and Decision Making Final Exam December 15 th, 2003 Name E-mail Note: Budget your time wisely. Some parts of this exam could take you much longer than others. Move on if

More information

The exam is closed book, closed calculator, and closed notes except your one-page crib sheet.

The exam is closed book, closed calculator, and closed notes except your one-page crib sheet. CS 188 Spring 2017 Introduction to Artificial Intelligence Midterm V2 You have approximately 80 minutes. The exam is closed book, closed calculator, and closed notes except your one-page crib sheet. Mark

More information

CS 4700: Foundations of Artificial Intelligence

CS 4700: Foundations of Artificial Intelligence CS 4700: Foundations of Artificial Intelligence Bart Selman selman@cs.cornell.edu Module: Knowledge, Reasoning, and Planning Part 2 Logical Agents R&N: Chapter 7 1 Illustrative example: Wumpus World (Somewhat

More information

NP-Completeness Part II

NP-Completeness Part II NP-Completeness Part II Recap from Last Time NP-Hardness A language L is called NP-hard iff for every L' NP, we have L' P L. A language in L is called NP-complete iff L is NP-hard and L NP. The class NPC

More information

Knowledge representation DATA INFORMATION KNOWLEDGE WISDOM. Figure Relation ship between data, information knowledge and wisdom.

Knowledge representation DATA INFORMATION KNOWLEDGE WISDOM. Figure Relation ship between data, information knowledge and wisdom. Knowledge representation Introduction Knowledge is the progression that starts with data which s limited utility. Data when processed become information, information when interpreted or evaluated becomes

More information

Logical Agents: Propositional Logic. Chapter 7

Logical Agents: Propositional Logic. Chapter 7 Logical Agents: Propositional Logic Chapter 7 Outline Topics: Knowledge-based agents Example domain: The Wumpus World Logic in general models and entailment Propositional (Boolean) logic Equivalence, validity,

More information

CS 380: ARTIFICIAL INTELLIGENCE

CS 380: ARTIFICIAL INTELLIGENCE CS 380: RTIFICIL INTELLIGENCE PREDICTE LOGICS 11/8/2013 Santiago Ontañón santi@cs.drexel.edu https://www.cs.drexel.edu/~santi/teaching/2013/cs380/intro.html Summary of last day: Logical gents: The can

More information

CS 188: Artificial Intelligence Spring 2007

CS 188: Artificial Intelligence Spring 2007 CS 188: Artificial Intelligence Spring 2007 Lecture 8: Logical Agents - I 2/8/2007 Srini Narayanan ICSI and UC Berkeley Many slides over the course adapted from Dan Klein, Stuart Russell or Andrew Moore

More information

CS 4700: Artificial Intelligence

CS 4700: Artificial Intelligence CS 4700: Foundations of Artificial Intelligence Fall 2017 Instructor: Prof. Haym Hirsh Lecture 14 Today Knowledge Representation and Reasoning (R&N Ch 7-9) Prelim, Statler Auditorium Tuesday, March 21

More information

Knowledge Representation. Propositional logic.

Knowledge Representation. Propositional logic. CS 1571 Introduction to AI Lecture 10 Knowledge Representation. Propositional logic. Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Announcements Homework assignment 3 due today Homework assignment

More information

Why Learning Logic? Logic. Propositional Logic. Compound Propositions

Why Learning Logic? Logic. Propositional Logic. Compound Propositions Logic Objectives Propositions and compound propositions Negation, conjunction, disjunction, and exclusive or Implication and biconditional Logic equivalence and satisfiability Application of propositional

More information

Reasoning Under Uncertainty: Bayesian networks intro

Reasoning Under Uncertainty: Bayesian networks intro Reasoning Under Uncertainty: Bayesian networks intro Alan Mackworth UBC CS 322 Uncertainty 4 March 18, 2013 Textbook 6.3, 6.3.1, 6.5, 6.5.1, 6.5.2 Lecture Overview Recap: marginal and conditional independence

More information

Discrete Mathematics Fall 2018 Midterm Exam Prof. Callahan. Section: NetID: Multiple Choice Question (30 questions in total, 4 points each)

Discrete Mathematics Fall 2018 Midterm Exam Prof. Callahan. Section: NetID: Multiple Choice Question (30 questions in total, 4 points each) Discrete Mathematics Fall 2018 Midterm Exam Prof. Callahan Section: NetID: Name: Multiple Choice Question (30 questions in total, 4 points each) 1 Consider the following propositions: f: The student got

More information

Artificial Intelligence

Artificial Intelligence Artificial Intelligence Propositional Logic Marc Toussaint University of Stuttgart Winter 2016/17 (slides based on Stuart Russell s AI course) Motivation: Most students will have learnt about propositional

More information

Introduction to Artificial Intelligence. Logical Agents

Introduction to Artificial Intelligence. Logical Agents Introduction to Artificial Intelligence Logical Agents (Logic, Deduction, Knowledge Representation) Bernhard Beckert UNIVERSITÄT KOBLENZ-LANDAU Winter Term 2004/2005 B. Beckert: KI für IM p.1 Outline Knowledge-based

More information

CS 70 Discrete Mathematics and Probability Theory Fall 2016 Seshia and Walrand Midterm 1 Solutions

CS 70 Discrete Mathematics and Probability Theory Fall 2016 Seshia and Walrand Midterm 1 Solutions CS 70 Discrete Mathematics and Probability Theory Fall 2016 Seshia and Walrand Midterm 1 Solutions PRINT Your Name: Answer: Oski Bear SIGN Your Name: PRINT Your Student ID: CIRCLE your exam room: Dwinelle

More information

PHYS 1444 Section 004 Lecture #22

PHYS 1444 Section 004 Lecture #22 PHYS 1444 Section 004 Lecture #22 Monday, April 23, 2012 Dr. Extension of Ampere s Law Gauss Law of Magnetism Maxwell s Equations Production of Electromagnetic Waves Today s homework is #13, due 10pm,

More information

Lecture 7: Logic and Planning

Lecture 7: Logic and Planning Lecture 7: Logic and Planning Planning and representing knowledge Logic in general Propositional (Boolean) logic and its application to planning COMP-424, Lecture 8 - January 30, 2013 1 What is planning?

More information

CSE 20 DISCRETE MATH WINTER

CSE 20 DISCRETE MATH WINTER CSE 20 DISCRETE MATH WINTER 2017 http://cseweb.ucsd.edu/classes/wi17/cse20-ab/ Reminders Homework 3 due Sunday at noon Exam 1 in one week One note card can be used. Bring photo ID. Review sessions Thursday

More information

Logic in AI Chapter 7. Mausam (Based on slides of Dan Weld, Stuart Russell, Dieter Fox, Henry Kautz )

Logic in AI Chapter 7. Mausam (Based on slides of Dan Weld, Stuart Russell, Dieter Fox, Henry Kautz ) Logic in AI Chapter 7 Mausam (Based on slides of Dan Weld, Stuart Russell, Dieter Fox, Henry Kautz ) Knowledge Representation represent knowledge in a manner that facilitates inferencing (i.e. drawing

More information

CS 380: ARTIFICIAL INTELLIGENCE PREDICATE LOGICS. Santiago Ontañón

CS 380: ARTIFICIAL INTELLIGENCE PREDICATE LOGICS. Santiago Ontañón CS 380: RTIFICIL INTELLIGENCE PREDICTE LOGICS Santiago Ontañón so367@drexeledu Summary of last day: Logical gents: The can reason from the knowledge they have They can make deductions from their perceptions,

More information

COMP219: Artificial Intelligence. Lecture 20: Propositional Reasoning

COMP219: Artificial Intelligence. Lecture 20: Propositional Reasoning COMP219: Artificial Intelligence Lecture 20: Propositional Reasoning 1 Overview Last time Logic for KR in general; Propositional Logic; Natural Deduction Today Entailment, satisfiability and validity Normal

More information

CS 730/730W/830: Intro AI

CS 730/730W/830: Intro AI CS 730/730W/830: Intro AI 1 handout: slides 730W journal entries were due Wheeler Ruml (UNH) Lecture 9, CS 730 1 / 16 Logic First-Order Logic The Joy of Power Wheeler Ruml (UNH) Lecture 9, CS 730 2 / 16

More information

Your Comments. I have three midterms this week; specifically, two tomorrow. I am studying for chemistry and calculus tonight.

Your Comments. I have three midterms this week; specifically, two tomorrow. I am studying for chemistry and calculus tonight. Your Comments I wish we had a day off for exams that would be fantastic WE SHOULD NOT HAE HAD CLASS TODAY!!!!! BOOOOOOOo!!! I have three midterms this week; specifically, two tomorrow. I am studying for

More information

Introduction to Artificial Intelligence (AI)

Introduction to Artificial Intelligence (AI) Introduction to Artificial Intelligence (AI) Computer Science cpsc502, Lecture 9 Oct, 11, 2011 Slide credit Approx. Inference : S. Thrun, P, Norvig, D. Klein CPSC 502, Lecture 9 Slide 1 Today Oct 11 Bayesian

More information

CS 771 Artificial Intelligence. Propositional Logic

CS 771 Artificial Intelligence. Propositional Logic CS 771 Artificial Intelligence Propositional Logic Why Do We Need Logic? Problem-solving agents were very inflexible hard code every possible state E.g., in the transition of 8-puzzle problem, knowledge

More information

ENEE 459E/CMSC 498R In-class exercise February 10, 2015

ENEE 459E/CMSC 498R In-class exercise February 10, 2015 ENEE 459E/CMSC 498R In-class exercise February 10, 2015 In this in-class exercise, we will explore what it means for a problem to be intractable (i.e. it cannot be solved by an efficient algorithm). There

More information

Reasoning Under Uncertainty: Conditioning, Bayes Rule & the Chain Rule

Reasoning Under Uncertainty: Conditioning, Bayes Rule & the Chain Rule Reasoning Under Uncertainty: Conditioning, Bayes Rule & the Chain Rule Alan Mackworth UBC CS 322 Uncertainty 2 March 13, 2013 Textbook 6.1.3 Lecture Overview Recap: Probability & Possible World Semantics

More information

Propositional Reasoning

Propositional Reasoning Propositional Reasoning CS 440 / ECE 448 Introduction to Artificial Intelligence Instructor: Eyal Amir Grad TAs: Wen Pu, Yonatan Bisk Undergrad TAs: Sam Johnson, Nikhil Johri Spring 2010 Intro to AI (CS

More information

Knowledge-based systems

Knowledge-based systems CS 750 Foundations of I Lecture 6 Knowledge-based systems Milos Hauskrecht milos@cs.pitt.edu 539 Sennott Square dministration announcements Midterm: Thursda October 6, 07 In-class Closed book What does

More information

Preparing for the CS 173 (A) Fall 2018 Midterm 1

Preparing for the CS 173 (A) Fall 2018 Midterm 1 Preparing for the CS 173 (A) Fall 2018 Midterm 1 1 Basic information Midterm 1 is scheduled from 7:15-8:30 PM. We recommend you arrive early so that you can start exactly at 7:15. Exams will be collected

More information

Recap from Last Time

Recap from Last Time NP-Completeness Recap from Last Time Analyzing NTMs When discussing deterministic TMs, the notion of time complexity is (reasonably) straightforward. Recall: One way of thinking about nondeterminism is

More information

COMP3702/7702 Artificial Intelligence Week 5: Search in Continuous Space with an Application in Motion Planning " Hanna Kurniawati"

COMP3702/7702 Artificial Intelligence Week 5: Search in Continuous Space with an Application in Motion Planning  Hanna Kurniawati COMP3702/7702 Artificial Intelligence Week 5: Search in Continuous Space with an Application in Motion Planning " Hanna Kurniawati" Last week" Main components of PRM" Collision check for a configuration"

More information

1 Primals and Duals: Zero Sum Games

1 Primals and Duals: Zero Sum Games CS 124 Section #11 Zero Sum Games; NP Completeness 4/15/17 1 Primals and Duals: Zero Sum Games We can represent various situations of conflict in life in terms of matrix games. For example, the game shown

More information

Lecture 10: Introduction to reasoning under uncertainty. Uncertainty

Lecture 10: Introduction to reasoning under uncertainty. Uncertainty Lecture 10: Introduction to reasoning under uncertainty Introduction to reasoning under uncertainty Review of probability Axioms and inference Conditional probability Probability distributions COMP-424,

More information

CSE 20 DISCRETE MATH. Fall

CSE 20 DISCRETE MATH. Fall CSE 20 DISCRETE MATH Fall 2017 http://cseweb.ucsd.edu/classes/fa17/cse20-ab/ Today's learning goals Describe and use algorithms for integer operations based on their expansions Relate algorithms for integer

More information

Midterm: CS 6375 Spring 2015 Solutions

Midterm: CS 6375 Spring 2015 Solutions Midterm: CS 6375 Spring 2015 Solutions The exam is closed book. You are allowed a one-page cheat sheet. Answer the questions in the spaces provided on the question sheets. If you run out of room for an

More information

Probability and Time: Hidden Markov Models (HMMs)

Probability and Time: Hidden Markov Models (HMMs) Probability and Time: Hidden Markov Models (HMMs) Computer Science cpsc322, Lecture 32 (Textbook Chpt 6.5.2) Nov, 25, 2013 CPSC 322, Lecture 32 Slide 1 Lecture Overview Recap Markov Models Markov Chain

More information

n Empty Set:, or { }, subset of all sets n Cardinality: V = {a, e, i, o, u}, so V = 5 n Subset: A B, all elements in A are in B

n Empty Set:, or { }, subset of all sets n Cardinality: V = {a, e, i, o, u}, so V = 5 n Subset: A B, all elements in A are in B Discrete Math Review Discrete Math Review (Rosen, Chapter 1.1 1.7, 5.5) TOPICS Sets and Functions Propositional and Predicate Logic Logical Operators and Truth Tables Logical Equivalences and Inference

More information

Mathematical Logic Part One

Mathematical Logic Part One Mathematical Logic Part One Question: How do we formalize the definitions and reasoning we use in our proofs? Where We're Going Propositional Logic (oday) Basic logical connectives. ruth tables. Logical

More information