Notes for October 23.
Search and Planning so far:
- actions have deterministic effects
- states are completely observable
- A plan is a sequence of actions that can be executed blindly in the world.
- Example: Robot navigation
o Noisy actuators
o Noisy sensors of limited range
o Uncertainty in interpretation of sensor data
o Uncertainty in the map
o Uncertainty about initial location of robot
o Uncertainty about dynamic state of environment
![]()
![]()
![]()
![]()
![]()
![]()
ááááááááááááááááááááááá Where am I?á How sure am I?
Use dynamic probabilities
- frequentist view: frequency of occurrences determines probability (# of times heads vs. tails)
- objectivist view: properties of objects determine probability (6 sided die)
- subjectivist view: Doctors give different probabilities for a patient having a given disease).
Notation
- P(Var = value): the probability that the (random) variable Var takes on the given value.
o P(students=38) = 0.93
- P(propositional_sentence): the probability that the given sentence is true.
o P(happy) = .4
o P(happy ^ Ûhungry) = .39
- Note: P(A,B) = P(A^B)
Axioms of probabilities
- Probabilities can be derived from a few rules
o 0 ú P(A) ú 1.0
o P(true) = 1.0; P(false) = 0.0;
o P(A or B) = P(A) + P(B) û P(A^B)
- Prove P(ÛA) = 1 û P(A):
o P(A or ÛA) = P(A) + P(ÛA) û P(A^ÛA)
o P(A or ÛA) = 1.0; P(A^ÛA) = 0.0;
o 1 = P(A) + P(ÛA)
o P(ÛA) = 1 û P(A)
Joint Probability Distribution
- Truth Table:
happyáá hungry Tááááááááá Tááááááááá .01 Tááááááááá Fááááááááá .39 Fááááááááá Tááááááááá .54 Fááááááááá Fááááááááá .06
- Venn Diagram:

- Computing Probabilities from Joint probability distribution
o X = P(happy ^ (hungry EQUIV Ûhappy)) = .94
o Enumerate models and add their probabilities
happyáá hungryá X Tááááááááá Tááááááááá T Tááááááááá Fááááááááá T Fááááááááá Tááááááááá T Fááááááááá Fááááááááá F P(X)= P(happy^hungry) + P(happy^Ûhungry)
+ P(Ûhappy
^ hungry) = .94
![]()
o P(Ûhungry) = .45
o P(Ûhungry) = P(Ûhungry^happy) + P(Ûhungry^Ûhappy)
- Conditional Probabilities
o P(happy | hungry): probability of æhappyÆ given that æhungryÆ is true
P(happy |
hungry) = ááááááááááá P(happy^hungry)/P(hungry)

o Example: Die
º P(Die = 2) = 1/6ááááááááá (by enumerating all possibilities)
º P(Die = Even) = 3/6ááá = P(Die = 2 or Die = 4 or Die = 6)
= P(Die = 2) + P(Die = 4) + P(Die = 6)
= 1/6 + 1/6 + 1/6 = 1/2
º P(Die = 2 | Die = Even) áááááááá = 1/3
= P(Die = 2 ^ Die = Even) / P(Even)
= (1/6) / (3/6) = 1/3
What if we donÆt have all the probabilities?
- Doctor example
o P(cold | sneeze) = P(code ^ sneeze) / P(sneeze) [doesnÆt really get us anywhere]
o Instead we can use P(sneeze | cold), P(cold), and P(sneeze) to find P(cold|sneeze).
º P(cold | sneeze)*P(sneeze) = P(sneeze | cold)*P(cold)
Conditional probabilities and Bayes Rule
- P(model | data) = P(model)*P(data | model) / P(data)
- P(data) is a normalizing constant (no need to compute it)
- Example: Speech Recognition
o P(word | utterance) = P(word)*P(utterance|word) / P(utterance)
- Example: Diagnosis
o P(disease | symptoms) = P(disease)*P(symptoms | disease)/ P(symptoms)
o P(symptoms) is causal information
o P(cold | sneeze) + P(Ûcold | sneeze) = 1.0
o P(cold | sneeze) = P(sneeze | cold)*P(cold) / Scale áááááááááááááá = 0.1
o P(Ûcold | sneeze) = P(sneeze |á Ûcold)*P(Ûcold) / Scale ááááá = 0.2
o Given P(cold | sneeze) and P(Ûcold | sneeze), we can calculate the Scale
o € (.1/Scale) + (.2/Scale) = 1 € Scale = .3
o Scale is just a scaling constant that is the same for both
Bayes Rule: problem from book
- You are a witnessà
- B = ôit was a blue carö; G = ôit was a green carö;
- seeB = ôWitness saw a blue car; seeG = ôWitness saw a green carö
- P(B or G) = 1.0
- P(G) = 0.9
- P(B) = 0.1
- P(seeB | B) = .75; P(seeG | G) = .75
- P(seeG | B) = .25; P(seeB | G) = .25
- P(G | SeeB) = ?
- P(B | SeeB) = P(SeeB | B)*P(B) / X
- P(G | SeeB) = P(SeeB | G)*P(G) / X
- P(B | SeeB) + P(G | SeeB) = 1.0
- ((.75*.1)/X) + ((.25*.9)/X) = 1.0
- = (.075 + .225) / X = 1
- X = .3
- P(G | seeB) = .25*.9/.3 = .75