Download Chapter Three Discrete Random Variables & Probability

Document related concepts

Statistics wikipedia , lookup

History of statistics wikipedia , lookup

Ars Conjectandi wikipedia , lookup

Probability wikipedia , lookup

Probability interpretations wikipedia , lookup

Transcript
Chapter Three
Discrete Random
Variables & Probability
Distributions
Random Variable
A “rule” that assigns a
number to each outcome
in the sample space.
Types of RVs
Discrete:
Possible values either constitute a finite
set or else an infinite sequence in
which there is a first element, second
element, etc.
Continuous:
Possible values consists of an entire
interval on the number line.
Bernoulli RV
A RV with only two
possible values: 0 or 1
Probability Distribution
A mathematical model that
relates the value of a RV
with the probability of
occurrence of that value in
the population.
Probability Measures
Given real numbers r1 & r2:
Probability that a RV
a) Equals r1
b) Is greater than r1
c) Is between r1 & r2
d) Is less than r1
e) Is less than or equal to r1
Example: Discrete Probability Distribution
A machine produces 3 items per day.
QC inspection assigns to each item at
the end of the day: defective or nondefective. Assume that each point in
the sample space has equal probability.
If RV X is the number of defective
units at the end of the day, what is the
probability distribution for X?
Example: Discrete Probability Distribution
Continued from Previous Example:
If a non-defective items yields a
profit of $1,000 whereas a defective
item results in a loss of $250. What
is the probability distribution for the
total profit for a day?
Discrete Probability Distribution
A mfg. plant has 3 student & 3
veteran engineers assigned to the
shop floor. Two engineers are
chosen at random for a special
project. Let the RV X denote the
number of student engineers
selected. Find the probability
distribution for X.
Discrete Probability Distribution
Starting at a fixed time, we observe
the make of each car passing by a
certain point until a Ford passes by.
Let p = P(Ford) & RV X defined as
the number of cars observed. Find
the probability distribution for X.
Example: PMF
Consider the number of cells exposed to
antigen-carrying lymphocytes in the presence
of polyethylene glycol to obtain first fusion.
The probability that a given cell will fuse is
known to be ½. Assuming that the cells
behave independently, find the probability
distribution for the number of cells required
for first fusion. What is the probability that
four or more cells require exposure to obtain
the first fusion?
Cumulative Distribution Function
CDF of a Discrete RV X with pmf p(x)
is defined for every number x by:
F(x) = P(X<=x) =  p(y)
y: y<=x
OR
F(n) = p(x1) + p(x2) + …+ p(xn)
Where xn is the largest value of the x’s
less than or equal to n.
CDF Properties
For any two numbers a & b with a <= b,
P(a<=X<=b) = F(b) – F(a )
Where a represents the largest possible
X value that is strictly less than a.
If all integers for a, b, and values:
P(a<= X<=b) = F(b) – F(a-1)
Taking a=b: P(a) = F(a) – F(a-1)
Example CDF
Let X denote the RV which is the toss
of a loaded die. The probability
distribution of X follows:
p(1) = p(2) = 1/6 p(3) = 1/12
p(4) = p(5) = ¼
p(6) = x
a) Find the value of x.
b) Evaluate the CDF at 3.6.
c) Find p(3<=X<=5).
CDF to Find Probabilities
A mail-order business has 6 telephones. Let
RV X denote the number of phones in use at
a specified time. The pmf of X is given as
follows:
x |
0
1
2
3
4
5
6
p(x) | .01 .03 .13 .25 .39 .17 .02
What is the probability of:
a) at most 3 lines are in use?
b) at least 5 lines are in use?
c) between 2 & 4 lines, inclusive
are in use?
Expected Values Of Discrete RV
E(X) = X =  xnp(xn)
All n
Multiply every value that the RV can
take on by the probability that it takes
on this value; then add all of these
terms together.
Example of Expect Values
What is the expected value
of the RV X where X is the
value on the face of a die?
Expected Value
What is the expected value for
the RV X, which is the sum of
the upturned faces when two dice
are tossed?
Expected Value
A university has 15,000 students. Let
RV X equal the number of courses
for which a randomly selected
student is registered. The pmf of X
follows:
x | 1 2 3 4 5 6 7
p(x) | .01 .03 .13 .25 .39 .17 .02
Find the expected value of X.
Expected Value of Bernoulli RV
pmf: p(x) = 1 – p
p
for x = 0
for x = 1
What is the expected value of X?
Expected Value of a Function
E[h(X)] =  h(k)p(k)
All k
RV X has set of possible values k
& pmf p(x).
Variance of a Discrete RV
V(X) =
2

=  (k -
2
) p(k)
All k
RV X has a set of possible values k
with pmf p(x) and expected value .
SD(X) = X =
2
√(X )
Variance Shortcut Method
V(X)=[
2
k p(k)]
-
2

=
2
2
E(X )-[E(X)]
All k
Steps:
Find E(X2)
Compute E(X)
Square E(X)
Subtract this value from E(X2)
Example of Variance & E(X)
A discrete pmf is given by:
p(x) = Ax x = 0,1,2,3,4,5
Determine A.
What is the probability that x<=3?
What is the expected value of X?
What is the Variance & SD?
Example of E(X) & Variance
Given the following pmf for RV X:
x p(x)
0 1/8
1 ¼
2 3/8
3 ¼
Find the E(X).
Find the Variance. (Use Short Cut)
Expect Value & Variance
Three engineering students volunteer for a
taste test to compare Coke & Pepsi. Each
student samples 2 identical looking cups &
decides which beverage he or she prefers.
How many students do we expect to pick
Pepsi; knowing that 3/5 of all students
prefer Pepsi over Coke?
b) Find the Variance of the RV.
Discrete Probability Distributions
Binomial
Negative Binomial
Hypergeometric
Poisson
Binomial Probability Distribution
Binomial Experiment:
> Consists of a sequence of n trials,
where n is fixed in advance.
> The trials are identical & each
trial can result in one of the same
two possible outcomes.
> The trials are independent.
> The probability of the outcomes
is constant & is equal to p & 1-p.
Binomial pmf
b(x; n, p) =
n!
x!(n-x)!
x = 0,1,2,3,…,n
x
n-x
p (1-p)
Example Discrete pmf
You draw at random a 20 piece
sample from a group of 300 parts
in storage where 10% of the parts
are known to be out of
specification. What is the probability
that 1 part in your sample will be out
of spec.?
Binomial Example
A coin is tossed 4 times. What is
the pmf for the RV X; the
number heads?
What is the probability of having
3 or fewer Heads?
Binomial Example
There are 5 intermittent loads
connected to a power supply. Each
load demands either 2w or no power.
The probability of demanding 2w is
¼ for each load. The demands are
independent. What is the pmf for the
RV X, the power required?
Example Binomial pmf
A lot of 300 manufactured
baseballs contains 5% defects. If
a sample of 5 baseballs is tested,
what is the probability of
discovering at least one defect.
Negative Binomial pmf
Experiment:
> The trials are independent.
> Each trial can result in either a
success (S) or a failure (F).
> The probability of the outcomes is
constant from trial to trial.
> The experiment continues until a
total of r successes have been
observed, where r is a specified
positive integer of interest.
Negative Binomial pmf
nb(x; r, p) = (x+r-1)!
(r-1)!(x)!
x = 0,1,2,3,…
r
x
p (1-p)
Negative Binomial Example
An engineering manager needs to recruit
5 graduating student engineers. Let
p = P (a randomly selected student
agrees to be hired). If p = 0.20, what is
the probability that 15 student engineers
must be given an offer before 5 are
found who accept?
Discrete pmf Example
Your oil exploration crew is testing for well
sites. Historically, the probability of finding
oil in your present geographical location is
1/20. HQs needs your crew to locate 2 oil
producing wells within 2 weeks. If set-up &
testing for oil takes 1 day, what is the
probability that it will take less than 2
working weeks to find these 2 spots?
nb Probability Distribution
You have passed your ISE 261 at the end of the
semester & decide to celebrate. For whatever reason,
you are arrested for a misdemeanor & sentenced for 90
days in the county jail. The judge being a student of
Probability Theory decides to give you an option. You
can have the full 90 days or you can elect to leave jail
after rolling 1 die for 16 straight even numbers.
Which option do you decide to take? Remember, the
judge will only give you a guard for affirming your rolls
for 8 hours per day. Your ability to roll one die for 16
rolls is 2 minutes & the judge insists on blocks of 16
rolls.
Geometric Probability Distribution
You have conducted a series of
experiments to reduce the proportion of
scrapped battery cells to 1% in your
manufacturing plant. Now, what is the
probability of testing 51 cells without
finding a defect until the last cell?
Hypergeometric pmf
Experiment:
> Consists of N individuals, objects, or
elements (a finite population).
> Each individual can be characterized
as a success (S) or failure (F), & there a
M successes in the population.
> A sample of n individuals is selected
without replacement in such a way that
each subset of size n is equally likely to
be chosen.
Hypergeometric Probability Distribution
For RV X the number of S’s in the sample.
h(x; n, M, N) = Cx,M Cn-x,N-M
Cn,N
Integer x satisfies:
Max(0, n-N+M)<= x <= Min(n,M)
Example Hypergeometric pmf
From a group of 20 EE students, you
select 10 for employment. What is
the probability that the 10 selected
include all the 5 best engineers in the
group of 20?
Hypergeometric Example
Your manufactured product is shipped in lots of
20. Testing is costly, so you sample production
rather than use 100% inspection. A sampling plan
constructed to minimize the number of defectives
shipped to customers calls for sampling 5 items
from each lot & rejecting the lot if more than 1
defective is observed. If a lot contains 4
defectives, what is the probability that it will be
rejected?
Poisson Probability Distribution
For RV X, the number of random events
that occur in a unit of time, space, or any
other dimension often follows:
p(x; ) =
-
x
e ()
x!
x = 0,1,2,…
>0
Binomial Approximation
In any binomial experiment in which
n is large & p is small, the binomial
pmf is approximately equal to the
poisson pmf where  = np.
Rule of Thumb
n => 100; p <= .01; np <= 20
Mean & Variance of Poisson
E(X) = V(X) = 
Poisson pmf Example
You are in charge of a PCB operation.
It is known that the distribution of
the number of solder balls occurring
on 1 board in this process is Poisson
with  = 1.0. You have 1,000 PCBs in
this process & would like to estimate
how many boards would have solder
balls on them.
Poisson Probability Distribution
A radioactive substance emits alpha
particles. The number of particles
reaching a counter during an interval of
1 second has been observed to have a
Poisson probability distribution with
 = 10.
What is the probability that the RV X,
the number of particles reaching the
counter during 1 second is 3.0?
Poisson pmf
A machine produces sheet metal
where the RV X, the number of
flaws per yard follows a Poisson
distribution. The average number of
flaws per yard is 2.0. Plot the pmf
for RVX.
Poisson Approximation Example
Electrical resistors are packaged 200 to a
continuous feed ribbon. Historically, 1.5
percent of the resistors manufactured by
a machine are defective. Compute the
pmf of the number of defective
resistors on a ribbon and compare it to
the Poisson approximation.
(Stop at x = )
Poisson Process
Px(t) =
-
t
x
e (t)
x!
For time interval t with parameter = t.
Poisson Process Example
As system’s engineering manager, you have devised a
random system of police patrol so that an officer may
only visit a given location in his area with the Poisson
RV X = 0,1,2,3,… times per 1-hour period. The system
is arranged so that he visits each location on an average
of once per hour.
Calculate the probability that an officer will miss a
given location during a half-hour period.
What is the probability that an officer will visit once?
Twice? At least once?
Poisson pmf
In an industrial plant there is a dc power supply in
continuous use. The known failure rate is  = 0.40
per year & replacement supplies are delivered at 6
months intervals. If the probability of running
out of replacement power supplies is to be limited
to 0.01, how many replacement power supplies
should the operations engineer have on-hand at
the beginning of the 6-month interval?
Poisson Process
The number of hits on the ISE 261 Web site
from Noon to 12:30 PM on the day before a
Quiz follows a Poisson distribution. The
mean rate is 3 per minute. Find the
probability that there will be exactly 10 hits
in the next 5 minutes.
Let RV X be the number of hits in t
minutes, what is the pmf in terms of
t minutes?
Distribution Parameters
Binomial
Negative Binomial
Hypergeometic
Poisson
n&p
r&p
n, M, & N

Expected Values & Variances
pmf
E(X)
V(X)
Binomial:
np
np(1-p)
Negative Binomial: r(1-p) r(1-p)
p
p2
Hypergeometric: nM nM(N-M)(N-n)
2
N
N (N-1)
Poisson:

