Matheuristics: Hybridizing Mathematical Programming and Metaheuristics

Decision Sciences
Introduced by
Maniezzo, Stützle & Voß
Year
2009
Type
Hybrid optimization framework
Family
Metaheuristics

What does it do?

Matheuristics is a family of hybrid optimization methods that combine exact mathematical programming components, such as mixed-integer programming (MIP) solvers, with metaheuristic search procedures.

The approach is associated with the 2009 Springer edited volume by Maniezzo, Stützle, and Voß, which treats the hybridization of metaheuristics and mathematical programming as a common topic. It is aimed at large combinatorial problems that are hard to solve with either an exact solver or a metaheuristic alone.

The intuition behind the method

Consider a large routing or scheduling problem as a search among very many candidate arrangements. A heuristic component proposes a candidate and marks part of it as worth refining. An exact solver then optimizes the remaining free decisions within that part, with the other decisions held fixed. The refined result is compared with the heuristic's own solution and the better one is kept, and the cycle can repeat. The heuristic provides broad exploration, and the solver provides precise decisions on a smaller piece of the problem.

History

The term 'matheuristics' is most closely associated with the 2009 Springer edited volume by Maniezzo, Stützle, and Voß, titled Matheuristics: Hybridizing Metaheuristics and Mathematical Programming. The volume is an edited collection and is cited here as a key reference for the term rather than as the origin of the underlying methods.

When to use it

Consider a matheuristic when the problem is combinatorial or mixed-integer and too large for an exact solver to finish in the available time, and when its structure allows a useful MIP model to be written. Routing, scheduling, network design, and supply chain planning are typical examples. The approach assumes that fixing part of a heuristic solution still leaves a meaningful sub-problem. Avoid it when no reasonable MIP formulation exists, when the decision variables are continuous and smooth so that standard continuous methods apply, or when the instance is small enough for an exact solver to handle directly.

Limitations and considerations

  • The method requires a valid MIP model. If the constraints are difficult to express linearly, the exact component cannot be applied directly.
  • The choice of variables to fix determines what the exact phase can improve. A poor choice can leave the optimum outside the restricted problem.
  • Each refinement call adds solver time. If the subproblem is not much smaller than the original, the cost may outweigh the benefit.
  • The pipeline does not certify optimality of its output. The heuristic phase has no guarantee of reaching the global optimum, and the MIP phase is optimal only for the fixed-variable subproblem.

Source conditions do not replace independent scientific review or validation by an analysis engine.

Strengths

  • The heuristic phase searches a neighbourhood of candidate solutions, while the MIP phase optimizes the free variables exactly, so each component covers part of the search that the other handles weakly.
  • Fixing the variables in S can shrink the exact subproblem, so the exact solve may scale better, provided the remaining subproblem is substantially smaller than the original.
  • The integration step returns the lower-valued of the two candidate solutions, so the returned objective is no worse than either candidate.
  • The framework does not prescribe a particular metaheuristic or solver. The MIP sub-model must, however, be built on the same variables and neighbourhood moves that the heuristic changes, so that both phases refer to the same solutions.

Applications

  • Vehicle routing and logistics, where exact optimization of part of the routes can be combined with heuristic search over the rest.
  • Production scheduling, where some sequencing decisions can be fixed and the remaining timing decisions optimized.
  • Network design, where some design choices are fixed and the remaining configuration is searched heuristically.
  • Supply chain planning, where facility location decisions can be fixed and routing or inventory decisions optimized with heuristics.
  • Crew scheduling, where assignment variables can be restricted and the remaining assignments searched heuristically.

How it works

How it works

1

The problem is written as a binary mathematical program with a linear objective c^T x, linear constraints Ax ≤ b, and binary decision variables x ∈ {0,1}^n. This is the full model with the integrality restriction kept. A relaxation, such as the LP relaxation obtained by replacing x ∈ {0,1}^n with 0 ≤ x ≤ 1, is often solved at this stage to obtain bounds, dual information, or a starting point. The formula shown here does not include that relaxed form.

Formula
\min_{x \in \mathcal{F}} c^\top x \quad \text{s.t.} \quad Ax \leq b, \; x \in \{0,1\}^n
2

A metaheuristic searches the feasible set F by evaluating candidates in a neighbourhood N(x_0) of a starting point x_0 and selecting the best candidate found. The starting point is a feasible solution, which may come from a constructive heuristic or from an earlier iteration. The neighbourhood must lie within the feasible set. The search is not guaranteed to reach the global optimum.

Formula
x^* \leftarrow \arg\min_{x \in \mathcal{N}(x_0)} f(x), \quad \mathcal{N}(x_0) \subseteq \mathcal{F}
3

The variables with indices in S are fixed to their values in the heuristic solution, which leaves a smaller problem over the remaining binary variables. This restricted model is solved exactly, so its result is optimal for the restricted problem. The restriction can exclude solutions that differ from the heuristic solution on the fixed variables. The choice of S is the main design decision. Common strategies fix whole groups of decisions that share a structure, such as all routes outside one region, all periods outside a chosen window, or the opening decisions for a subset of sites, and free the rest. As an illustration, in a facility location model with binary opening variables y_j and binary assignment variables x_ij, the heuristic may fix every y_j to its heuristic value and free only the assignment variables. The restricted model then decides only assignments to the facilities that are open. Fixing too many groups can exclude the optimum, while fixing too few can leave a subproblem that is too slow to solve.

Formula
\min c^\top x \quad \text{s.t.} \quad Ax \leq b, \; x_i = x^*_i \; \forall i \in S, \; x \in \{0,1\}^n
4

The objective values of the MIP refinement result and the heuristic solution are compared, and the one with the lower value is kept as the final solution. The formula shows this single comparison. The cycle can be repeated by passing the retained solution back to the heuristic phase. Both candidates should satisfy the original constraints: the MIP candidate does so because its constraints include all of Ax ≤ b, and the heuristic candidate does so because its neighbourhood lies within F. The objective value of the final solution is an upper bound on the optimum for a minimisation problem. The MIP phase is optimal only for the restricted subproblem, so the final result is not certified as optimal. To judge the benefit of the refinement, compare the final value with the heuristic value to measure the improvement. Where a lower bound is available, for example from an LP relaxation, report the remaining gap between the final value and that bound.

Formula
x^{\text{final}} \leftarrow \arg\min\{f(x^{\text{mip}}), f(x^{\text{heur}})\}

Common pitfalls

  • Fixing too many variables in the refinement step can make the restricted problem infeasible or exclude the global optimum. Fixing too few can make the exact solve too slow.
  • Running the heuristic without diversification tends to keep the search in one region of the feasible set, so the refinement step only polishes that region.
  • A solver time limit that is too tight in the refinement phase can return a weak result and reduce the benefit of the exact component.
  • If the heuristic's neighbourhood moves do not correspond to the variables in the MIP model, the two phases use different notions of nearby solutions and may not improve each other.

Frequently asked questions

How does a matheuristic differ from a pure metaheuristic?

A pure metaheuristic relies solely on heuristic moves and evaluations without any formal mathematical structure. A matheuristic embeds at least one exact mathematical programming component, such as an LP relaxation, a MIP sub-solver, or dual variable information, into the search loop. This allows it to use the algebraic structure of the problem, which can help on structured combinatorial instances.

Is matheuristics the same as hybrid metaheuristics?

Hybrid metaheuristics is a broader term covering any combination of two or more optimization strategies, including combinations of two metaheuristics. Matheuristics specifically require the integration of a mathematical programming (exact) component. All matheuristics are hybrid metaheuristics, but not all hybrid metaheuristics qualify as matheuristics in the usual matheuristic sense.

What size of problem benefits most from matheuristics?

Problems that are too large for an exact solver to finish in the available time, yet structured enough that a MIP sub-problem becomes quick to solve once part of the solution is fixed, are the most suitable. Small instances are usually better handled by an exact solver directly, and unstructured problems without a workable MIP model are better suited to pure metaheuristics. No universal size threshold is established, since suitability depends on the structure of the model and the solver.

Related methods

Sources

  1. Maniezzo, V., Stützle, T., & Voß, S. (Eds.). (2009). Matheuristics: Hybridizing Metaheuristics and Mathematical Programming. Springer.

    ISBN: 978-1-4419-1305-0