CS520: Steinberg 1 Lecture 16 CS 520: Introduction to Artificial Intelligence Prof. Louis Steinberg Lecture 16: Uncertainty.

Slides:



Advertisements
Similar presentations
Computer Science and Software Engineering University of Wisconsin - Platteville Note 5. Testing Yan Shi Lecture Notes for SE 3730 / CS 5730.
Advertisements

1 Applications of Optimization to Logic Testing Gary Kaminski and Paul Ammann ICST 2010 CSTVA Workshop.
Software Testing Logic Coverage. Introduction to Software Testing (Ch 3) © Ammann & Offutt 2 Logic Coverage Four Structures for Modeling Software Graphs.
Tutorial 1: Logic Peter Poon. Self Introduction You can call me Peter Office: SHB117 Office hour:
Introduction to Software Testing Chapter 3.1, 3.2 Logic Coverage Paul Ammann & Jeff Offutt
Logic ChAPTER 3 1. Truth Tables and Validity of Arguments
Probabilistic Reasoning Course 8
PROBABILITY. SIMULATION THE ACT OF IMITATING AN ACTUAL EVENT, CONDITION, OR SITUATION. WE OFTEN USE SIMULATIONS TO MODEL EVENTS THAT ARE TOO LARGE OR.
Insert Lesson Title Here 1) Joann flips a coin and gets a head. Then she rolls a 6 on a number cube. 2) You pull a black marble out of a bag. You don’t.
Dependent Events Objective: Find the probability of dependent events. Standard Addressed: : D Use theoretical probability distributions to make judgments.
Decision Theory: Single Stage Decisions Computer Science cpsc322, Lecture 33 (Textbook Chpt 9.2) March, 30, 2009.
Snick  snack CPSC 121: Models of Computation 2009 Winter Term 1 Propositional Logic: Conditionals and Logical Equivalence Steve Wolfman, based on notes.
Probability Notation Review Prior (unconditional) probability is before evidence is obtained, after is posterior or conditional probability P(A) – Prior.
Approximation Algorithms Lecture for CS 302. What is a NP problem? Given an instance of the problem, V, and a ‘certificate’, C, we can verify V is in.
NP and NP-completeness
Uncertainty Management for Intelligent Systems : for SEP502 June 2006 김 진형 KAIST
Ai in game programming it university of copenhagen Welcome to... the Crash Course Probability Theory Marco Loog.
Introduction to Software Testing Chapter 8.2
Snick  snack CPSC 121: Models of Computation 2008/9 Winter Term 2 Sets Steve Wolfman, based on notes by Patrice Belleville and others.
Uncertainty Chapter 13.
Discuss With A Neighbor Look at the spinners below: If you spin each spinner one time, what is the probability that you will land on an odd number.
CSCI 121 Special Topics: Bayesian Network Lecture #1: Reasoning Under Uncertainty.
CSE 20 DISCRETE MATH Prof. Shachar Lovett Clicker frequency: CA.
Chapter 1 The Logic of Compound Statements. Section 1.1 Logical Form and Logical Equivalence.
Today’s Agenda  Quick Review  Finish Graph-Based Testing  Predicate Testing Software Testing and Maintenance 1.
Uncertainty1 Uncertainty Russell and Norvig: Chapter 14 Russell and Norvig: Chapter 13 CS121 – Winter 2003.
Probabilistic graphical models. Graphical models are a marriage between probability theory and graph theory (Michael Jordan, 1998) A compact representation.
Independent and Dependent Events
Introduction to Software Testing Chapter 8.1 Logic Coverage Paul Ammann & Jeff Offutt
Logical Form and Logical Equivalence Lecture 2 Section 1.1 Fri, Jan 19, 2007.
1 Reasoning Under Uncertainty Artificial Intelligence Chapter 9.
CSE PR 1 Reasoning - Rule-based and Probabilistic Representing relations with predicate logic Limitations of predicate logic Representing relations.
Uncertainty Uncertain Knowledge Probability Review Bayes’ Theorem Summary.
Introduction to Software Testing Chapter 3.6 Disjunctive Normal Form Criteria Paul Ammann & Jeff Offutt
Introduction to Software Testing Chapter 3.1, 3.2 Logic Coverage Paul Ammann & Jeff Offutt
Chapter 13 February 19, Acting Under Uncertainty Rational Decision – Depends on the relative importance of the goals and the likelihood of.
ARTIFICIAL INTELLIGENCE [INTELLIGENT AGENTS PARADIGM] Professor Janis Grundspenkis Riga Technical University Faculty of Computer Science and Information.
Fall  Types of Uncertainty 1. Randomness : Probability Knowledge about the relative frequency of each event in some domain Lack of knowledge which.
Counter Probabilities Teacher's Notes Topic: Probability
CS1022 Computer Programming & Principles Lecture 1 Logic and Proof.
Logical Form and Logical Equivalence Lecture 1 Section 1.1 Wed, Jan 12, 2005.
Math I.  Probability is the chance that something will happen.  Probability is most often expressed as a fraction, a decimal, a percent, or can also.
Uncertainty ECE457 Applied Artificial Intelligence Spring 2007 Lecture #8.
Math I.  Probability is the chance that something will happen.  Probability is most often expressed as a fraction, a decimal, a percent, or can also.
PROBABILITY (Theoretical) Predicting Outcomes. What is probability? Probability refers to the chance that an event will happen. Probability is presented.
Introduction to Artificial Intelligence CS 438 Spring 2008 Today –AIMA, Ch. 13 –Reasoning with Uncertainty Tuesday –AIMA, Ch. 14.
Notes - Truth Tables fun, fun, and more fun!!!!. A compound statement is created by combining two or more statements, p and q.
Introduction to Software Testing Chapter 3.6 Disjunctive Normal Form Criteria Paul Ammann & Jeff Offutt
Introduction to Software Testing Chapter 3.6 Disjunctive Normal Form Criteria Paul Ammann & Jeff Offutt
Warm up Decide if the following represent permutations or combinations. Then calculate the desired results. 1. How many different four digit numbers can.
Slot machines A healthy way to learn about connectives!
MATH 110 Sec 12-1 Lecture: Intro to Counting Introduction to Counting: Just how many are there?
1 Probability FOL fails for a domain due to: –Laziness: too much to list the complete set of rules, too hard to use the enormous rules that result –Theoretical.
Introduction to Software Testing Chapter 3.2 Logic Coverage
CSE 473 Uncertainty. © UW CSE AI Faculty 2 Many Techniques Developed Fuzzy Logic Certainty Factors Non-monotonic logic Probability Only one has stood.
Warm Up What is the theoretical probability of rolling a die and landing on a composite number?
Chapter 12. Probability Reasoning Fall 2013 Comp3710 Artificial Intelligence Computing Science Thompson Rivers University.
Lecture 21, Bayesian Networks Wrap Up Intro to Decision Theory Slide 1.
Probability of Independent and Dependent Events 11-5.
Introduction to Discrete Mathematics Lecture 1: Sep 6 AB C a = qb+r gcd(a,b) = gcd(b,r)
Introduction to Software Testing Chapter 8.2
NP and NP-completeness
Quick Review Probability Theory
Quick Review Probability Theory
Where are we in CS 440? Now leaving: sequential, deterministic reasoning Entering: probabilistic reasoning and machine learning.
Probability Topics Random Variables Joint and Marginal Distributions
Probability and Information
Decision Theory: Single Stage Decisions
Course Overview and Introduction
Probability of Independent Event
Presentation transcript:

CS520: Steinberg 1 Lecture 16 CS 520: Introduction to Artificial Intelligence Prof. Louis Steinberg Lecture 16: Uncertainty

CS520: Steinberg 2 Lecture 16 Start goal Review: Building Plans Progression –Choose first step, what state does that result in? –Plan from that state to goal Means-Ends –Choose an operator that reduces start-goal difference –Plan from start to preconditions of operator –Plan from result of operator to goal Regression –Choose last step, what conditions needs to be true before it to –ensure goal met after it? –Plan from start to those conditions Start goal op plan Start goal op plan op plan2plan1

CS520: Steinberg 3 Lecture 16 Sources of Uncertainty Incomplete knowledge of the world state –Which room is the wumpus in? Uncertainty in operator effects –Command: turn 90 degrees right –Result: robot turns degrees right Theoretical vs practical uncertainty –We have no way to know, v.s. –It would cost too much to know –Human time –Computer time

CS520: Steinberg 4 Lecture 16 Modeling Uncertainty Degree of belief –Historical interest: approximations of probability Fuzzy logic –Oriented towards linguistic imprecision –It is hot vs it is warm vs it is sweltering Probability

CS520: Steinberg 5 Lecture 16 Acting under uncertainty Probability: methods for representing and reasoning about uncertainty of knowledge Utility theory: a way to represent and reason about the desirability of different outcomes Decision theory: A way to combine probability and utility to decide what to do.

CS520: Steinberg 6 Lecture 16 Probability Bag with 10 marbles: 3 red, 7 blue –Reach in, take one, put it back –Repeat lots of times. –What fraction red? About.3 –P(red) =.3

CS520: Steinberg 7 Lecture 16 Probability Distribution The probability for each value of a random variable if color = (red, blue) P(color) = (.3,.7)

CS520: Steinberg 8 Lecture 16 Conditional Probability Marbles are red or blue, striped or solid Take marble, look at it, put it back Ignore non-red What fraction are striped? P(striped | red) = 1/3 P(red | striped) = 1/4

CS520: Steinberg 9 Lecture 16 Conditional Probability P(A | B) = P(A  B) / P(B).1P(red  striped).4P(striped).1/.4 = 1/4 = P(red | striped).1P(red  striped).3P(red).1/.3 = 1/3 = P(striped | red) Equivalently: P(A^B) = P(A | B) * P(B)

CS520: Steinberg 10 Lecture 16 Basic Properties 0 ≤ P(A) ≤ 1 P(true) = 1 P(red  blue  green) = 1 P(false) = 0 P(black) = 0

CS520: Steinberg 11 Lecture 16 Basic Properties P(A  B) = P(A) + P(B) - P(A  B).3 P(red) +.4P(striped) -.1P(red  striped) P(red  striped) =.6 Counted twice So subtract once

CS520: Steinberg 12 Lecture 16 Example Proofs Prove P(true | A) = 1 Proof: P(true | A) = P(true^A)/P(A) = P(A)/P(A) = 1 Prove: P(B|A)+P(¬B|A)= 1 Proof: P(B|A)+P(¬B|A) = P(B v ¬B |A) + P(B ^ ¬B|A) = P(true | A) + P(false | A) = 1 + 0

CS520: Steinberg 13 Lecture 16 Example Proof Prove: P(A) = P(A | B)*P(B) + P(A|¬B)*P(¬B) Proof: P(B|A)+P(¬B|A)=P(B v ¬B |A)=P(true | A) = 1 P(B|A)+P(¬B|A)= P(A|B)*P(B)/P(A) + P(A|¬B)*P(¬B)/P(A) = (P(A | B)*P(B) + P(A|¬B)*P(¬B)) / P(A)

CS520: Steinberg 14 Lecture 16 Example Use: Mine Sweeper Grid of cells, some have mines Probe a cell: –If has a mine, lose –Else tells number of neighboring mines Variables: –M(x, y): boolean: mine –C(x, y): neighbor mine count –N: total mines

CS520: Steinberg 15 Lecture 16 Mine Sweeper Mine Sweeper P(M(1, 1)) = # ways of choosing 2 of 5 # ways of choosing 3 of 6 = 5! /(2!3!) 6! /(3!3!) = 10/20 =.5

CS520: Steinberg 16 Lecture 16 Mine Sweeper Mine Sweeper P( C(1,2)=2 ^ ~M(1,2) ) = choose(2, 3) * choose(1,2) choose (3, 6) = 3*2/20 =.3

CS520: Steinberg 17 Lecture 16 Mine Sweeper Mine Sweeper P( C(1,2)=2 ^ ~M(1,2) ^ M(1,1) )= choose(1, 2) * choose(1,2) choose (3, 6) = 2 * 2 / 20 =.2

CS520: Steinberg 18 Lecture 16 Mine Sweeper Mine Sweeper P( C(1,2)=2 ^ ~M(1,2) | M(1,1) )= P( C(1,2)=2 ^ ~M(1,2) ^ M(1,1) ) P( M(1,1) ) =.2/.5 = 2/5

CS520: Steinberg 19 Lecture 16 Mine Sweeper Mine Sweeper P( M(1,1) | C(1,2)=2 ^ ~M(1,2) )= P( C(1,2)=2 ^ ~M(1,2) | M(1,1) ) * P( M(1,1) ) / P(C(1,2)=2 ^ ~M(1,2) ) = 2/5 * 1/2 / 3/10 = 2/3

CS520: Steinberg 20 Lecture 16 Mine Sweeper Known: P(M(1, 1) v M(2, 1)) =1 P(M(1, 1) ^ M(2, 1)) = 0 P(M(1, 1)) = P(M(2, 1)) Conclude: 1 = P(M(1, 1)) + P(M(2, 1)) - 0 P(M(1, 1)) = P(M(2, 1)) =.5 Mine Sweeper

CS520: Steinberg 21 Lecture 16 Joint Probability The state of a single situation / domain may be represented by a set of random variables.

CS520: Steinberg 22 Lecture 16 Example of Joint Probability Distribution Mine Sweeper ABCDProbability FFFF0 FFFT1/2 FFTF FFTT0 FTFF0 FTFT0 FTTF0 FTTT0 TFFF0 TFFT0 TFTF0 TFTT0 TTFF0 TTFT0 TTTF0 TTTT0