4.2 Estimation of Absolute Performance
4.2 Estimation of Absolute Performance
Outline:
1. Type of Simulation w.r.t. Output Analysis
2. Stochastic Nature of Output Data
3. Absolute Measures
4. Output Analysis for Terminating Simulation
5. Output Analysis for Steady-State Simulation
1. Type of Simulation w.r.t. Output Analysis
3
1. Type of Simulation w.r.t. Output Analysis
4
1. Type of Simulation w.r.t. Output Analysis
5
1. Type of Simulation w.r.t. Output Analysis
6
1. Type of Simulation w.r.t. Output Analysis
Non-terminating simulation:
• Runs continuously, or at least over a very long period of time.
• Examples: assembly lines that shut down infrequently, telephone systems,
hospital emergency rooms.
• Initial conditions defined by the analyst.
• Runs for some analyst-specified period of time TE.
• Study the steady-state (long-run) properties of the system, properties that
are not influenced by the initial conditions of the model.
Whether a simulation is considered to be terminating or non-terminating
depends on both
• The objectives of the simulation study and
• The nature of the system.
7
2. Stochastic Nature of Output Data
Model output consist of one or more random variables because the model is an
input-output transformation and the input variables are r.v.’s.
M/G/1 queueing example:
• Poisson arrival rate = 0.1 per minute;
service time ~ N(= 9.5, =1.75).
• System performance: long-run mean queue length, LQ(t).
• Suppose we run a single simulation for a total of 5,000 minutes
– Divide the time interval [0, 5000) into 5 equal subintervals of 1000
minutes.
– Average number of customers in queue from time (j-1)1000 to j(1000) is
Yj .
8
2. Stochastic Nature of Output Data
9
3. Absolute Measures
10
3. Absolute Measures
Simulation output data are of the form {Y1,Y2,…,Yn} for estimating is referred to
as discrete-time data, because the index n is discrete valued
The simulation data of the form {Y(t), 0 t TE} is referred to as continuous-time
data with time-weighted mean because the index t is continuous valued.
Point estimation for discrete time data.
• The point estimator:
n
1
ˆ Yi
n i 1
– Is unbiased if its expected value is , that is if:
– Is biased if:
E (ˆ) Desired
E (ˆ)
11
3. Absolute Measures: Point Estimator
12
3. Absolute Measures : Point Estimator
Performance measure that does not fit this common framework is a “quantile” or
“percentile”
Pr{Y } p
• e.g., p=0.85; 85% of the customers will experience a delay of minutes are
less. Or a customer has only a 0.15 probability of experiencing a delay longer
than minutes.
• Estimating quantiles: the inverse of the problem of estimating a proportion or
probability. In estimating probability, a proportion is given and p is to be
estimated; but in estimating a quantile, p is given and is to be estimated.
• Consider a histogram of the observed values Y:
– Find such that 100p% of the histogram is to the left of (smaller than) .
ˆ
– e.g., if we observe n=250 customer delays, then an estimate of the 85th
percentileˆ of delay is a value such that (0.85)(250)=212.5 213 of the
observed values are less than or equal to ˆ
13
3. Absolute Measures: Confidence-Interval Estimation
14
3. Absolute Measures: Confidence-Interval Estimation
Suppose the model is the normal distribution with mean , variance 2 (both
unknown).
• Let Yi. be the average cycle time for parts produced on the ith
replication (representing a day of production) of the simulation.
– Therefore, its mathematical expectation is and let be the day-
to-day variation of the average cycle-time
• Suppose our goal is to estimate
• Average cycle time will vary from day to day, but over the long-run
the average of the averages will be close to .
• The natural estimator for is the overall sample mean of R
independent replications, R
, but it is not , is only estimate
.. Yi. Rof that error
• A confidence interval (CI) is aYmeasure
i 1
16
3. Absolute Measures: Confidence-Interval Estimation
17
3. Absolute Measures: Confidence-Interval Estimation
1
Y.. t / 2, R 1S 1
R
Example:
• Suppose that the overall average of the average cycle time on
120 replications of a manufacturing simulation is 5.80 hours,
with a sample standard deviation of 1.60 hours
• Since t0.025,119=1.98, a 95% confidence interval for the long-run
expected daily average cycle time is 5.801.98(1.60/120) or
5.800.29 hours.
– Our best guess for average cycle time is 5.80 hours, but there
could be as much as 0.29 hours error in that estimate
• On any particular day, we are 95% confident that the average
cycle time for all parts produced on that day will be
5.801.98(1.60)(1+1/120) = 5.803.18 hours!!
19
4. Output Analysis for Terminating Simulations
A terminating simulation: runs over a simulated time interval [0, TE] and results
in observations Y1, …, Yn
The sample size n may be a fixed number or a random variable.
A common goal is to estimate:
1 n
E Yi , for discrete output
n
i 1
1 TE
E Y (t )dt , for continuous output Y (t ),0 t TE
TE 0
In general, independent replications (R) are used, each run using a different
random number stream and independently chosen initial conditions.
20
4. Output Analysis for Terminating Simulations: Statistical
Background
21
4. Output Analysis for Terminating Simulations: Statistical
Background
Across Replication:
• For example: the daily cycle time Raverages (discrete time data)
1
– The average: Y..
R
Yi.
i 1
1 R
– The sample variance: S
2
i. ..
R 1 i 1
(Y Y ) 2
S
– The confidence-interval half-width: H t / 2, R 1
R
Within replication:
• For example: the WIP (a continuous time data)
1 TEi
– The average: Yi.
T Ei 0
Yi (t )dt
22
4. Output Analysis for Terminating Simulations: Statistical
Background
23
4. Output Analysis for Terminating Simulations: C.I. with
Specified Precision
Suppose that an error criterion is specified with probability 1 - , a sufficiently
large sample size should satisfy: P Y.. 1
(in other words, it is desired to estimate by ) Y..
24
4. Output Analysis for Terminating Simulations: C.I. with
Specified Precision
2
2
z0.025 S0 1.96 * 0.00518
12.14
• For the final sample size:
2
0.04 R must be
greater than
R 13 14 15 this #
t 0.025, R-1 2.18 2.16 2.14
t / 2,R1S 0 / 2 15.39 15.1 14.83
• R = 15 is the smallest integer satisfying the error criterion, so R - R0 = 11 additional
replications are needed.
• After obtaining additional outputs, half-width should be checked.
26
4. Output Analysis for Terminating Simulations: Quantiles
27
4. Output Analysis for Terminating Simulations: Quantiles
pˆ (1 pˆ )
pˆ z / 2
R 1
The sample proportion
28
4. Output Analysis for Terminating Simulations: Quantiles
The best way is to sort the outputs and use the (R*p)th smallest value, i.e., find
such that 100p% of the data in a histogram of Y is to the left of .
• Example: If we have R=10 replications and we want the p = 0.8 quantile,
first sort, then estimate by the (10)(0.8) = 8th smallest value (round if
necessary).
30
4. Output Analysis for Terminating Simulations: Quantiles
31
5. Output Analysis for Steady-State Simulation
32
5. Output Analysis for Steady-State Simulation: Initialization
Bias
33
5. Output Analysis for Steady-State Simulation:
Initialization Bias
34
5. Output Analysis for Steady-State Simulation: Initialization
Bias
R
• The preferred1 method to determine deletion point.
Y. j
R
Y
r 1
rj R replications
35
5. Output Analysis for Steady-State Simulation: Error Estimation
If {Y1, …, Yn} are not statistically independent, then S2/n is a biased estimator of
the true variance.
• Almost always the case when {Y1, …, Yn} is a sequence of output
observations from within a single replication (autocorrelated sequence,
time-series).
Suppose the point estimator is the sample mean
Y i 1Yi / n
n
36
5. Output Analysis for Steady-State Simulation: Error Estimation
k
• Lag-k autocorrelation is: k
2
38
5. Output Analysis for Steady-State Simulation: Error Estimation
S2 n / c 1
E BV (Y ), where B and V (Y ) is the variance of Y
n n 1
39
5. Output Analysis for Steady-State Simulation: Replication
Method
40
5. Output Analysis for Steady-State Simulation: Batch Means for
Interval Estimation
S 2
1
k
Y j Y 2 k
Y j2 kY 2
k
k
j 1
k 1
j 1
k (k 1)
If the batch size is sufficiently large, successive batch means will be
approximately independent, and the variance estimator will be
approximately unbiased.
No widely accepted and relatively simple method for choosing an acceptable
batch size m (see text for a suggested approach). Some simulation software
does it automatically.
42