Try our new documentation site (beta).
Examples
Let's continue with a few examples of how these parameters would be used. Imagine that you are solving a MIP model with an optimal (minimization) objective of 100. Further imagine that, using default settings, the MIP solver finds four solutions to this model with objectives 100, 110, 120, and 130.
If you set the PoolSolutions
parameter to 3 and solve the model again, the MIP solver would discard
the worst solution and return with 3 solutions in the solution pool
(i.e., the SolCount attribute would have
value 3). If you instead set the
PoolGap parameter to value
0.2
, the MIP solver would discard any solutions whose objective
value is worse than 120 (which would also leave 3 solutions in the
solution pool).
If you set the PoolSearchMode
parameter to 2 and the
PoolSolutions parameter to 10,
the MIP solver would attempt to find the 10 best solutions to the
model. An OPTIMAL
return status would indicate that either (i)
it found the 10 best solutions, or (ii) it found all feasible
solutions to the model, and there were fewer than 10. If you also set
the PoolGap parameter to a value of
0.1, the MIP solver would try to find 10 solutions with objective no
worse than 110. While this may appear equivalent to asking for 10
solutions and simply ignoring those with objective worse than 110, the
solve will typically complete significantly faster with this parameter
set, since the solver does not have to expend effort looking for
solutions beyond the requested gap.