[Cbc] Simple c++ receip to mimic a command line

Patrik Dufresne ikus060 at gmail.com
Wed Oct 23 19:05:28 EDT 2013


Hi,

I've played alot with the CBC api via Java binding since the last time I
post on the mailing list. I've managed to accomplish most of what I need:
model the problem and solve it.

To model the problem, I'm creating a single instance of
OsiClpSolverInterface then I make multiple calls to addRow() and addCol().

To solve the problem, I'm making a call to CbcMain0() and CbcMain1(). While
this methods are doing almost all the work, I'm concerns about a change in
implementation breaking my stuff. Also, this magic methods does much more
than I want like. i.e.: printing stuff to console. Thus, I want to replace
the call to CbcMain1() to the real thing being a call to
OsiClpSolverInterface.initialSolve() and then to CbcModel.branchAndBound().
I've made the change and I get a complete different result in term of
performance.

This is the list of arguments I pass to CbcMain1()
"-heuristicsOnOff", "off", "-feasibilityPump", "on", "-cuts", "off",
"-logLevel", "0", "-slogLevel", "0", "-passF", "5", "-solve"

I had a look at the method source code. OMG this is a monster of 7283 lines
!!

1. Can someone describe me what CbcMain1() is doing more then a simple call
to OsiClpSolverInterface.initialSolve() and CbcModel.branchAndBound() ?

2. Is their any other low level method to solve the problem ?

The ultimate solution is to read this monster method and keep what I need.
Still, I have trouble to understand every line. Some are very cryptic and
refer to magic number.

--
Patrik Dufresne
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://list.coin-or.org/pipermail/cbc/attachments/20131023/9a6a3d79/attachment-0001.html>


More information about the Cbc mailing list