Probability Distributions
Lukmanul Hakim
Jurusan Teknik Elektro Universitas Lampung
Probability Distribution
• Random Variable
• The Binomial Distribution
• The Hypergeometric Distribution
• The Mean and the Variance of a Probability Distribution
• Chebyshev’s Theorem
• The Poisson Approximation to the Binomial Distribution
• Poisson Processes
• The Geometric Distribution
• The Multinomial Distribution
• Simulation
Random Variables
• May be thought of as a function defined over the elements of the sample space
• Discrete Random Variables
• Continuous Random Variables
f(x) = 1/6 , for x=1,2,3,4,5,6 → the probability
distribution for the number of points we roll
with a balanced die.
Random Variables
Example
Check whether the following can serve as probability distributions:
(a) f(x) = [(x-2)/2], for x=1,2,3,4 (b) h(x) = (x
2/25), for x=0,1,2,3,4
Solution
a. This function cannot serve as a probability distribution because f(1) is negative
b. This function cannot serve as a probability distribution
because the sum of the five probabilities is (6/5) and
not 1
The Binomial Distribution (1)
• Repeated trials
• Probability of getting x successes in n trials or in other words, x successes and n – x failures in n attempts
• Binomial distribution applies to a sample with replacement problem, namely, if each unit
selected for the sample is replaced before the next one is drawn
( ) n p ( p ) x n
p x n x
b ; , =
x1 −
n−xfor = 0 , 1 , 2 ,...,
The Binomial Distribution (2)
Assumptions:
1. There are only two possible outcomes for each trial
2. The probability of a success is the same for each trial
3. There are n trials, where n is a constant 4. The n trials are independent
Trials satisfying this assumptions are referred to as
Bernoulli trials.
7
Solution:
a. Substituting x=4, n=5, and p=0.60
The Binomial Distribution (3)
( ) 5 ( 0 . 60 ) ( 1 0 . 60 ) 0 . 259
60 4 . 0 , 5
;
4
4−
5 4=
=
−b
Example 1:
It has been claimed that in 60 % of all solar heat installations the utility bill is reduced by at least one-third. Accordingly, what are the probabilities that the utility bill will be reduced by at least one-third in:
a. Four of five installations
b. At least four of five installations
b. Substituting x=5, n=5, and p=0.60
( )
5(
0.60) (
1 0.60)
0.07860 5 . 0 , 5
;
5 = 5 − 5−5 = b
(
4;5,0.60) (
+b 5;5,0.60)
= 0.259+0.078 = 0.337b
The answer is 0.337
The Binomial Distribution (4)
( x n p ) ( B x n p ) ( B x n p )
b ; , = ; , − − 1 ; ,
If n is large then calculation can be very tedious.
Table 1 at the end of the book provide solution through cumulative probabilities rather than the values of b(x;n,p)
( x n p ) b ( k n p ) x n
B
x
k
,..., 2
, 1 , 0 for
,
; ,
;
0
=
=
=
The Binomial Distribution (5)
Solution:
a. Table 1 shows that B(2;16,0.05)=0.9571 b. Since
( ) ( )
=−
16
=
4
05 . 0 , 16
; 3 1
05 . 0 , 16
;
x
B x
b
Table 1 yields 1 – 0.9930 = 0.0070 Example 2:
If the probability is 0.05 that a certain wide-flange column will fail under a given axial load, what are the probabilities that among 16 such columns
a. At most two will fail;
b. At least four will fail?
Solution:
Using the relationship to cumulative probabilities and then looking up these probabilities in Table 1, we get
The Binomial Distribution (6)
Example 3:
If the probability is 0.20 that any one person will dislike the taste of a new toothpaste, what is the probability that 5 of 18 randomly selected persons will dislike it?
( ) ( ) ( )
( )
( 5 5 ; ; 18 18 , , 0 0 . . 20 20 ) 0 0 . . 1507 8671 0 . 7164
20 . 0 , 18
; 4 20
. 0 , 18
; 5 20
. 0 , 18
; 5
=
−
=
−
= b
b
B B
b
The Binomial Distribution (7)
Example 4:
A washing machine manufacturer claims that only 10% of his
machines require repairs within the warranty period of 12 months. If 5 of 20 of his machines required repairs within the first year, does this tend to support or refute the claim?
Solution:
Let us first find the probability that five or more 20 of the washing machines will require repairs within a year when the probability that any one will require repairs within a year is 0.10. Using Table 1, we get
( ) ( )
0432 .
0
9568 .
0 1
10 . 0 , 20
; 4 1
10 . 0 , 20
;
20
5
=
−
=
−
== x
B x
b Since this value is very small, it
would seem reasonable to reject the washing machine manufacturer’s claim
The Hypergeometric Distribution (1)
◼ Suppose that we are interested in the number of defectives in a sample of n units drawn from a lot containing N units, of which a are defective.
If the sample is drawn in such a way that at each successive drawing whatever units are left in the lot have the same chance of being
selected, the probability that the first drawing will yield a defective unit is (a/N), but for the second drawing it is (a-1)/(N-1) or a/(N-1),
depending on whether or not the first unit drawn was defective. Thus, the trials are not independent, the fourth assumption underlying the binomial distribution is not met, and the binomial distribution does not apply.
◼ Hypergeometric Distribution applies to the sampling without replacement problem
( ) ( )( )
( ) x n
N a n x
h
Nn a N
x n a
x
for 0 , 1 ,..., ,
,
; =
−−=
The Hypergeometric Distribution (2)
Example:
A shipment of 20 tape recorders contains 5 that are defective. If 10 of them are randomly chosen for inspection, what is the probability that 2 of the 10 will be defective?
Solution:
Substituting x=2, n=10, a=5, and N=20 into the formula for the hypergeometric distribution, we get
( ) ( )( )
( ) 10 184 6 , , 756 435 0 . 348
20 ,
5 , 10
;
2
2010 15
8 5
2
= =
=
h
14
The Hypergeometric Distribution (3)
Example:
Repeat the preceding example for a lot of 100 tape recorders, of which 25 are defective, by using
a. The formula for the hypergeometric distribution;
b. The formula for the binomial distribution as an approximation.
Solution:
a. Substituting x=2, n=10, a=25, and N=100 into the formula for the hypergeometric distribution, we get
( ) ( )( )
( )
0.292100 , 25 , 10
;
2 100
10 75 8 25
2 =
= h
b. Substituting x=2, n=10, p=25/100 into the formula for the binomial distribution, we get
( )
10(
0.25) (
1 0.25)
0.28225 2 . 0 , 10
;
2 2 − 10 2 =
= −
b
15
The Mean and The Variance of A Probability Distribution (1)
0 1 2 3 4 5
x
1/32 5/32 10/32
b(x;5,0.50)
Symmetrical Binomial Distribution
0 1 2 3 4 5
x 0.1
b(x;5,0.20)
0.2 0.3 0.4 0.5
Positively Skewed Binomial Distribution
0 1 2 3 4 5
x 0.1
b(x;5,0.80)
0.2 0.3 0.4 0.5
Negatively Skewed Binomial Distribution
The Mean and The Variance of A Probability Distribution (2)
General Characteristics of Probability Distribution:
1. Symmetry and Skewness as shown in the previous slide 2. Mean of Probability Distribution
It is simply the mathematical expectation of a corresponding random variable →
3. Variance of Probability Distribution
Indication of spread or dispersion of a probability distribution
( )
+ ( )
+ ( )
+ + ( )
=
( )
x all k
k f x x f x
x x
f x x
f x x
f
x1 1 2 2 3 3
Example:
Find the mean of the probability distribution of the number of heads obtained in three flips of a balanced coin.
The Mean and The Variance of A Probability Distribution (3)
( )
=
x all
x f
x
Mean of Discrete Probability Distribution:
Mean of a Probability Distribution measures its center in the sense of an average.
Solution:
The probabilities for 0,1,2, or 3 heads are (1/8), (3/8), (3/8), and (1/8), as can easily be verified by counting equally likely
possibilities or by using the formula for the binomial distribution with n=3 and p=(1/2), thus
2 3 8
3 1 8
2 3 8
1 3 8
0 1 + + + =
=
18
The Mean and The Variance of A Probability Distribution (4)
Mean of Binomial Distribution:
Mean of Hypergeometric Distribution:
p n
=
N n a
=
Example:
With reference to the example on page 97, where 5 of 20 tape recorders were defective, find the mean of the probability
distribution of the number of defectives in a sample of 10 randomly chosen for inspection.
Solution:
n=10, a=5, and N=20 into the above formula, we get
5 . 20 2
10 5 =
=
The Mean and The Variance of A Probability Distribution (5)
Variance of Probability Distribution:
Variance of Binomial Distribution:
Variance of Hypergeometric Distribution:
( ) ( )
−
=
x all
x f
x
22
( p )
p
n −
= 1
2( ) ( ) ( 1 )
2 2
−
−
−
=
N N
n N
a N
a
n
20
The Mean and The Variance of A Probability Distribution (6)
Example:
For binomial distribution, n=16 and p=(1/2), find the standard deviation.
2 4
2 4 1 1 2
16 1
2
=
=
=
−
=
Example:
For hypergeometric distribution, n=10, a=5 and N=20, find the standard deviation.
( ) ( )
99 . 76 0
75
76 75 19
20
10 20
5 20 5
10
2 2
=
=
=
−
−
=
Chebyshev’s Theorem (1)
Theorem 4.2. If a probability distribution has mean μ and a standard deviation σ, the probability of getting a value which deviates from μ by at least kσ is at most (1/k2).
( ) 1
2k k x
P −
Example:
The number of customers who visit a car dealer’s showroom on a Saturday morning is a random variable with μ = 18 and σ=2.5. With what probability can we assert that there will be between 8 and 28 customers?
5 4 . 2
8 18 5
. 2
18
28 − =
− =
k = ( )
16 15 4
1 1 5
. 2 4
18 = −
2=
−
x
P
Chebyshev’s Theorem (2)
Example:
Show that for 40,000 flips of a balanced coin, the probability is at least 0.99 that the proportion of heads will fall between 0.475 and 0.525.
10 99
. 1 0
1
2 100 1 2 000 1 ,
40
; 000 ,
2 20 000 1
, 40
2
= =
−
=
=
=
=
k yields k
Chebyshev’s theorem tells us that the probability is at least 0.99 that we will get between 20,000 – 10(100) = 19,000 and 20,000 +
10(100) = 21,000 heads. Hence, the probability is at least 0.99 that the proportion of heads will fall between (19,000/40,000)=0.475 and (21,000/40,000)=0.525
The Poisson Approximation to the Binomial Distribution (1)
When n is large and p is small, binomial probabilities are often
approximated by means of the formula (POISSION DISTRIBUTION)
( ) x n p
x x e
f
x
= =
=
−
for 0 , 1 , 2 ,... and
; !
Modification of third axiom of probability:
Axiom 3’. If A1, A2, A3,… is a finite or infinite sequence of mutually exclusive events in S, then
( A
1 A
2 A
3 ... ) ( ) ( ) ( ) = P A
1+ P A
2+ P A
3+ ...
P
Solution:
a. Binomial Distribution
b. Poisson Approximation to Binomial Distribution
The Poisson Approximation to the Binomial Distribution (2)
Example:
It is known that 5% of the books bound at a certain bindery have defective bindings. Find the probability that 2 of 100 books bound by this bindery will have defective bindings using:
a. Binomial Distribution
b. Poisson Approximation to Binomial Distribution
( 2 ; 100 , 0 . 05 ) = ( )
1002( 0 . 05 ) (
20 . 95 )
98= 0 . 081 b
( ) 0 . 084 where 100 0 . 05
! 2 5 5
; 2
5
2
= = =
= e
−n p
f
The Poisson Approximation to the Binomial Distribution (3)
Example:
A fire insurance company has 3,840 policyholders. If the probability is (1/1,200) that any one of the policyholders will file at least one claim in any given year, find the probabilities that 0,1,2,3,4,…, 10 of the policyholders will file at least one claim in a given year.
Solution:
2 . 200 3
, 1 840 1 ,
3 =
=
Consult Table 2 and the identity:
( ) x ; = F ( ) ( x ; − F x − 1 ; )
f
The Poisson Approximation to the Binomial Distribution (4)
0.041
0.130
0.209
0.223
0.178
0.114
0.060
0.028
0.011 0.004 0.002
0 1 2 3 4 5 6 7 8 9 10
Mean and Variance of Poisson Distribution:
This histogram shows number of policyholders filing at least one claim using Poisson
Distribution with λ = 3.2
= and
2=
The Geometric Distribution (1)
( ) ( x ; p = p 1 − p )
−1x = 1 , 2 , 3 , 4 ,...
g
xfor
The first success is to come on the xth trial, it has to be preceded by (x – 1) failures, and if the probability of a success is p, the
probability of (x – 1) failures on (x – 1) trials is (1 – p)x – 1. Then, if we multiply this expression by the probability p of a success on the xth trial, we find that the probability of getting the first success on the xth trial is given by
→ Geometric Distribution
p
= 1
→ Mean of Geometric DistributionGeometric Distribution has important applications in queueuing theory in connection with the number of units that are being served or are waiting to be served.
The Geometric Distribution (2)
Example:
If the probability is 0.20 that a burglar will get caught on any given job, what is the probability of being caught for the first time on the fourth job?
Solution:
Substituting x=4 and p=0.20 into the formula for the geometric distribution, we get
g(4; 0.20) = (0.20)(1 – 0.20)
(4 – 1)g(4; 0.20) = 0.102
The Geometric Distribution (3)
Example:
If the probability is 0.05 that a certain kind of measuring device will show excessive drift, what is the probability that the sixth of the measuring devices tested will be the first to show excessive drift?
Solution:
Substituting x=6 and p=0.05 into the formula for the geometric distribution, we get
g(6; 0.05) = (0.05)(1 – 0.05)
(6 – 1)g(6; 0.05) = 0.039
The Multinomial Distribution (1)
An immediate generalization of the binomial distribution arises when each trial can have more than two possible outcomes. This happens, for example, when a manufactured product is classified as superior, average, or poor, when a student performance is
graded as an A, B, C, D, or F, or when a experiment is judged successful, unsuccessful, or inconclusive. Here, we treat these in general, by considering the case where there are n independent trials, with each trial permitting k mutually exclusive outcomes whose respective probabilities are p1, p2, …, pk where total summation of probabilities is 1.
( )
x x kxkk
k
p p p
x x
x x n
x x
f =
11
22
2 1 2
1
! !... !
,..., !
,
The Multinomial Distribution (2)
Example:
The probabilities that the light bulb of a certain kind of slide projector will last fewer than 40 hours of continuous use,
anywhere from 40 to 80 hours of continuous use, or more than 80 hours of continuous use, are 0.30, 0.50, and 0.20. Find the probability that among eight such bulbs two will last fewer than 40 hours, five will last anywhere from 40 to 80 hours, and one will last more than 80 hours.
( ) ( ) ( ) ( )
( 2 , 5 , 1 ) 0 . 0945
20 . 0 50
. 0 30
.
! 0 1
! 5
! 2
! 1 8
, 5 ,
2
2 5 1=
= f
f
Simulation (1)
• Simulation techniques have been applied to sciences
• Simulation process involves an element of chance → MONTE CARLO METHOD
• Monte Carlo simulation eliminates the cost of building and operating expensive equipment → study of collisions of photons with electrons
• Useful in situations where direct experiment is
impossible → study of the spread of cholera
epidemics
Simulation (2)
Classical example is determination of π in the early eighteenth century by George de Buffon proved
that if a very fine needle of length a is thrown at
random on a board with equidistant parallel lines,
the probability that the needle will intersect one of
the lines is 2a/πb, where b is the distance between
parallel lines and hence, an estimate of π is known.
Simulation (3)
Example:
Suppose that the probabilities are 0.082, 0.205, 0.256, 0.214,
0.134, 0.067, 0.028, 0.010, 0.003, and 0.001 that 0, 1, 2, 3, …, or 9 cars will arrive at a toll booth of a turnpike during any one-
minute interval in the early afternoon.
a. Distribute the three-digit random numbers from 000 to 999
among the 10 values of this random variable, so that they can be used to simulate the arrival of cars at the toll booth.
b. Use the 5th, 6th, and 7th columns of the fourth page of Table 7, starting with the 11th row and going down the page, to simulate the arrival of cars at the toll booth during 20 one-minute intervals in the early afternoon.
35
Simulation (4)
Solution:
a. Calculating the cumulative probabilities and following the suggestion given above, we arrive at the following scheme:
Number of Cars Probability Cumulative Probability Random Numbers
0 0.082 0.082 000 – 081
1 0.205 0.287 082 – 286
2 0.256 0.543 287 – 542
3 0.214 0.757 543 – 756
4 0.134 0.891 757 – 890
5 0.067 0.958 891 – 957
6 0.028 0.986 958 – 985
7 0.010 0.996 986 – 995
8 0.003 0.999 996 – 998
9 0.001 1.000 999
Simulation (5)
b. Following the instructions, we get the random
numbers 036, 417, 962, 458, 778, 541, 869, 379, 973,
553, 325, 674, 907, 710, 709, 499, 384, 346 and 301,
and this means that 0, 2, 6, 2, 4, 2, 4, 2, 6, 3, 2, 3, 5,
3, 3, 2, 2, 2, 2, and 2 cars arrived at toll booth during