Download as pdf or txt
Download as pdf or txt
You are on page 1of 45

C S

T I
T I S )
T A 14
S 30
N G C E
R I E C E T
E E 4& C R
I N 0 0 IS
N G 3 5 D Y
E NG L E ON ILIT ON
( E O D U M B TI
M BA U
M O
C RO RIB
P IST
D
OUTLINE
§ Common discrete probability distributions:
q Discrete Uniform Distribution
q Binomial Distribution
q Geometric Distributions
q Poisson Distribution
q Applications in Engineering
DISCRETE UNIFORM DISTRIBUTION
§ The simplest of all discrete probability distributions is one where the
random variable assumes each of its values with an equal probability.
§ And this probability is called Discrete Uniform Distribution.
§ If the random variable 𝑋 assumes the values 𝑥! , 𝑥" , … . , 𝑥# . with equal
probabilities, then the discrete uniform distribution is given by:
§ PMF:
!
𝑓 𝑥; 𝑛 = " , 𝑥 = 1, 2, 3,…, 𝑛

This notation tells that the uniform


distribution depend on the parameter 𝑛

§ Expectation:
q The mean, E(X) and variance, Var(X) of the discrete uniform distribution 𝑓(𝑥; 𝑛)
are given by:

𝑏+𝑎 𝜎 " = 𝑉𝑎𝑟 𝑋


𝜇 = 𝐸 𝑋 = ' 𝑥𝑓(𝑥) = (𝑏 − 𝑎 + 1)" −1
2 =
!
12
EXERCISE
Let random variable X has the discrete uniform
distribution. The pmf is given by

1
𝑓 𝑥 = 𝑓𝑜𝑟 𝑥 = 1, 2, 3, … , 𝑘
𝑘

Show that :
!"#
a) mean is 𝐸 𝑋 =
$

! "%#
b) variance is 𝜎$ =
#$
https://www.youtu
' # #%' $# be.com/watch?v=x
c) MGF is 𝑀& 𝑡 = OpqCysL5zg
! #%' #
SOLUTION
EXAMPLE
When a fair dice is tossed, each element of the sample
space 𝑆 = {1,2,3,4,5,6} occurs with probability 1/6 .
Therefore, we have a uniform distribution with
1
f ( x;6 ) = , x = 1, 2, 3, 4, 5, 6.
6
Find the mean and variance.
EXERCISE
Random variable X has a discrete uniform with
parameters: a=0, b=9
a. Calculate the mean and the variance.
b. Calculate the mean, the variance and standard
deviation for the random variable 5X.
SOLUTION
BINOMIAL PROBABILITY DISTRIBUTION
Notation: 𝑿~𝑩𝒊𝒏(𝒏, 𝒑)
§ 𝑿 represent the number of successes in 𝑛 Bernoulli trials
§ Suppose we repeat the Bernoulli experiment for 𝒏 trials, where each
trial is independent and 𝒑 is the probability of a success in each trial.
If 𝑋 denotes the number of success in these 𝑛 trials, then 𝑋 follows
the binomial distribution with parameters (𝒏, 𝒑) is given by:

𝑛 - ./-
𝑏 𝑥; 𝑛, 𝑝 = 𝑝 𝑞 , 𝑥 = 0,1,2, … , 𝑛
𝑥
the number of outcomes
How do you proof this? that contain 𝑥 success
and 𝑛 − 𝑥 failures within
𝑛 trials
𝜇 = 𝐸 𝑋 = 𝑛𝑝,
𝜎 , = 𝑉𝑎𝑟 𝑋 = 𝐸 𝑋 − 𝜇 ,
= 𝑛𝑝𝑞 𝑞 =1−𝑝
Binomial pmf Binomial cdf
EXAMPLE 5.1
The probability that a certain kind of component
will survive a shock test is ¾. Find the probability
that exactly 2 of the next 4 components tested
survive.
Solution:
Assuming that the tests are independent and 𝑝 =
¾ for each of the 4 tests, so
3
𝑋~𝐵𝑖𝑛(4, )
4
EXAMPLE 5.2
The probability that a patient recovers from a rare blood disease is 0.4. If 15 people
are known to have contracted this disease, what is the probability that
a) at least 10 survive,
b) from 3 to 8 survive, Refer Table A.1
c) exactly 5 survive, (

d) find the mean and the variance ' 𝑏(𝑥; 𝑛, 𝑝)


!#$
Solution:
Let 𝑋 be the number of people that survive. 𝑋~𝐵𝑖𝑛(15, 0.4).

a) 𝑃 𝑋 ≥ 10 = 1 − 𝑃 𝑋 < 10 = 1 − ∑%!#$ 𝑏 𝑥; 15,0.4 = 0.0338

b) 𝑃 3≤𝑋≤8 =
∑'!#& 𝑏 𝑥; 15,0.4 = ∑'!#$ 𝑏 𝑥, 15,0.4 − ∑"!#$ 𝑏(𝑥; 15,0.4)=0.8779

c) 𝑃 𝑋 = 5 = 𝑏 5; 15,0.4 = 0.1859

d) 𝜇 = 15 0.4 = 6 𝑎𝑛𝑑 𝜎 " = 15 0.4 0.6 = 3.6


EXAMPLE 5.3
A large chain retailer purchases a certain kind of electronic
device from a manufacturer. The manufacturer indicates
that the defective rate of the device is 3%:

a) The inspector of the retailer randomly picks 20 items


from a shipment. What is the probability that there will
be at least one defective item among there 20?

b) Suppose that the retailer receives 10 shipments in a


month and the inspector randomly tests 20 devices per
shipment. What is the probability that there will be 3
shipments containing at least one of defective device?
Solution:
a) Denote by 𝑋 the number of defective devices among the 20. This 𝑋
follows a 𝑏(𝑥; 20, 0.03) distribution. Hence;

b) In this case, each shipment can either contain at least one


defective items or not. Hence, testing the result of each shipment
can be viewed as a Bernoulli trial with 𝑝 = 0.4562 from part (a).
Assuming the independence from a shipment to shipment and
denoting by 𝑌 the number of shipments containing as least one
defective item 𝑌 follows another binomial distribution
𝑏(𝑦; 10, 0.4562). Therefore, the answer is:
APPLICATION OF BINOMIAL DISTRIBUTION
Some examples
§ A drug has probability 0.9 of curing a disease. It is administered to
100 patients, where the outcome for each patient is either cured or
not cured. If 𝑋 is the number of patients cured, then 𝑋 is a binomial
random variable with parameters (100, 0.9).

§ The National Institute of Mental Health estimates that there is a 20%


chance that an adult American suffers from, a psychiatric disorder.
Fifty adult Americans are randomly selected. If we let 𝑋 represent the
number who have a psychiatric disorder, then 𝑋 takes on values
according to the binomial distribution with parameters (50,0.2)

§ A manufacturer of computer chips finds that on the average 5% are


defective. To monitor the manufacturing process, they take a random
sample of size 75. If the sample contains more than five defective
chips, then the process is stopped. The binomial distribution with
parameters (75, 0.05) can be used to model the random variable 𝑋,
where 𝑋 represents the number of defective chips.
IMPORTANT NOTE FOR BINOMIAL
DISTRIBUTION
§ The binomial distribution is frequently used to model the
number of successes in a sample of size 𝒏 drawn with
replacement from a population of size 𝑵.

§ If the sampling is carried out without replacement, the draws


are not independent and so the resulting distribution is a
hypergeometric distribution, not a binomial one. However, for 𝑁
much larger than 𝑛 , the binomial distribution is a good
approximation, and widely used.

§ As a rule of thumb, if the population size is more than 20 times


the sample size (N > 20 n), then we may use binomial
probabilities in place of hypergeometric probabilities.

§ Example: https://onlinecourses.science.psu.edu/stat414/node/68

§ Example: https://onlinecourses.science.psu.edu/stat414/node/69
NORMAL APPROXIMATION TO BINOMIAL
§ According to Central Limit Theorem, as 𝑛 ⟶ ∞, and 𝑝
close to 0.5, the binomial can be approximated by the
normal distribution with mean 𝜇 = 𝑛𝑝 and standard
deviation 𝜎=𝑛𝑝𝑞
§ This approximation is good if 𝑛𝑝(1 − 𝑝) ≥ 10 and

https://www.geogebra.org/m/YJx90N9v
QUESTIONS
1. Suppose there is a 20% chance that an adult American suffers from a
psychiatric disorder. We randomly sample 25 adult Americans. What is the
probability that at most 3 of the selected people have such a disorder?
prob=binocdf(3,25,0.2) or Since the size of population is
large compared to the size of
prob2=sum(binopdf(0:3,25,0.2))
sample, then we can use Binomial
distribution

2. Prove that the mean and variance for Bernoulli is 𝑝 and 𝑝𝑞 respectively.
3. Prove that the mean and variance for Binomial is 𝑛𝑝 and 𝑛𝑝𝑞 respectively.
(Relate this with Bernoulli. Let the outcome on the 𝑗𝑡ℎ trial, 𝐼) )
4. Prove that the distribution function of geometric random variable is
𝑝 1 − 𝑝 !*+
SCILAB CODE EXAMPLE
Using Scilab we can plot binomial density function using
built in function binomial(p,n).
n=15;
p=0.4;
clf();
fx=binomial(p,n)
plot2d3(0:n,fx);
xlabel('x')
ylabel('f(x)')

%bar(0:n,fx,'green')
PLOT BINOMIAL DISTRIBUTION IN EXCEL
§ http://www.real-statistics.com/binomial-and-
related-distributions/binomial-distribution/
QUESTION
When sending messages over a network, there is a chance that the bits
will be corrupted. A Hamming code allows for a 4 bit code to be
encoded as 7 bits (adding three parity bits), with the advantage that if 0
or 1 bit(s) are corrupted, then the message can be perfectly
reconstructed. You are working on the Voyager space mission and the
probability of any bit being lost in space is 0.1. How does reliability
change when using a Hamming code?
GEOMETRIC DISTRIBUTIONS
Represent the probability of number of successive failures before a
success.
If repeated independent trials can result in a success with probability 𝑝
and a failure with probability 𝑞 = 1 − 𝑝, and the random variable 𝑋
represent the number of trials until the first success occurs, then 𝑿
follows a geometric distribution.

𝑔 𝑥; 𝑝 = 𝑝𝑞 -/B , 𝑥 = 1,2,3, … .
The mean and variance of a random variable following the geometric
distribution are

1 1−𝑝
𝐸 𝑋 =𝜇= , 𝑉𝑎𝑟 𝑋 = 𝜎Q = Q
𝑝 𝑝
https://onlinecourses.science.psu.edu/stat414/node/77
EXAMPLE 5.15
In a certain manufacturing process it is known that, on the
average, 1 in very 100 items is defective. What is the
probability that the fifth item inspected is the first defective
item found?

Solution:
Let 𝑋 be number of trials required to produce the first
defective. Using the geometric distribution with 𝑥 = 5 and
𝑝 = 0.01, we have

𝑔 5; 0.01 = 0.01 0.99 R = 0.0096


EXAMPLE 5.16
At "busy time" a telephone exchange is very near to capacity, so callers
have difficulty placing their calls It may be of interest to know the
number of attempts necessary in order to gain a connection. Suppose
that we let 𝑝 = 0.05 be the probability of a connection during busy
time. We are interested in knowing the probability that 5 attempts are
necessary for a successful call.

Solution:
Using the geometric distribution with 𝑎 = 5 and 𝑝 = 0.05 yields

𝑃 𝑋 = 𝑥 = 𝑔 5; 0.05 = 0.05 0.95 $ = 0.041

Quite often, in applications dealing with the geometric


distribution, the mean and variance are important. For
example, in the above example, the expected number of calls
necessary to make a connection is quite important.
QUESTION
POISSON DISTRIBUTION
Poisson Experiment
§ Experiments yielding numerical values of a random variable 𝑋, the
number of outcomes occurring during a given time interval or in a
specified region, are called Poisson experiments

§ The given time interval may be of any length, such as a minute, a day,
a week, a month, or even a year.
q the number of telephone calls per hour received by an office
q the number of days school is closed due to snow in winter season or the
number of postponed games due to rain during a baseball season
q the number of cars passing through in one minute
q the number of customers at an ATM in 10-minute intervals

§ The specified region could be a line segment, an area, a volume, or


perhaps a piece of material.
q The number of field mice per acre.
q The number of bacteria in a given culture.
q The number of typing errors per page
q the number of Alaskan salmon caught in a squid driftnet
CONT…
Poisson Process
Let the number of outcomes occurring in a given continuous interval be
counted. We have a Poisson process with parameter 𝜆 > 0 if the
following are satisfied:

1. The numbers of outcomes occurring in non overlapping intervals


(disjoint time intervals) are independent. (Has no memory)

2. The probability of exactly one change in a sufficiently short


interval of length of time ℎ is approximately 𝜆ℎ.

3. The probability of two or more outcomes in a sufficiently short


interval is essentially zero.

https://www.youtube.com/watch?v=jmqZG6roVqU
https://www.youtube.com/watch?v=sv_KXSiorFk
CONT…
Properties of Poisson Process

1. (No memory) The number of outcomes occurring in one


time interval or specified region is independent of the
number that occurs in any other disjoint time interval
or region of space.

2. The probability that a single outcome will occur during


a very short time interval or in a small region is
proportional to the length of the time interval or the
size of the region and does not depend on the number
of outcomes occurring outside this time interval or
region.

3. The probability that more than one outcome will occur


in such a short time interval or fall in such a small
region is negligible.
CONT…
The probability distribution of the Poisson random variable 𝑋,
representing the number of outcomes occurring in a given
time interval or specified region denoted by 𝑡, is
𝑒 %&' (𝜆𝑡)(
𝑝 𝑥; 𝜆𝑡 = 𝑃 𝑋 = 𝑥 = , 𝑥 = 0,1,2, … ,
𝑥!
where 𝜆 is the average number of outcomes per unit time,
distance, area, or volume, and e = 2.71828 · · ·

𝐸(𝑋) = 𝑉𝑎𝑟(𝑋) = 𝜆𝑡.

Table A.2 (refer last slide) contains Poisson probability sums


r
P(r ; lt ) = å p( x; lt )
x =0
for a few selected values of 𝜆𝑡 ranging from 0.1 to 18.
QUESTION
BINOMIAL APPROXIMATION TO POISSON
§ If n > 20 and np < 5 OR nq < 5 then the Poisson is a good approximation

https://www.geogebra.org/m/Rd947RzA
EXAMPLE 5.17
During a laboratory experiment the average
number of radioactive particles passing through a
counter in 1 millisecond is 4. What is the
probability that 6 particles enter the counter in a
given millisecond?

Solution:
Using the Poisson distribution with 𝑥 = 6 and 𝜆𝑡 = 4 and
Table A.2, we have
EXAMPLE 5.18
Ten is the average number of oil tankers arriving each day
at a certain port city. The facilities at the port can handle at
most 15 tankers per day. What is the probability that on a
given day tankers have to be turned away?

Solution:
Let 𝑋 be the number of tankers arriving each day. Then
using Table A.2, we have

Poisson distribution is used for quality control, quality


assurance, and acceptance sampling.

The mean and variance of the Poisson distribution are 𝝀𝒕


CONT…
Nature of Poisson Probability Function
The form of the distribution become more and
more symmetric as the mean grows large.

Poisson density functions for different means


EXAMPLE 5.19
In a certain industrial facility accidents occur infrequently. It is known
that the probability of an accident on any given day is 0.005 and
accidents are independent of each other.
(a) What is the probability that in any given period of 400 days there will
be an accident on one day?
(b) What is the probability that there are at most three days with an
accident?

Solution:
Let 𝑋 be a binomial random variable with n = 400 and p = 0.005. Thus
np = 2. Using the Poisson approximation,
EXAMPLE 5.20
In a manufacturing process where glass products are produced, defects
or bubbles occur, occasionally rendering the piece undesirable for
marketing. It is known that, on average, 1 in every 1000 of these items
produced has one or more bubbles. What is the probability that a
random sample of 8000 will yield fewer than 7 items possessing
bubbles?

Solution:
This is essentially a binomial experiment with 𝑛= 8000 and 𝑝= 0.001.
Since 𝑝 is very close to zero and n is quite large, we shall approximate
with the Poisson distribution using
𝜇 = (8000)(0.001) = 8

Hence, if 𝑋 represents the number of items producing bubbles, we have


APPLICATIONS IN ENGINEERING
Applications of Poisson distribution

Poisson distribution has several applications in civil engineering. In


earth quake engineering, in a specific time interval the probability of
occurrence of an earth quake at a particular fault follows Poisson
distribution. Occurrence of cyclones in a particular time period follows
Poisson distribution.

Example 1
From the past experience it is known that on an average every two
years 3 cyclones hit the coastal area of Andhra Pradesh and Orissa
states. If it is assumed that the cyclone hitting the coastal areas
follows Poisson distribution then what is the probability of two
cyclones crossing the coastal area of Andhra Pradesh and Orissa in the
next two years?

𝑒 *& 3"
𝑃 𝑥=2 = = 0.224
2
CONT…
Example 2

The most widely used situation is the arrival pattern of vehicles.


In this case m becomes the average number of vehicles per any
stated time interval. For this case we may write:

(𝜆𝑡)) 𝑒 %&'
𝑃 𝑟 =
𝑟!

𝜆 = the average vehicular arrival rate

Solution:
QUESTIONS

Suppose that accidents at a certain intersection occur in a manner that


satisfies the conditions for a Poisson process with a rate of 2 per week (𝜆 = 2).
What is the probability that at most 3 accidents will occur during the next
weeks?
prob=poisscdf(3,2*2)
SOME DISCRETE PROBABILITY
DISTRIBUTIONS

You might also like