Chapter 5
Chapter 5
Statistical Models in
Simulation
In this chapter:
Review several important probability distributions
Present some typical application of these models
2
Review of Terminology and Concepts
In this section, we will review the following
concepts:
Discreterandom variables
Continuous random variables
Cumulative distribution function
Expectation
3
Discrete Random Variables [Probability Review]
2. i 1
p ( xi ) 1
X 1 2 3 4 5 6
P(x) 1/21 2/21 3/21 4/21 5/21 6/21
5
Continuous Random Variables [Probability Review]
3. f ( x) 0, if x is not in RX
Properties x0
1. P( X x0 ) 0, because f ( x)dx 0
x0
7
Cumulative Distribution Function [Probability Review]
Cumulative Distribution Function (cdf) is denoted by F(x), where F(x)
= P(X <= x)
If X is discrete, then F ( x) p ( xi )
all
xi x
If X is continuous, then x
F ( x) f (t )dt
Properties of cdf
1. F is nondecreasing function. If a b, then F (a ) F (b)
2. lim x F ( x) 1
3. lim x F ( x) 0
8
Example 5.4
9
Cumulative Distribution Function[Probability Review]
The probability that the device lasts for less than 2 years:
P (0 X 2) F (2) F (0) F (2) 1 e 1 0.632
10
Expectation [Probability Review]
11
Expectations [Probability Review]
V (X ) 2
12
Useful Statistical Models
In this section, statistical models appropriate
to some application areas are presented.
The areas include:
Queuing systems
Inventory and supply-chain systems
Reliability and maintainability
Limited data
13
14
15
16
Other areas [Useful Models]
17
Discrete Distributions
Discrete random variables are used to
describe random phenomena in which only
integer values can occur.
In this section, we will learn about:
Bernoullitrials and Bernoulli distribution
Binomial distribution
Geometric and negative binomial distribution
Poisson distribution
18
Bernoulli Trials
and Bernoulli Distribution [Discrete Dist’n]
Bernoulli Trials:
Consider an experiment consisting of n trials, each can be a
success or a failure.
Let Xj = 1 if the jth experiment is a success
and Xj = 0 if the jth experiment is a failure
The Bernoulli distribution (one trial):
p, x j 1, j 1,2,..., n
p j ( x j ) p ( x j ) 1 p q, x j 0 ,j 1,2 ,...,n
0, otherwise
where E(Xj) = p and V(Xj) = p (1-p) = p q
Bernoulli process:
The n Bernoulli trials where trails are independent:
p(x1,x2,…, xn) = p1(x1) p2(x2) … pn(xn)
19
Binomial Distribution [Discrete Dist’n]
20
Geometric & Negative
Binomial Distribution [Discrete Dist’n]
Geometric distribution
The number of Bernoulli trials, X, to achieve the 1st success:
q x 1 p, x 0,1,2,..., n
p( x)
0, otherwise
E(x) = 1/p, and V(X) = q/p2
21
Poisson Distribution [Discrete Dist’n]
That expresses the probability of a given number of events occurring in a fixed interval of time or
space if these events occur with a known constant rate and independently of the time since the
last event.
An event can occur 0, 1, 2, … times in an interval. The average number of events in an interval is
designated λ (lambda). Lambda is the event rate, also called the rate parameter. The probability of
observing k events in an interval is given by the equation
x
e i
F ( x)
E(X) = = iV(X)
0 i!
22
Poisson Distribution [Discrete Dist’n]
23
Continuous Distributions
Continuous random variables can be used to
describe random phenomena in which the
variable can take on any value in some
interval.
In this section, the distributions studied are:
Uniform
Exponential
Normal
Weibull
Lognormal
24
Uniform Distribution [Continuous Dist’n]
Properties
P(x1 < X < x2) is proportional to the length of the interval
[F(x2) – F(x1) = (x2-x1)/(b-a)]
E(X) = (a+b)/2 V(X) = (b-a)2/12
U(0,1) provides the means to generate random
numbers, from which random variates can be
generated.
25
Exponential Distribution [Continuous Dist’n]
Memoryless property
For all s and t greater or equal to 0:
P(X > s+t | X > s) = P(X > t)
27
Normal Distribution [Continuous Dist’n]
Mean:
Variance: 2 0
Denoted as X ~ N(,2)
Special properties:
lim x f ( x) 0, and lim x f ( x) 0.
f(-x)=f(+x); the pdf is symmetric about .
The maximum value of the pdf occurs at x = ; the mean and
mode are equal.
28
Normal Distribution [Continuous Dist’n]
30
Weibull Distribution [Continuous Dist’n]
3 parameters:
Location parameter: ( )
Scale parameter:
Shape parameter.
Example: = 0 and = 1:
When = 1,
X ~ exp( = 1/)
31
Lognormal Distribution [Continuous Dist’n]
2
Mean E(X) = e + /2
2 2
Variance V(X) = e e - 1)
+ /2 (
33
Interarrival Times [Poisson Dist’n]
The 1st arrival occurs after time t iff there are no arrivals in the
interval [0,t], hence:
P{A1 > t} = P{N(t) = 0} = e-t
P{A1 <= t} = 1 – e-t [cdf of exp()]
Interarrival times, A1, A2, …, are exponentially distributed and
independent with mean 1/
Splitting:
Suppose each event of a Poisson process can be classified
as Type I, with probability p and Type II, with probability 1-p.
N(t) = N1(t) + N2(t), where N1(t) and N2(t) are both Poisson
processes with rates p and (1-p)
p N1(t) ~ Poi[p]
N(t) ~ Poi()
Pooling:
Suppose two Poisson processes are pooled together
N1(t) + N2(t) = N(t), where N(t) is a Poisson processes with
rates 1 + 2 N1(t) ~ Poi[ ] 1
N(t) ~ Poi(12)
N2(t) ~ Poi[] 2
35
Nonstationary Poisson
Process (NSPP) [Poisson Dist’n]
Poisson Process without the stationary increments, characterized by
(t), the arrival rate at time t.
The expected number of arrivals by time t, (t):
t
Λ(t) λ(s)ds
0
Relating stationary Poisson process n(t) with rate and NSPP N(t)
with rate (t):
Let arrival times of a stationary process with rate = 1 be t1, t2, …,
and arrival times of a NSPP with rate (t) be T1, T2, …, we know:
ti = (Ti)
Ti = (ti)
36
Nonstationary Poisson
Process (NSPP) [Poisson Dist’n]
Example: Suppose arrivals to a Post Office have rates 2 per minute
from 8 am until 12 pm, and then 0.5 per minute until 4 pm.
Let t = 0 correspond to 8 am, NSPP N(t) has rate function:
2, 0 t 4
(t )
0.5, 4 t 8
Expected number of arrivals by time t:
2t , 0 t 4
(t ) 4 t t
0 2 ds 4 0 . 5 ds
2
6, 4 t 8
37
Empirical Distributions [Poisson Dist’n]
38
Summary
The world that the simulation analyst sees is probabilistic,
not deterministic.
In this chapter:
Reviewed several important probability distributions.
Showed applications of the probability distributions in a simulation
context.
Important task in simulation modeling is the collection and
analysis of input data, e.g., hypothesize a distributional
form for the input data. Reader should know:
Difference between discrete, continuous, and empirical
distributions.
Poisson process and its properties.
39