Professional Documents
Culture Documents
Berlin Chen
Department of Computer Science & Information Engineering
National Taiwan Normal University
Reference:
- D. P. Bertsekas, J. N. Tsitsiklis, Introduction to Probability , Sections 1.3-1.4
Conditional Probability (1/2)
• Conditional probability provides us with a way to reason
about the outcome of an experiment, based on partial
information
– Suppose that the outcome is within some given event B , we
wish to quantify the likelihood that the outcome also belongs
some other given event A
P A B A B
P AB
P B
• If PB has zero probability, P A B is undefined
• We can think of P A B as out of the total probability of the
elements of B, the fraction that is assigned to possible
outcomes that also belong to A
Probability-Berlin Chen 2
Conditional Probability (2/2)
P AB
number of elements of A B
number of elements of B
Probability-Berlin Chen 3
Conditional Probabilities Satisfy the Three Axioms
• Nonnegative:
P AB 0
• Normalization:
P B P B
PB
P B
P B
1
Probability-Berlin Chen 5
Simple Examples using Conditional Probabilities (1/3)
Probability-Berlin Chen 6
Simple Examples using Conditional Probabilities (2/3)
Probability-Berlin Chen 7
Simple Examples using Conditional Probabilities (3/3)
F SF FF
N
S SS FS
S F
C
Probability-Berlin Chen 8
Using Conditional Probability for Modeling (1/2)
Probability-Berlin Chen 9
Using Conditional Probability for Modeling (2/2)
P A B
P A Bc
P Ac B
P Ac B c
Probability-Berlin Chen 10
Multiplication (Chain) Rule
P in1 Ai P A1 P A2 A1 P A3 A1 A2 P An in11Ai
– The above formula can be verified by writing
in1 Ai P A1
P A1 A2 P A1 A2 A3 P in1 Ai
P
P A1 P A1 A2
P in11Ai
– For the case of just two events, the multiplication rule is simply
the definition of conditional probability
P A1 A2 P A1 P A2 A1
Probability-Berlin Chen 11
Multiplication (Chain) Rule: Examples (1/2)
P A1 A2 A3 P A1 P A2 A1 P A3 A1 A2
39 38 37
C339
52 51 50 52
?
C3
Probability-Berlin Chen 12
Multiplication (Chain) Rule: Examples (2/2)
P A2 A1 8
14 8
P A3 A1 A2 4
13 4
12 8 4
P A3
15 14 13
Probability-Berlin Chen 13
Total Probability Theorem (1/2)
P B P A1 B P An B
P A1 P B A1 P An P B An
– Note that each possible outcome of the experiment (sample
space) is included in one and only one of the events A1 ,, An
Probability-Berlin Chen 14
Total Probability Theorem (2/2)
Figure 1.13:
Probability-Berlin Chen 15
Some Examples Using Total Probability Theorem (1/3)
Example 1.13.
Probability-Berlin Chen 16
Some Examples Using Total Probability Theorem (2/3)
Example 1.14.
Probability-Berlin Chen 17
Some Examples Using Total Probability Theorem (3/3)
• Example 1.15. Alice is taking a probability class and at the end of
each week she can be either up-to-date or she may have fallen
behind. If she is up-to-date in a given week, the probability that she
will be up-to-date (or behind) in the next week is 0.8 (or 0.2,
respectively). If she is behind in a given week, the probability that
she will be up-to-date (or behind) in the next week is 0.4 (or 0.6,
respectively). Alice is (by default) up-to-date when she starts the
class. What is the probability that she is up-to-date after three weeks?
U i : up - to - date
PU 3 PU 2 P U 3 U 2 PB2 P U 3 B2 PU 2 0.8 PB2 0.4
Bi : behind PU 2 PU1 P U 2 U1 PB1 P U 2 B1 PU 1 0.8 PB1 0.4
PB2 PB1 P B2 U1 PB1 P B2 B1 PU1 0.2 PB1 0.6
As we know that PU1 0.8 , PB1 0.2 PU 0 1.0
PU 2 0.8 0.8 0.2 0.4 0.72 Recursion formulea
P U i 1 P U i 0.8 P Bi 0.4
PB2 0.8 0.2 0.2 0.6 0.28
P Bi 1 P U i 0.2 P Bi 0.6
PU 3 0.72 0.8 0.28 0.4 0.688 P U1 0.8, P B1 0.2
Probability-Berlin Chen 18
Bayes’ Rule
P Ai P B Ai
P B Total probability theorem
P Ai P B Ai
nk 1 P Ak P B Ak
P Ai P B Ai
P A1 P B A1 P An P B An
Probability-Berlin Chen 19
Inference Using Bayes’ Rule (1/2)
惡性腫瘤
良性腫瘤
Figure 1.14:
Probability-Berlin Chen 20
Inference Using Bayes’ Rule (2/2)
P A B
P A P B A
P B
P B A c 1 P B c A c 0 . 05
P A P B A
P A P B A P A c P B A c
0 . 001 0 . 95
0 . 0187
0 . 001 0 . 95 0 . 999 0 . 05
Probability-Berlin Chen 21
Recitation
Probability-Berlin Chen 22