Data Science

Markdown Pricing Optimization: Stochastic Programming for Retail

How retailers transform predictive demand models into prescriptive pricing decisions through stochastic programming, jointly optimizing markdown prices and inventory allocation under uncertainty

Cyril Noirot
By Cyril NoirotMay 1, 20255 min read
Share on

Executive Summary

The profit optimization problem lies at the heart of markdown pricing and inventory allocation. It represents the prescriptive analytics layer—the point where predictive demand models are translated into actionable decisions that maximize expected profit under uncertainty.

Retailers, especially in e-commerce, face thin margins, short product life cycles, and fixed inventories that cannot be replenished mid-season. Under such conditions, optimizing pricing and allocation jointly—while accounting for uncertain demand parameters—becomes a stochastic programming challenge.

1. The Profit optimization problem as stochastic programming

In its most general form, the profit optimization problem seeks to find the optimal price policy p∗p^* that maximizes the expected profit (or revenue) under uncertain demand parameters Θ\Theta.

Let f(θ)f(\theta) denote the probability density function of the demand parameters. Then, the expected revenue function is defined as:

Rˉ(p)=∫dom(f)R(p,θ) f(θ) dθ\bar{R}(p) = \int_{\text{dom}(f)} R(p, \theta) \, f(\theta) \, d\theta

The optimization problem is thus:

max⁡p  Rˉ(p)\max_{p} \; \bar{R}(p)

This formulation captures the essence of prescriptive analytics under uncertainty—rather than optimizing revenue for a single estimated parameter set, we optimize the expected value of profit over all plausible parameter realizations.

2. The joint markdown pricing and inventory allocation problem

In practice, retailers rarely optimize prices in isolation. Markdown pricing and inventory allocation are jointly determined because pricing influences demand, and demand, in turn, determines how much inventory should be assigned to each market or channel.

The joint optimization problem simultaneously solves for:

  1. Group-specific markdown prices pℓp_\ell—one for each customer group ℓ\ell.
  2. Inventory allocations xmℓx_{m\ell}—quantities shipped from fulfillment center mm to customer group ℓ\ell.

The objective is to maximize total expected profit:

max⁡{pℓ,xmℓ}∑ℓ∈L(Rˉℓ∗(Sℓ)−∑m∈Mcmℓxmℓ)\max_{\{p_\ell, x_{m\ell}\}} \sum_{\ell \in L} \Big( \bar{R}^*_\ell(S_\ell) - \sum_{m \in M} c_{m\ell} x_{m\ell} \Big)

where:

  • Rˉℓ∗(Sℓ)\bar{R}^*_\ell(S_\ell) = optimal expected revenue for group ℓ\ell, given inventory SℓS_\ell
  • cmℓc_{m\ell} = unit delivery cost from fulfillment center mm to group ℓ\ell
  • Sℓ=∑mxmℓS_\ell = \sum_m x_{m\ell} = total inventory assigned to group ℓ\ell

Constraints

Optimization Constraints

1. Fulfillment Center Capacity

∑ℓxmℓ≤Bm,∀m\sum_{\ell} x_{m\ell} \leq B_m, \quad \forall m

where BmB_m is the total available stock at fulfillment center mm

2. Inventory Balance

Sℓ=∑mxmℓ,∀ℓS_\ell = \sum_{m} x_{m\ell}, \quad \forall \ell

Total inventory for group ℓ\ell equals sum from all fulfillment centers

This framework ensures that both pricing and logistics decisions are optimized simultaneously within the same stochastic system.

3. Structural properties and solution approach

The solvability of the problem depends on the shape of the expected revenue function.

Key properties

1. Diminishing Returns

Allocating more inventory cannot reduce revenue, but additional units can only be sold at lower prices

2. Concavity

Expected revenue Rˉℓ∗(Sℓ)\bar{R}^*_\ell(S_\ell) is concave in inventory, making the problem convex

3. Network Flow

Problem equivalent to minimum-cost network flow with convex costs

4. Key modeling requirements and inputs

Solving the profit optimization problem presupposes that several critical assumptions are met:

Monotonic Demand Function

The expected demand dˉ(p)\bar{d}(p) must be a monotonically decreasing function of price. This ensures that price elasticity behaves consistently with economic theory and that the optimization surface remains convex.

Inventory clearing condition

The optimal price policy p(t)p(t) should ensure that inventory SS is sold out by the exit time TT, or—if inventory is high—that prices converge to the revenue-maximizing level.

Uncertainty Integration

The predictive demand model must provide probability distributions for key parameters (such as price elasticity and baseline demand). These distributions are necessary for computing the expected revenue integral:

Rˉ(p)=EΘ[R(p,Θ)]\bar{R}(p) = \mathbb{E}_\Theta [R(p, \Theta)]

In practice, this uncertainty is often modeled using:

  • Bayesian posterior distributions (via MCMC or variational inference)
  • Analytical variance approximations (via the Hessian at MLE)

5. Managerial interpretation

From a business standpoint, the stochastic profit optimization problem represents the transition from forecasting to decision-making.

It answers the ultimate operational question:

This framework allows decision-makers to:

  • Quantify the risk–return tradeoff of markdown schedules
  • Simulate outcomes under different elasticity distributions
  • Implement robust, data-driven pricing policies aligned with business constraints

Summary

ConceptDescription
ObjectiveMaximize expected profit (or revenue) under demand uncertainty
Decision VariablesPrices pℓp_\ell and inventory allocations xmℓx_{m\ell}
StructureConvex, concave expected revenue; solvable via network flow methods
Key AssumptionsMonotonic demand, known parameter distributions
OutputOptimal price and allocation policy (p∗,x∗)(p^*, x^*)

Conclusion

The profit optimization problem is the culmination of the predictive–prescriptive pipeline in markdown optimization. It formalizes how statistical uncertainty propagates into business risk—and how to optimize around it.

In a world where demand is never known exactly, stochastic programming provides a principled way to make pricing decisions that are both data-driven and economically sound.

Next Steps

We'll explore Algorithmic Strategies for Solving the Stochastic Markdown Optimization Problem, comparing analytical convex approaches and simulation-based methods like Sample Average Approximation (SAA).

Solutions

Try the mechanics

About the author

Cyril Noirot

Cyril Noirot

Lead Data Scientist

Freelance data scientist. I design and ship decision systems — forecasting, pricing, marketing measurement, optimization.

Newsletter

Technical writing on forecasting, pricing, and decision systems. No fixed schedule, no spam.

Enter your email
Subscribe