Robust and Stochastic Optimization Answer Different Uncertainty Questions

Optimization under uncertainty is not one method. Expected-cost models, chance constraints, robust counterparts and distributionally robust models encode different beliefs about what is known and different definitions of failure.

Topics

Optimization is easiest when every coefficient is known. Demand is 100, production capacity is 120, lead time is five days, energy price is 70, and the model returns the decision that minimizes cost subject to the stated constraints. Real systems rarely provide those numbers as certainties. Demand is forecast, processing time varies, prices move, yields fluctuate, failures occur, and even the probability distributions used to describe those quantities are estimated from finite data.

A common response is to replace each uncertain input by its expected value and solve the resulting deterministic problem. This can be reasonable when the loss is nearly linear around the operating point or when decisions can be revised after uncertainty is observed. It can also fail badly because optimization and averaging do not generally commute. The decision that is optimal at average demand need not minimize average loss, and a plan that is cheap on average can violate an important capacity constraint too often.

The alternatives are not different names for the same correction. Stochastic programming assumes a probability model and optimizes an expectation or another distributional functional. Chance-constrained optimization controls the probability of violating a constraint. Robust optimization protects against every realization inside a specified uncertainty set. Distributionally robust optimization goes one level higher and protects against a family of probability distributions because the law of the uncertainty is itself uncertain.

These formulations answer different questions. The distinction becomes much clearer if the model, loss function and uncertainty remain fixed while only the mathematical treatment of uncertainty changes.

One capacity decision, five different answers

Suppose a planner must choose capacity

$$ q $$

before demand

$$ D $$

is observed. Unused capacity costs one unit per unit, while unmet demand costs four units per unit. The loss is

$$ L(q,D) = (q-D)_+ + 4(D-q)_+, $$

where

$$ x_+ = \max(x,0). $$

The asymmetry matters. One unit of shortage is four times as expensive as one unit of excess capacity. A decision based only on expected demand therefore ignores an important part of the problem.

Assume the nominal demand model is

$$ D \sim N(100,20^2). $$

The deterministic plug-in approach replaces uncertain demand by its mean,

$$ D=100, $$

and solves

$$ \min_q L(q,100). $$

The solution is

$$ q_{\mathrm{det}} = 100. $$

This decision is optimal for a world in which demand is exactly equal to its mean. It is not the optimizer of expected loss under the stated demand distribution.

For the stochastic formulation, solve

$$ \min_q \mathbb E[L(q,D)]. $$

This is the classical asymmetric newsvendor problem. If the overage cost is

$$ c_o=1 $$

and the underage cost is

$$ c_u=4, $$

the optimal quantile satisfies

$$ F_D(q^\star) = \frac{ c_u }{ c_u+c_o } = \frac45 = 0.8. $$

Under the nominal normal model,

$$ q_{\mathrm{stoch}} = 100 + 20\Phi^{-1}(0.8) \approx 116.83. $$

The stochastic decision is larger than the mean because shortage is more expensive than overage. The probability model does not merely add an uncertainty interval around the deterministic solution. It changes the optimizer.

The expected loss under a normal demand model can be calculated exactly. Let

$$ z = \frac{ q-\mu }{ \sigma }. $$

Then

$$ \mathbb E[(q-D)_+] = (q-\mu)\Phi(z) + \sigma\phi(z), $$

and

$$ \mathbb E[(D-q)_+] = (\mu-q) \left[ 1-\Phi(z) \right] + \sigma\phi(z). $$

For the nominal model

$$ \mu=100, \qquad \sigma=20, $$

the deterministic decision

$$ q=100 $$

has expected loss approximately

$$ 39.89, $$

while the stochastic optimum

$$ q=116.83 $$

has expected loss approximately

$$ 28.00. $$

Replacing demand by its mean therefore costs about 42% more in expected loss in this example even though the demand forecast itself is unbiased.

Now change the question. Suppose the planner does not trust a full probability law but is confident that demand will lie somewhere in

$$ [60,140]. $$

A robust formulation minimizes the worst possible loss,

$$ \min_q \max_{D\in[60,140]} L(q,D). $$

For

$$ 60\le q\le140, $$

the worst overage loss occurs at the lower endpoint,

$$ q-60, $$

while the worst shortage loss occurs at the upper endpoint,

$$ 4(140-q). $$

The robust optimizer equalizes these two worst cases:

$$ q-60 = 4(140-q). $$

Therefore,

$$ 5q = 620, $$

and

$$ q_{\mathrm{rob}} = 124. $$

At this decision, the worst loss is

$$ 64. $$

The stochastic optimum has lower nominal expected cost but a larger worst-case loss over the interval,

$$ \max_{D\in[60,140]} L(116.83,D) \approx 92.67. $$

The robust decision is not "better" in the abstract. It is better for the criterion it was asked to optimize.

The distinction can be summarized directly:

Formulation Uncertainty object Decision Nominal expected loss Worst loss over [60,140]
Deterministic plug-in Mean demand 100 100.00 39.89 160.00
Stochastic expected loss $N(100,20^2)$ 116.83 28.00 92.67
Robust worst case $D\in[60,140]$ 124.00 29.61 64.00

The robust solution sacrifices about

$$ 29.61-28.00 = 1.61 $$

units of nominal expected performance relative to the stochastic optimum in exchange for a substantial reduction in worst-case loss over the stated interval. That trade-off is not an implementation defect. It is the mathematical expression of a different risk criterion.

Chance constraints answer a probability-of-failure question

Expected loss and worst-case loss are not the only possible objectives. Many operational rules are stated as service requirements:

capacity should meet demand at least 95% of the time.

The corresponding chance constraint is

$$ P(D\le q) \ge 0.95. $$

If the objective is simply to minimize capacity subject to that reliability requirement,

$$ \min_q q $$

subject to

$$ P(D\le q) \ge 0.95, $$

the solution under the nominal Gaussian model is the 95th percentile,

$$ q_{\mathrm{chance}} = 100 + 20\Phi^{-1}(0.95) \approx 132.90. $$

This is larger than both the stochastic expected-cost solution and the robust minimax solution from the previous section.

There is no contradiction because the objective is different. The stochastic solution balances one unit of overage cost against four units of shortage cost and therefore selects the 80th percentile. The chance constraint imposes a 95% service requirement independently of that cost ratio. If the service-level requirement is contractual, safety-critical or regulatory, expected-cost optimality may be irrelevant.

Chance constraints are particularly useful when the unacceptable event is naturally binary. A power system either exceeds a capacity limit or it does not. A portfolio either violates a capital requirement or it does not. A production plan either meets a deadline or it does not. The probability threshold

$$ 1-\alpha $$

then has an operational interpretation.

The difficulty is that the probability model must be credible in the region defining the constraint. A nominal 99.9% chance constraint can create false confidence when the tail distribution is estimated poorly. Moving from an expected-loss criterion to a high-reliability constraint often makes distributional assumptions more rather than less important.

Stochastic programming assumes a probability law

The one-period capacity problem is a one-stage stochastic program. Many operational decisions have recourse. A capacity decision is made now, uncertainty is revealed later, and a second decision adapts to what happened.

A standard two-stage stochastic program has the form

$$ \min_x \left\{ c^\top x + \mathbb E_\xi[ Q(x,\xi) ] \right\}, $$

where the second-stage value function is

$$ Q(x,\xi) = \min_y \left\{ q(\xi)^\top y : W(\xi)y = h(\xi)-T(\xi)x, \quad y\ge0 \right\}. $$

The first-stage decision

$$ x $$

must be chosen before uncertainty

$$ \xi $$

is known. The recourse decision

$$ y $$

can adapt after uncertainty is observed.

This separation is one of the main strengths of stochastic programming. It distinguishes commitments from actions that remain flexible. A manufacturer may choose plant capacity years in advance but adjust production weekly. A hospital may choose staffing levels before the day begins and reassign staff after arrivals are observed. A supply chain may select warehouse locations before demand is known and route products after orders arrive.

The expectation in the objective requires a probability distribution for

$$ \xi. $$

In practice, this is often approximated by scenarios,

$$ \xi_1,\ldots,\xi_S, $$

with probabilities

$$ p_1,\ldots,p_S. $$

The stochastic program becomes

$$ \min_x \left[ c^\top x + \sum_{s=1}^S p_s Q(x,\xi_s) \right]. $$

Scenario design is therefore part of the statistical model. Historical observations are not automatically representative scenarios, and generating thousands of simulations from a fitted model does not remove uncertainty about whether that model is correct.

A two-stage solution can also be misleading if it quietly assumes perfect information between stages. Recourse is allowed to depend only on information available at that point. In multi-stage stochastic programming, this is enforced through nonanticipativity constraints. Decisions that are made before two scenarios become distinguishable must be identical across those scenarios.

Without nonanticipativity, an optimization model can cheat by using future information.

Robust optimization assumes an uncertainty set instead

Robust optimization removes the need to specify probabilities and instead defines a set of realizations considered possible,

$$ \xi \in \mathcal U. $$

The basic robust problem is

$$ \min_x \max_{\xi\in\mathcal U} L(x,\xi), $$

or, for constraints,

$$ g(x,\xi) \le 0 \qquad \text{for every } \xi\in\mathcal U. $$

The capacity interval

$$ D\in[60,140] $$

was a one-dimensional uncertainty set. In higher dimensions, the geometry of

$$ \mathcal U $$

becomes central.

A box uncertainty set,

$$ |\xi_j-\bar\xi_j| \le d_j \qquad \text{for every }j, $$

allows every uncertain component to take its worst admissible value simultaneously. This can be far too conservative when such joint extremes are physically impossible or statistically implausible.

Ellipsoidal sets encode joint magnitude,

$$ (\xi-\bar\xi)^\top \Sigma^{-1} (\xi-\bar\xi) \le \rho^2. $$

Budgeted uncertainty sets allow individual coefficients to vary within bounds while limiting how many can be extreme simultaneously. In the Bertsimas-Sim framework, a budget parameter

$$ \Gamma $$

controls the total amount of simultaneous adverse deviation.

These sets are not merely computational devices. Their geometry states what combinations of uncertainty the decision must survive.

A badly chosen uncertainty set can make a robust solution meaningless. If it is too small, the robustness guarantee excludes relevant events. If it is too large, the optimizer can pay heavily to protect against combinations that have no scientific or operational plausibility.

The size and shape of

$$ \mathcal U $$

therefore require the same discipline as specifying a probability model. Historical quantiles, engineering tolerances, confidence regions, physical limits and stress scenarios can all inform the set. Choosing the radius solely because it produces a comfortable answer reverses the logic of robustness.

Distributionally robust optimization separates outcome uncertainty from model uncertainty

Stochastic and robust optimization treat different objects as uncertain. Stochastic programming assumes the probability distribution is known and outcomes are random. Robust optimization assumes a set of outcomes is possible and refuses to assign probabilities.

Distributionally robust optimization addresses a third problem: the distribution itself is uncertain.

Let

$$ \mathcal P $$

be an ambiguity set containing plausible probability laws. A distributionally robust problem can be written as

$$ \min_x \sup_{P\in\mathcal P} \mathbb E_P[ L(x,\xi) ]. $$

This is not the same as robust optimization over realizations. The adversary chooses a probability distribution, not one outcome.

Return to the capacity example. Suppose the nominal model

$$ N(100,20^2) $$

is based on limited data. Instead of treating its mean and standard deviation as known, consider the ambiguity class

$$ \mathcal P = \left\{ N(\mu,\sigma^2) : 95\le\mu\le105, \quad 15\le\sigma\le25 \right\}. $$

The distributionally robust decision solves

$$ \min_q \sup_{ 95\le\mu\le105,\, 15\le\sigma\le25 } \mathbb E_{\mu,\sigma} [ L(q,D) ]. $$

Because the loss is convex in demand, larger variance increases expected loss within this Gaussian family, so the worst standard deviation is

$$ \sigma=25. $$

For the mean, the worst case occurs at one of the interval endpoints. Using the exact Gaussian loss formulas, the minimax expected-loss decision is approximately

$$ q_{\mathrm{DRO}} = 121.18. $$

Its nominal expected loss under

$$ N(100,20^2) $$

is approximately

$$ 28.62. $$

Its worst realized loss over

$$ [60,140] $$

is approximately

$$ 75.28. $$

This places the decision between the nominal stochastic solution and the hard robust solution:

Formulation Decision
Deterministic mean demand 100.00
Stochastic expected loss 116.83
Distributionally robust expected loss 121.18
Robust worst realized loss 124.00
95% chance-constrained minimum capacity 132.90

The numerical ordering is specific to this example and should not be treated as a universal hierarchy. The important distinction is conceptual.

The stochastic model trusts one distribution. The distributionally robust model trusts only that the distribution belongs to a family. The robust model protects against every realization in a set regardless of probability. The chance constraint protects a probability level. Each formulation places uncertainty in a different mathematical object.

Modern ambiguity sets are not limited to parameter intervals. Moment-based sets specify means, variances or other moments. Divergence balls contain distributions sufficiently close to a nominal law under a statistical divergence. Wasserstein balls contain distributions whose transportation distance from an empirical or nominal distribution is bounded.

The radius of an ambiguity set controls how much distributional model risk is admitted. As the radius shrinks to zero, a distributionally robust model approaches the nominal stochastic model. As it grows, the decision usually becomes more conservative.

That radius should be connected to data uncertainty or domain knowledge. It is not a free robustness dial detached from the statistical problem.

Conservatism is not one-dimensional

Robust optimization is often described as conservative and stochastic programming as efficient. The distinction is too crude.

A stochastic model can be extremely conservative if the objective contains a large tail-risk penalty, if it minimizes conditional value at risk, or if it enforces a very high chance constraint. A robust model can be relatively mild if its uncertainty set is tightly calibrated to realistic perturbations.

Conservatism is determined jointly by the uncertainty model and the loss or constraint.

The same expected-value stochastic program can also be risk-neutral in a way that is operationally unacceptable. Two decisions can have similar expected cost while one has a small probability of catastrophic failure. Replacing expected loss by a coherent risk measure changes the problem.

Conditional value at risk at level

$$ \alpha $$

can be written as

$$ \operatorname{CVaR}_\alpha(L) = \min_{\eta} \left[ \eta + \frac{ 1 }{ 1-\alpha } \mathbb E[ (L-\eta)_+ ] \right]. $$

Optimizing CVaR focuses on losses in the upper tail rather than only on their mean. This remains a stochastic optimization problem because it depends on a probability law.

Robust optimization instead asks what happens at the worst admissible realization, even if no probability is assigned to that realization.

A planner who says "I can tolerate a 5% chance of shortage" is asking for a probabilistic constraint. A planner who says "this system must work for every demand between 60 and 140" is asking for robustness over a set. A planner who says "I have a fitted distribution, but I do not trust it exactly" is describing distributional ambiguity.

The mathematics should follow the statement.

Data do not automatically tell us which uncertainty model to use

Historical data can estimate a probability distribution, but optimization often magnifies errors in that estimate. The optimizer searches for decisions that exploit whatever the model says is cheap. Small errors in tail probability, dependence or support can therefore create large decision errors.

This phenomenon is sometimes called the optimizer's curse. An estimated model contains noise, and optimization tends to select decisions that benefit most from favourable estimation errors.

Scenario-based stochastic programs are vulnerable when rare but costly events are absent from the sample. Robust models are vulnerable when the uncertainty set is calibrated from extreme sample observations that themselves are noisy. Distributionally robust models are vulnerable when the ambiguity set is centered on a misspecified representation or when its radius does not reflect actual estimation uncertainty.

Out-of-sample decision evaluation is therefore essential. The quantity to validate is not only forecast accuracy. It is decision performance under new data.

A demand model with slightly lower RMSE can produce worse inventory decisions if its upper quantiles are poorly calibrated. A robust set can produce excellent historical feasibility because it was constructed after observing the same stress periods used for evaluation. A distributionally robust model can look stable because the ambiguity set is so wide that every decision becomes dominated by worst-case behaviour.

Optimization under uncertainty should therefore be evaluated with the same separation used elsewhere in statistical modelling: training data define or estimate the uncertainty model, validation data tune model choices, and genuinely held-out data assess the resulting decisions.

When possible, stress tests should include scientifically plausible distribution shifts rather than only resampling the historical distribution.

Recourse often matters more than the choice between robust and stochastic

A plan that can be revised after uncertainty is observed does not need to protect every decision variable in advance.

Suppose a firm chooses annual production capacity now but can schedule overtime after demand is observed. A model that requires base capacity alone to cover every possible demand realization can be unnecessarily expensive. The real decision structure contains recourse.

In stochastic programming, recourse is explicit through

$$ Q(x,\xi). $$

In robust optimization, adjustable robust formulations allow some decisions to depend on uncertainty:

$$ y = y(\xi). $$

Full functional dependence can be intractable, so practical models often use affine decision rules,

$$ y(\xi) = y_0 + Y\xi. $$

The important conceptual point is that uncertainty and flexibility must be modelled together. A highly uncertain environment can still support aggressive first-stage decisions when later adaptation is cheap and rapid. A moderately uncertain environment may require conservative commitments when decisions are irreversible.

This is why capacity expansion, staffing, energy storage, supply contracts and maintenance scheduling cannot be classified simply by uncertainty magnitude. The timing of information and decisions matters.

A mathematically careful model should state what is known at each decision time. Otherwise an optimizer can either become needlessly conservative or silently use information that would not exist operationally.

Robustness should be attached to a scientific uncertainty statement

The phrase "make the optimization robust" is incomplete. Robust against what?

Against bounded measurement error? Demand forecast error? Model misspecification? Supplier disruption? Correlation uncertainty? Parameter estimation error? Tail uncertainty? Structural change?

Each object suggests a different mathematical treatment.

If uncertain coefficients have well-supported probability distributions and repeated decisions make average performance meaningful, stochastic programming can be natural. If physical or contractual limits define a credible range but probabilities are unavailable, robust optimization may be more defensible. If a service requirement is naturally probabilistic, chance constraints express it directly. If the estimated distribution is itself the main uncertainty, distributionally robust optimization can separate model risk from ordinary outcome randomness.

Hybrid formulations are also possible. A model can include robust physical tolerances, stochastic demand, a chance constraint on service level and a distributionally robust component for an uncertain demand law. The categories are not mutually exclusive.

What matters is that each piece of uncertainty is attached to an interpretation.

The capacity example illustrates the consequence. The deterministic decision of 100 was optimal only if mean demand were the entire problem. The stochastic decision of 116.83 was optimal for expected asymmetric loss under one trusted Gaussian distribution. The robust decision of 124 was optimal for worst-case loss over a hard interval. The distributionally robust decision of about 121.18 guarded expected loss against uncertainty in the Gaussian parameters. The 95% chance-constrained decision of 132.90 enforced a reliability target.

Asking which number is "the optimal capacity" without stating the uncertainty criterion has no mathematical answer.

There is an optimal solution only relative to a model of uncertainty, a loss function, a timing structure and a definition of acceptable risk.

References

Ben-Tal, A., El Ghaoui, L., & Nemirovski, A. (2009). Robust Optimization. Princeton University Press.

Bertsimas, D., Brown, D. B., & Caramanis, C. (2011). Theory and applications of robust optimization. SIAM Review, 53(3), 464–501. https://doi.org/10.1137/080734510

Bertsimas, D., & Sim, M. (2004). The price of robustness. Operations Research, 52(1), 35–53. https://doi.org/10.1287/opre.1030.0065

Birge, J. R., & Louveaux, F. (2011). Introduction to Stochastic Programming (2nd ed.). Springer.

Delage, E., & Ye, Y. (2010). Distributionally robust optimization under moment uncertainty with application to data-driven problems. Operations Research, 58(3), 595–612. https://doi.org/10.1287/opre.1090.0741

Esfahani, P. M., & Kuhn, D. (2018). Data-driven distributionally robust optimization using the Wasserstein metric. Mathematical Programming, 171, 115–166. https://doi.org/10.1007/s10107-017-1172-1

Nemirovski, A., & Shapiro, A. (2006). Convex approximations of chance constrained programs. SIAM Journal on Optimization, 17(4), 969–996. https://doi.org/10.1137/050622328

Rahimian, H., & Mehrotra, S. (2019). Distributionally robust optimization: A review. arXiv preprint arXiv:1908.05659.

Rockafellar, R. T., & Uryasev, S. (2000). Optimization of conditional value-at-risk. Journal of Risk, 2(3), 21–41.

Shapiro, A., Dentcheva, D., & Ruszczyński, A. (2014). Lectures on Stochastic Programming: Modeling and Theory (2nd ed.). SIAM.

Embed interactive plots, widgets, and demos using <figure>, <iframe>, or <div class="interactive-embed"> containers. Ensure each embed includes descriptive captions for accessibility.

How to cite

Use the quick export buttons to save citations for reference managers or copy the formatted text directly.

Diogo Ribeiro (2026). Robust and Stochastic Optimization Answer Different Uncertainty Questions. Faculty of Media Arts and Design, Technical University of Porto. https://diogoribeiro7.github.io/mathematics/robust_and_stochastic_optimization_answer_different_uncertainty_questions/.

BibTeX

RIS

EndNote

Related posts

Loading mathematical content