Section [2]
Section [2]
P(B) ≠ 0
P(A) ≠ 0
CONDITIONAL PROBABILITY
Example 1
You roll a die twice What is the probability that the sum equal 10, if
you know that the1st element equal 6?
A = {(4,6), (5,5), (6,4)} P(A)=3/36
B = {(6,1), (6,2), (6,3), (6,4), (6,5), (6,6)} P(B)=6/36
CONDITIONAL PROBABILITY
Example 2
A class of 40 students was asked, “do you like school?” The results of
the survey are recorded in the two-way table.find the probability a
student likes school given they are male
CONDITIONAL PROBABILITY
Example 2 solution
CONDITIONAL PROBABILITY
P(A)=1/8
CONDITIONAL PROBABILITY
Example 5
Consider an industrial process in the textile industry in which strips of a
particular type of cloth are being produced. These strips can be
defective in two ways, length and nature of texture. It is known from
historical information on the process that 10% of strips fail the length
test, 5% fail the texture test, and only 0.8% fail both tests. If a strip is
selected randomly from the process and a quick measurement
identifies it as failing the length test, what is the probability that it is
texture defective?
CONDITIONAL PROBABILITY
Example 5 solution
P(L)= 0.1
P(T)=0.05
P(L∩T)= 0.008
P(T|L)= 0.008/0.1 =0.08
Disjoint (or mutually exclusive):
Independent Events
Example 6
A single fair die is rolled. Let A={3} and B {1,3,5} Are A and B independent?
Solution:
In this example we can compute all three probabilities
P(A)=1∕6,
P(B)=1 ∕ 2,
P(A∩B)=P({3})=1∕6
Since the product P(A)⋅P(B)=(1∕6)(1∕2)=1∕12
as P(A∩B) != P(A)⋅P(B)
the events A and B are not independent.
Independent Events
Example 6
A single fair die is rolled. Let A={3}and B={1,3,5} Are A and B independent?
Solution:
In this example we can compute all three probabilities
P(A)=1∕6,
P(B)=1 ∕ 2,
P(A∩B)={3} =1/6
P(A|B)= 1/6 / ½ = 2/6
P(A|B) != P(A)
the events A and B are not independent
THE MULTIPLICATION RULE
THE MULTIPLICATION RULE
Example 7
Box contains 20 red and 10 blue balls. Two balls are drawn from a bag one after the other without
replacement. What is the probability that both the balls are drawn are red?
P(A) = P(red balls in first draw) = 20/30
Now, only 19 red balls and 10 blue balls are left in the bag, The probability of drawing a red ball in the
second draw too is an example of conditional probability where the drawing of the second ball depends on
the drawing of the first ball.
Conditional probability of B on A will be,
P(B|A) = 19/29
By multiplication rule of probability,
P(A∩B) = P(A) × P(B|A)
THE MULTIPLICATION RULE
Example 8
Suppose we have a fuse box containing 20 fuses of which 5 are defective (D) and 15 are non-
defective (N). If 2 fuses are selected at random and removed from the box in succession
without replacing the first, what is the probability that both fuses are defective?
Solution:
Define the following events:
A = {the first fuse is defective}
B = {the second fuse is defective}
A∩B={the first fuse is defective and the second fuse is defective} = {both fuses are defective}
THE MULTIPLICATION RULE
Example 8
MULTIPLICATION RULE OF PROBABILITY
FOR MORE THAN two events
• The theorem of total probability is useful to find the probability of happening an event from the different
partitions of the sample space.
• A = A∩ S
• A = A ∩ {B U C}
• A = {A∩ B} U {A ∩ C}
• P(A) = P(A ∩ B) ∪ P(A ∩ C)
• P(A ∩ B ) = P(A|B ) P(B )
• P(A ∩ C) = P(A|C ) P(C )
• Therefore,
P (A) = P(A|B ) P(B ) ∪ P(A|C ) P(C )
P (A) = P(A|B ) P(B ) + P(A|C ) P(C )
THEOREM OF TOTAL PRBABILITY (Multiple
Events):
• A = A∩ S
• A = A ∩ {B1 U B2 U B3 U B4}
• A = {A∩ B1} U {A ∩ B2 }U {A ∩ B3}U {A ∩ B4}
• P(A) = P(A ∩ B1) + P(A ∩ B2)+P(A ∩ B3) + P(A ∩ B4)
• P(A ∩ B1 ) = P(A|B1 ) P(B1 )
• P(A ∩ B2 ) = P(A|B2 ) P(B2 )
• P(A ∩ B3 ) = P(A|B3 ) P(B3 )
• P(A ∩ B4 ) = P(A|B4 ) P(B4 )
• Therefore,
P (A) = P(A|B1 ) P(B1 ) ∪P(A|B2 ) P(B2 )∪P(A|B3 ) P(B3 )∪P(A|B4 ) P(B4 )
P (A) = P(A|B1 ) P(B1 ) +P(A|B2 ) P(B2 )+P(A|B3 ) P(B3 )+P(A|B4 ) P(B4 )
THEOREM OF TOTAL PRBABILITY
In general
• Let {E1 , E2 ,...,En } be a partition of the sample space S, E1, E2, E3, ......En mutually exclusive events.
Ei ∩ Ej = ∅
• Let A be any event associated with S, Then
• A = A∩ S
• A = A ∩ {E1 U E2 U E3, .....U En}
• A = {A∩ E1} U {A ∩ E2} U {A ∩ E3}, .....U {A ∩ En}
• P(A) = P [(A ∩ E1 ) ∪ (A ∩ E2 )∪ .....∪ (A ∩ En )]
• P(A) = P (A ∩ E1 ) + P (A ∩ E2 ) + ... + P (A ∩ En )
• P(A) = P(A ∩ Ei ) = P(Ei ) P(A|Ei ) as P (Ei ) ≠ 0∀i = 1,2,..., n
• Therefore, P (A) = P (E1 ) P (A|E1 ) + P (E2 ) P (A|E2 ) + ... + P (En )P(A|En )
THEOREM OF TOTAL PRBABILITY
Example 10
Company A supplies 80% of widgets for a car shop and only 1% of their widgets turn out to be defective. Company B
supplies the remaining 20% of widgets for the car shop and 3% of their widgets turn out to be defective.if a customer
randomly purchases a widget from the car shop, what is the probability that it will be defective?
If we let P(D) = the probability of a widget being defective and P(Bi) be the probability that the widget came from
one of the companies, then we can compute the probability of buying a defective widget as:
• P(D) = ΣP(D|Bi) P(Bi)
• P(D) = P (D ∩ B1 ) + P (D ∩ B2 )
• P(D) = P(D|B1) P(B1) + P(D|B2) P(B2)
• P(D) = (0.01) (0.80) + (0.03) (0.20)
• P(D) = 0.014
THEOREM OF TOTAL PRBABILITY
Example 11:
Each of Rohit’s three bags holds 100 marbles.
Bag 1 contains 75 red and 25 blue marbles
Bag 2 contains 40 blue and 60 red marbles.
Bag 3 contains 45 red and 55 blue marbles.
Rohit randomly selects one of the bags and then randomly selects a marble from
the selected bag. How likely is it that the selected marble is red?
THEOREM OF TOTAL PRBABILITY
Example 11 Solution:
If the selected stone is red, let R be that event. Let Bi be the event in which Rohit selects Bag i. We are aware of
that.
P(R|B1)=0.75
P(R|B2)=0.60
P(R|B3)=0.45
Now, Using the law of total probability, we can write
P(R)=P(R|B1)P(B1)+P(R|B2)P(2)+P(R|B3)P(B3)
=(0.75)1/3+(0.60)1/3+(0.45)1/3= 0.60
Baye's Theorem.
Let E1, E2,…, En be a set of events associated with a sample space S, where all the events E1, E2,…,
En have nonzero probability of occurrence and they form a partition of S. Let A be any event associated with S,
then according to Bayes theorem,
Baye's Theorem.
Example 12 :
Example 12 solution :
• Let E1, E2, E3 and A be the events defined as follows :
E1= box I is chosen,
E2= box II is chosen,
E3= box III is chosen and
A= a gold coin has been taken out
1
Then P(E1)=P(E2)=P(E3)=3
2
P(A∣E1)=P( drawing a gold coin from box I) =2 = 1
0
P(A∣E2)=P(drawing a gold coin from box II) =2 = 0
1
P(A∣E3)=P(drawing a gold coin from box III) =2
We want to find the probability that the other coin in the chosen box is gold i.e., the probability that gold coin is
drawn from box I By Bayes' theorem,
Baye's Theorem.
Example 13 :
At a certain university, 4% of men are over 6 feet tall and 1% of women are over
6 feet tall. The total student population is divided in the ratio 3:2 in favour of
women. If a student is selected at random from among all those over six feet tall,
what is the probability that the student is a woman
Baye's Theorem.
Example 13 solution :
صلّوا علي النبي ﷺ