Skip to content

Newsvendor problem

The newsvendor problem turns underage and overage costs into a demand quantile. Derive the critical fractile, check discrete demand and recognise tied optima.

The newsvendor problem chooses a stock quantity before uncertain demand is known, balancing the cost of unmet demand against the cost of leftovers over one selling period. Its practical lesson for quantitative decisions is that the best quantity depends on the cost of forecast errors: estimating average demand alone does not identify how much to stock.

Think of a perishable product ordered before the day begins. There is one chance to order; replenishment cannot arrive before the selling period ends. Demand is random, but the stock decision is already committed.

Price the two mistakes first

Let Q≥0Q\ge 0 be the chosen quantity and D≥0D\ge 0 the period's demand. Suppose the demand distribution is known, has finite mean, and each unit of mismatch has a constant cost:

  • Underage cost Cu>0C_u>0: the opportunity cost of being one unit short.
  • Overage cost Co>0C_o>0: the net cost of one unit left over.
For selling price pp, purchase cost cc and end-of-period salvage value ss, a simple lost-sales model with p>c>sp>c>s gives Cu=p−cC_u=p-c and Co=c−sC_o=c-s. A separately specified penalty for unmet demand can be added to CuC_u. Lost revenue pp alone overstates underage cost because supplying the missed sale would also have required buying the unit. MIT's single-period inventory notes develop this marginal-cost interpretation and the salvage adjustment.
Write (x)+=max⁡(x,0)(x)^+=\max(x,0). The mismatch loss and its expected value are
ℓ(Q,D)=Cu(D−Q)++Co(Q−D)+,L(Q)=E[ℓ(Q,D)].\ell(Q,D)=C_u(D-Q)^+ + C_o(Q-D)^+, \qquad L(Q)=\mathbb{E}[\ell(Q,D)].

This is an opportunity-loss objective, rather than the retailer's full cash expense. Under the simple price/cost/salvage assumptions above, minimising it is equivalent to maximising expected profit: the difference is the expected profit available if stock could be chosen after seeing demand. Fixed order charges, quantity discounts and constraints need their own treatment.

The next unit decides the quantile

For nonnegative integer demand and integer quantities, compare QQ with Q+1Q+1. The extra unit saves CuC_u if D>QD>Q, but costs CoC_o if D≤QD\le Q. With cumulative distribution function FD(Q)=P(D≤Q)F_D(Q)=\mathbb{P}(D\le Q),
L(Q+1)−L(Q)=CoFD(Q)−Cu[1−FD(Q)].L(Q+1)-L(Q) =C_oF_D(Q)-C_u[1-F_D(Q)].
Add units while this change is negative. It becomes nonnegative once the CDF reaches the critical fractile, also called the critical ratio,
α=CuCu+Co.\alpha=\frac{C_u}{C_u+C_o}.
The smallest optimal stock quantity is therefore the lower quantile
Q∗=inf⁡{q≥0:FD(q)≥α}.Q^*=\inf\{q\ge0:F_D(q)\ge\alpha\}.
For integer demand this selects an integer; for continuous demand the marginal condition becomes FD(Q∗)=αF_D(Q^*)=\alpha. Columbia's newsvendor lecture, §1.1, gives the expected-loss formulation and this generalised-inverse rule.
If underage becomes more expensive relative to overage, the target moves to a higher quantile. Equal costs target a median; that is not generally the mean. A discrete CDF can jump past the target, and a flat stretch exactly at the target can give several equally good quantities.

A 75% target can mean 100% demand coverage

Consider a fictional product with the following one-period demand law:

Demand DD (units)ProbabilityCumulative probability
020%20%
150%70%
230%100%

Set Cu=9C_u=9 and Co=3C_o=3, in USD per unit. These costs could arise from a USD 12 selling price, USD 3 purchase cost and zero salvage value, with no additional shortage penalty. The critical fractile is 9/(9+3)=0.759/(9+3)=0.75.

One unit covers only 70% of the demand distribution. Two units are the first quantity to reach at least 75%. Check the expected loss directly:

Stock QQ (units)Expected mismatch cost (USD)
00.5(9)+0.3(18)=9.900.5(9)+0.3(18)=9.90
10.2(3)+0.3(9)=3.300.2(3)+0.3(9)=3.30
20.2(6)+0.5(3)=2.700.2(6)+0.5(3)=2.70
The second unit reduces expected loss by USD 0.60: its USD 2.70 expected shortage saving exceeds its USD 2.10 expected overage cost. A third unit cannot sell under this demand law and adds USD 3 of certain overage cost. The optimum is two units, even though expected demand is only 1.1 units.
Fictional demand is 0, 1 or 2 units with probabilities 20%, 50% and 30%. The CDF rises from 70% to 100% at 2 units, crossing the 75% critical fractile. Expected mismatch costs for stocking 0, 1 and 2 units are USD 9.90, USD 3.30 and USD 2.70.
Fictional demand is 0, 1 or 2 units with probabilities 20%, 50% and 30%. The CDF rises from 70% to 100% at 2 units, crossing the 75% critical fractile. Expected mismatch costs for stocking 0, 1 and 2 units are USD 9.90, USD 3.30 and USD 2.70.
Original finite-demand example. The first CDF crossing and direct expected-cost calculation both select 2 units. Hollow dots exclude endpoints; dotted vertical connectors show jumps, not attainable intermediate CDF values.

The 75% fractile is a threshold used to choose QQ, not a statement that precisely 75% of periods will avoid shortages. Here P(D≤Q∗)=100%\mathbb{P}(D\le Q^*)=100\%. Nor is the fractile a fraction of units sold: the chance of meeting all demand and the proportion of demand filled measure different things.

For more on why a discrete distribution skips probability levels, Cumulative Distribution Functions develops the staircase and its connection to probability masses. The link opens a public preview; the full lesson requires membership.

What the one-period model leaves open

The quantile rule solves the stated expected-cost problem. It does not select the demand model or establish that its costs are accurate. In practice, observed sales can be censored: selling every available unit reveals demand of at least QQ, not necessarily demand equal to QQ. Fitting a demand law to sales as though every stockout were an exact demand observation can understate the upper tail. Rudin and Vahn's data-driven newsvendor research explicitly considers demand features and extensions to censored observations.
Repeated replenishment, shared capacity across products and a selling price that changes demand alter the decision problem. Likewise, a dealer adjusting quotes while prices and fills evolve faces a dynamic market-making problem; the static newsvendor rule alone does not determine optimal quotes or inventory limits.

Check the tie

A different fictional product has demand of 1, 2 or 3 units with probabilities 25%, 35% and 40%. Underage costs USD 3 per unit; overage costs USD 2 per unit. There are no other costs or constraints. Among nonnegative integer quantities, is the smallest optimal order also the only optimal order?

Answer. The target is 3/(3+2)=0.603/(3+2)=0.60, and FD(2)=0.25+0.35=0.60F_D(2)=0.25+0.35=0.60. The smallest optimal order is two units, but a third unit has zero expected marginal cost: 2(0.60)−3(0.40)=02(0.60)-3(0.40)=0. Both orders have expected loss USD 1.70. At two units this is 0.25(2)+0.40(3)0.25(2)+0.40(3); at three it is 0.25(4)+0.35(2)0.25(4)+0.35(2). The lower-quantile convention selects two without making three suboptimal.

Sources

Last updated
  • newsvendor
  • inventory
  • critical fractile
  • quantiles
  • decision theory
← Back to the glossaryBack to top ↑