Branch and bound and valid bounds
Build an exhaustive integer search whose relaxed bounds justify pruning and whose incumbent certifies achievable value.
On this page
The question for today
What you’ll understand
- Separate incumbent and relaxation bounds for integer maximization.
- Create an exhaustive integer branch and justify each pruning rule.
- Compute a global optimality gap from the remaining live nodes.
Dropping integer restrictions enlarges a feasible set and can make optimization easier, but its optimum may describe an impossible fractional decision. Branch and bound uses that relaxation as a bound rather than pretending it is the final answer. A search tree splits the integer possibilities into exhaustive subproblems, while feasible integer incumbents and valid relaxation bounds identify subproblems that cannot improve the best known decision. Correctness depends on those logical relationships, not on visiting an impressive number of nodes.
Bounds have directions
For integer maximization, any feasible integer solution gives a lower bound on the unknown optimal value. The best one found so far is the incumbent. A maximized LP relaxation gives an upper bound because its feasible set contains all integer-feasible points of that node. Reversing either direction can wrongly discard the optimum. The relaxed optimum is not itself an incumbent unless its integer-restricted coordinates satisfy the required integrality and all original constraints. Rounding a fractional vector is merely a candidate-generation heuristic until feasibility is checked again.
An exact optimal LP value is one source of a node upper bound, but a feasible LP dual vector also provides a valid bound without requiring primal optimality. For a maximization LP, a partially optimized primal point alone does not supply such an upper bound. This matters when numerical LP solves terminate early. If the integer objective is known to be integer-valued, a valid real upper bound can be rounded downward; otherwise that strengthening is unjustified. Bounds must include all constant terms and scaling used when translating the objective.
Branch exhaustively and prune logically
If a node relaxation has a fractional integer-restricted coordinate , create children with and . Every integer value satisfies exactly one side, so no integer-feasible point is lost. The branch is not a claim that the parent optimizer survives in either child; removing that fractional point is intentional. A child can be pruned when it is infeasible, when its valid upper bound is no greater than the incumbent, or when its relaxation has an integer-feasible optimizer attaining that bound.
The search ends with a global certificate when every node has been pruned or solved. With live nodes, the largest valid upper bound among them, combined with the incumbent, bounds the global optimum. If no incumbent exists, there is no achieved lower bound to report as a feasible answer. If no live nodes remain and no incumbent was ever found, the original integer model is infeasible. Node-selection strategies and branching heuristics can greatly alter runtime, but they must preserve coverage of all unresolved integer possibilities and the validity of every bound used for deletion.
Finite trees and numerical caution
For a pure integer problem with finite bounds on every variable, exhaustive branching can eventually isolate all integer assignments, giving a finite exact search. This does not provide a polynomial worst-case guarantee: the number of assignments and the branch tree can grow exponentially. Unbounded integer domains need additional assumptions and algorithmic treatment before a termination claim is justified. General mixed-integer linear programming retains hard discrete structure even though each node relaxation is a polynomially solvable continuous LP. Small integrality gaps and strong bounds often help, but they do not alone guarantee a small tree.
In floating-point implementations, integrality tolerances, feasibility tolerances, and bound tolerances serve different purposes. A coordinate near an integer does not make a resource violation acceptable, and an optimistic rounded upper bound can invalidate pruning. Certified workflows use validated dual bounds, directed rounding, or exact arithmetic where necessary. Report an absolute gap along with feasible incumbent data and a clear relative-gap convention; relative gaps become delicate near zero or when objectives have opposite signs. A time-limited run with a nonzero certified gap is an honest partial result, not a proof of optimality.
Work it through
A small tree with a closing certificate
Maximize over nonnegative integer subject to and . Trace a branch on the root's x coordinate.
The root LP has optimizer with value . The integer point has value six, so set incumbent . Branch into and .
In the first child, implies . The bound six equals the incumbent, so this child cannot improve it. Its fractional optimum need not be rounded.
In the second child, and nonnegativity force even in the relaxation. This is an integer optimizer with value six. Both children are resolved, closing the global gap.
The integer optimum is six, certified by incumbent (2,0) and exhaustive child bounds no larger than six.
The living notebook
Explore the model
Interactive lab · root-finding
Bounds must enclose what remains possible
Pause and Reset; set target c to 2 and upper bound U to 4. Predict the positive root stays inside each bisection bracket, then Step several times and inspect the interval and midpoint error bound. Reset and set c to 2 and U to 2 for a shorter initial bracket; compare again from time zero.
- Midpoint after 0 refinements
- 1.5
- Bracket error bound
- 1.5
- Computed residual · x² − c
- 0.25
Bisection of x² − c on [0,U], capped at 50 iterations for floating-point resolution. The error bound is the maximum distance from the displayed midpoint to either bracket endpoint (half the width in exact arithmetic). Compensated square evaluation preserves the bracket when ordinary multiplication rounds a residual to zero. A truly exact endpoint or midpoint collapses the bracket. This is one monotone quadratic, not a general root solver. Parameter changes pause playback and recompute the model at the current elapsed time. Reset restores both parameters and returns time to zero. Playback starts paused. Adjust either parameter, then choose Play or Step.
Look forThe instrument demonstrates a certified shrinking interval for one root. Branch and bound similarly needs valid enclosures, but an integer tree has many disjoint live regions; bisection here is not an integer optimizer or an LP relaxation.
Pause & reason
Check your understanding
Your turn
Try it yourself
A maximization search has incumbent value 11 and live node upper bounds 12.4, 10.7, and 11.8. Determine the immediate pruning decision and certified global absolute gap. What changes if every integer-feasible objective is known to be an integer?
Take a moment to make a prediction or work it out on paper. Open a hint when you need one.
Give me a hint
Use the maximum unresolved upper bound, then separately apply any justified objective-integrality strengthening.
Compare with the solution
Prune the node bounded by 10.7 because it cannot exceed the incumbent. The global upper bound is 12.4, so the absolute gap is 1.4. If all integer-feasible objective values are integers, floor the remaining bounds to 12 and 11. The node bounded by 11.8 can then also be pruned, and the global gap is at most one. This still does not certify value eleven optimal because the bound twelve remains live.
Keep the idea
Take it with you
- A maximization incumbent is a lower bound; a relaxed or dual node certificate gives an upper bound.
- Integer floor/ceiling branches preserve exhaustive coverage.
- A closed certified gap proves optimality; a large explored tree alone proves nothing.
Read further
Original sources and deeper explanations to follow at your own pace.
Optional progress, saved in this browser when available. Revisit any lesson at any time.
Lesson not marked complete.