- Introduced by
- Integrated from Dantzig (LP) and Zellner/Bayesian econometrics traditions
- Year
- 1970s–1980s
- Type
- Optimization under Bayesian uncertainty
- Family
- Simulation / optimization
What does it do?
Bayesian Linear Programming (BLP) combines Bayesian inference with linear programming for problems in which objective coefficients, constraint coefficients or right-hand-side values are uncertain.
Rather than fixing these parameters at point values or bounding them in a worst-case set, BLP places prior distributions on them, updates the priors with data into posterior distributions, and solves the resulting LP using posterior summaries or posterior samples. The resulting decision is therefore tied to the posterior summary the analyst chooses to report.
The intuition behind the method
Classical linear programming assumes that cost coefficients and constraint values are known exactly, which is often not the case. BLP treats each uncertain parameter as a random variable with a prior distribution that records existing knowledge or expert judgement. As data arrive, Bayes' theorem turns the prior into a posterior distribution. The LP is then solved with posterior point estimates, or with an objective averaged over posterior draws (sample-average approximation), so the solution reflects both the structural constraints and the remaining uncertainty about the parameters. The approach is most natural when the same decision is revisited as the estimates improve.
History
The LP component traces to Dantzig's work on linear programming (Dantzig, 1963, listed in the citations). The Bayesian component traces to the Bayesian econometrics literature, represented here by Zellner (1971). The sources available for this entry do not identify who first combined the two into a single procedure, or when, so this page does not attribute the method to a single originator.
When to use it
Use Bayesian linear programming when LP coefficients or right-hand-side values are uncertain, when prior knowledge or observed data can narrow them, and when the decision will be revisited as data accumulate. Repeated allocation or procurement decisions, in which costs or demands are re-estimated each cycle, are a typical fit. It is also appropriate when the decision maker wants uncertainty expressed as a posterior distribution rather than as a worst-case bound. Do not use it when all parameters are known (standard LP is sufficient), when the model is substantially nonlinear (a nonlinear programming formulation is more appropriate), when the decision is one-off and there are no data to update the priors, or when computing posterior draws is too costly for the decision timeline.
Limitations and considerations
- Prior specification is subjective. When data are scarce, the prior can dominate the posterior, and a poorly calibrated prior biases the LP solution.
- Posterior inference by MCMC or variational methods is computationally costly, and the cost grows with the number of uncertain LP parameters and the number of posterior draws used to build the averaged LP.
- With many variables and constraints, the link between the Bayesian inference step and the LP solver must be implemented carefully so that each posterior draw maps consistently onto the LP data.
- The quality of the solution depends on the posterior approximation. If MCMC or variational inference is used, approximation error in the posterior passes directly into the LP inputs and into the reported objective interval.
- Off-the-shelf software support is thinner than for standard stochastic LP, so the workflow is usually assembled from separate inference and LP tools.
Source conditions do not replace independent scientific review or validation by an analysis engine.
Strengths
- Coherently incorporates prior knowledge and observed data into optimization decisions, which reduces reliance on single point estimates.
- Handles sequential decision-making naturally: the posterior from one cycle becomes the prior for the next, so solutions can be refined as data arrive.
- Posterior distributions over the objective value give credible intervals for the objective value of the chosen decision, rather than only sensitivity ranges around fixed inputs.
- More flexible than worst-case robust LP: the decision maker chooses which posterior summary to act on (e.g., the posterior mean or a chosen quantile) instead of assuming adversarial parameter values.
- The probabilistic framework makes prior assumptions explicit, so stakeholders can inspect and challenge them.
Applications
- Illustrative: supply chain planning with uncertain transport costs, where cost estimates are refreshed from recent shipment records.
- Illustrative: resource allocation where demand levels are unknown and are estimated from historical data.
- Illustrative: healthcare capacity planning where patient-flow parameters are estimated from historical records.
- Illustrative: energy planning under uncertain fuel prices, with priors informed by market analysis.
- Illustrative: sequential production planning where machine efficiency parameters are updated after each production run.
How it works
How it works
Step 1 — Elicit prior distributions. For each uncertain LP parameter (e.g., cost vector c, constraint matrix A, right-hand side b), specify a prior distribution p(theta) reflecting domain knowledge or expert beliefs before observing data. Conjugate priors (e.g., Normal-Normal, Dirichlet-Multinomial) are preferred when feasible to allow analytical posterior updates.
Step 2 — Update to posterior. Given observed data D, apply Bayes' theorem: p(theta | D) proportional to p(D | theta) * p(theta). For each uncertain parameter, compute or approximate the posterior distribution p(theta | D) using analytical conjugate updates, MCMC, or variational inference.
Step 3 — Formulate one LP with posterior information. Fix the rule for using the posterior before solving, and use one rule only. (a) Plug-in: substitute the posterior means of c, A and b into the LP, minimize c^T x subject to Ax <= b, x >= 0, and solve it once to obtain a single decision x*. (b) Sample-average approximation (SAA): draw S posterior samples and build one LP whose objective (or constraint) coefficients are averaged over the S draws. Both rules return one decision x*. Solutions of separate draw-specific LPs are not averaged into a decision, so this combination should not be used.
Step 4 — Solve the LP. Apply the simplex method, interior-point method, or another LP solver to the single LP built in Step 3 to obtain the optimal solution x* and objective value z*. Do not solve draw-specific LPs and then aggregate their solutions; see Step 3.
Step 5 — Make posterior-informed decisions. Report the chosen solution x* together with the spread of its objective value across posterior draws, for example a credible interval: evaluate c_s^T x* for each posterior draw s and summarise the resulting values. Check feasibility of x* under each draw by evaluating Ax* - b for each draw, and report the fraction of draws in which x* is feasible. If this fraction is too low for the application, tighten the right-hand side or use a chance-constrained formulation; this is a modelling choice made by the analyst, not a result established by the cited sources. Re-solving the LP for individual draws may be used only as a diagnostic of how often the optimal solution would change; these solutions are not combined into the decision. In sequential settings, use new data to update the current posterior as the next prior and repeat from Step 2.
Common pitfalls
- Plugging in the posterior mean and reporting only that LP value ignores the posterior spread; propagate the uncertainty to the objective value of x* across draws.
- Misspecifying the likelihood or the prior family can produce posteriors far from the truth, leading to systematically biased LP solutions.
- Ignoring constraint uncertainty while modelling only objective uncertainty can produce solutions that are infeasible under the realised parameter values; check the feasibility rate of x* across draws as described in Step 5.
- Conflating Bayesian LP with stochastic programming: stochastic LP uses scenario trees with fixed probabilities, whereas Bayesian LP derives its inputs from posterior updating of data-based beliefs.
- Failing to re-solve the LP after each posterior update removes the main advantage of the Bayesian approach in sequential settings.
Frequently asked questions
How does Bayesian LP differ from stochastic linear programming?
Stochastic LP uses a fixed set of scenarios with predefined probabilities (e.g., from a scenario tree), while Bayesian LP uses posterior distributions derived from prior beliefs updated by data. Bayesian LP is more naturally suited to sequential settings where beliefs are refined as new observations arrive.
Is Bayesian LP the same as robust linear programming?
No. Robust LP optimizes against the worst case within an uncertainty set, which is typically conservative and does not incorporate data. Bayesian LP integrates data via Bayes' theorem and allows the decision maker to balance expected performance and risk according to the posterior distribution.
What software can I use to implement Bayesian LP?
There is no single dedicated package. Practitioners typically combine a Bayesian inference library (e.g., Stan, PyMC in Python; JAGS, brms in R) to estimate posteriors with a standard LP solver (e.g., GLPK, Gurobi, CPLEX). Under sample-average approximation, the posterior draws are averaged into one LP, which is solved once. Solving a separate LP for each draw is a different approach and requires an explicit aggregation rule.
Can Bayesian LP handle integer or binary variables?
The Bayesian uncertainty quantification layer is independent of the LP relaxation structure. Bayesian mixed-integer programming extends the same idea to integer programs, though solving becomes significantly harder.
How many posterior samples are needed for stable results?
There is no general sample size. Check that the chosen decision x* and the interval endpoints of the objective spread stop changing materially as draws are added, and report the number of draws used.
Related methods
Sources
Dantzig, G. B. (1963). Linear Programming and Extensions. Princeton University Press, Princeton, NJ.
ISBN: 9780691059136Zellner, A. (1971). An Introduction to Bayesian Inference in Econometrics. Wiley, New York.
ISBN: 9780471169376