[Cbc] Equivalence between command line and API

Alexis aguigue at softree.com
Thu Aug 8 19:20:01 EDT 2013


Hi,

Now, in my code, I have

     CbcMain0(cbcModel);
     const char * argv2[]={"cbc","-presolve", "off","-preprocess", 
"off","-solve","-quit"};
     CbcMain1(7,argv2,cbcModel);

so I am disabling presolve and preprocess.

How can do you this using CbcModel and OsiClpSolverInterface objects? 
This is what I have tried

     ClpSolve options;
     options.setPresolveType(ClpSolve::presolveOff);
     myOsiClpSolverInterface.setSolveOptions(options);

     CbcModel myCbcModel(m_myOsiClpSolverInterface);

     myCbcModel.initialSolve();

     myCbcModel.branchAndBound();

I believe that does the job to prevent presolve but what about 
preventing preprocessing?

Thanks

-- 
Alexis Guigue, E.I.T., B.Eng., M.A.Sc., Ph.D.
Software Engineer/Research Engineer
aguigue at softree.com
604-519-6222, ext. 3

Softree Technical Systems Inc.
Engineering an Easier Way
www.softree.com



More information about the Cbc mailing list