---
title: "Simulation run statistics"
subject: "Simulation and Modeling"
chapter: 8
key: "semester_8/simulation_and_modeling:simulation-run-statistics"
source: https://www.bctengineer.com/q/semester_8/simulation_and_modeling/simulation-run-statistics
site: BCT Engineering
---

# Simulation run statistics

Simulation and Modeling · Chapter 8: Analysis of simulation output

- Asked in: 2074 Bhadra, 6 marks; 2073 Bhadra, 5 marks (asked 2 times)
- Answer checked by Claude Opus 5.5 (high effort) on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_8/simulation_and_modeling/simulation-run-statistics
- Whole chapter: https://www.bctengineer.com/md/semester_8/simulation_and_modeling/chapter-8

## Question

Explain how you can analyze simulation output using simulation run statistics, with example.

## Short answer

Run statistics estimate performance measures from a single simulation run. Observation-based (tally) statistics like mean delay are computed from discrete data; time-persistent statistics like average queue length use time-weighted area/duration. Counts, rates, and extremes are also computed. Example: mean delay 2.0 min from five customer waits.

## Answer

Simulation output is random, so a run produces a set of observations from which **run statistics** are computed to estimate the system's performance measures. The statistics are calculated over the whole run (or over a chosen time period T), and a single run of length T gives one estimate for each measure.

#### Types of run statistics
1. **Observation-based (tally) statistics**: computed from a list of discrete observations, such as the delay of each customer. Mean = (sum of x_i) / n and variance S² = sum(x_i - mean)² / (n - 1).
2. **Time-persistent statistics**: computed for variables that hold a value for a duration, such as queue length or server status. The time-weighted average is the area under the curve divided by run length T:  Q̄ = (1/T) · ∫ Q(t) dt = Σ (Q_i · duration_i) / T.
3. **Counts and rates**: number served, throughput = number completed / T, number lost or balked.
4. **Extremes**: maximum queue length, maximum waiting time.

#### Procedure
1. Decide the measures and the run length (or terminating event).
2. Collect data during the run, usually updating running sums at each event.
3. At the end, compute the statistics, and, from several runs, form confidence intervals.

#### Example: single-server queue, T = 10 min
Queue length: 0 for 0-2 min, 1 for 2-5 min, 2 for 5-6 min, 1 for 6-10 min. The server is idle for 0-2 min.

- Average queue length = (0·2 + 1·3 + 2·1 + 1·4) / 10 = 9/10 = **0.9**.
- Utilization = busy time / T = 8/10 = **0.8**.

Five customers wait 0, 2, 3, 1, 4 min.
- Mean delay = 10/5 = **2.0 min**.
- S² = (4 + 0 + 1 + 1 + 4)/4 = 2.5, so S = 1.58 min.
- Maximum delay = 4 min.

These are estimates from one run; another random stream gives other values, so the statistics from independent runs are used for confidence intervals.

## Check yourself

The answer's key points as multiple-choice questions, with the correct option and why.

1. How is a time-persistent statistic such as average queue length computed?
   A. Sum of observations divided by n
   B. Maximum value in the run
   C. Area under the curve divided by run length T
   D. Number completed divided by T
   Answer: C. Time-weighted average = sum(Q_i x duration_i)/T. (Key point: Time-persistent statistics)

2. Which statistic is observation-based (tally)?
   A. Server utilization
   B. Mean delay of customers computed from each customer's delay
   C. Average queue length
   D. Throughput
   Answer: B. Tally statistics come from a list of discrete observations such as customer delays. (Key point: Tally statistics)

3. In the T = 10 example, queue length is 0 for 2 min, 1 for 3 min, 2 for 1 min, 1 for 4 min. What is the average queue length?
   A. 0.9
   B. 0.8
   C. 1.0
   D. 2.0
   Answer: A. (0x2 + 1x3 + 2x1 + 1x4)/10 = 9/10 = 0.9. (Key point: Example calculation)

4. For delays 0, 2, 3, 1, 4 (mean 2.0), what is the sample variance S^2?
   A. 2.0
   B. 3.0
   C. 1.58
   D. 2.5
   Answer: D. Sum of squared deviations is 10, divided by n-1 = 4 gives 2.5. (Key point: Sample variance)

## Related in Simulation and Modeling

- [Estimation methods in output analysis](https://www.bctengineer.com/question.md?key=semester_8%2Fsimulation_and_modeling%3Aestimation-methods-output) — Simulation and Modeling, chapter 8, asked 2×
- [Types of output analysis; infinite population](https://www.bctengineer.com/question.md?key=semester_8%2Fsimulation_and_modeling%3Aoutput-analysis-types-infinite) — Simulation and Modeling, chapter 8

## Related in other subjects

- [GIC simulation of HPF at ωo = 4000 rad/s](https://www.bctengineer.com/question.md?key=semester_5%2Ffilter_design%3Agic-hpf-4000-simulation) — Filter Design, chapter 8
- [GIC simulation of HPF with Kf = 2000](https://www.bctengineer.com/question.md?key=semester_5%2Ffilter_design%3Agic-hpf-kf-2000-simulation) — Filter Design, chapter 8, asked 2×
- [Petrol pump queue simulation](https://www.bctengineer.com/question.md?key=semester_4%2Fdata_structure_and_algorithm%3Apetrol-pump-simulation) — Data Structure and Algorithm, chapter 2
- [Leapfrog simulation of given ladder at 6 kHz](https://www.bctengineer.com/question.md?key=semester_5%2Ffilter_design%3Aleapfrog-ladder-6khz) — Filter Design, chapter 8
