Overview | Group | Tree | Graph | Index | Concepts |
This is an advanced class. Advanced classes typically demand a profound understanding of the algorithms used by ILOG CPLEX. Thus they incur a higher risk of incorrect behavior in your application, behavior that can be difficult to debug. Therefore, ILOG encourages you to consider carefully whether you can accomplish the same task by means of other classes instead.
An instance of the class IloCplex::CutCallbackI
represents
a user-written callback in an application that uses an instance of
IloCplex
to solve a mixed integer
programming problem (a MIP). This class offers a method to add a
local or global cut to the current node LP subproblem
from a user-written callback. More than one cut
can be added in this callback by calling the method add
or
addLocal
multiple times. All added cuts must be linear.
The constructor and methods of this class are protected for use
in deriving a user-written callback class and in implementing the
main
method there.
If an attempt is made to access information not available to an instance of this class, an exception is thrown.
See Also:
IloCplex, IloCplex::Callback, IloCplex::CallbackI, IloCplex::MIPCallbackI, IloCplex::ControlCallbackI, IloCplex::OptimizationCallbackI, ILOCUTCALLBACK0
Constructor Summary | |
---|---|
protected | CutCallbackI(IloEnv env) |
Method Summary | |
---|---|
protected IloConstraint | add(IloConstraint con) |
protected IloConstraint | addLocal(IloConstraint con) |
Inherited Methods from MIPCallbackI |
---|
getNcliques, getNcovers, getNdisjunctiveCuts, getNflowCovers, getNflowPaths, getNfractionalCuts, getNGUBcovers, getNimpliedBounds, getNMIRs, getObjCoef, getObjCoef, getObjCoefs, getObjCoefs, getUserThreads |
Inherited Methods from OptimizationCallbackI |
---|
getModel, getNcols, getNQCs, getNrows |
Inherited Methods from CallbackI |
---|
abort, duplicateCallback, getEnv, main |
Constructor Detail |
---|
This constructor creates a callback for use in an application with a user-defined cut to solve a MIP.
Method Detail |
---|
This method adds a cut to the current node LP subproblem
for the constraint specified by
con
. This cut must be globally valid; it will not be
removed by backtracking or any other means during the search. The added
cut must be linear.
This method adds a local cut to the current node LP subproblem
for the constraint specified by
con
. IloCplex
will manage the local cut in
such a way that it will be active only when processing nodes of this
subtree. The added cut must be linear.