STA 111 - Topic 6 Notes - Probability
STA 111 - Topic 6 Notes - Probability
6.1 Objectives
By the end of the topic, the learner should be able to:
i) Define the term probability
ii) Work out problems involving the different types of events
iii) Apply the concept of compound probability
iv) State, prove and apply Baye’s theorem in problem solving
6.2 Introduction
Outline of Statistics
Statistics is an increasingly important subject which is useful in many types of scientific
investigation. It has become the science of collecting, analysing and interpreting data in
the best possible way. Statistics is particularly useful in situations where there is
experimental uncertainty and may be defined as ‘the science of making decisions in the
face of uncertainty’.
The concept of probability
Some Definitions
The sample space is defined as the set of all possible outcomes of an experiment. For
example:
When a die is thrown the sample space is 1, 2, 3, 4, 5 and 6. i.e. S 1, 2, 3, 4, 5, 6
If two coins are tossed, the sample space is HH, TT, HT, and TH. i.e.
S HH , TT , HT , TH
In testing the reliability of a machine, the sample space is ‘success’ and ‘failure’.
Each possible outcome is a sample point. A collection of sample points with common
property is called an event. It is usually denoted by E.
If a die is thrown and a number less than 4 is obtained, this is an event containing
the sample points 1, 2, and 3.
If two coins are tossed and at least one head is obtained, this is an event
containing the sample points HH, HT and TH.
NOTE:
(i) ES
(ii) A sample point is an event consisting of one element only.
(iii) An empty set, , is an event in S, i.e, S
(iv) S itself is also an event
Page 1 of 16
i. A B is an event that occurs if A occurs or B occurs or both A and B occurs.
ii. A B is an event that occurs if both A and B occurs.
iii. A , Ac , or A is the event that occurs if A does not occur.
n( A) No. of elements in A
From definition; P ( A) and 0 P( A) 1 for every event A
n( S ) No. of elements in S
in S.
The probability of a sample point is the proportion of occurrences of the sample point in
a long series of experiments.
We will denote the probability that sample point x will occur by Px . For example, a
coin is said to be ‘fair’ if heads and tails are equally likely to occur, so that
P (H) = P (T) = ½. By this we mean that if the coin is tossed N times and f H heads are
observed, then the ratio f H / N tends to get closer to ½ as N increases. On the other
hand if the coin is ‘loaded’ then the ratio f H / N will not tend to ½.
The probability of a sample point always lies between zero and one
If the sample point cannot occur, then its probability is zero, but if the sample
point must occur, then its probability is one.
The sum of all the sample points is one.
Probability theory is concerned with setting up a list of rules for manipulating these
probabilities and for calculating the probabilities of more complex events. Most
probabilities have to be estimated from sample data but simple examples deal with
equally likely sample points which are known to all have the same probability.
6.3 Probability
Likelihood of an event happening. It is a measure of chance with which we expect an
event to occur and it is assigned values ranging from 0 to 1.
For an impossibility, the probability is 0 and for a certain event it is 1.
Page 2 of 16
𝑆 = {1, 2, 3, − − − − 𝑛}
And the probability of 𝐴𝑖 is equal to 𝑃 (𝐸𝑖 ), this leads us to the following axioms:
i) For every event A S , 0 P( A) 1
ii) P (S) = 1
iii) If A and B are mutually exclusive events in S, P( A B) P( A) P( B) .
iv) If A1 , A2 , , An are mutually exclusive events (defined below) in S,
P( A1 A2 An ) P( A1 ) P( A2 ) P( An ) .
The notation ( E1 E2 ) means that at least one of the events occurs; as applied to
mutually exclusive events it means that one event or the other occurs.
For example if a coin is tossed once and head appears the tail cannot appear.
Example 6.1
A deck of playing cards is thoroughly shuttled and a card drawn from the deck.
What is the probability that the card drawn is an Ace of Diamond 1/52
Example 6.2
The probability of obtaining either a two or a five in a single throw of a single
dice.
E1 = {a two}
E2 = {a five}
P (E1 u E2) = P (E1) + P (E2)
= 1/6 + 1/6 = 2/6 = 1/3
Example 6.3
A ball is thrown at random from a box with 6 red balls. A white and 5 blue balls.
Determine probability that it is
Page 3 of 16
i) Red
ii) White
iii) Blue
iv) Not Red
v) Red or White
Page 4 of 16
P ( E1 E2 ) P ( E1 ) P ( E2 ) P ( E1 E2 ) , where (E1 ∩E2) is the event that both E1
and E2 occur.
Example 6.5
What is the probability of rolling two dice to obtain the sum seven and/or the
number three on at least one die?
Solution
Let event 𝐸1 be ‘the sum is 7’ and event E2 be ‘at least one 3 turns up’. By
inspection of the table in the previous example, we find
6 11 2
P (E1) = , P ( E2 ) , P ( E1 E 2 )
36 36 36
6 11 2 15
Thus P ( E1 E 2 ) P ( E1 ) P ( E 2 ) P ( E1 E 2 )
36 36 36 36
Events that are not mutually exclusive may be further classified as dependent or
independent events. Dependence between events is treated by the notion of
conditional probability.
Page 5 of 16
ii. Not Replaced
4/25*3/5
Example 6.7
A bowl consists of 8 clips 3 red and the rest blue. Two clips are drawn successfully at
random without replacement. What is the probability that the first clip drawn is red and
the second drawn is blue.
P (Fr) = 3/8
P (Sb) = 5/7
P (A n B) = P (A).P (B/A)
= 3/8 * 5/7
Example 6.8
A driving school had 1000 students derivers of whom attended a drivers training
course. A survey of all the drivers was conducted over a one year period to find out
how many were involved in at least one road accident in which they were at fault. The
results are calculated
below
Attend Course Did not attend Total
Course
Accidents 30 70 100
No Accident 570 330 900
Total 600 400 1000
What is the probability that a student who took the course was not involved in any
accident?
Let A = {had an accident}
C = {took the course}
P (C n A1) = P (C).P (A1/C)
=600/1000.570/600
Theorems of Conditional Probability
i. P (A1 n A2) = P (A1). P(A2/A1)
ii. P (A1 n A2 n An3) = P (A1).P(A2/A1).P(A3/A1 n A2)
iii. P (A1 n A2….An) = P (A1). P (A2/A1)…..P(An/A1 n A2….An-1)
Page 6 of 16
6.5.2.2 Independent and Dependent events
Two events, E1 and E2, are said to be independent if P ( E1 ) P ( E1 | E2 ) . Thus the
knowledge that event E2 has occurred has no effect on the probability of event E1.
Conversely, two events are said to be dependent if P ( E1 ) P ( E1 | E2 ) .
Example 6.9
A coin is tossed three times and the eight possible outcomes, HHH, HHT, HTH, THH,
HTT, THT, TTH, and TTT, are assumed to be equally likely. If A is the event that a head
occurs on each of the first two tosses, B is the event that a tail occurs on the third toss,
and C is the event that exactly two tails occur in the three tosses, show that:
(a) events A and B are independent;
(b) events B and C are independent.
Solution
Since
A HHH , HHT
B HHT , HTT , THT , TTT
C HTT , THT , TTH
A B HHT
B C HTT , THT
the assumption that the eight possible outcomes are all equiprobable yields
1 1 3 1 1
P( A) , P( B) , P(C ) , P( A B) , and P( B C ) .
4 2 8 8 4
1 1 1
(a) Since P( A) P( B) P( A B) , events A and B are independent.
4 2 8
1 3 3
(a) Since P( B) P(C ) P( B C ) , events B and C are not independent.
2 8 16
Example 6.10
Balls are drawn successfully from a box containing 5 Red of balls 4 white, 6 red
Find the probability they are drawn in order red, white and blue if each ball is
i. Replaced
ii. Not Replaced
Replaced
P (R n W n B) = P (R). P (W/R) P (B/R n W)
= 6/15.4/15.5/15
Page 7 of 16
Not Replaced
= 6/15.4/14.5/13
Exercise
One bag containing 4 white & 2 black balls and another bag 3 white & 25 black ball if
one ball is drawn from each bag. Find the probability that
a. Both are white
b. Both are black
c. One is white and one is black
Example 6.11
A Son is to meet his Father at a given time. The probability of him being punctual if he
travels by bus is 0.2 & 0.5 if he travels by train. It is 0.9 if he is given a lift in a car. The
probability of him travelling by train, bus and car are 0.3, 0.4 and 0.3 respectively. What
is the probability that he will be punctual?
Solution
Example 6.12
A motor company works orders 40% from steelworks & 30% from steel works & 30%
from steelworks. It is known from experience that 6% from S1, 5% from S2 and 4% from
Page 8 of 16
S3 are of inferior quality. The quality control department choices are random a piece of
metal in order to check its probability.
a. What’s probability that the piece of metal is of inferior quality
b. If the metal work
i. S1
ii. S2
iii. S3
Solution
a) Let E = Inferior quality
E1 = {from S1}
E2 = {from S2}
E3 = {from S3}
P/ (E) =0.4*0.06+0.3*0.05+0.3*0.04 =
i. Probability from S1
P (E/E) = P (E1).P (E/E1) / P (E1).P (E/E1) + P (E2). P (E3). P (E/E3)
0.4*0.06/0.4*0.06+0.3*0.05+0.3*0.04 = 0.4*0.06/0.051
ii. S2
0.3*0.05/0.05 = 0.294
iii. S3
0.3*0.04/0.051 = 0.235
Example 6.13
There are 3 Urns, 1 black containing 3 red 7 white marble, 1 red containing 4 yellow 6
green marble and 1 white containing 8 yellow 2 green marble. A marble is first drawn
from the black Urn, a second marble is drawn from the Urn that has the same color as
marble drawn. If the second marble is yellow. What is the probability that 2 marble was
Red?
Let E = {Red}
E2 = {white}
P (E1/E) = (PE1). P (E/E1)/ P (E1). P (E/E1) + P (E2). P (E/E2)
= 0.3 *0.4/0.3*0.4+0.7*0.8 = 0.3*0.4
Example 6.14
Box 1 contains 3 red and 2 blue marbles and box 2 contains 2 red and 8 blue marbles. A
fair coin is tossed for the coin turns up heads a marble from box 1 is chosen and if the
coins turns tails a marble from box 2 is chosen.
Page 9 of 16
i. Find probability that a red marble is chosen
ii. Supposed a red marble is chosen and the box from which is chosen is not
revealed what is the probability that box 1 was chosen?
Example 6.15
A newspaper receives 500 newspapers daily as follows
100 copies of newspaper A
150 copies of newspaper B
250 copies of newspaper C
On a particular day 70% A, 80% of B and 90% of C have prospects randomly selected
inserted inside the newspaper. What is the probability of the first customer of day
receives a newspaper without a prospect?
Supposing a customer received a newspaper is the prospect. What is the probability he
bought newspaper A
Page 10 of 16
6.7.1 Venn Diagrams
In a language’s college there are 60 students of this 30 students study French, 25
German & 20 study both German & French.
A student from the College is randomly chosen. What is the probability that the student
a. Study’s French = 30/60
b. Does not study French = 30/60
c. Study German = 25/60
d. Does not study German =35/60
e. Studies both German & French = 20/60
f. Study’s French or German = 35/60
g. Study’s none of the above languages = 25/60
F G
10 5
Page 11 of 16
A 2A
8/20 12/20
1
EXAMPLE 2
Contingency table for 2 event is as shown below
A 2A
0.80 0.20 1
Determine
i. 𝑃 (𝐴 ∪ 𝐵) = 𝑃 (𝐴) + 𝑃(𝐵) – 𝑃 (𝐴 𝑛 𝐵)
0.8 + 0.60 − 0.45
ii. P (A/B)
iii. P (A/B) = P (A n B)/P(B) = 0.45/0.6
Example 6.16
Page 12 of 16
Two events are mutually exclusive. Copy and complete the contingency table below
hence determine
I. P (A u B)
II. P (2A/2B)
A 2A
B 0 1/4 ¼
2B
2/5 7/20 3/4
2/5 3/5 11
P (A u B)
= P (A) + P (B) – P (A n B)
2/5 +1/4 - 0 = 13/20
P (2A/2B)
P (2A n 2B)/P (2B) = 7/20/ 3/4 = 7/15
Exercise
Given that A & B are independent events. Copy and complete the table below.
A 2A
1/4 3/4 1
Determine
i. P (A u B )
ii. P (A/B)
iii. P (2A/2B)
Page 13 of 16
6.8 Tree Diagrams
This are logical diagrams representing 3 or more events. The simple rule while drawing
tree diagram is that for only event A
P (A) + P (2A) = 1
Example 6.17
In a large flower farm 20% of a particular kind of flower is red the remaining 80% is
white. The farmer decides to take samples of flowers from the production. What is the
probability that he obtains.
a) 1 or 2 red flowers in a sample of two.
b) At least 2 red flowers in a sample of three
R = RR
0.2
R
0.8
0.2 W = RW
0.8 R = WR
0.2
W
0.8
W = WW
P (RR) + P (RW) + P (WR)
= 0.2 * 0.2 + 0.2 *0.8 + 0.8 *0.2 = 0.36
Or
1 – P (WW)
0.8 *0.8 = 0.64
1 – 0.64 = 0.36
At least 2 red flowers
0.2*0.2+0.2*0.8+0.2*0.8 0.2 R =RRR
R 0.8
Page 14 of 16
0.2 W = RWR
R 0.8 0.2 R = RWR
0.2 W 0.8 W = RWW
W 0.2 R = WRW
0.8 W
0.8 W = WWW
1. A bag containing 3 red, 2 black & 1 green marble. 2 marble are drawn without
replacement
2. Prof Owino has 3 cars of colors red, white and blue. One day he uses red car he
travels to the university he squealy travels to use white or blue car the following
day. On the day he uses the red car he is usually likes to use the same car next day
with probability of ½ or either of the other car with probability of ¼ of each car.
On the day he uses the blue car he is likely to use the same car next day with
probability of 2/3 or either of the two cars with probability of 1/6 each.
On any Monday at the start of week he squealy likely to use any of the 3 cars.
Page 15 of 16
6.9 Combinational Analysis
If the sample points are not countable and combinations of subjects of this sets cannot
be easily identified then combinations and permutations can be used.
𝑛!
i. Permutations𝑛𝑃𝑟 = (𝑛 – 𝑟)!
Example
How many 4 letters combinations can be made from the 7 letters A, B, C, D, E,
F, G
n=7
7! 7! 7∗6∗5∗4∗3∗2∗1
r=4 7P4 = = = 840
7−4 ! 3 ! 3∗2∗1
ii. Combination
In permutation interest is in the order of objects arrangement A, B, C, D, BCD
A
Selection with regard to order of selection is called Combinational B C D A & A B
C D are the same combination
𝑛!
n Cr = 𝑛 −𝑟 !𝑟!
Example
a) Determine the no of ways of selecting 3 cards from a total of 8 different cards.
n=8
r=3
𝑛! 40320
8C3 = = = 2016
8−3 !3! 5 !3!
Page 16 of 16