Professional Documents
Culture Documents
● Concept of probability
● Random variables
● Distribution functions: discrete and continuous
● Moments and moment generating functions
2
Rules of Probability Recap:
3
Joint Probability:
4
Bayes’ Theorem:
Bayes’ Theorem
𝑃 𝐴 ∩ 𝐵 = 𝑃 𝐴 𝐵 𝑃 𝐵 = 𝑃 𝐵 𝐴 𝑃(𝐴)
Note: as in the example, the Total Probability rule is often used to evaluate P(B):
𝑃 𝐵𝐴 𝑃 𝐴
𝑃 𝐴 𝐵) =
∑ 𝑃 𝐵|𝐴 𝑃(𝐴 )
𝑃 𝐴 and 𝐵
=
𝑃 𝐴 and 𝐵 𝑃 𝐴 and 𝐵 𝑃 𝐴 and 𝐵 ⋯
If you have a model that tells you how likely B is given A, Bayes’ theorem allows you
to calculate the probability of A if you observe B. This is the key to learning about
your model from statistical data.
5
Baye’s Theorem:
● Let A1, A2,...,Ak be events such that P(Ai) > 0, i = 1, 2,...,k. Assume
further that A1, A2,...,Ak form a partition of the sample space C. Let B be
any event. Then
6
Bayes’ Theorem:
• Example: Evidence in court
The cars in a city are 90% black and 10% grey.
A witness to a bank robbery briefly sees the escape car, and says it is grey. Testing the
witness under similar conditions shows the witness correctly identifies the colour 80% of the
time (in either direction).
What is the probability that the escape car was actually grey?
• Answer:
• Given two events A and B and suppose that P(A) > 0. Then
P( 𝐴𝐵) P( 𝐴|𝐵) P( 𝐵)
P( 𝐵|𝐴) = =
P( 𝐴) P( 𝐴)
• Example:
P(R) = 0.8
R: It is a rainy day
P(W|R) R ¬R
W: The grass is wet
W 0.7 0.4 P(R|W) = ?
¬W 0.3 0.6
9
Bayes’ Rule:
R ¬R
R: It rains
W 0.7 0.4
W: The grass is wet
¬W 0.3 0.6
Information
P(W|R)
R W
Inference
P(R|W)
10
Bayes’ Rule:
R ¬R
R: It rains
W 0.7 0.4
W: The grass is wet
¬W 0.3 0.6
Information: P(E|H)
Hypothesis H Evidence E
Posterior Likelihood
Inference: Pr(H|E)
Prior
11
Bayes’ Rule: More Complicated
Bi B j = ∅; i Bi = S
Suppose that P(Bi) > 0 and P(A) > 0. Then
P( 𝐴|𝐵 ) P( 𝐵 )
P( 𝐵 |𝐴) =
P( 𝐴)
P( 𝐴|𝐵 ) P( 𝐵 )
=
∑ P( 𝐴𝐵 )
P( 𝐴|𝐵 ) P( 𝐵 )
=
∑ P( 𝐵 ) P( 𝐴|𝐵 )
12
A More Complicated Example:
R It rains
R
W The grass is wet
P(W|R) R ¬R P(U|R) R ¬R
W 0.7 0.4 U 0.9 0.2
P(U|W) = ?
13
Reliability of a System:
• General approach: bottom-up analysis. Need to break down the system into
subsystems just containing elements in series or just containing elements in
parallel.
• Find the reliability of each of these subsystems and then repeat the process at
the next level up.
14
Reliability of a System:
Series subsystem: in the diagram 𝑝 = probability that element i fails, so 1 𝑝=
probability that it does not fail.
p p p p
1 2 3 n
The system only works if all n elements work. Failures of different elements are
assumed to be independent (so the probability of Element 1 failing does alter after
connection to the system).
𝑃 𝑠𝑦𝑠𝑡𝑒𝑚 𝑑𝑜𝑒𝑠 𝑛𝑜𝑡 𝑓𝑎𝑖𝑙 = 𝑃(1 𝑑𝑜𝑒𝑠 𝑛𝑜𝑡 𝑓𝑎𝑖𝑙 𝐴𝑁𝐷 2 𝑑𝑜𝑒𝑠 𝑛𝑜𝑡 𝑓𝑎𝑖𝑙 𝐴𝑁𝐷 … 𝑛 𝑑𝑜𝑒𝑠 𝑛𝑜𝑡 𝑓𝑎𝑖𝑙)
= 1 𝑝 1 𝑝 … 1 𝑝 = (1 𝑝)
=1 (1 𝑝)
15
Reliability of a System:
Parallel subsystem: the subsystem only fails if all the elements fail.
p
1
p
2
p
n
= 𝑝 𝑝 …𝑝 = 𝑝
16
Example:
Subsystem 3:
P(Subsystem 3 fails) =
0.1 x 0.1 = 0.01
Answer:
0.02 0.006162 0.01 P(System doesn't fail) =
(1 - 0.02)(1 - 0.006162)(1 - 0.01) =
0.964
Answer to (b)
1
What is probability that this system does not fail,
3
given the failure probabilities of the components?
1
3
1
2
20
Next Class…
21