[Coin-discuss] OsiClp proper use of initialSolve and resolve, setObjective

Sebastian Nowozin nowozin at gmail.com
Thu May 22 14:31:54 EDT 2008


Hello everybody,

I am using Osi 0.98.2 and OsiClpSolverInterface to perform parametric 
programming on a LP relaxation of a combinatorial optimization problem. 
  In the outer parametric programming iterations I slightly change the 
objective coefficients and perform an inner loop which solves the LP and 
adds cutting planes and removes inactive constraints.  I hope to be able 
to recycle most active constraints in the next inner iteration.

The call order is:

1. OsiClpSolverInterface* si = new OsiClpSolverInterface();
2. si->loadProblem(...)
Parametric Programming iterations:
   3. si->setObjective(...)
   Solving specific instance by cutting planes
      4. si->resolve();
      5. assert(si->isProvenOptimal())
      6. assert(si->getColSolution() != NULL);
      7. (Solving a set of separation problems and adding constraints)
      8. (Optimality check and either exiting the loop to 3. or go to 4.)

The first main iteration succeeds (cutting planes are added and 3. is 
reached a second time.  Then, the call to si->resolve() succeeds, 5. is 
passed but surprisingly, 6. fails and si->getColSolution() returns NULL.

Is the above logic a proper usage of OsiClpSolverInterface?

Also, is it better to enable factorization and use 
si->setObjectiveAndRefresh() if I want to make the inner iterations 
warm-start from the previous solution?

Another detail question: all textbooks I have only deal with the 
standard LP formulation min_x c'x, sb.t. Ax=b, x>=0.  However, Clp 
provides reduced costs also for constraints of the form Ax<=b.  The 
reduced cost are sometimes negative, wereas the plain LP optimality 
conditions for Ax=b type constraints state \bar{c} >= 0.  Where (in 
which LP book) can I find the generalized definition of "reduced costs" 
as Clp uses them?

Thanks,
Sebastian



More information about the Coin-discuss mailing list