+ P(B) - staff.city.ac.uk

Download Report

Transcript + P(B) - staff.city.ac.uk

P(A) = Oval Area
P(A or B) = r + w + g
So, P(A) + P(B)
= r+w+g+w
The Addition Rule for
2 events A and B
P(A or B) = P(A) +
P(B) - P( A and B)
P(B) = Triangle Area
P(A and B) = w
What is the probability of
choosing a red tile at random? = 2/9
Event: Five blue tiles are removed
What is the probability now,
given the event?
=1/2
Conditional Probability
A
AB
B
A
P(A|B) = P(A and B)/ P(B)
• An Example:
• Suppose 5% of 2m cars in a community
are ‘bad’ (B), 20% are brand A and 2%
are both bad and brand A (A and B).
• Question: What is the probability that a
car is bad, given that it is brand A?
• Answer : |A| = 400000; |B| = 100000
• |B and A| = 40000
• P(B|A) = P(B and A)/P(A)
• =(40000/2m)/(400000/2m) = 0.1
• The probability of event B is dependent
on the the event A.
• A and B are not independent events.
Statistical independence
Two events e and f are statistically
independent if and only if
P(e|f) = P(e)
P (e | f) = P(e and f)/P( f)
•The Multiplication rule:
•For two events e and f
•P (e and f) = P (e | f)* P ( f)
If e and f are independent then
P (e and f ) = P (e) *P( f)
An example to show that two events can
be mutually exclusive and dependent
A bag contains 6 black and 4 red balls.
Experiment : Two balls are chosen one
after the other (with replacement)
A : Event the first ball is red
B: Event both are black
P(A) = 4/10 = 0.4
P(B) = 6/10 * 6/10 = 0.36
P(A and B) = 0
So A and B are mutually exclusive
But,
P(B|A) =P(A and B)/P(A) = 0
So, P(B|A)  P(B)
A and B are not independent events
An example to show that two events can
be independent yet not mutually exclusive
A community has 1m people.
600,000 are women (W)
500,000 are adults (A)
300,000 adults are women (A and W)
Obviously A and W are not
mutually exclusive
P(A|W) = P(A and W)/P(W)
= 300,000/600,000 = 0.5
Also, P(A) = 500,000/1 million = 0.5
Thus, P(A|W) = P(A)
A and W are independent events
• Arrangements and Selections
• Consider the following two problems:
• a. How many ways two letters can be
selected from the set containing the three,
A, B and C, (order of selection important)
• b. How many ways two letters can be
selected from the set containing the three,
A, B and C, (order of selection not
important)
A
B
A
C
B
A
B
C
C
A
C
B
In problem a, the answer is AB, AC,
BA, BC, CA, CB.
The problem is relevant in choosing a
password, for example.
The password AB123 is not the same
as BA123 !
Each of the six possibilities is called
an arrangement or a permutation.
Altogether, we have 6 = 3 X 2
ways
The 3 represents the number of letters
to choose from and the number of
terms in the multiplication represents
the number of letters to choose.
In problem b, the answer is AB, BC
and CA, a total of 3 different
selections or combinations.
This problem is relevant when
selecting members of a committee, for
example.
The committee consisting of member
A being selected first and then B is not
different from the one in which B was
chosen first and then A.
Arrangements
AB
AC
BC
BA
CA
CB
Now consider problem c:
Selections
AB
AC
BC
How many ways three letters can be
selected from the set containing the
three, A, B, C. (order of selection
important)?
A
B
C
A
C
B
B
C
A
B
A
C
C
A
B
C
B
A
ABC
BAC
ACB
BCA
CAB
CBA
Altogether, we have 6 = 3 X 2 X 1
ways
The 3 represents the number of letters
to choose from and the number of
terms in the multiplication represents
the number of letters to choose.
In general, if r letters are to be selected
from n possible ones, where (r ≤ n),
order of selection important, the total
number of selections is
nP = nx(n-1)x(n-2)…x(n-r+1)
r
If r = n, we have the total number of
selections = nx(n-1)x(n-2)….x2x1 = n!
(read ‘factorial n’).
We cannot choose the same answer for
problem b as that of a, since order is
unimportant.
AB is no different from BA!
So for every two selections in a, we
need to take only one. Hence the
answer is 3.
Arrangements
AB
AC
BC
BA
CA
CB
Selections
AB
AC
BC
In general, if r letters are to be selected
from n possible ones, where (r ≤ n), order
of selection not important, we first start
with the number
nPr = nx(n-1)x(n-2)…x(n-r+1)
 Then we realise that the r letters selected
can themselves be arranged in r! ways.
Since order is not important, we should
just count only one selection for every r!
of them.
So the required number is
 nCr = nPr /r! = {nx(n-1)x(n-2)…x(nr+1)}/rx(r-1)x(r-2)x …x2x1
Thus, the number of 5-member
committees formed out of 20 possible
candidates is
 20C5 = (20 x 19 x 18 x 17 x 16) / (5
x 4 x 3 x 2 x 1) = 15504
Examples:
1. A committee of three is to be selected
from 3 boys and 4 girls. It must have
exactly 1 boy and 2 girls in it. How many
such committees can be formed?
Let the boys be called B1, B2 and B3, the
girls G1, G2, G3 and G4 First, consider
those selections in which B1 is selected.
So two girls have to chosen to form the
committee.
Two girls out of four can be chosen in
4C = 4x3/2x1 = 6 ways. So we shall have
2
6 committees in which B1 is a member.
But what about committees of which (i)
B2 is a member and (ii) B3 is a member?
There are six of each type above.
So there are 6 x 3 = 18 committees
altogether.
• The formal way of answering the question
is as follows:
• 1 boy can be chosen out of 3 in 3C1 = 3
possibilities.
• For each such selection of a boy, 2 girls
out of 4 can be selected in 4C2 w= 6
different ways.
• So the total number of possible selections
is 3C1 X 4C2 = 18
• 2. The
UK National Lottery
• (i) What is the probability of winning the
jackpot from a single ticket?
• (ii) What is the probability of winning
exactly £10 from a single ticket?
• Answer (i) : If 6 balls are chosen out of
49 then there are 49C6 or 13983816 ways
of doing so.
• The machine can select any one of
13983816 combinations.
• So P(one ticket wins jackpot)
• = 1/ 13983816
• Answer (ii): Consider the six (yet unknown)
numbers to be chosen by the machine and
call them ‘winners’.
• So there are 6 winners and 43 losers.
• A ticket wins £10 if it selects exactly 3
winners out of 6 and 3 losers out of 43.