What Is Monte Carlo Simulation and How Does It Help You Manage Uncertainty?
Monte Carlo simulation is a computational technique that uses repeated random sampling to model the behavior of systems affected by uncertainty. Developed by physicists Stanislaw Ulam and Nicholas Metropolis in 1949 (during the Manhattan Project), it is now a cornerstone of risk analysis and measurement uncertainty evaluation. The method is formally endorsed in the ISO/IEC Guide 98-3:2008 Supplement 1 for propagating probability distributions through measurement models — making it a standard alternative to traditional uncertainty calculations.
What It Is
At its core, Monte Carlo simulation treats each uncertain input in your model not as a single fixed number, but as a probability distribution that reflects your knowledge (or lack of it) about that input. Instead of solving equations analytically, the simulation runs the model thousands or millions of times, each time drawing a random value for every input from its assigned distribution. The collection of output results forms a histogram — an empirical probability distribution of the possible outcomes.
This approach is powerful because it handles:
How It Works: Steps and Formula
The procedure follows a clear, repeatable sequence:
The underlying principle is the Law of Large Numbers: as the number of trials increases, the simulated output distribution converges to the true distribution of Y.
A Worked Illustrative Example
Example data (illustrative only) — Suppose you measure the volume of a cylinder using:
The model is: V = π × (d/2)² × h
Analytical approach (simplified): Using the GUM method, you would calculate partial derivatives and combine uncertainties. But the model is nonlinear in d, so the result is approximate.
Monte Carlo approach:
Result (illustrative): Mean V ≈ 1570.8 mm³, standard deviation ≈ 31.6 mm³, and the 95% coverage interval ≈ [1509, 1633] mm³. The histogram would reveal slight skewness — something the analytical method would miss.
Common Pitfalls
Closing
Monte Carlo simulation turns "I'm not sure" into "here is the probability of each outcome." Whether you are assessing measurement uncertainty per ISO/IEC 98-3 Supplement 1 or evaluating process risk, this method gives you defensible, visual results. To start simulating without writing code, try the free Monte Carlo tool at https://www.6sq.com/tools/montecarlo/ — just define your model and distributions, and let the random sampling do the work.
What It Is
At its core, Monte Carlo simulation treats each uncertain input in your model not as a single fixed number, but as a probability distribution that reflects your knowledge (or lack of it) about that input. Instead of solving equations analytically, the simulation runs the model thousands or millions of times, each time drawing a random value for every input from its assigned distribution. The collection of output results forms a histogram — an empirical probability distribution of the possible outcomes.
This approach is powerful because it handles:
- Nonlinear models where analytical error propagation fails
- Non-normal input distributions (e.g., triangular, uniform, lognormal)
- Correlations between input variables
- Complex systems with many interacting uncertainties
How It Works: Steps and Formula
The procedure follows a clear, repeatable sequence:
- Define the model: Write the mathematical relationship between inputs (X₁, X₂, …, Xₙ) and the output Y = f(X₁, X₂, …, Xₙ).
- Assign probability distributions to each input based on available data, expert judgment, or standard assumptions (e.g., normal for repeated measurements, rectangular for resolution limits).
- Generate random samples — draw one value for each input from its distribution. This is the "random sampling" step.
- Compute the output Y for that set of inputs.
- Repeat steps 3–4 many times (typically 10,000 to 1,000,000 iterations).
- Analyze the results: Build a histogram of all Y values, then calculate statistics such as the mean, standard deviation, and percentiles (e.g., the 2.5th and 97.5th percentiles give the 95% coverage interval).
The underlying principle is the Law of Large Numbers: as the number of trials increases, the simulated output distribution converges to the true distribution of Y.
A Worked Illustrative Example
Example data (illustrative only) — Suppose you measure the volume of a cylinder using:
- Diameter d = 10.0 mm, with standard uncertainty u(d) = 0.1 mm (normal distribution)
- Height h = 20.0 mm, with standard uncertainty u(h) = 0.2 mm (normal distribution)
The model is: V = π × (d/2)² × h
Analytical approach (simplified): Using the GUM method, you would calculate partial derivatives and combine uncertainties. But the model is nonlinear in d, so the result is approximate.
Monte Carlo approach:
- Assign d ~ Normal(10.0, 0.1²) and h ~ Normal(20.0, 0.2²).
- Run 100,000 iterations. In each iteration, draw a random d and h, compute V.
- The output histogram shows the distribution of V.
Result (illustrative): Mean V ≈ 1570.8 mm³, standard deviation ≈ 31.6 mm³, and the 95% coverage interval ≈ [1509, 1633] mm³. The histogram would reveal slight skewness — something the analytical method would miss.
Common Pitfalls
- Too few iterations: Using fewer than 10,000 runs can produce unstable percentiles. Increase runs until results stabilize.
- Ignoring correlations: If inputs are correlated (e.g., temperature affects both length and density), the simulation must model that joint distribution — otherwise results are misleading.
- Wrong distribution choice: A normal distribution for a strictly positive quantity (like mass or time) can generate negative samples. Use lognormal or truncated distributions instead.
- Confusing standard deviation with coverage interval: Report percentiles, not just σ, for a full picture of risk.
Closing
Monte Carlo simulation turns "I'm not sure" into "here is the probability of each outcome." Whether you are assessing measurement uncertainty per ISO/IEC 98-3 Supplement 1 or evaluating process risk, this method gives you defensible, visual results. To start simulating without writing code, try the free Monte Carlo tool at https://www.6sq.com/tools/montecarlo/ — just define your model and distributions, and let the random sampling do the work.
No related results found
Invited:
6SQ Tools
0 replies