AI Glossary / Graphs and symbolic AI / Beginner
Monte Carlo
Definition
Monte Carlo refers to a family of computational methods that use random sampling to estimate quantities or study the behavior of a model. Instead of examining every possibility exactly, the method samples possibilities according to a specified procedure and summarizes the results. Its estimates contain sampling uncertainty as well as any errors in the underlying model.
What it means
A question may be easy to describe but difficult to calculate exactly: for example, how often a queue exceeds capacity when arrivals and service durations both vary. Monte Carlo can generate many model-based runs and count how often the event occurs.
Randomness is a computational tool, not a substitute for defining the problem. The sampling distribution, simulator, and summary statistic determine what is being estimated. A large collection of plausible-looking scenarios is not automatically a Monte Carlo estimate of a meaningful probability unless the scenarios are sampled and weighted appropriately.
How it works
In simple Monte Carlo estimation, express the desired quantity as an expectation, generate independent draws from the relevant distribution, compute the quantity for each draw, and average. For an event probability, record one when the event occurs and zero otherwise; the average is the estimated probability.
For independent, identically distributed observations with finite variance, the standard error of a sample mean scales with one over the square root of the sample count. Reducing that error by half therefore generally requires about four times as many draws. Correlated sampling, rare events, heavy tails, and specialized estimators need more careful analysis.
Three practical examples
- An operations analyst can estimate the chance that simulated daily workload exceeds available capacity under a specified demand model.
- A computer-graphics system can sample light paths to estimate image intensities when exact integration is impractical.
- An AI researcher can estimate a policy's expected return by evaluating it across sampled episodes in a controlled simulator.
Think of it this way
Think of tasting well-mixed samples to learn about a much larger batch. More representative samples improve the estimate, but they cannot tell you about ingredients excluded from the batch in the first place. The analogy is limited because Monte Carlo samples often come from a mathematical model, and their representativeness must be established by the sampling procedure rather than assumed.
Worked example
Suppose a hypothetical queue simulator produces 1,000 independent model-based days. On 120 days, the queue exceeds a chosen capacity threshold. The estimated exceedance probability is 120/1,000 = 0.12, or 12%.
For this Bernoulli event estimate, an approximate plug-in standard error is square root of [0.12 times 0.88 divided by 1,000], approximately 0.0103. A rough normal-approximation 95% interval is 0.12 plus or minus 1.96 times 0.0103, giving approximately 10.0% to 14.0%. The sample is large enough here for this approximation to be a reasonable teaching illustration, though other interval methods are available.
At a similar underlying probability, 4,000 independent simulated days would roughly halve the standard error. It would not eliminate uncertainty about the arrival model or prove that actual operations have a 12% exceedance rate. The counts are invented to explain calculation; no simulator was run for this example.
Illustrative case study
In a fictional repair center, a manager wants to assess a proposed booking limit. An analyst simulates arrivals, job types, and service durations using a documented candidate model. She reports both the estimated overload frequency and its simulation uncertainty.
The team then changes assumptions about unusually long repairs and compares the conclusions. A narrow sampling interval under one assumption does not reassure them if a reasonable alternative model changes the result substantially. They use the analysis to design a small operational evaluation. This scenario illustrates separating numerical precision from model credibility, not an actual implementation or a guaranteed capacity recommendation.
Common misconceptions and mistakes
More samples reduce sampling error under appropriate conditions; they do not correct biased inputs or a flawed simulator. Do not interpret a random seed as evidence of validity: it can help reproduce a run, but the model may still be wrong.
Avoid claiming that an event is impossible because it never appeared in a finite sample. Rare events can be missed entirely. Also do not apply independent-sample error formulas blindly to correlated draws, such as consecutive states in many Markov-chain methods. Finally, simulated observations are not additional real-world evidence about whether the model assumptions are correct.
Business use
Monte Carlo is useful when decisions depend on distributions of outcomes rather than a single average. It can make uncertainty visible through estimated probabilities, ranges, and comparisons between alternatives. The report should state the target quantity, sampling design, model inputs, number of runs, and limitations.
Separate three questions: whether the calculation is implemented correctly, whether sampling uncertainty is small enough for the decision, and whether the model represents the relevant situation. A team may spend more computation for little practical benefit if uncertainty in the model dominates. Sensitivity analysis and real observations can then be more informative than simply increasing run counts.
People also ask
Is Monte Carlo always a simulation of time?
No. It can estimate an integral or other expectation without modeling a sequence of events.
Must random numbers come from a physical source?
No. Computational implementations commonly use pseudorandom generators, with suitable attention to their properties and reproducibility.
Does a 95% simulation interval cover all real-world uncertainty?
No. The interval usually describes a particular estimation procedure under assumptions; model uncertainty and misspecification require separate consideration.
Check your understanding
Under the same independent finite-variance conditions, approximately how many samples are needed to reduce standard error to one-third of its current size?
Answer: Nine times as many, because standard error scales as 1/square root of n. Three times as many samples only reduce it by a factor of square root of three.
Related terms
- Expected value
- Standard error
- Confidence interval
- Importance sampling
- Markov chain Monte Carlo
- Monte Carlo planning
- Sensitivity analysis
- random sampling
- simulation
- variance reduction
Learn next
Repeat the worked calculation with 20 exceedances in 1,000 runs, then compare the absolute and relative uncertainty with the 120-exceedance case. Next examine why zero observed events needs a different discussion from an estimated probability known to be exactly zero.
More in Graphs and symbolic AI
- Monoidal t-norm logic - Monoidal t-norm logic, usually abbreviated MTL, is a formal system of mathematical fuzzy logic associated with all left-continuous triangular norms and...
- Monotonic preference - A monotonic preference is a preference that moves consistently in a specified direction as an attribute increases, with other relevant conditions held fixed.
- Monotonicity - In logical reasoning, monotonicity is the property that adding premises cannot remove conclusions already entailed by the original premises.
- Monte Carlo tree search - Monte Carlo tree search, or MCTS, is a search method that grows a decision tree through repeated sampled simulations and uses their results to guide further...
- Mosaic effect - The mosaic effect occurs when combining separate pieces of information reveals something that the pieces did not clearly reveal on their own.
- Most general unifier - A most general unifier, or MGU, is a substitution that makes two symbolic expressions identical while imposing no unnecessary restrictions on their variables.
Sources
Sources: Art Owen, Monte Carlo theory, methods and examples, introductory and simple Monte Carlo chapters, especially independent-sample accuracy and error estimation: https://artowen.su.domains/mc/Ch-intro.pdf . The queue counts, interval calculation, and repair-center case above are original teaching illustrations.
Previous: Monotonicity Next: Monte Carlo dropout