[Coin-discuss] Extracting the best solution in Cbc.
acw at ascent.com
acw at ascent.com
Tue Jan 17 17:07:26 EST 2006
(Apologies if this message is a duplication; this message bounced the
first time because I had not properly joined the mailing list.)
__________________
We are using a COIN/Cbc application that we created by making slight
modifications to the test example provided with Cbc.
What is the recommended way to extract the best feasible integer solution?
The documentation says to use CbcModel::bestSolution. We tried this, and
got bad (infeasible) results. The example application (in its
implementation of the SOLUTION command) uses CbcModel::getColSolution,
which is not documented. The documentation does mention
OsiSolverInterface::getColSolution, but this is deprecated (with somewhat
ambiguous language) in favor of CbcModel::bestSolution.
We decided to mimic the example, and tried the undocumented
CbcModel::getColSolution. This worked nicely with instances that ran to
completion, but when we added a time limit (with
CbcModel::setMaximumSeconds) the reported solution was again infeasible.
(CbcModel::branchAndBound did report finding several integer solutions in
the running time available.)
Thank you for your assistance. We are finding Cbc, overall, quite easy to
work with and adapt to our needs.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://list.coin-or.org/pipermail/coin-discuss/attachments/20060117/10e233fc/attachment.html>
More information about the Coin-discuss
mailing list