Lec 4
Lec 4
Probability
Dr . Mohammed. Yusef Dr. Salma Shatta
Lecture 4
Conditional Probability
𝐏(𝐀 ∩ 𝐁)
𝐏 𝐀𝐁 =
𝐏(𝐁)
𝐏(𝐀 ∩ 𝐁)
Note that; 𝐏 𝑩𝑨 =
𝐏(𝐀)
Example
𝑃(𝐴∩𝐵) 0.3
𝑃 𝐴𝐵 = = = 0.6
𝑃(𝐵) 0.5
and
𝑃(𝐴∩𝐵) 0.3
𝑃 𝐵𝐴 = = = 0.75
𝑃(𝐴) 0.4
𝑃 𝐴∩𝐵 𝑃 ∅
𝑃 𝐴𝐵 = = = 0.
𝑃 𝐵 𝑃 𝐵
For certain pairs of events, the occurrence of one of them may or may not
change the probability of the occurrence of the other. In the latter case
they are said to be independent events.
Definition
If A and B are independent events:
𝑃 𝐵 𝐴 = 𝑃(𝐵)
𝑃 𝐴 𝐵 = 𝑃(𝐴)
Independent Events
Two events A and B are said to be mutually independent, if and only if,
P(A ∩ B) = P(A)P(B).
P(A ∩ B ∩ C) = P(A)P(B)P(C).
Example :
A card is chosen at random from a standard deck of 52
playing cards. Without replacing it, a second card is
chosen. What is the probability that the first card chosen
is a queen and the second card chosen is a jack?
Solution
Example
Flip a coin twice and observe the sequence of heads
and tails. Find 𝑃 𝐵 𝐴 , where A is heads on the first flip
and B is tails on the second flip. The sample space is
S = {HH, HT, T H, T T}.
Solution
It is reasonable to assign a probability of 1/4 to each of these four outcomes.
2
Let, A = {heads on the first flip} = {HH, HT} → 𝑃 𝐴 =
4
2
B = {tails on the second flip} = {HT, T T}→ 𝑃 𝐵 =
4
1
∴ 𝐴 ∩ 𝐵 = {HT} → 𝑃 𝐴 ∩ 𝐵 = 𝑃 𝐴 𝑃 𝐵 =
4
𝑃(𝐴∩𝐵) 1/4 1
𝑃 𝐵𝐴 = = = = 𝑃(𝐵)
𝑃(𝐴) 2/4 2
𝟔
A = {(4, 1),(4, 2),(4, 3),(4, 4),(4, 5),(4, 6)} → 𝐏 𝐀 =
𝟑𝟔
B = {(1, 2),(1, 4),(1, 6),(2, 1),(2, 3),(2, 5), (3, 2),(3, 4),(3, 6),(4, 1),(4, 3),(4, 5), (5,2),
𝟏𝟖
(5, 4),(5, 6),(6, 1),(6, 3),(6, 5)} →𝐏 𝐁 =
𝟑𝟔
𝟑
A ∩ B = {(1, 4),(3, 4),(5, 4)} → 𝐏 A ∩ B =
𝟑𝟔
Thus,
𝟔 𝟏𝟖 𝟑
P(A) × P(B) = × = = P(A ∩ B).
𝟑𝟔 𝟑𝟔 𝟑𝟔
Hence A and B are independent.
In previous Example , let the events C and D be defined as
C = {5 on second dice} and D = {sum of dice is 11}
Solution
2 2 1 2 5 1 3 2 3
𝑎 ∗ = 𝑏 ∗ = 𝑐 ∗ =
10 10 25 10 10 10 10 10 50
Example:
Solve the previous example when the balls are selected without replacement.
Solution
Let
Bi = {the i-th selected ball is blue, i = 1,2},
Ri = {the i-th selected ball is red, i = 1,2}
Gi = {the i-th selected ball is green, i = 1,2}.
2 1 1
𝑎 𝑃 𝐵1 𝑎𝑛𝑑 𝐵2 = 𝑃 𝐵1 𝑃 𝐵2 𝐵1 = ∗ =
10 9 45
2 5 1
𝑏 𝑃 𝐵1 𝑎𝑛𝑑 𝑊2 = 𝑃 𝐵1 𝑃 G2 𝐵1 = ∗ =
10 9 9
3 2 1
𝑐 𝑃 𝑅1 𝑎𝑛𝑑 𝐵2 = 𝑃 𝑅1 𝑃 𝐵2 𝑅1 = ∗ =
10 9 15
Theorem ( The Multiplication Law of Probability)
Solution
(a)Since there are four aces among the 52 cards, we get
4 4 1
× =
52 52 169
(b) Since there are only three aces among the 51 cards which remain after
one ace has been removed from the deck, we get
4 3 1
× =
52 51 221
Theorem ( Bayes Rule )
Then, for any event B in the same sample space with P(B) > 0, we have
P(T|not D) = 0.05
40% of applicants have high test scores. Among those with high scores,
80% are admitted. Among those without high scores, 30% are admitted.
If a student is admitted, what’s the probability they had high test
scores?
Solution:
Let 𝐻be the event that a student has high test scores.
Let 𝐴 be the event that a student is admitted.
P(H) = 0.4, P(A|H) = 0.8, P(A|not H) = 0.3 P(not H)=0.6
•A. 0.2
•B. 0.9
•C. 0.1
•D. 0.4
Answer: A
P(Studied∩Passed)=P(Passed)×P(Studied∣Passed)=0.7×0.85=0.595
3-In a factory, machine A1 produces 40% of the products, and machine A2 produces
60% of the products. The probability that a product is defective from machine A1 is
0.05, and from machine A2 is 0.02. What is the probability that a randomly selected
product is defective?
•A. 0.03
•B. 0.025
•C. 0.04
•D. 0.05
Answer: A
By the law of total probability:
P(Defective)=P(A 1 )×P(Defective∣A 1 )+P(A 2 )×P(Defective∣A2 )𝑃(Defective)
=(0.40)(0.05)+(0.60)(0.02)=0.02+0.012=0.032
P(Defective)=(0.40)(0.05)+(0.60)(0.02)=0.02+0.012=0.032
4-If 𝑃(𝐴∩𝐵)=0.2 and 𝑃(𝐵)=0.5, what is 𝑃(𝐴∣𝐵)?
A. 0.2
B. 0.5
C. 0.4
D. 0.1
Answer: C
𝑃(𝐴∣𝐵)=𝑃(𝐴∩𝐵)/𝑃(𝐵)=0.2/0.5=0.4
5-Two events 𝐴 and 𝐵 are independent. If 𝑃(𝐴)=0.6 and 𝑃(𝐴∪𝐵)=0.8, what
is 𝑃(𝐵)?
A. 0.2
B. 0.5
C. 0.4
D. 0.33
Answer: C
0.8=0.6+𝑃(𝐵)−0.6×𝑃(𝐵)
Solving, 𝑃(𝐵)=0.4
6-In a group of 100 people, 40 are male and 60 are female. Out of the 40
males, 10 have a driver's license. Out of the 60 females, 20 have a driver’s
license. If a randomly selected person has a driver's license, what is the
probability that the person is female?
•A. 0.33
•B. 0.67
•C. 0.75
•D. 0.5
Answer: B
Use Bayes'Theorem:
7-In a survey, 70% of respondents said they liked product A, and 50%
said they liked product B. If 40% liked both products, what is the
probability that a respondent likes product A given that they like
product B?
•A. 0.57
•B. 0.80
•C. 0.50
•D. 0.40
Answer: B
Conditional probability:
P(A∣B)=P(A∩B)/ P(B)=0.40/0.50= 0.80
8-Events A and B are independent. If P(A∣B)=0.4 and P(B)=0.5, what is P(A)?
•A. 0.2
•B. 0.5
•C. 0.4
•D. 0.8
Answer: C
For independent events,
P(A∣B)=P(A)
P(A)=0.4
9-A coin is tossed twice. Let A be the event "the first toss results in heads," and
B be the event "the second toss results in heads." What is P(A∣B)?
•A. 0.5
•B. 0.25
•C. 0.75
•D. 0.1
Answer: A
Answer: B
.
Thanks!