You are on page 1of 62

RANDOM EXPERIMENTS

• An experiment that can result in different outcomes, even though it is repeated in the
same manner every time, is called a random experiment.
• It refers to any activity or process in which there is uncertainty as to which of the
possible outcomes will be observed
Examples:
✓tossing a coin
✓rolling a die
✓selecting a card from a deck of playing cards
✓measuring current in a copper wire
✓recording the annual Return of Investment
SAMPLE SPACE
• The set of all possible outcomes of a random experiment is called the sample
space of the experiment. The sample space is denoted as S.
Experiment 1: Tossing a coin
→ S={head, tail}
Experiment 2: Rolling a die
→ S={1, 2, 3, 4, 5, 6}
Experiment 3: Rolling a pair of dice
→ S={(1,1), (1,2), …, (6,6)}
SAMPLE SPACE

Experiment: Consider an experiment that selects a cell phone camera and records
the recycle time of a flash (the time taken to ready the camera for another
flash). The possible values for this time depend on the resolution of the
timer and on the minimum and maximum recycle times.

• Since time is positive it is convenient to define the sample space as 𝑆1 =ℝ+


• If it is known that all recycle times are between 1.5 and 5 seconds, the sample
space can be 𝑆2 ={x|1.5<x<5 }
SAMPLE SPACE
•If the objective of the analysis is to consider only whether
the recycle time is low, medium, or high, the sample space
can be taken to be S3 ={low, medium, high}
•If the objective is only to evaluate whether or not a
particular camera conforms to a minimum recycle time
specification, the sample space can be simplified as
S4 ={yes, no}
TYPES OF SAMPLE SPACE
• A sample space is discrete if it consists of a finite or countable
infinite set of outcomes.
Examples: S3 and S4

• A sample space is continuous if it contains an interval (either


finite or infinite) of real numbers.
Examples: S1 and S2
TREE DIAGRAMS
• Outcomes in finite sample spaces can be displayed in a tree diagram.
Experiment: Recording the sexes of the children of three-child families

1st child G B

2nd child G B G B

3rd child G B G B G B G B

Outcomes {GGG, GGB, GBG, GBB, BGG, BGB, BBG, BBB}


EVENTS
•We may be interested in only part of the sample space.
•For example, we may only be concerned with one girl in
a three-child family; that is, the outcomes GBB, BGB
and BBG.
•These three outcomes constitute a subset of the
sample space and are called events.
EVENTS
• Each outcome in a sample space is an event; each outcome is a
simple event.
• Every sample point is a simple event.
• Events are denoted by uppercase letters
Example:
A = event of having one girl in a three-child family
= {GBB, BGB, BBG}
COMBINING EVENTS
• We can describe new events from combinations of existing events via the
use of basic set operations such as unions, intersections, and
complements to form other events of interest.
• The union of two events is the event that consists of all outcomes that
are contained in either of the two events. We denote the union as A∪B.
(or)
• The intersection of two events is the event that consists of all outcomes
that are contained in both of the two events. We denote the intersection
as A∩B. (and)
COMBINING EVENTS
•The complement of an event in a sample space is the set
of outcomes in the sample space that are not in the event.
We denote the complement of the event A as A′ or Ac
•Events with no intersection are said to be mutually
exclusive.
•Event operations can be displayed on a Venn diagram.
COMBINING EVENTS

Union Intersection Complement


➢ Union of events A and B ➢ Intersection of events A ➢ Complement of A is
is shaded and B is shaded shaded
COMBINING EVENTS
Example: Consider the random experiment of recording the sexes of the children of three-
child families: S = {GGG, GGB, GBG, GBB, BGG, BGB, BBG, BBB}
Let A = event that there is at least two girl in a three-child family
= {GGG, GGB, GBG, BGG}
B = event that a three-child family has all children of the same sex
= {GGG, BBB}
Then,
Ac = {GBB, BGB, BBG, BBB}, A∪B = {GGG, GGB, GBG, BGG, BBB}, and A∩B = {GGG}
COMBINING EVENTS
Example: Consider the camera recycle times where sample space
S= ℝ+ =the set of positive real numbers.
Let E1 = { x | 10<x<12} and E2 = { x | 11<x<15}
Then
E1∩E2 = { x | 11<x<12}
E1∪E2 = { x | 10<x<15}
E2c = { x | 0<x≤11 or x≥15}
COUNTING METHODS

• Multiplication Rule
• Permutation Rule
• Circular Permutation
• Combination Rule
MULTIPLICATION RULE
Assume an operation can be described as a sequence of k steps, and
•the number of ways of completing step 1 is n1, and
•the number of ways of completing step 2 is n2 for each way of completing
step 1, and
•the number of ways of completing step 3 is n3 for each way of completing
step 2,
and so forth.
The total number of ways of completing the operation is
n1 × n2 × n3 × … × nk
MULTIPLICATION RULE

Example 1: How many pairs of a letter and a digit can be made


from the letters A, B, and C and the digits 1, 2, 3, and 4?
Answer: 12 pairs
Example 2: How many two-digit numbers of different digits can be
formed from the numbers 1, 2, 3, and 4?
Answer: 12 two-digit numbers
MULTIPLICATION RULE
Example 3: How many outcomes are possible in tossing a
coin and a die?
Answer: 12 outcomes
Example 4: How many outcomes are possible in tossing a
coin five times?
Answer: 32 outcomes
PERMUTATION RULE
• A permutation of the elements in a set is an ordered sequence of
the elements
• Consider a set of elements, such as S = {a, b, c}. Then the number
of permutations using all letters are: abc, acb, bac, bca, cab, and
cba.
• The number of permutations of n different elements is n!
where:
n! = n × (n-1) × (n-2) × (n-3) × … × 2 × 1
PERMUTATION RULE
• The number of permutations of subsets of r elements selected from a
set of n different elements is
𝐧!
P(n,r) = nPr =
𝐧−𝐫 !
Example 5: How many three-letter words, with or without meaning, can
be formed out of the letters of the world LOGARITHMS, if repetition of
letter is not allowed?
Answer: 720 words
PERMUTATION RULE

• The number of permutations of n = n1 + n2 + … + nr objects of which n1 are of


one type, n2 are of a second type, …, and nr are of an rth type is given by
𝐧!
𝐧𝟏 !×𝐧𝟐 !×...×𝐧𝐫 !
Example 6: How many different ways can 10 flags be arranged in a vertical line
if 3 of the flags are red, 3 are blue, 2 are green, and 2 are white?
Answer: 25200 different signals
PERMUTATION RULE
Example 7: How many arrangements can be made out of the
letters of the word ‘ENGINEERING’?
Answer: 277,200 arrangements
Example 8: In how many ways can the letters of the word
‘LEADER’ be arranged?
Answer: 360 ways
CIRCULAR PERMUTATION

•The number of permutations of n objects in a “circle” is


𝐧−𝟏 !
Example 9: How many ways can four differently colored
poles be arranged around the campus oval?
Answer: 6 ways
COMBINATION RULE
• Another counting problem of interest is the number of subsets of 𝑟
elements that can be selected from a set of 𝑛 elements where order is
not important. These are called combinations.
• The number of combinations, subsets of r elements that can be
𝐧
selected from a set of n elements, is denoted as 𝐫
or nCr and is
computed as
𝐧 𝐧!
= 𝐧𝐂𝐫 =
𝐫 𝐫! 𝐧 − 𝐫 !
COMBINATION RULE
Example 10: How many groups of 3 students can be formed
from 20 students?
Answer: 1,140 groups
Example 11: How many committees of 3 members can be
formed from 18 people?
Answer: 816 committees
COMBINATION RULE

Example 12: Out of seven consonants and 4 vowels, how


many words of 3 consonants and 2 vowels can be
formed?
Answer: 210 words
COMBINATION RULE
Example 13: A class contains 9 boys and 3 girls.
a) In how many ways can the teacher choose a committee of 4?
b) How many committees will contain at least two girls?
c) How many committees will contain exactly two boys?
d) How many committees will contain at most three girls?
Answers: 13a. 495 committees 13c. 108 committees
13b. 117 committees 13d. 495 committees
AXIOMS OF PROBABILITY
Probability is used to quantify the likelihood, or chance, that an outcome of a
random experiment will occur.
Probability is a number that is assigned to each member of a collection of events
from a random experiment that satisfies the following properties/axioms:
a) P(S) = 1
b) 0 ≤ P(E) ≤ 1, for any event E
c) For any two events E1 and E2, with E1∩E2=∅, then
P(E1∪E2)=P(E1)+P(E2)
COMPUTATION OF PROBABILITY
• Equally-likely Outcomes
• Relative Frequency Approach
• Addition Rules of Probability
• Conditional Probability
• Multiplicative Rule of Probability
• Law of Total Probability
• Baye’s Theorem
EQUALLY-LIKELY OUTCOMES
• If we can assume that all the simple events in a sample space have the
same chance of occurrence, then we can measure the probability of an
event as a proportion relative to the number of points in the sample
space
• Equivalently, this is equal to the number of simple events in E divided
by the number of outcomes in S.
no. of simple events in E 𝐧 𝐄
𝑷 𝐄 = =
no. of simple events in S 𝐧 𝐒
EQUALLY-LIKELY OUTCOMES
Example 14: The probability of observing at least one head
when a coin is tossed twice is .
Answer: 3/4
Example 15: What is the probability of recoding a sum of at
least 10 when two dice is rolled?
Answer: 1/6
RELATIVE FREQUENCY
The probability of an event can also be interpreted as the relative frequency at
which the event occurs when the random experiment is repeated a large number
of times
no. of times E is observed
𝑷 𝐄 =
no. of times the experiment is repeated

Example 16: If 54 heads are recorded when a coin is tossed 100 times, then the
probability of a head in the next toss is estimated to be .
Answer: 0.54
PROBABILITY: ADDITIONAL EXAMPLES
Example 17: A random experiment can result in one of the
outcomes {a, b, c, d} with probabilities 0.1, 0.3, 0.5, and 0.1,
respectively. Let A denote the event {a, b, c}, B the event {b, c, d},
and C the event {d}. Compute the following:
a. P(A) = 0.9 d. P(B∪C) = 0.9
b. P(B) = 0.9 e. P(A∩B) = 0.8
c. P(C) = 0.1
PROBABILITY: ADDITIONAL EXAMPLES
Example 18: A box of 50 parts contains 5 that are defective.
A sample of 10 parts is selected at random, without
replacement. What is the probability that the sample
a) no defective part? Answer: 0.311
b) at least 3 defective parts? Answer: 0.048
c) at most 2 defective parts? Answer: 0.952
PROBABILITY: ADDITIONAL EXAMPLES
Example 19: A group of tourists is composed of 3 British, 4 Thais, and 2
Americans.
a) How many ways can a tourist guide select 4 persons at random for a
trip to Corregidor? Answer: 126 ways
b) What is the probability that of the 4 persons, 2 are British and 2 are
Thais? Answer: 0.143
c) What is the chance that 1 British, 2, Thais, and 1 American can go
with the trip to Corregidor? Answer: 0.286
PROBABILITY: ADDITIONAL EXAMPLES
Example 20: Samples of emissions from three suppliers are classified for conformance to
air-quality specifications. The results from 100 samples are summarized as follows
Conforms
Yes No
1 22 8
Supplier 2 25 5
3 30 10

Let A denote the event that a sample is from supplier 1, and let B denote the event that a
sample conforms to specifications. If a sample is selected at random, determine the
following probabilities: a) P(A), b) P(B), c) P(A∪B), d) P(A∩B), e) P(A’)
ADDITION RULES OF PROBABILITY
• For any two events E1 and E2,
P(E1∪E2)=P(E1)+P(E2)-P(E1∩E2)
• If E1 and E2 are mutually exclusive events, then
P(E1∪E2)=P(E1)+P(E2)
• A collection of events E1, E2, E3, …, Ek, is said to be mutually exclusive if for all
pairs Ei∩Ej=∅.
• For a collection of mutually exclusive events,
P(E1∪E2∪…∪Ek)=P(E1)+P(E2)+…+P(Ek)
ADDITION RULES OF PROBABILITY
Example 21: A digit is selected from the set of digits
from 1 through 9.
a) What is the probability that a prime or an odd digit is
selected? Answer: 2/3
b) What is the probability that a digit greater than 5 is
selected? Answer: 4/9
ADDITION RULES OF PROBABILITY
Example 22: In a group of 2500 persons, 1400 are
female, 600 are vegetarian, and 400 are female
and vegetarian. What is the probability that a
randomly selected person from this group is a
male or vegetarian?
Answer: 0.6
CONDITIONAL PROBABILITY
• There are times when we change the probability we assign to an event
once we have additional information concerning the occurrence of
other related events.
• For example, at any given day we may assign a 45% chance of rain.
However, if it rained hard the previous two days, do you risk of leaving
the dorm without an umbrella?
• Of course not!
• You tend to increase the chance of rain today to 99% (from 45%).
CONDITIONAL PROBABILITY

• The probability that event A will occur given a related event B has occurred is
called conditional probability. It is denoted by P(A|B) and is computed as
𝐏 𝐀∩𝐁
𝐏 𝐀|𝐁 = ,𝐏 𝐁 > 𝟎
𝐏 𝐁
• We call event B the “conditioning” event
• Knowing the conditioning event, the sample space is no longer S but B
• The conditioning event is equivalent to the “reduced” sample space
CONDITIONAL PROBABILITY
Example 23: A digit is selected from the set of digits
from 1 through 9.
a) What is the probability that a prime is selected if the
digit is odd? Answer: 3/5
b) If the digit selected is even, what is the probability
that it is composite? Answer: 3/4
CONDITIONAL PROBABILITY
Example 24: Suppose the probability that a randomly selected
student passes Stat21 is 0.6, the probability that he passes
Eng23 is 0.85, and the probability that he passes at least one of
the two subjects is 0.95.
a) If the student received a passing grade in Stat21, what is the
probability that he passes Eng23? Answer: 5/6
b) If the student received a failing grade in Stat21, what is the
probability that he passes Eng23? Answer: 0.875
CONDITIONAL PROBABILITY
Example 25: Suppose 100 employees of VSU were asked whether they are in favor
of or against imposing strictly the “No Smoking Policy” in the campus. The
table below shows the distribution of the 100 employees based on smoking
behavior (smoker or nonsmoker) and opinion (in favor or against).
Favor Against
Non-Smoker 45 15
Smoker 36 4
If an employee is selected at random, what is the probability that he is against
the policy if he smokes? Answer: 0.1
MULTIPLICATION RULE OF PROBABILITY

Let any two events A and B be defined in the


same sample space S. Then
𝐏(𝐀 ∩ 𝐁) = 𝐏(𝐁) × 𝐏(𝐀|𝐁)
or
𝐏(𝐀 ∩ 𝐁) = 𝐏(𝐀) × 𝐏(𝐁|𝐀)
MULTIPLICATION RULE OF PROBABILITY

Example 26: Suppose two cards are drawn in


succession (without replacement) from a deck of
playing cards. What is the probability that both
cards are diamond?
Answer: 1/17
INDEPENDENT EVENTS
•Two events A and B are independent if the occurrence of
one does not affect the probability assigned to the
occurrence of the other.
• Two events are independent if the occurrence of one does
not alter the probability of the other
• Two events A and B are independent events if and only if
any one of the following conditions is true:
1. 𝐏 𝐀|𝐁 = 𝐏 𝐀 3. 𝐏 𝐀 ∩ 𝐁 = 𝐏 𝐀 × 𝐏 𝐁
2. 𝐏 𝐁|𝐀 = 𝐏 𝐁
INDEPENDENT EVENTS
Example 27: Consider tossing a fair die twice. Define
A=event of an even number on the first toss
B=event of observing more than 4 dots on the second toss
C=event of observing less than 6 dots on the first toss
Are the following pairs of events independent? Support your answer.
a) A and B
b) A and C
c) B and C
INDEPENDENT EVENTS

Example 28: Suppose events A and B are independent with


P(A)=0.3 and P(B)=0.6. Compute the following probabilities.
a) P(A∩B)
b) P(A∪B)
c) P(A∩Bc)
SOME IMPORTANT RESULTS
• If A and B are mutually exclusive events and both have nonzero
probabilities, then it is impossible for them to be independent
• If A and B are independent and both have nonzero probabilities, then it
is impossible for them to be mutually exclusive
• If A and B are independent, then so are
a) Ac and Bc
b) Ac and B
c) A and Bc
LAW OF TOTAL PROBABILITY

• Let the sample space be partitioned into two: A and A’. Suppose an event
B cuts across these two partitions.
• The probability of B occurring is given by
𝐏(𝐁) = 𝐏 𝐁 ∩ 𝐀 + 𝐏 𝐁 ∩ 𝐀′
= 𝐏 𝐁|𝐀 𝐏 𝐀 + 𝐏 𝐁|𝐀′ 𝐏 𝐀′
LAW OF TOTAL PROBABILITY
Example 29: Suppose we have two hats: one has 4 red
balls and 6 green balls, the other has 6 red and 4
green. We toss a fair coin, if heads, pick a random
ball from the first hat, if tails from the second.
What is the probability of getting a red ball?
Answer: 0.5
LAW OF TOTAL PROBABILITY
Example 30: A soccer team wins 60% of its games
when it scores the first goal, and 10% of its
games when the opposing team scores first. If
the team scores the first goal about 30% of the
time, what fraction of the games does it win?
Answer: 0.25
LAW OF TOTAL PROBABILITY
•Suppose the sample space S is partitioned into k
mutually exclusive and exhaustive events E1, E2, …, Ek
(refer to the figure below for k=4). Then
𝐏(𝐁) = 𝐏 𝐁 ∩ 𝐄𝟏 + 𝐏 𝐁 ∩ 𝐄𝟐 + ⋯ + 𝐏 𝐁 ∩ 𝐄𝐤
= 𝐏 𝐁|𝐄𝟏 𝐏 𝐄𝟏 + 𝐏 𝐁|𝐄𝟐 𝐏 𝐄𝟐 + ⋯ + 𝐏 𝐁|𝐄𝐤 𝐏 𝐄𝐤
𝐤

= ෍ 𝐏 𝐁|𝐄𝐢 𝐏 𝐄𝐢
𝐢=𝟏
LAW OF TOTAL PROBABILITY
Example 31: A factory production line is manufacturing bolts using three
machines, A, B and C. Of the total output, machine A is
responsible for 25%, machine B for 35% and machine C for the
rest. It is known from previous experience with the machines that
5% of the output from machine A is defective, 4% from machine B
and 2% from machine C. A bolt is chosen at random from the
production line, what is the probability that it is defective?
Answer: 0.0345
LAW OF TOTAL PROBABILITY

Example 32: A factory production line is manufacturing bolts using three


machines, A, B and C. Of the total output, machine A is responsible for
25%, machine B for 35% and machine C for the rest. It is known from
previous experience with the machines that 5% of the output from
machine A is defective, 4% from machine B and 2% from machine C. A
bolt is chosen at random from the production line and found to be
defective. From which machine it most likely comes from?
Answer: Machine B
BAYES’ THEOREM
Let A1, A2, …, Ak be a collection of mutually exclusive and
exhaustive events with prior probabilities P(Ai), i=1, 2,…, k. Then
for any event B for which P(B)>0, the posterior probability of Ai
given that B has occurred is
𝐏 𝐀𝐢 ∩ 𝐁
𝐏(𝐀𝐢 |𝐁) =
𝐏 𝐁
𝐏 𝐁|𝐀𝐢 ⋅ 𝐏 𝐀𝐢
=
𝐏 𝐁|𝐀𝟏 × 𝐏 𝐀𝟏 + 𝐏 𝐁|𝐀𝟐 × 𝐏 𝐀𝟐 + ⋯ + 𝐏 𝐁|𝐀𝐤 × 𝐏 𝐀𝐤
BAYES’ THEOREM

Example 33: The probability of having an accident in a factory


that triggers an alarm is 0.1. The probability of it
sounding after the event of an incident is 0.97 and the
probability of it sounding after no incident has occurred
is 0.02. If the alarm has been triggered, what is the
probability that there has been no accident?
Answer: 0.1565217391
ADDITIONAL EXAMPLES
1. The route used by a certain motorist in commuting to work contains
two intersections with traffic signals. The probability that he must stop
at the first signal is 0.4, the analogous probability for the second signal
is 0.75, and the probability that he must stop at least one of the two
signals is 0.6. What is the probability that he must stop
a. At both signals?
b. At the first signal but not at the second one?
c. At exactly one signal?
Answers: a) 0.3 b) 0.1 c) 0.85
ADDITIONAL EXAMPLES

2. A math teacher gave her class two tests. 25%


of the class passed both tests and 42% of the
class passed the first test. What percent of
those who passed the first test also passed the
second test?
Answer: 60%
ADDITIONAL EXAMPLES

3. The probability that it is Friday and that a


student is absent is 0.03. What is the
probability that a student is absent given that
today is Friday?
Answer: 0.15
ADDITIONAL EXAMPLES
4. There are three boxes, each containing a different
number of light bulbs. The first box has 10 bulbs, of
which four are dead, the second has six bulbs, of
which one is dead, and the third box has eight bulbs
of which three are dead. What is the probability of a
dead bulb being selected when a bulb is chosen at
random from one of the three boxes?
Answer: 113/360≈31.4%

You might also like