Dip
0.92.4
|
Simple Branch and bound class. More...
#include <CbcModel.hpp>
Public Member Functions | |
void | setMIPStart (const std::vector< std::pair< std::string, double > > &mips) |
void | setKeepNamesPreproc (bool _keep) |
if original column names will be preserved in preprocessed problem More... | |
bool | getKeepNamesPreproc () const |
void | setMIPStart (int count, const char **colNames, const double colValues[]) |
may be safer to use this overload method: c++ string libraries implementation may not be binary compatible More... | |
const std::vector< std::pair < std::string, double > > & | getMIPStart () |
Presolve methods | |
CbcModel * | findCliques (bool makeEquality, int atLeastThisMany, int lessThanThis, int defaultValue=1000) |
Identify cliques and construct corresponding objects. More... | |
CbcModel * | integerPresolve (bool weak=false) |
Do integer presolve, creating a new (presolved) model. More... | |
bool | integerPresolveThisModel (OsiSolverInterface *originalSolver, bool weak=false) |
Do integer presolve, modifying the current model. More... | |
void | originalModel (CbcModel *presolvedModel, bool weak) |
Put back information into the original model after integer presolve. More... | |
bool | tightenVubs (int type, bool allowMultipleBinary=false, double useCutoff=1.0e50) |
For variables involved in VUB constraints, see if we can tighten bounds by solving lp's. More... | |
bool | tightenVubs (int numberVubs, const int *which, double useCutoff=1.0e50) |
For variables involved in VUB constraints, see if we can tighten bounds by solving lp's. More... | |
void | analyzeObjective () |
Analyze problem to find a minimum change in the objective function. More... | |
const OsiSolverInterface * | postProcessedSolver (int solutionType=1) |
Returns postProcessed solution in solver(called from event handler) Normally used for integer solution (not really tested otherwise) solutionType 1 is best integer so far, 0 is current solution (may not be integer) More... | |
void | AddIntegers () |
Add additional integers. More... | |
void | saveModel (OsiSolverInterface *saveSolver, double *checkCutoffForRestart, bool *feasible) |
Save copy of the model. More... | |
void | flipModel () |
Flip direction of optimization on all models. More... | |
int | cleanBounds (OsiSolverInterface *solver, char *cleanVariables) |
Clean model i.e. More... | |
char * | setupCleanVariables () |
Sets up cleanVariables array (i.e. ones to be careful about) More... | |
Object manipulation routines | |
int | numberObjects () const |
Get the number of objects. More... | |
void | setNumberObjects (int number) |
Set the number of objects. More... | |
OsiObject ** | objects () const |
Get the array of objects. More... | |
const OsiObject * | object (int which) const |
Get the specified object. More... | |
OsiObject * | modifiableObject (int which) const |
Get the specified object. More... | |
void | setOptionalInteger (int index) |
Get the number of objects. More... | |
void | deleteObjects (bool findIntegers=true) |
Delete all object information (and just back to integers if true) More... | |
void | addObjects (int numberObjects, OsiObject **objects) |
Add in object information. More... | |
void | addObjects (int numberObjects, CbcObject **objects) |
Add in object information. More... | |
void | synchronizeModel () |
Ensure attached objects point to this model. More... | |
void | findIntegers (bool startAgain, int type=0) |
Identify integer variables and create corresponding objects. More... | |
void | addSOSEtcToSolver () |
Add SOS info to solver - Overwrites SOS information in solver with information in CbcModel. More... | |
Parameter set/get methods | |
The set methods return true if the parameter was set to the given value, false if the value of the parameter is out of range. The get methods return the value of the parameter. | |
bool | setIntParam (CbcIntParam key, int value) |
Set an integer parameter. More... | |
bool | setDblParam (CbcDblParam key, double value) |
Set a double parameter. More... | |
int | getIntParam (CbcIntParam key) const |
Get an integer parameter. More... | |
double | getDblParam (CbcDblParam key) const |
Get a double parameter. More... | |
void | setCutoff (double value) |
Set cutoff bound on the objective function. More... | |
double | getCutoff () const |
Get the cutoff bound on the objective function - always as minimize. More... | |
bool | setMaximumNodes (int value) |
Set the maximum node limit . More... | |
int | getMaximumNodes () const |
Get the maximum node limit . More... | |
bool | setMaximumSolutions (int value) |
Set the maximum number of solutions desired. More... | |
int | getMaximumSolutions () const |
Get the maximum number of solutions desired. More... | |
bool | setPrintingMode (int value) |
Set the printing mode. More... | |
int | getPrintingMode () const |
Get the printing mode. More... | |
bool | setMaximumSeconds (double value) |
Set the maximum number of seconds desired. More... | |
double | getMaximumSeconds () const |
Get the maximum number of seconds desired. More... | |
double | getCurrentSeconds () const |
Current time since start of branchAndbound. More... | |
bool | maximumSecondsReached () const |
Return true if maximum time reached. More... | |
bool | setIntegerTolerance (double value) |
Set the integrality tolerance . More... | |
double | getIntegerTolerance () const |
Get the integrality tolerance . More... | |
bool | setInfeasibilityWeight (double value) |
Set the weight per integer infeasibility . More... | |
double | getInfeasibilityWeight () const |
Get the weight per integer infeasibility . More... | |
bool | setAllowableGap (double value) |
Set the allowable gap between the best known solution and the best possible solution. More... | |
double | getAllowableGap () const |
Get the allowable gap between the best known solution and the best possible solution. More... | |
bool | setAllowableFractionGap (double value) |
Set the fraction allowable gap between the best known solution and the best possible solution. More... | |
double | getAllowableFractionGap () const |
Get the fraction allowable gap between the best known solution and the best possible solution. More... | |
bool | setAllowablePercentageGap (double value) |
Set the percentage allowable gap between the best known solution and the best possible solution. More... | |
double | getAllowablePercentageGap () const |
Get the percentage allowable gap between the best known solution and the best possible solution. More... | |
bool | setHeuristicGap (double value) |
Set the heuristic gap between the best known solution and the best possible solution. More... | |
double | getHeuristicGap () const |
Get the heuristic gap between the best known solution and the best possible solution. More... | |
bool | setHeuristicFractionGap (double value) |
Set the fraction heuristic gap between the best known solution and the best possible solution. More... | |
double | getHeuristicFractionGap () const |
Get the fraction heuristic gap between the best known solution and the best possible solution. More... | |
bool | setCutoffIncrement (double value) |
Set the CbcModel::CbcCutoffIncrement desired. More... | |
double | getCutoffIncrement () const |
Get the CbcModel::CbcCutoffIncrement desired. More... | |
bool | canStopOnGap () const |
See if can stop on gap. More... | |
void | setHotstartSolution (const double *solution, const int *priorities=NULL) |
Pass in target solution and optional priorities. More... | |
void | setMinimumDrop (double value) |
Set the minimum drop to continue cuts. More... | |
double | getMinimumDrop () const |
Get the minimum drop to continue cuts. More... | |
void | setMaximumCutPassesAtRoot (int value) |
Set the maximum number of cut passes at root node (default 20) Minimum drop can also be used for fine tuning. More... | |
int | getMaximumCutPassesAtRoot () const |
Get the maximum number of cut passes at root node. More... | |
void | setMaximumCutPasses (int value) |
Set the maximum number of cut passes at other nodes (default 10) Minimum drop can also be used for fine tuning. More... | |
int | getMaximumCutPasses () const |
Get the maximum number of cut passes at other nodes (default 10) More... | |
int | getCurrentPassNumber () const |
Get current cut pass number in this round of cuts. More... | |
void | setCurrentPassNumber (int value) |
Set current cut pass number in this round of cuts. More... | |
void | setNumberStrong (int number) |
Set the maximum number of candidates to be evaluated for strong branching. More... | |
int | numberStrong () const |
Get the maximum number of candidates to be evaluated for strong branching. More... | |
void | setPreferredWay (int value) |
Set global preferred way to branch -1 down, +1 up, 0 no preference. More... | |
int | getPreferredWay () const |
Get the preferred way to branch (default 0) More... | |
int | whenCuts () const |
Get at which depths to do cuts. More... | |
void | setWhenCuts (int value) |
Set at which depths to do cuts. More... | |
bool | doCutsNow (int allowForTopOfTree) const |
Return true if we want to do cuts If allowForTopOfTree zero then just does on multiples of depth if 1 then allows for doing at top of tree if 2 then says if cuts allowed anywhere apart from root. More... | |
void | setNumberBeforeTrust (int number) |
Set the number of branches before pseudo costs believed in dynamic strong branching. More... | |
int | numberBeforeTrust () const |
get the number of branches before pseudo costs believed in dynamic strong branching. More... | |
void | setNumberPenalties (int number) |
Set the number of variables for which to compute penalties in dynamic strong branching. More... | |
int | numberPenalties () const |
get the number of variables for which to compute penalties in dynamic strong branching. More... | |
const CbcFullNodeInfo * | topOfTree () const |
Pointer to top of tree. More... | |
void | setNumberAnalyzeIterations (int number) |
Number of analyze iterations to do. More... | |
int | numberAnalyzeIterations () const |
Set an integer parameter. More... | |
double | penaltyScaleFactor () const |
Get scale factor to make penalties match strong. More... | |
void | setPenaltyScaleFactor (double value) |
Set scale factor to make penalties match strong. More... | |
void | setProblemType (int number) |
Problem type as set by user or found by analysis. More... | |
int | problemType () const |
Set an integer parameter. More... | |
int | currentDepth () const |
Current depth. More... | |
void | setHowOftenGlobalScan (int number) |
Set how often to scan global cuts. More... | |
int | howOftenGlobalScan () const |
Get how often to scan global cuts. More... | |
int * | originalColumns () const |
Original columns as created by integerPresolve or preprocessing. More... | |
void | setOriginalColumns (const int *originalColumns, int numberGood=COIN_INT_MAX) |
Set original columns as created by preprocessing. More... | |
OsiRowCut * | conflictCut (const OsiSolverInterface *solver, bool &localCuts) |
Create conflict cut (well - most of) More... | |
void | setPrintFrequency (int number) |
Set the print frequency. More... | |
int | printFrequency () const |
Get the print frequency. More... | |
Methods returning info on how the solution process terminated | |
bool | isAbandoned () const |
Are there a numerical difficulties? More... | |
bool | isProvenOptimal () const |
Is optimality proven? More... | |
bool | isProvenInfeasible () const |
Is infeasiblity proven (or none better than cutoff)? More... | |
bool | isContinuousUnbounded () const |
Was continuous solution unbounded. More... | |
bool | isProvenDualInfeasible () const |
Was continuous solution unbounded. More... | |
bool | isNodeLimitReached () const |
Node limit reached? More... | |
bool | isSecondsLimitReached () const |
Time limit reached? More... | |
bool | isSolutionLimitReached () const |
Solution limit reached? More... | |
int | getIterationCount () const |
Get how many iterations it took to solve the problem. More... | |
void | incrementIterationCount (int value) |
Increment how many iterations it took to solve the problem. More... | |
int | getNodeCount () const |
Get how many Nodes it took to solve the problem (including those in complete fathoming B&B inside CLP). More... | |
void | incrementNodeCount (int value) |
Increment how many nodes it took to solve the problem. More... | |
int | getExtraNodeCount () const |
Get how many Nodes were enumerated in complete fathoming B&B inside CLP. More... | |
int | getFathomCount () const |
Get how many times complete fathoming B&B was done. More... | |
int | status () const |
Final status of problem Some of these can be found out by is...... More... | |
void | setProblemStatus (int value) |
Are there a numerical difficulties? More... | |
int | secondaryStatus () const |
Secondary status of problem -1 unset (status_ will also be -1) 0 search completed with solution 1 linear relaxation not feasible (or worse than cutoff) 2 stopped on gap 3 stopped on nodes 4 stopped on time 5 stopped on user event 6 stopped on solutions 7 linear relaxation unbounded 8 stopped on iteration limit. More... | |
void | setSecondaryStatus (int value) |
Are there a numerical difficulties? More... | |
bool | isInitialSolveAbandoned () const |
Are there numerical difficulties (for initialSolve) ? More... | |
bool | isInitialSolveProvenOptimal () const |
Is optimality proven (for initialSolve) ? More... | |
bool | isInitialSolveProvenPrimalInfeasible () const |
Is primal infeasiblity proven (for initialSolve) ? More... | |
bool | isInitialSolveProvenDualInfeasible () const |
Is dual infeasiblity proven (for initialSolve) ? More... | |
Problem information methods | |
These methods call the solver's query routines to return information about the problem referred to by the current object. Querying a problem that has no data associated with it result in zeros for the number of rows and columns, and NULL pointers from the methods that return vectors. Const pointers returned from any data-query method are valid as long as the data is unchanged and the solver is not called. | |
int | numberRowsAtContinuous () const |
Number of rows in continuous (root) problem. More... | |
int | getNumCols () const |
Get number of columns. More... | |
int | getNumRows () const |
Get number of rows. More... | |
CoinBigIndex | getNumElements () const |
Get number of nonzero elements. More... | |
int | numberIntegers () const |
Number of integers in problem. More... | |
const int * | integerVariable () const |
Number of rows in continuous (root) problem. More... | |
char | integerType (int i) const |
Whether or not integer. More... | |
const char * | integerType () const |
Whether or not integer. More... | |
const double * | getColLower () const |
Get pointer to array[getNumCols()] of column lower bounds. More... | |
const double * | getColUpper () const |
Get pointer to array[getNumCols()] of column upper bounds. More... | |
const char * | getRowSense () const |
Get pointer to array[getNumRows()] of row constraint senses. More... | |
const double * | getRightHandSide () const |
Get pointer to array[getNumRows()] of rows right-hand sides. More... | |
const double * | getRowRange () const |
Get pointer to array[getNumRows()] of row ranges. More... | |
const double * | getRowLower () const |
Get pointer to array[getNumRows()] of row lower bounds. More... | |
const double * | getRowUpper () const |
Get pointer to array[getNumRows()] of row upper bounds. More... | |
const double * | getObjCoefficients () const |
Get pointer to array[getNumCols()] of objective function coefficients. More... | |
double | getObjSense () const |
Get objective function sense (1 for min (default), -1 for max) More... | |
bool | isContinuous (int colIndex) const |
Return true if variable is continuous. More... | |
bool | isBinary (int colIndex) const |
Return true if variable is binary. More... | |
bool | isInteger (int colIndex) const |
Return true if column is integer. More... | |
bool | isIntegerNonBinary (int colIndex) const |
Return true if variable is general integer. More... | |
bool | isFreeBinary (int colIndex) const |
Return true if variable is binary and not fixed at either bound. More... | |
const CoinPackedMatrix * | getMatrixByRow () const |
Get pointer to row-wise copy of matrix. More... | |
const CoinPackedMatrix * | getMatrixByCol () const |
Get pointer to column-wise copy of matrix. More... | |
double | getInfinity () const |
Get solver's value for infinity. More... | |
const double * | getCbcColLower () const |
Get pointer to array[getNumCols()] (for speed) of column lower bounds. More... | |
const double * | getCbcColUpper () const |
Get pointer to array[getNumCols()] (for speed) of column upper bounds. More... | |
const double * | getCbcRowLower () const |
Get pointer to array[getNumRows()] (for speed) of row lower bounds. More... | |
const double * | getCbcRowUpper () const |
Get pointer to array[getNumRows()] (for speed) of row upper bounds. More... | |
const double * | getCbcColSolution () const |
Get pointer to array[getNumCols()] (for speed) of primal solution vector. More... | |
const double * | getCbcRowPrice () const |
Get pointer to array[getNumRows()] (for speed) of dual prices. More... | |
const double * | getCbcReducedCost () const |
Get a pointer to array[getNumCols()] (for speed) of reduced costs. More... | |
const double * | getCbcRowActivity () const |
Get pointer to array[getNumRows()] (for speed) of row activity levels. More... | |
Methods related to querying the solution | |
double * | continuousSolution () const |
Holds solution at continuous (after cuts if branchAndBound called) More... | |
int * | usedInSolution () const |
Array marked whenever a solution is found if non-zero. More... | |
void | incrementUsed (const double *solution) |
Increases usedInSolution for nonzeros. More... | |
void | setBestSolution (CBC_Message how, double &objectiveValue, const double *solution, int fixVariables=0) |
Record a new incumbent solution and update objectiveValue. More... | |
void | setBestObjectiveValue (double objectiveValue) |
Just update objectiveValue. More... | |
CbcEventHandler::CbcAction | dealWithEventHandler (CbcEventHandler::CbcEvent event, double objValue, const double *solution) |
Deals with event handler and solution. More... | |
virtual double | checkSolution (double cutoff, double *solution, int fixVariables, double originalObjValue) |
Call this to really test if a valid solution can be feasible Solution is number columns in size. More... | |
bool | feasibleSolution (int &numberIntegerInfeasibilities, int &numberObjectInfeasibilities) const |
Test the current solution for feasiblility. More... | |
double * | currentSolution () const |
Solution to the most recent lp relaxation. More... | |
const double * | testSolution () const |
For testing infeasibilities - will point to currentSolution_ or solver–>getColSolution() More... | |
void | setTestSolution (const double *solution) |
Holds solution at continuous (after cuts if branchAndBound called) More... | |
void | reserveCurrentSolution (const double *solution=NULL) |
Make sure region there and optionally copy solution. More... | |
const double * | getColSolution () const |
Get pointer to array[getNumCols()] of primal solution vector. More... | |
const double * | getRowPrice () const |
Get pointer to array[getNumRows()] of dual prices. More... | |
const double * | getReducedCost () const |
Get a pointer to array[getNumCols()] of reduced costs. More... | |
const double * | getRowActivity () const |
Get pointer to array[getNumRows()] of row activity levels. More... | |
double | getCurrentObjValue () const |
Get current objective function value. More... | |
double | getCurrentMinimizationObjValue () const |
Get current minimization objective function value. More... | |
double | getMinimizationObjValue () const |
Get best objective function value as minimization. More... | |
void | setMinimizationObjValue (double value) |
Set best objective function value as minimization. More... | |
double | getObjValue () const |
Get best objective function value. More... | |
double | getBestPossibleObjValue () const |
Get best possible objective function value. More... | |
void | setObjValue (double value) |
Set best objective function value. More... | |
double | getSolverObjValue () const |
Get solver objective function value (as minimization) More... | |
double * | bestSolution () const |
The best solution to the integer programming problem. More... | |
void | setBestSolution (const double *solution, int numberColumns, double objectiveValue, bool check=false) |
User callable setBestSolution. More... | |
int | getSolutionCount () const |
Get number of solutions. More... | |
void | setSolutionCount (int value) |
Set number of solutions (so heuristics will be different) More... | |
int | numberSavedSolutions () const |
Number of saved solutions (including best) More... | |
int | maximumSavedSolutions () const |
Maximum number of extra saved solutions. More... | |
void | setMaximumSavedSolutions (int value) |
Set maximum number of extra saved solutions. More... | |
const double * | savedSolution (int which) const |
Return a saved solution (0==best) - NULL if off end. More... | |
double | savedSolutionObjective (int which) const |
Return a saved solution objective (0==best) - COIN_DBL_MAX if off end. More... | |
void | deleteSavedSolution (int which) |
Delete a saved solution and move others up. More... | |
int | phase () const |
Current phase (so heuristics etc etc can find out). More... | |
int | getNumberHeuristicSolutions () const |
Get number of heuristic solutions. More... | |
void | setNumberHeuristicSolutions (int value) |
Set number of heuristic solutions. More... | |
void | setObjSense (double s) |
Set objective function sense (1 for min (default), -1 for max,) More... | |
double | getContinuousObjective () const |
Value of objective at continuous. More... | |
void | setContinuousObjective (double value) |
Holds solution at continuous (after cuts if branchAndBound called) More... | |
int | getContinuousInfeasibilities () const |
Number of infeasibilities at continuous. More... | |
void | setContinuousInfeasibilities (int value) |
Holds solution at continuous (after cuts if branchAndBound called) More... | |
double | rootObjectiveAfterCuts () const |
Value of objective after root node cuts added. More... | |
double | sumChangeObjective () const |
Sum of Changes to objective by first solve. More... | |
int | numberGlobalViolations () const |
Number of times global cuts violated. More... | |
void | clearNumberGlobalViolations () |
Holds solution at continuous (after cuts if branchAndBound called) More... | |
bool | resolveAfterTakeOffCuts () const |
Whether to force a resolve after takeOffCuts. More... | |
void | setResolveAfterTakeOffCuts (bool yesNo) |
Holds solution at continuous (after cuts if branchAndBound called) More... | |
int | maximumRows () const |
Maximum number of rows. More... | |
CoinWarmStartBasis & | workingBasis () |
Work basis for temporary use. More... | |
int | getStopNumberIterations () const |
Get number of "iterations" to stop after. More... | |
void | setStopNumberIterations (int value) |
Set number of "iterations" to stop after. More... | |
CbcModel * | heuristicModel () const |
A pointer to model from CbcHeuristic. More... | |
void | setHeuristicModel (CbcModel *model) |
Set a pointer to model from CbcHeuristic. More... | |
Node selection | |
CbcCompareBase * | nodeComparison () const |
void | setNodeComparison (CbcCompareBase *compare) |
void | setNodeComparison (CbcCompareBase &compare) |
Problem feasibility checking | |
CbcFeasibilityBase * | problemFeasibility () const |
void | setProblemFeasibility (CbcFeasibilityBase *feasibility) |
void | setProblemFeasibility (CbcFeasibilityBase &feasibility) |
Tree methods and subtree methods | |
CbcTree * | tree () const |
Tree method e.g. heap (which may be overridden by inheritance) More... | |
void | passInTreeHandler (CbcTree &tree) |
For modifying tree handling (original is cloned) More... | |
void | passInSubTreeModel (CbcModel &model) |
For passing in an CbcModel to do a sub Tree (with derived tree handlers). More... | |
CbcModel * | subTreeModel (OsiSolverInterface *solver=NULL) const |
For retrieving a copy of subtree model with given OsiSolver. More... | |
int | numberStoppedSubTrees () const |
Returns number of times any subtree stopped on nodes, time etc. More... | |
void | incrementSubTreeStopped () |
Says a sub tree was stopped. More... | |
int | typePresolve () const |
Whether to automatically do presolve before branch and bound (subTrees). More... | |
void | setTypePresolve (int value) |
Tree method e.g. heap (which may be overridden by inheritance) More... | |
Branching Decisions | |
See the CbcBranchDecision class for additional information. | |
CbcBranchDecision * | branchingMethod () const |
Get the current branching decision method. More... | |
void | setBranchingMethod (CbcBranchDecision *method) |
Set the branching decision method. More... | |
void | setBranchingMethod (CbcBranchDecision &method) |
Set the branching method. More... | |
CbcCutModifier * | cutModifier () const |
Get the current cut modifier method. More... | |
void | setCutModifier (CbcCutModifier *modifier) |
Set the cut modifier method. More... | |
void | setCutModifier (CbcCutModifier &modifier) |
Set the cut modifier method. More... | |
Row (constraint) and Column (variable) cut generation | |
int | stateOfSearch () const |
State of search 0 - no solution 1 - only heuristic solutions 2 - branched to a solution 3 - no solution but many nodes. More... | |
void | setStateOfSearch (int state) |
State of search 0 - no solution 1 - only heuristic solutions 2 - branched to a solution 3 - no solution but many nodes. More... | |
int | searchStrategy () const |
Strategy worked out - mainly at root node for use by CbcNode. More... | |
void | setSearchStrategy (int value) |
Set strategy worked out - mainly at root node for use by CbcNode. More... | |
int | strongStrategy () const |
Stong branching strategy. More... | |
void | setStrongStrategy (int value) |
Set strong branching strategy. More... | |
int | numberCutGenerators () const |
Get the number of cut generators. More... | |
CbcCutGenerator ** | cutGenerators () const |
Get the list of cut generators. More... | |
CbcCutGenerator * | cutGenerator (int i) const |
Get the specified cut generator. More... | |
CbcCutGenerator * | virginCutGenerator (int i) const |
Get the specified cut generator before any changes. More... | |
void | addCutGenerator (CglCutGenerator *generator, int howOften=1, const char *name=NULL, bool normal=true, bool atSolution=false, bool infeasible=false, int howOftenInSub=-100, int whatDepth=-1, int whatDepthInSub=-1) |
Add one generator - up to user to delete generators. More... | |
Strategy and sub models | |
See the CbcStrategy class for additional information. | |
CbcStrategy * | strategy () const |
Get the current strategy. More... | |
void | setStrategy (CbcStrategy &strategy) |
Set the strategy. Clones. More... | |
void | setStrategy (CbcStrategy *strategy) |
Set the strategy. assigns. More... | |
CbcModel * | parentModel () const |
Get the current parent model. More... | |
void | setParentModel (CbcModel &parentModel) |
Set the parent model. More... | |
Heuristics and priorities | |
void | addHeuristic (CbcHeuristic *generator, const char *name=NULL, int before=-1) |
Add one heuristic - up to user to delete. More... | |
CbcHeuristic * | heuristic (int i) const |
Get the specified heuristic. More... | |
int | numberHeuristics () const |
Get the number of heuristics. More... | |
void | setNumberHeuristics (int value) |
Set the number of heuristics. More... | |
CbcHeuristic * | lastHeuristic () const |
Pointer to heuristic solver which found last solution (or NULL) More... | |
void | setLastHeuristic (CbcHeuristic *last) |
set last heuristic which found a solution More... | |
void | passInPriorities (const int *priorities, bool ifNotSimpleIntegers) |
Pass in branching priorities. More... | |
int | priority (int sequence) const |
Returns priority level for an object (or 1000 if no priorities exist) More... | |
void | passInEventHandler (const CbcEventHandler *eventHandler) |
Set an event handler. More... | |
CbcEventHandler * | getEventHandler () const |
Retrieve a pointer to the event handler. More... | |
Setting/Accessing application data | |
void | setApplicationData (void *appData) |
Set application data. More... | |
void * | getApplicationData () const |
Get application data. More... | |
void | passInSolverCharacteristics (OsiBabSolver *solverCharacteristics) |
For advanced applications you may wish to modify the behavior of Cbc e.g. More... | |
const OsiBabSolver * | solverCharacteristics () const |
Get solver characteristics. More... | |
Message handling etc | |
void | passInMessageHandler (CoinMessageHandler *handler) |
Pass in Message handler (not deleted at end) More... | |
void | newLanguage (CoinMessages::Language language) |
Set language. More... | |
void | setLanguage (CoinMessages::Language language) |
Pass in Message handler (not deleted at end) More... | |
CoinMessageHandler * | messageHandler () const |
Return handler. More... | |
CoinMessages & | messages () |
Return messages. More... | |
CoinMessages * | messagesPointer () |
Return pointer to messages. More... | |
void | setLogLevel (int value) |
Set log level. More... | |
int | logLevel () const |
Get log level. More... | |
void | setDefaultHandler (bool yesNo) |
Set flag to say if handler_ is the default handler. More... | |
bool | defaultHandler () const |
Check default handler. More... | |
Specialized | |
void | setSpecialOptions (int value) |
Set special options 0 bit (1) - check if cuts valid (if on debugger list) 1 bit (2) - use current basis to check integer solution (rather than all slack) 2 bit (4) - don't check integer solution (by solving LP) 3 bit (8) - fast analyze 4 bit (16) - non-linear model - so no well defined CoinPackedMatrix 5 bit (32) - keep names 6 bit (64) - try for dominated columns 7 bit (128) - SOS type 1 but all declared integer 8 bit (256) - Set to say solution just found, unset by doing cuts 9 bit (512) - Try reduced model after 100 nodes 10 bit (1024) - Switch on some heuristics even if seems unlikely 11 bit (2048) - Mark as in small branch and bound 12 bit (4096) - Funny cuts so do slow way (in some places) 13 bit (8192) - Funny cuts so do slow way (in other places) 14 bit (16384) - Use Cplex! for fathoming 15 bit (32768) - Try reduced model after 0 nodes 16 bit (65536) - Original model had integer bounds 17 bit (131072) - Perturbation switched off 18 bit (262144) - donor CbcModel 19 bit (524288) - recipient CbcModel 20 bit (1048576) - waiting for sub model to return 22 bit (4194304) - do not initialize random seed in solver (user has) 23 bit (8388608) - leave solver_ with cuts 24 bit (16777216) - just get feasible if no cutoff 25 bit (33554432) - feasibility pump after root cuts 26 bit (67108864) - child model but going for complete search More... | |
int | specialOptions () const |
Get special options. More... | |
void | setRandomSeed (int value) |
Set random seed. More... | |
int | getRandomSeed () const |
Get random seed. More... | |
void | setMultipleRootTries (int value) |
Set multiple root tries. More... | |
int | getMultipleRootTries () const |
Get multiple root tries. More... | |
void | sayEventHappened () |
Tell model to stop on event. More... | |
bool | normalSolver () const |
Says if normal solver i.e. has well defined CoinPackedMatrix. More... | |
bool | waitingForMiniBranchAndBound () const |
Says if model is sitting there waiting for mini branch and bound to finish This is because an event handler may only have access to parent model in mini branch and bound. More... | |
void | setMoreSpecialOptions (int value) |
Set more special options at present bottom 6 bits used for shadow price mode 1024 for experimental hotstart 2048,4096 breaking out of cuts 8192 slowly increase minimum drop 16384 gomory 32768 more heuristics in sub trees 65536 no cuts in preprocessing 131072 Time limits elapsed 18 bit (262144) - Perturb fathom nodes 19 bit (524288) - No limit on fathom nodes 20 bit (1048576) - Reduce sum of infeasibilities before cuts 21 bit (2097152) - Reduce sum of infeasibilities after cuts 22 bit (4194304) - Conflict analysis 23 bit (8388608) - Conflict analysis - temporary bit 24 bit (16777216) - Add cutoff as LP constraint (out) 25 bit (33554432) - diving/reordering 26 bit (67108864) - load global cuts from file 27 bit (134217728) - append binding global cuts to file 28 bit (268435456) - idiot branching 29 bit (536870912) - don't make fake objective 30 bit (1073741824) - Funny SOS or similar - be careful. More... | |
int | moreSpecialOptions () const |
Get more special options. More... | |
void | setMoreSpecialOptions2 (int value) |
Set more more special options 0 bit (1) - find switching variables 1 bit (2) - using fake objective until solution 2 bit (4) - switching variables exist 3 bit (8) - skip most of setBestSolution checks 4 bit (16) - very lightweight preprocessing in smallB&B 5 bit (32) - event handler needs to be cloned when parallel 6 bit (64) - testing - use probing to make cliques 7/8 bit (128) - try orbital branching (if nauty) 9 bit (512) - branching on objective (later) 10 bit (1024) - branching on constraints (later) 11/12 bit 2048 - intermittent cuts 13/14 bit 8192 - go to bitter end in strong branching (first time) 15 bit 32768 - take care of very very small values for Integer/SOS variables. More... | |
int | moreSpecialOptions2 () const |
Get more special options2. More... | |
void | setCutoffAsConstraint (bool yesNo) |
Set cutoff as constraint. More... | |
void | setUseElapsedTime (bool yesNo) |
Set time method. More... | |
bool | useElapsedTime () const |
Get time method. More... | |
void * | temporaryPointer () const |
Get useful temporary pointer. More... | |
void | setTemporaryPointer (void *pointer) |
Set useful temporary pointer. More... | |
void | goToDantzig (int numberNodes, ClpDualRowPivot *&savePivotMethod) |
Go to dantzig pivot selection if easy problem (clp only) More... | |
bool | ownObjects () const |
Now we may not own objects - just point to solver's objects. More... | |
void | checkModel () |
Check original model before it gets messed up. More... | |
Constructors and destructors etc | |
CbcModel () | |
Default Constructor. More... | |
CbcModel (const OsiSolverInterface &) | |
Constructor from solver. More... | |
void | assignSolver (OsiSolverInterface *&solver, bool deleteSolver=true) |
Assign a solver to the model (model assumes ownership) More... | |
void | setModelOwnsSolver (bool ourSolver) |
Set ownership of solver. More... | |
bool | modelOwnsSolver () |
Get ownership of solver. More... | |
CbcModel (const CbcModel &rhs, bool cloneHandler=false) | |
Copy constructor . More... | |
virtual CbcModel * | clone (bool cloneHandler) |
Clone. More... | |
CbcModel & | operator= (const CbcModel &rhs) |
Assignment operator. More... | |
virtual | ~CbcModel () |
Destructor. More... | |
OsiSolverInterface * | solver () const |
Returns solver - has current state. More... | |
OsiSolverInterface * | swapSolver (OsiSolverInterface *solver) |
Returns current solver - sets new one. More... | |
OsiSolverInterface * | continuousSolver () const |
Returns solver with continuous state. More... | |
void | createContinuousSolver () |
Create solver with continuous state. More... | |
void | clearContinuousSolver () |
Clear solver with continuous state. More... | |
OsiSolverInterface * | referenceSolver () const |
A copy of the solver, taken at constructor or by saveReferenceSolver. More... | |
void | saveReferenceSolver () |
Save a copy of the current solver so can be reset to. More... | |
void | resetToReferenceSolver () |
Uses a copy of reference solver to be current solver. More... | |
void | gutsOfDestructor () |
Clears out as much as possible (except solver) More... | |
void | gutsOfDestructor2 () |
Clears out enough to reset CbcModel as if no branch and bound done. More... | |
void | resetModel () |
Clears out enough to reset CbcModel cutoff etc. More... | |
void | gutsOfCopy (const CbcModel &rhs, int mode=0) |
Most of copy constructor mode - 0 copy but don't delete before 1 copy and delete before 2 copy and delete before (but use virgin generators) More... | |
void | moveInfo (const CbcModel &rhs) |
Move status, nodes etc etc across. More... | |
semi-private i.e. users should not use | |
int | getNodeCount2 () const |
Get how many Nodes it took to solve the problem. More... | |
void | setPointers (const OsiSolverInterface *solver) |
Set pointers for speed. More... | |
int | reducedCostFix () |
Perform reduced cost fixing. More... | |
void | synchronizeHandlers (int makeDefault) |
Makes all handlers same. More... | |
void | saveExtraSolution (const double *solution, double objectiveValue) |
Save a solution to saved list. More... | |
void | saveBestSolution (const double *solution, double objectiveValue) |
Save a solution to best and move current to saved. More... | |
void | deleteSolutions () |
Delete best and saved solutions. More... | |
int | resolve (OsiSolverInterface *solver) |
Encapsulates solver resolve. More... | |
int | chooseBranch (CbcNode *&newNode, int numberPassesLeft, CbcNode *oldNode, OsiCuts &cuts, bool &resolved, CoinWarmStartBasis *lastws, const double *lowerBefore, const double *upperBefore, OsiSolverBranch *&branches) |
Encapsulates choosing a variable - anyAction -2, infeasible (-1 round again), 0 done. More... | |
int | chooseBranch (CbcNode *newNode, int numberPassesLeft, bool &resolved) |
Get how many Nodes it took to solve the problem. More... | |
CoinWarmStartBasis * | getEmptyBasis (int ns=0, int na=0) const |
Return an empty basis object of the specified size. More... | |
int | takeOffCuts (OsiCuts &cuts, bool allowResolve, OsiCuts *saveCuts, int numberNewCuts=0, const OsiRowCut **newCuts=NULL) |
Remove inactive cuts from the model. More... | |
int | addCuts (CbcNode *node, CoinWarmStartBasis *&lastws) |
Determine and install the active cuts that need to be added for the current subproblem. More... | |
bool | addCuts1 (CbcNode *node, CoinWarmStartBasis *&lastws) |
Traverse the tree from node to root and prep the model. More... | |
void | previousBounds (CbcNode *node, CbcNodeInfo *where, int iColumn, double &lower, double &upper, int force) |
Returns bounds just before where - initially original bounds. More... | |
void | setObjectiveValue (CbcNode *thisNode, const CbcNode *parentNode) const |
Set objective value in a node. More... | |
void | convertToDynamic () |
If numberBeforeTrust >0 then we are going to use CbcBranchDynamic. More... | |
void | synchronizeNumberBeforeTrust (int type=0) |
Set numberBeforeTrust in all objects. More... | |
void | zapIntegerInformation (bool leaveObjects=true) |
Zap integer information in problem (may leave object info) More... | |
int | cliquePseudoCosts (int doStatistics) |
Use cliques for pseudocost information - return nonzero if infeasible. More... | |
void | pseudoShadow (int type) |
Fill in useful estimates. More... | |
void | fillPseudoCosts (double *downCosts, double *upCosts, int *priority=NULL, int *numberDown=NULL, int *numberUp=NULL, int *numberDownInfeasible=NULL, int *numberUpInfeasible=NULL) const |
Return pseudo costs If not all integers or not pseudo costs - returns all zero Length of arrays are numberIntegers() and entries correspond to integerVariable()[i] User must allocate arrays before call. More... | |
void | doHeuristicsAtRoot (int deleteHeuristicsAfterwards=0) |
Do heuristics at root. More... | |
void | adjustHeuristics () |
Adjust heuristics based on model. More... | |
const double * | hotstartSolution () const |
Get the hotstart solution. More... | |
const int * | hotstartPriorities () const |
Get the hotstart priorities. More... | |
CbcCountRowCut ** | addedCuts () const |
Return the list of cuts initially collected for this subproblem. More... | |
int | currentNumberCuts () const |
Number of entries in the list returned by addedCuts() More... | |
CbcRowCuts * | globalCuts () |
Global cuts. More... | |
void | zapGlobalCuts () |
Get rid of global cuts. More... | |
void | setNextRowCut (const OsiRowCut &cut) |
Copy and set a pointer to a row cut which will be added instead of normal branching. More... | |
CbcNode * | currentNode () const |
Get a pointer to current node (be careful) More... | |
CglTreeProbingInfo * | probingInfo () const |
Get a pointer to probing info. More... | |
CoinThreadRandom * | randomNumberGenerator () |
Thread specific random number generator. More... | |
void | setNumberStrongIterations (int number) |
Set the number of iterations done in strong branching. More... | |
int | numberStrongIterations () const |
Get the number of iterations done in strong branching. More... | |
int | maximumNumberIterations () const |
Get maximum number of iterations (designed to be used in heuristics) More... | |
void | setMaximumNumberIterations (int value) |
Set maximum number of iterations (designed to be used in heuristics) More... | |
void | setFastNodeDepth (int value) |
Set depth for fast nodes. More... | |
int | fastNodeDepth () const |
Get depth for fast nodes. More... | |
int | continuousPriority () const |
Get anything with priority >= this can be treated as continuous. More... | |
void | setContinuousPriority (int value) |
Set anything with priority >= this can be treated as continuous. More... | |
void | incrementExtra (int nodes, int iterations, int fathoms=1) |
Get how many Nodes it took to solve the problem. More... | |
void | zeroExtra () |
Zero extra. More... | |
int | numberExtraIterations () const |
Number of extra iterations. More... | |
void | incrementStrongInfo (int numberTimes, int numberIterations, int numberFixed, bool ifInfeasible) |
Increment strong info. More... | |
const int * | strongInfo () const |
Return strong info. More... | |
int * | mutableStrongInfo () |
Return mutable strong info. More... | |
CglStored * | storedRowCuts () const |
Get stored row cuts for donor/recipient CbcModel. More... | |
void | setStoredRowCuts (CglStored *cuts) |
Set stored row cuts for donor/recipient CbcModel. More... | |
bool | allDynamic () const |
Says whether all dynamic integers. More... | |
void | generateCpp (FILE *fp, int options) |
Create C++ lines to get to current state. More... | |
OsiBranchingInformation | usefulInformation () const |
Generate an OsiBranchingInformation object. More... | |
void | setBestSolutionBasis (const CoinWarmStartBasis &bestSolutionBasis) |
Warm start object produced by heuristic or strong branching. More... | |
void | redoWalkBack () |
Redo walkback arrays. More... | |
Private Attributes | |
Private member data | |
OsiSolverInterface * | solver_ |
The solver associated with this model. More... | |
unsigned int | ownership_ |
Ownership of objects and other stuff. More... | |
OsiSolverInterface * | continuousSolver_ |
A copy of the solver, taken at the continuous (root) node. More... | |
OsiSolverInterface * | referenceSolver_ |
A copy of the solver, taken at constructor or by saveReferenceSolver. More... | |
CoinMessageHandler * | handler_ |
Message handler. More... | |
bool | defaultHandler_ |
Flag to say if handler_ is the default handler. More... | |
CoinMessages | messages_ |
Cbc messages. More... | |
int | intParam_ [CbcLastIntParam] |
Array for integer parameters. More... | |
double | dblParam_ [CbcLastDblParam] |
Array for double parameters. More... | |
CoinWarmStart * | emptyWarmStart_ |
Pointer to an empty warm start object. More... | |
double | bestObjective_ |
Best objective. More... | |
double | bestPossibleObjective_ |
Best possible objective. More... | |
double | sumChangeObjective1_ |
Sum of Changes to objective by first solve. More... | |
double | sumChangeObjective2_ |
Sum of Changes to objective by subsequent solves. More... | |
double * | bestSolution_ |
Array holding the incumbent (best) solution. More... | |
double ** | savedSolutions_ |
Arrays holding other solutions. More... | |
double * | currentSolution_ |
Array holding the current solution. More... | |
const double * | testSolution_ |
For testing infeasibilities - will point to currentSolution_ or solver–>getColSolution() More... | |
std::vector< std::pair < std::string, double > > | mipStart_ |
MIPstart values values for integer variables which will be converted to a complete integer initial feasible solution. More... | |
bool | keepNamesPreproc |
keepNamesPreproc if variables names will be preserved in the pre-processed problem (usefull in callbacks) More... | |
CoinWarmStartBasis | bestSolutionBasis_ |
Warm start object produced by heuristic or strong branching. More... | |
CbcRowCuts | globalCuts_ |
Global cuts. More... | |
CbcRowCuts * | globalConflictCuts_ |
Global conflict cuts. More... | |
double | minimumDrop_ |
Minimum degradation in objective value to continue cut generation. More... | |
int | numberSolutions_ |
Number of solutions. More... | |
int | numberSavedSolutions_ |
Number of saved solutions. More... | |
int | maximumSavedSolutions_ |
Maximum number of saved solutions. More... | |
int | stateOfSearch_ |
State of search 0 - no solution 1 - only heuristic solutions 2 - branched to a solution 3 - no solution but many nodes. More... | |
int | whenCuts_ |
At which depths to do cuts. More... | |
double * | hotstartSolution_ |
Hotstart solution. More... | |
int * | hotstartPriorities_ |
Hotstart priorities. More... | |
int | numberHeuristicSolutions_ |
Number of heuristic solutions. More... | |
int | numberNodes_ |
Cumulative number of nodes. More... | |
int | numberNodes2_ |
Cumulative number of nodes for statistics. More... | |
int | numberIterations_ |
Cumulative number of iterations. More... | |
int | numberSolves_ |
Cumulative number of solves. More... | |
int | status_ |
Status of problem - 0 finished, 1 stopped, 2 difficulties. More... | |
int | secondaryStatus_ |
Secondary status of problem -1 unset (status_ will also be -1) 0 search completed with solution 1 linear relaxation not feasible (or worse than cutoff) 2 stopped on gap 3 stopped on nodes 4 stopped on time 5 stopped on user event 6 stopped on solutions. More... | |
int | numberIntegers_ |
Number of integers in problem. More... | |
int | numberRowsAtContinuous_ |
Number of rows at continuous. More... | |
int | cutoffRowNumber_ |
-1 - cutoff as constraint not activated -2 - waiting to activate >=0 - activated More... | |
int | maximumNumberCuts_ |
Maximum number of cuts. More... | |
int | phase_ |
Current phase (so heuristics etc etc can find out). More... | |
int | currentNumberCuts_ |
Number of entries in addedCuts_. More... | |
int | maximumDepth_ |
Current limit on search tree depth. More... | |
CbcNodeInfo ** | walkback_ |
Array used to assemble the path between a node and the search tree root. More... | |
CglPreProcess * | preProcess_ |
preProcess used before branch and bound (optional) More... | |
CbcNodeInfo ** | lastNodeInfo_ |
The solver associated with this model. More... | |
const OsiRowCut ** | lastCut_ |
The solver associated with this model. More... | |
int | lastDepth_ |
The solver associated with this model. More... | |
int | lastNumberCuts2_ |
The solver associated with this model. More... | |
int | maximumCuts_ |
The solver associated with this model. More... | |
int * | lastNumberCuts_ |
The solver associated with this model. More... | |
CbcCountRowCut ** | addedCuts_ |
The list of cuts initially collected for this subproblem. More... | |
OsiRowCut * | nextRowCut_ |
A pointer to a row cut which will be added instead of normal branching. More... | |
CbcNode * | currentNode_ |
Current node so can be used elsewhere. More... | |
int * | integerVariable_ |
Indices of integer variables. More... | |
char * | integerInfo_ |
Whether of not integer. More... | |
double * | continuousSolution_ |
Holds solution at continuous (after cuts) More... | |
int * | usedInSolution_ |
Array marked whenever a solution is found if non-zero. More... | |
int | specialOptions_ |
Special options 0 bit (1) - check if cuts valid (if on debugger list) 1 bit (2) - use current basis to check integer solution (rather than all slack) 2 bit (4) - don't check integer solution (by solving LP) 3 bit (8) - fast analyze 4 bit (16) - non-linear model - so no well defined CoinPackedMatrix 5 bit (32) - keep names 6 bit (64) - try for dominated columns 7 bit (128) - SOS type 1 but all declared integer 8 bit (256) - Set to say solution just found, unset by doing cuts 9 bit (512) - Try reduced model after 100 nodes 10 bit (1024) - Switch on some heuristics even if seems unlikely 11 bit (2048) - Mark as in small branch and bound 12 bit (4096) - Funny cuts so do slow way (in some places) 13 bit (8192) - Funny cuts so do slow way (in other places) 14 bit (16384) - Use Cplex! for fathoming 15 bit (32768) - Try reduced model after 0 nodes 16 bit (65536) - Original model had integer bounds 17 bit (131072) - Perturbation switched off 18 bit (262144) - donor CbcModel 19 bit (524288) - recipient CbcModel 20 bit (1048576) - waiting for sub model to return 22 bit (4194304) - do not initialize random seed in solver (user has) 23 bit (8388608) - leave solver_ with cuts 24 bit (16777216) - just get feasible if no cutoff More... | |
int | moreSpecialOptions_ |
More special options at present bottom 6 bits used for shadow price mode 1024 for experimental hotstart 2048,4096 breaking out of cuts 8192 slowly increase minimum drop 16384 gomory 32768 more heuristics in sub trees 65536 no cuts in preprocessing 131072 Time limits elapsed 18 bit (262144) - Perturb fathom nodes 19 bit (524288) - No limit on fathom nodes 20 bit (1048576) - Reduce sum of infeasibilities before cuts 21 bit (2097152) - Reduce sum of infeasibilities after cuts. More... | |
int | moreSpecialOptions2_ |
More more special options 0 bit (1) - find switching variables 1 bit (2) - using fake objective until solution 2 bit (4) - switching variables exist 3 bit (8) - skip most of setBestSolution checks 4 bit (16) - very lightweight preprocessing in smallB&B 5 bit (32) - event handler needs to be cloned when parallel 6 bit (64) - testing - use probing to make cliques 7/8 bit (128) - try orbital branching (if nauty) 9 bit (512) - branching on objective (later) 10 bit (1024) - branching on constraints (later) 11/12 bit 2048 - intermittent cuts. More... | |
CbcCompareBase * | nodeCompare_ |
User node comparison function. More... | |
CbcFeasibilityBase * | problemFeasibility_ |
User feasibility function (see CbcFeasibleBase.hpp) More... | |
CbcTree * | tree_ |
Tree. More... | |
CbcFullNodeInfo * | topOfTree_ |
Pointer to top of tree. More... | |
CbcModel * | subTreeModel_ |
A pointer to model to be used for subtrees. More... | |
CbcModel * | heuristicModel_ |
A pointer to model from CbcHeuristic. More... | |
int | numberStoppedSubTrees_ |
Number of times any subtree stopped on nodes, time etc. More... | |
CbcBranchDecision * | branchingMethod_ |
Variable selection function. More... | |
CbcCutModifier * | cutModifier_ |
Cut modifier function. More... | |
CbcStrategy * | strategy_ |
Strategy. More... | |
CbcModel * | parentModel_ |
Parent model. More... | |
const double * | cbcColLower_ |
Whether to automatically do presolve before branch and bound. More... | |
const double * | cbcColUpper_ |
Pointer to array[getNumCols()] (for speed) of column upper bounds. More... | |
const double * | cbcRowLower_ |
Pointer to array[getNumRows()] (for speed) of row lower bounds. More... | |
const double * | cbcRowUpper_ |
Pointer to array[getNumRows()] (for speed) of row upper bounds. More... | |
const double * | cbcColSolution_ |
Pointer to array[getNumCols()] (for speed) of primal solution vector. More... | |
const double * | cbcRowPrice_ |
Pointer to array[getNumRows()] (for speed) of dual prices. More... | |
const double * | cbcReducedCost_ |
Get a pointer to array[getNumCols()] (for speed) of reduced costs. More... | |
const double * | cbcRowActivity_ |
Pointer to array[getNumRows()] (for speed) of row activity levels. More... | |
void * | appData_ |
Pointer to user-defined data structure. More... | |
int | presolve_ |
Presolve for CbcTreeLocal. More... | |
int | numberStrong_ |
Maximum number of candidates to consider for strong branching. More... | |
int | numberBeforeTrust_ |
The number of branches before pseudo costs believed in dynamic strong branching. More... | |
int | numberPenalties_ |
The number of variables for which to compute penalties in dynamic strong branching. More... | |
int | stopNumberIterations_ |
For threads - stop after this many "iterations". More... | |
double | penaltyScaleFactor_ |
Scale factor to make penalties match strong. More... | |
int | numberAnalyzeIterations_ |
Number of analyze iterations to do. More... | |
double * | analyzeResults_ |
Arrays with analysis results. More... | |
void * | temporaryPointer_ |
Useful temporary pointer. More... | |
int | numberInfeasibleNodes_ |
Number of nodes infeasible by normal branching (before cuts) More... | |
int | problemType_ |
Problem type as set by user or found by analysis. More... | |
int | printFrequency_ |
Print frequency. More... | |
int | numberCutGenerators_ |
Number of cut generators. More... | |
CbcCutGenerator ** | generator_ |
The solver associated with this model. More... | |
CbcCutGenerator ** | virginGenerator_ |
The solver associated with this model. More... | |
int | numberHeuristics_ |
Number of heuristics. More... | |
CbcHeuristic ** | heuristic_ |
Heuristic solvers. More... | |
CbcHeuristic * | lastHeuristic_ |
Pointer to heuristic solver which found last solution (or NULL) More... | |
int | fastNodeDepth_ |
Depth for fast nodes. More... | |
CbcEventHandler * | eventHandler_ |
CbcSymmetry * | symmetryInfo_ |
Symmetry information. More... | |
int | numberObjects_ |
Total number of objects. More... | |
OsiObject ** | object_ |
Integer and Clique and ... More... | |
bool | ownObjects_ |
Now we may not own objects - just point to solver's objects. More... | |
int * | originalColumns_ |
Original columns as created by integerPresolve or preprocessing. More... | |
int | howOftenGlobalScan_ |
How often to scan global cuts. More... | |
int | numberGlobalViolations_ |
Number of times global cuts violated. More... | |
int | numberExtraIterations_ |
Number of extra iterations in fast lp. More... | |
int | numberExtraNodes_ |
Number of extra nodes in fast lp. More... | |
int | numberFathoms_ |
Number of times fast lp entered. More... | |
double | continuousObjective_ |
Value of objective at continuous (Well actually after initial round of cuts) More... | |
double | originalContinuousObjective_ |
Value of objective before root node cuts added. More... | |
int | continuousInfeasibilities_ |
Number of infeasibilities at continuous. More... | |
int | maximumCutPassesAtRoot_ |
Maximum number of cut passes at root. More... | |
int | maximumCutPasses_ |
Maximum number of cut passes. More... | |
int | preferredWay_ |
Preferred way of branching. More... | |
int | currentPassNumber_ |
Current cut pass number. More... | |
int | maximumWhich_ |
Maximum number of cuts (for whichGenerator_) More... | |
int | maximumRows_ |
Maximum number of rows. More... | |
int | randomSeed_ |
Random seed. More... | |
int | multipleRootTries_ |
Multiple root tries. More... | |
int | currentDepth_ |
Current depth. More... | |
CoinThreadRandom | randomNumberGenerator_ |
Thread specific random number generator. More... | |
CoinWarmStartBasis | workingBasis_ |
Work basis for temporary use. More... | |
int * | whichGenerator_ |
Which cut generator generated this cut. More... | |
int | maximumStatistics_ |
Maximum number of statistics. More... | |
CbcStatistics ** | statistics_ |
statistics More... | |
int | maximumDepthActual_ |
Maximum depth reached. More... | |
double | numberDJFixed_ |
Number of reduced cost fixings. More... | |
CglTreeProbingInfo * | probingInfo_ |
Probing info. More... | |
int | numberFixedAtRoot_ |
Number of fixed by analyze at root. More... | |
int | numberFixedNow_ |
Number fixed by analyze so far. More... | |
bool | stoppedOnGap_ |
Whether stopping on gap. More... | |
bool | eventHappened_ |
Whether event happened. More... | |
int | numberLongStrong_ |
Number of long strong goes. More... | |
int | numberOldActiveCuts_ |
Number of old active cuts. More... | |
int | numberNewCuts_ |
Number of new cuts. More... | |
int | searchStrategy_ |
Strategy worked out - mainly at root node. More... | |
int | strongStrategy_ |
Strategy for strong branching 0 - normal when to do all fractional 1 - root node 2 - depth less than modifier 4 - if objective == best possible 6 - as 2+4 when to do all including satisfied 10 - root node etc. More... | |
int | numberStrongIterations_ |
Number of iterations in strong branching. More... | |
int | strongInfo_ [7] |
0 - number times strong branching done, 1 - number fixed, 2 - number infeasible Second group of three is a snapshot at node [6] More... | |
OsiBabSolver * | solverCharacteristics_ |
For advanced applications you may wish to modify the behavior of Cbc e.g. More... | |
bool | resolveAfterTakeOffCuts_ |
Whether to force a resolve after takeOffCuts. More... | |
int | maximumNumberIterations_ |
Maximum number of iterations (designed to be used in heuristics) More... | |
int | continuousPriority_ |
Anything with priority >= this can be treated as continuous. More... | |
int | numberUpdateItems_ |
Number of outstanding update information items. More... | |
int | maximumNumberUpdateItems_ |
Maximum number of outstanding update information items. More... | |
CbcObjectUpdateData * | updateItems_ |
Update items. More... | |
CglStored * | storedRowCuts_ |
Stored row cuts for donor/recipient CbcModel. More... | |
int | numberThreads_ |
Parallel 0 - off 1 - testing 2-99 threads other special meanings. More... | |
int | threadMode_ |
thread mode always use numberThreads for branching 1 set then deterministic 2 set then use numberThreads for root cuts 4 set then use numberThreads in root mini branch and bound default is 0 More... | |
int | numberGlobalCutsIn_ |
Number of global cuts on entry to a node. More... | |
CbcBaseModel * | master_ |
Thread stuff for master. More... | |
CbcThread * | masterThread_ |
Pointer to masterthread. More... | |
Solve methods | |
void | initialSolve () |
Solve the initial LP relaxation. More... | |
void | branchAndBound (int doStatistics=0) |
Invoke the branch & cut algorithm. More... | |
CglPreProcess * | preProcess () const |
Returns CglPreProcess used before branch and bound. More... | |
void | setPreProcess (CglPreProcess *preProcess) |
Set CglPreProcess used before branch and bound. More... | |
void | addUpdateInformation (const CbcObjectUpdateData &data) |
Adds an update information object. More... | |
int | doOneNode (CbcModel *baseModel, CbcNode *&node, CbcNode *&newNode) |
Do one node - broken out for clarity? also for parallel (when baseModel!=this) Returns 1 if solution found node NULL on return if no branches left newNode NULL if no new node created. More... | |
int | resolve (CbcNodeInfo *parent, int whereFrom, double *saveSolution=NULL, double *saveLower=NULL, double *saveUpper=NULL) |
Reoptimise an LP relaxation. More... | |
void | makeGlobalCuts (int numberRows, const int *which) |
Make given rows (L or G) into global cuts and remove from lp. More... | |
int | makeGlobalCut (const OsiRowCut *cut) |
Make given cut into a global cut. More... | |
int | makeGlobalCut (const OsiRowCut &cut) |
Make given cut into a global cut. More... | |
void | makeGlobalCut (const OsiColCut *cut) |
Make given column cut into a global cut. More... | |
void | makeGlobalCut (const OsiColCut &cut) |
Make given column cut into a global cut. More... | |
void | makePartialCut (const OsiRowCut *cut, const OsiSolverInterface *solver=NULL) |
Make partial cut into a global cut and save. More... | |
void | makeGlobalCuts () |
Make partial cuts into global cuts. More... | |
const int * | whichGenerator () const |
Which cut generator generated this cut. More... | |
bool | solveWithCuts (OsiCuts &cuts, int numberTries, CbcNode *node) |
Evaluate a subproblem using cutting planes and heuristics. More... | |
int | serialCuts (OsiCuts &cuts, CbcNode *node, OsiCuts &slackCuts, int lastNumberCuts) |
Generate one round of cuts - serial mode returns - 0 - normal 1 - must keep going 2 - set numberTries to zero -1 - infeasible. More... | |
int | parallelCuts (CbcBaseModel *master, OsiCuts &cuts, CbcNode *node, OsiCuts &slackCuts, int lastNumberCuts) |
Generate one round of cuts - parallel mode returns - 0 - normal 1 - must keep going 2 - set numberTries to zero -1 - infeasible. More... | |
CbcNode ** | solveOneNode (int whichSolver, CbcNode *node, int &numberNodesOutput, int &status) |
Input one node output N nodes to put on tree and optional solution update This should be able to operate in parallel so is given a solver and is const(ish) However we will need to keep an array of solver_ and bases and more status is 0 for normal, 1 if solution Calling code should always push nodes back on tree. More... | |
void | resizeWhichGenerator (int numberNow, int numberAfter) |
Update size of whichGenerator. More... | |
Multithreading | |
CbcThread * | masterThread () const |
Get pointer to masterthread. More... | |
CbcNodeInfo ** | walkback () const |
Get pointer to walkback. More... | |
int | getNumberThreads () const |
Get number of threads. More... | |
void | setNumberThreads (int value) |
Set number of threads. More... | |
int | getThreadMode () const |
Get thread mode. More... | |
void | setThreadMode (int value) |
Set thread mode always use numberThreads for branching 1 set then deterministic 2 set then use numberThreads for root cuts 4 set then use numberThreads in root mini branch and bound 8 set and numberThreads - do heuristics numberThreads at a time 8 set and numberThreads==0 do all heuristics at once default is 0. More... | |
int | parallelMode () const |
Return -2 if deterministic threaded and main thread -1 if deterministic threaded and serial thread 0 if serial 1 if opportunistic threaded. More... | |
CbcBaseModel * | master () const |
Thread stuff for master. More... | |
bool | isLocked () const |
From here to end of section - code in CbcThread.cpp until class changed Returns true if locked. More... | |
void | lockThread () |
Get pointer to masterthread. More... | |
void | unlockThread () |
Get pointer to masterthread. More... | |
void | setInfoInChild (int type, CbcThread *info) |
Set information in a child -3 pass pointer to child thread info -2 just stop -1 delete simple child stuff 0 delete opportunistic child stuff 1 delete deterministic child stuff. More... | |
void | moveToModel (CbcModel *baseModel, int mode) |
Move/copy information from one model to another -1 - initialization 0 - from base model 1 - to base model (and reset) 2 - add in final statistics etc (and reset so can do clean destruction) More... | |
int | splitModel (int numberModels, CbcModel **model, int numberNodes) |
Split up nodes. More... | |
void | startSplitModel (int numberIterations) |
Start threads. More... | |
void | mergeModels (int numberModel, CbcModel **model, int numberNodes) |
Merge models. More... | |
static bool | haveMultiThreadSupport () |
Indicates whether Cbc library has been compiled with multithreading support. More... | |
Simple Branch and bound class.
The initialSolve() method solves the initial LP relaxation of the MIP problem. The branchAndBound() method can then be called to finish using a branch and cut algorithm.
Subproblems (aka nodes) requiring additional evaluation are stored using the CbcNode and CbcNodeInfo objects. Ancestry linkage is maintained in the CbcNodeInfo object. Evaluation of a subproblem within branchAndBound() proceeds as follows:
Note that there is never a node representing the active subproblem; the model and solver represent the active subproblem.
For a typical subproblem, the sequence of events is as follows:
See CbcCountRowCut for details of the bookkeeping associated with cut management.
Definition at line 100 of file CbcModel.hpp.
Definition at line 103 of file CbcModel.hpp.
Definition at line 129 of file CbcModel.hpp.
CbcModel::CbcModel | ( | ) |
Default Constructor.
CbcModel::CbcModel | ( | const OsiSolverInterface & | ) |
Constructor from solver.
CbcModel::CbcModel | ( | const CbcModel & | rhs, |
bool | cloneHandler = false |
||
) |
Copy constructor .
If cloneHandler is true then message handler is cloned
|
virtual |
Destructor.
void CbcModel::initialSolve | ( | ) |
Solve the initial LP relaxation.
Invoke the solver's initialSolve() method.
void CbcModel::branchAndBound | ( | int | doStatistics = 0 | ) |
Invoke the branch & cut algorithm.
The method assumes that initialSolve() has been called to solve the LP relaxation. It processes the root node, then proceeds to explore the branch & cut search tree. The search ends when the tree is exhausted or one of several execution limits is reached. If doStatistics is 1 summary statistics are printed if 2 then also the path to best solution (if found by branching) if 3 then also one line per node
Evaluate a subproblem using cutting planes and heuristics.
The method invokes a main loop which generates cuts, applies heuristics, and reoptimises using the solver's native resolve() method. It returns true if the subproblem remains feasible at the end of the evaluation.
|
private |
Generate one round of cuts - serial mode returns - 0 - normal 1 - must keep going 2 - set numberTries to zero -1 - infeasible.
|
private |
Generate one round of cuts - parallel mode returns - 0 - normal 1 - must keep going 2 - set numberTries to zero -1 - infeasible.
|
private |
Input one node output N nodes to put on tree and optional solution update This should be able to operate in parallel so is given a solver and is const(ish) However we will need to keep an array of solver_ and bases and more status is 0 for normal, 1 if solution Calling code should always push nodes back on tree.
|
private |
Update size of whichGenerator.
|
inline |
Returns CglPreProcess used before branch and bound.
Definition at line 322 of file CbcModel.hpp.
Referenced by setPreProcess().
|
inline |
Set CglPreProcess used before branch and bound.
Definition at line 327 of file CbcModel.hpp.
References preProcess(), and preProcess_.
void CbcModel::addUpdateInformation | ( | const CbcObjectUpdateData & | data | ) |
Adds an update information object.
Do one node - broken out for clarity? also for parallel (when baseModel!=this) Returns 1 if solution found node NULL on return if no branches left newNode NULL if no new node created.
int CbcModel::resolve | ( | CbcNodeInfo * | parent, |
int | whereFrom, | ||
double * | saveSolution = NULL , |
||
double * | saveLower = NULL , |
||
double * | saveUpper = NULL |
||
) |
Reoptimise an LP relaxation.
Invoke the solver's resolve() method. whereFrom - 0 - initial continuous 1 - resolve on branch (before new cuts) 2 - after new cuts 3 - obsolete code or something modified problem in unexpected way 10 - after strong branching has fixed variables at root 11 - after strong branching has fixed variables in tree
returns 1 feasible, 0 infeasible, -1 feasible but skip cuts
void CbcModel::makeGlobalCuts | ( | int | numberRows, |
const int * | which | ||
) |
Make given rows (L or G) into global cuts and remove from lp.
int CbcModel::makeGlobalCut | ( | const OsiRowCut * | cut | ) |
Make given cut into a global cut.
int CbcModel::makeGlobalCut | ( | const OsiRowCut & | cut | ) |
Make given cut into a global cut.
void CbcModel::makeGlobalCut | ( | const OsiColCut * | cut | ) |
Make given column cut into a global cut.
void CbcModel::makeGlobalCut | ( | const OsiColCut & | cut | ) |
Make given column cut into a global cut.
void CbcModel::makePartialCut | ( | const OsiRowCut * | cut, |
const OsiSolverInterface * | solver = NULL |
||
) |
Make partial cut into a global cut and save.
void CbcModel::makeGlobalCuts | ( | ) |
Make partial cuts into global cuts.
|
inline |
Which cut generator generated this cut.
Definition at line 374 of file CbcModel.hpp.
References whichGenerator_.
CbcModel* CbcModel::findCliques | ( | bool | makeEquality, |
int | atLeastThisMany, | ||
int | lessThanThis, | ||
int | defaultValue = 1000 |
||
) |
Identify cliques and construct corresponding objects.
Find cliques with size in the range [atLeastThisMany
, lessThanThis
] and construct corresponding CbcClique objects. If makeEquality
is true then a new model may be returned if modifications had to be made, otherwise this
is returned. If the problem is infeasible numberObjects_ is set to -1. A client must use deleteObjects() before a second call to findCliques(). If priorities exist, clique priority is set to the default.
CbcModel* CbcModel::integerPresolve | ( | bool | weak = false | ) |
Do integer presolve, creating a new (presolved) model.
Returns the new model, or NULL if feasibility is lost. If weak is true then just does a normal presolve
bool CbcModel::integerPresolveThisModel | ( | OsiSolverInterface * | originalSolver, |
bool | weak = false |
||
) |
Do integer presolve, modifying the current model.
Returns true if the model remains feasible after presolve.
void CbcModel::originalModel | ( | CbcModel * | presolvedModel, |
bool | weak | ||
) |
Put back information into the original model after integer presolve.
bool CbcModel::tightenVubs | ( | int | type, |
bool | allowMultipleBinary = false , |
||
double | useCutoff = 1.0e50 |
||
) |
For variables involved in VUB constraints, see if we can tighten bounds by solving lp's.
Returns false if feasibility is lost. If CglProbing is available, it will be tried as well to see if it can tighten bounds. This routine is just a front end for tightenVubs(int,const int*,double).
If type = -1
all variables are processed (could be very slow). If type = 0
only variables involved in VUBs are processed. If type = n > 0
, only the n most expensive VUB variables are processed, where it is assumed that x is at its maximum so delta would have to go to 1 (if x not at bound).
If allowMultipleBinary
is true, then a VUB constraint is a row with one continuous variable and any number of binary variables.
If useCutoff < 1.0e30
, the original objective is installed as a constraint with useCutoff
as a bound.
bool CbcModel::tightenVubs | ( | int | numberVubs, |
const int * | which, | ||
double | useCutoff = 1.0e50 |
||
) |
For variables involved in VUB constraints, see if we can tighten bounds by solving lp's.
This version is just handed a list of variables to be processed.
void CbcModel::analyzeObjective | ( | ) |
Analyze problem to find a minimum change in the objective function.
const OsiSolverInterface* CbcModel::postProcessedSolver | ( | int | solutionType = 1 | ) |
Returns postProcessed solution in solver(called from event handler) Normally used for integer solution (not really tested otherwise) solutionType 1 is best integer so far, 0 is current solution (may not be integer)
void CbcModel::AddIntegers | ( | ) |
Add additional integers.
void CbcModel::saveModel | ( | OsiSolverInterface * | saveSolver, |
double * | checkCutoffForRestart, | ||
bool * | feasible | ||
) |
Save copy of the model.
void CbcModel::flipModel | ( | ) |
Flip direction of optimization on all models.
int CbcModel::cleanBounds | ( | OsiSolverInterface * | solver, |
char * | cleanVariables | ||
) |
Clean model i.e.
make SOS/integer variables exactly at bound if needed. Only if moreSpecialOptions2_ 15 bit set (32768) as there is a small overhead (more2 in standalone cbc). Fine tuning can be done in configure with -DCLEAN_INTEGER_VARIABLES and -DZERO_ODD_TOLERANCE=1.0e-nn If CLEAN_INTEGER_VARIABLES not defined then cleaning is only done for SOS variables. If ZERO_ODD_TOLERANCE not defined then 1.0e-14 used. You can define as 0.0 if you are paranoid. Returns number of variables forced out cleanVariables array will be used if exists
char* CbcModel::setupCleanVariables | ( | ) |
Sets up cleanVariables array (i.e. ones to be careful about)
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
void CbcModel::setOptionalInteger | ( | int | index | ) |
Get the number of objects.
void CbcModel::deleteObjects | ( | bool | findIntegers = true | ) |
Delete all object information (and just back to integers if true)
void CbcModel::addObjects | ( | int | numberObjects, |
OsiObject ** | objects | ||
) |
Add in object information.
Objects are cloned; the owner can delete the originals.
void CbcModel::addObjects | ( | int | numberObjects, |
CbcObject ** | objects | ||
) |
Add in object information.
Objects are cloned; the owner can delete the originals.
void CbcModel::synchronizeModel | ( | ) |
Ensure attached objects point to this model.
void CbcModel::findIntegers | ( | bool | startAgain, |
int | type = 0 |
||
) |
Identify integer variables and create corresponding objects.
Record integer variables and create an CbcSimpleInteger object for each one. If startAgain
is true, a new scan is forced, overwriting any existing integer variable information. If type > 0 then 1==PseudoCost, 2 new ones low priority
void CbcModel::addSOSEtcToSolver | ( | ) |
Add SOS info to solver - Overwrites SOS information in solver with information in CbcModel.
Has no effect with some solvers. Also updates integer info.
|
inline |
Set an integer parameter.
Definition at line 579 of file CbcModel.hpp.
Referenced by setMaximumNodes(), setMaximumSolutions(), and setPrintingMode().
|
inline |
Set a double parameter.
Definition at line 585 of file CbcModel.hpp.
References dblParam_.
Referenced by setAllowableFractionGap(), setAllowableGap(), setAllowablePercentageGap(), setCutoffIncrement(), setHeuristicFractionGap(), setHeuristicGap(), setInfeasibilityWeight(), setIntegerTolerance(), and setMaximumSeconds().
|
inline |
Get an integer parameter.
Definition at line 591 of file CbcModel.hpp.
References intParam_.
Referenced by getMaximumNodes(), getMaximumSolutions(), and getPrintingMode().
|
inline |
Get a double parameter.
Definition at line 596 of file CbcModel.hpp.
References dblParam_.
Referenced by getAllowableFractionGap(), getAllowableGap(), getAllowablePercentageGap(), getCutoffIncrement(), getHeuristicFractionGap(), getHeuristicGap(), getInfeasibilityWeight(), getIntegerTolerance(), and getMaximumSeconds().
void CbcModel::setCutoff | ( | double | value | ) |
Set cutoff bound on the objective function.
When using strict comparison, the bound is adjusted by a tolerance to avoid accidentally cutting off the optimal solution.
Referenced by OsiCbcSolverInterface::setCutoff().
|
inline |
Get the cutoff bound on the objective function - always as minimize.
Definition at line 608 of file CbcModel.hpp.
References CbcCurrentCutoff, and dblParam_.
Referenced by OsiCbcSolverInterface::getCutoff().
|
inline |
Set the maximum node limit .
Definition at line 616 of file CbcModel.hpp.
References CbcMaxNumNode, and setIntParam().
Referenced by OsiCbcSolverInterface::setMaximumNodes().
|
inline |
Get the maximum node limit .
Definition at line 622 of file CbcModel.hpp.
References CbcMaxNumNode, and getIntParam().
Referenced by OsiCbcSolverInterface::getMaximumNodes().
|
inline |
Set the maximum number of solutions desired.
Definition at line 631 of file CbcModel.hpp.
References CbcMaxNumSol, and setIntParam().
Referenced by OsiCbcSolverInterface::setMaximumSolutions().
|
inline |
Get the maximum number of solutions desired.
Definition at line 639 of file CbcModel.hpp.
References CbcMaxNumSol, and getIntParam().
Referenced by OsiCbcSolverInterface::getMaximumSolutions().
|
inline |
Set the printing mode.
Definition at line 644 of file CbcModel.hpp.
References CbcPrinting, and setIntParam().
|
inline |
Get the printing mode.
Definition at line 650 of file CbcModel.hpp.
References CbcPrinting, and getIntParam().
|
inline |
Set the maximum number of seconds desired.
Definition at line 659 of file CbcModel.hpp.
References CbcMaximumSeconds, and setDblParam().
Referenced by OsiCbcSolverInterface::setMaximumSeconds().
|
inline |
Get the maximum number of seconds desired.
Definition at line 667 of file CbcModel.hpp.
References CbcMaximumSeconds, and getDblParam().
Referenced by OsiCbcSolverInterface::getMaximumSeconds().
double CbcModel::getCurrentSeconds | ( | ) | const |
Current time since start of branchAndbound.
bool CbcModel::maximumSecondsReached | ( | ) | const |
Return true if maximum time reached.
|
inline |
Set the integrality tolerance .
Definition at line 680 of file CbcModel.hpp.
References CbcIntegerTolerance, and setDblParam().
|
inline |
Get the integrality tolerance .
Definition at line 687 of file CbcModel.hpp.
References CbcIntegerTolerance, and getDblParam().
|
inline |
Set the weight per integer infeasibility .
Definition at line 696 of file CbcModel.hpp.
References CbcInfeasibilityWeight, and setDblParam().
|
inline |
Get the weight per integer infeasibility .
Definition at line 704 of file CbcModel.hpp.
References CbcInfeasibilityWeight, and getDblParam().
|
inline |
Set the allowable gap between the best known solution and the best possible solution.
Definition at line 712 of file CbcModel.hpp.
References CbcAllowableGap, and setDblParam().
|
inline |
Get the allowable gap between the best known solution and the best possible solution.
Definition at line 719 of file CbcModel.hpp.
References CbcAllowableGap, and getDblParam().
|
inline |
Set the fraction allowable gap between the best known solution and the best possible solution.
Definition at line 727 of file CbcModel.hpp.
References CbcAllowableFractionGap, and setDblParam().
|
inline |
Get the fraction allowable gap between the best known solution and the best possible solution.
Definition at line 734 of file CbcModel.hpp.
References CbcAllowableFractionGap, and getDblParam().
|
inline |
Set the percentage allowable gap between the best known solution and the best possible solution.
Definition at line 741 of file CbcModel.hpp.
References CbcAllowableFractionGap, and setDblParam().
|
inline |
Get the percentage allowable gap between the best known solution and the best possible solution.
Definition at line 748 of file CbcModel.hpp.
References CbcAllowableFractionGap, and getDblParam().
|
inline |
Set the heuristic gap between the best known solution and the best possible solution.
Definition at line 755 of file CbcModel.hpp.
References CbcHeuristicGap, and setDblParam().
|
inline |
Get the heuristic gap between the best known solution and the best possible solution.
Definition at line 762 of file CbcModel.hpp.
References CbcHeuristicGap, and getDblParam().
|
inline |
Set the fraction heuristic gap between the best known solution and the best possible solution.
Definition at line 770 of file CbcModel.hpp.
References CbcHeuristicFractionGap, and setDblParam().
|
inline |
Get the fraction heuristic gap between the best known solution and the best possible solution.
Definition at line 777 of file CbcModel.hpp.
References CbcHeuristicFractionGap, and getDblParam().
|
inline |
Set the CbcModel::CbcCutoffIncrement desired.
Definition at line 785 of file CbcModel.hpp.
References CbcCutoffIncrement, and setDblParam().
|
inline |
Get the CbcModel::CbcCutoffIncrement desired.
Definition at line 793 of file CbcModel.hpp.
References CbcCutoffIncrement, and getDblParam().
bool CbcModel::canStopOnGap | ( | ) | const |
See if can stop on gap.
void CbcModel::setHotstartSolution | ( | const double * | solution, |
const int * | priorities = NULL |
||
) |
Pass in target solution and optional priorities.
If priorities then >0 means only branch if incorrect while <0 means branch even if correct. +1 or -1 are highest priority
|
inline |
Set the minimum drop to continue cuts.
Definition at line 807 of file CbcModel.hpp.
References minimumDrop_.
|
inline |
Get the minimum drop to continue cuts.
Definition at line 812 of file CbcModel.hpp.
References minimumDrop_.
|
inline |
Set the maximum number of cut passes at root node (default 20) Minimum drop can also be used for fine tuning.
Definition at line 819 of file CbcModel.hpp.
References maximumCutPassesAtRoot_.
|
inline |
Get the maximum number of cut passes at root node.
Definition at line 824 of file CbcModel.hpp.
References maximumCutPassesAtRoot_.
|
inline |
Set the maximum number of cut passes at other nodes (default 10) Minimum drop can also be used for fine tuning.
Definition at line 831 of file CbcModel.hpp.
References maximumCutPasses_.
|
inline |
Get the maximum number of cut passes at other nodes (default 10)
Definition at line 836 of file CbcModel.hpp.
References maximumCutPasses_.
|
inline |
Get current cut pass number in this round of cuts.
(1 is first pass)
Definition at line 842 of file CbcModel.hpp.
References currentPassNumber_.
|
inline |
Set current cut pass number in this round of cuts.
(1 is first pass)
Definition at line 848 of file CbcModel.hpp.
References currentPassNumber_.
void CbcModel::setNumberStrong | ( | int | number | ) |
Set the maximum number of candidates to be evaluated for strong branching.
A value of 0 disables strong branching.
|
inline |
Get the maximum number of candidates to be evaluated for strong branching.
Definition at line 862 of file CbcModel.hpp.
References numberStrong_.
|
inline |
Set global preferred way to branch -1 down, +1 up, 0 no preference.
Definition at line 868 of file CbcModel.hpp.
References preferredWay_.
|
inline |
Get the preferred way to branch (default 0)
Definition at line 873 of file CbcModel.hpp.
References preferredWay_.
|
inline |
|
inline |
bool CbcModel::doCutsNow | ( | int | allowForTopOfTree | ) | const |
Return true if we want to do cuts If allowForTopOfTree zero then just does on multiples of depth if 1 then allows for doing at top of tree if 2 then says if cuts allowed anywhere apart from root.
void CbcModel::setNumberBeforeTrust | ( | int | number | ) |
Set the number of branches before pseudo costs believed in dynamic strong branching.
A value of 0 disables dynamic strong branching.
|
inline |
get the number of branches before pseudo costs believed in dynamic strong branching.
Definition at line 902 of file CbcModel.hpp.
References numberBeforeTrust_.
void CbcModel::setNumberPenalties | ( | int | number | ) |
Set the number of variables for which to compute penalties in dynamic strong branching.
A value of 0 disables penalties.
|
inline |
get the number of variables for which to compute penalties in dynamic strong branching.
Definition at line 914 of file CbcModel.hpp.
References numberPenalties_.
|
inline |
|
inline |
Number of analyze iterations to do.
Definition at line 924 of file CbcModel.hpp.
References numberAnalyzeIterations_.
|
inline |
Set an integer parameter.
Definition at line 928 of file CbcModel.hpp.
References numberAnalyzeIterations_.
|
inline |
Get scale factor to make penalties match strong.
Should/will be computed
Definition at line 934 of file CbcModel.hpp.
References penaltyScaleFactor_.
void CbcModel::setPenaltyScaleFactor | ( | double | value | ) |
Set scale factor to make penalties match strong.
Should/will be computed
|
inline |
Problem type as set by user or found by analysis.
This will be extended 0 - not known 1 - Set partitioning <= 2 - Set partitioning == 3 - Set covering 4 - all +- 1 or all +1 and odd
Definition at line 948 of file CbcModel.hpp.
References problemType_.
|
inline |
|
inline |
void CbcModel::setHowOftenGlobalScan | ( | int | number | ) |
Set how often to scan global cuts.
|
inline |
Get how often to scan global cuts.
Definition at line 965 of file CbcModel.hpp.
References howOftenGlobalScan_.
|
inline |
Original columns as created by integerPresolve or preprocessing.
Definition at line 970 of file CbcModel.hpp.
References originalColumns_.
void CbcModel::setOriginalColumns | ( | const int * | originalColumns, |
int | numberGood = COIN_INT_MAX |
||
) |
Set original columns as created by preprocessing.
OsiRowCut* CbcModel::conflictCut | ( | const OsiSolverInterface * | solver, |
bool & | localCuts | ||
) |
Create conflict cut (well - most of)
|
inline |
Set the print frequency.
Controls the number of nodes evaluated between status prints. If number <=0
the print frequency is set to 100 nodes for large problems, 1000 for small problems. Print frequency has very slight overhead if small.
Definition at line 987 of file CbcModel.hpp.
References printFrequency_.
|
inline |
bool CbcModel::isAbandoned | ( | ) | const |
Are there a numerical difficulties?
bool CbcModel::isProvenOptimal | ( | ) | const |
Is optimality proven?
bool CbcModel::isProvenInfeasible | ( | ) | const |
Is infeasiblity proven (or none better than cutoff)?
bool CbcModel::isContinuousUnbounded | ( | ) | const |
Was continuous solution unbounded.
bool CbcModel::isProvenDualInfeasible | ( | ) | const |
Was continuous solution unbounded.
bool CbcModel::isNodeLimitReached | ( | ) | const |
Node limit reached?
Referenced by OsiCbcSolverInterface::isNodeLimitReached().
bool CbcModel::isSecondsLimitReached | ( | ) | const |
Time limit reached?
bool CbcModel::isSolutionLimitReached | ( | ) | const |
Solution limit reached?
Referenced by OsiCbcSolverInterface::isSolutionLimitReached().
|
inline |
Get how many iterations it took to solve the problem.
Definition at line 1018 of file CbcModel.hpp.
References numberIterations_.
|
inline |
Increment how many iterations it took to solve the problem.
Definition at line 1023 of file CbcModel.hpp.
References numberIterations_.
|
inline |
Get how many Nodes it took to solve the problem (including those in complete fathoming B&B inside CLP).
Definition at line 1028 of file CbcModel.hpp.
References numberNodes_.
Referenced by OsiCbcSolverInterface::getNodeCount().
|
inline |
Increment how many nodes it took to solve the problem.
Definition at line 1033 of file CbcModel.hpp.
References numberNodes_.
|
inline |
Get how many Nodes were enumerated in complete fathoming B&B inside CLP.
Definition at line 1038 of file CbcModel.hpp.
References numberExtraNodes_.
|
inline |
Get how many times complete fathoming B&B was done.
Definition at line 1043 of file CbcModel.hpp.
References numberFathoms_.
|
inline |
Final status of problem Some of these can be found out by is......
functions -1 before branchAndBound 0 finished - check isProvenOptimal or isProvenInfeasible to see if solution found (or check value of best solution) 1 stopped - on maxnodes, maxsols, maxtime 2 difficulties so run was abandoned (5 event user programmed event occurred)
Definition at line 1056 of file CbcModel.hpp.
References status_.
Referenced by OsiCbcSolverInterface::status().
|
inline |
Are there a numerical difficulties?
Definition at line 1060 of file CbcModel.hpp.
References status_.
|
inline |
Secondary status of problem -1 unset (status_ will also be -1) 0 search completed with solution 1 linear relaxation not feasible (or worse than cutoff) 2 stopped on gap 3 stopped on nodes 4 stopped on time 5 stopped on user event 6 stopped on solutions 7 linear relaxation unbounded 8 stopped on iteration limit.
Definition at line 1076 of file CbcModel.hpp.
References secondaryStatus_.
|
inline |
Are there a numerical difficulties?
Definition at line 1080 of file CbcModel.hpp.
References secondaryStatus_.
bool CbcModel::isInitialSolveAbandoned | ( | ) | const |
Are there numerical difficulties (for initialSolve) ?
bool CbcModel::isInitialSolveProvenOptimal | ( | ) | const |
Is optimality proven (for initialSolve) ?
bool CbcModel::isInitialSolveProvenPrimalInfeasible | ( | ) | const |
Is primal infeasiblity proven (for initialSolve) ?
bool CbcModel::isInitialSolveProvenDualInfeasible | ( | ) | const |
Is dual infeasiblity proven (for initialSolve) ?
|
inline |
Number of rows in continuous (root) problem.
Definition at line 1109 of file CbcModel.hpp.
|
inline |
Get number of columns.
Definition at line 1115 of file CbcModel.hpp.
References OsiSolverInterface::getNumCols(), and solver_.
|
inline |
Get number of rows.
Definition at line 1121 of file CbcModel.hpp.
References OsiSolverInterface::getNumRows(), and solver_.
|
inline |
Get number of nonzero elements.
Definition at line 1127 of file CbcModel.hpp.
References OsiSolverInterface::getNumElements(), and solver_.
|
inline |
Number of integers in problem.
Definition at line 1133 of file CbcModel.hpp.
References numberIntegers_.
|
inline |
Number of rows in continuous (root) problem.
Definition at line 1138 of file CbcModel.hpp.
References integerVariable_.
|
inline |
|
inline |
|
inline |
Get pointer to array[getNumCols()] of column lower bounds.
Definition at line 1156 of file CbcModel.hpp.
References OsiSolverInterface::getColLower(), and solver_.
|
inline |
Get pointer to array[getNumCols()] of column upper bounds.
Definition at line 1162 of file CbcModel.hpp.
References OsiSolverInterface::getColUpper(), and solver_.
|
inline |
Get pointer to array[getNumRows()] of row constraint senses.
Definition at line 1176 of file CbcModel.hpp.
References OsiSolverInterface::getRowSense(), and solver_.
|
inline |
Get pointer to array[getNumRows()] of rows right-hand sides.
Definition at line 1189 of file CbcModel.hpp.
References OsiSolverInterface::getRightHandSide(), and solver_.
|
inline |
Get pointer to array[getNumRows()] of row ranges.
Definition at line 1202 of file CbcModel.hpp.
References OsiSolverInterface::getRowRange(), and solver_.
|
inline |
Get pointer to array[getNumRows()] of row lower bounds.
Definition at line 1208 of file CbcModel.hpp.
References OsiSolverInterface::getRowLower(), and solver_.
|
inline |
Get pointer to array[getNumRows()] of row upper bounds.
Definition at line 1214 of file CbcModel.hpp.
References OsiSolverInterface::getRowUpper(), and solver_.
|
inline |
Get pointer to array[getNumCols()] of objective function coefficients.
Definition at line 1220 of file CbcModel.hpp.
References OsiSolverInterface::getObjCoefficients(), and solver_.
|
inline |
Get objective function sense (1 for min (default), -1 for max)
Definition at line 1226 of file CbcModel.hpp.
References CbcOptimizationDirection, and dblParam_.
|
inline |
Return true if variable is continuous.
Definition at line 1233 of file CbcModel.hpp.
References OsiSolverInterface::isContinuous(), and solver_.
|
inline |
Return true if variable is binary.
Definition at line 1239 of file CbcModel.hpp.
References OsiSolverInterface::isBinary(), and solver_.
|
inline |
Return true if column is integer.
Note: This function returns true if the the column is binary or a general integer.
Definition at line 1248 of file CbcModel.hpp.
References OsiSolverInterface::isInteger(), and solver_.
|
inline |
Return true if variable is general integer.
Definition at line 1254 of file CbcModel.hpp.
References OsiSolverInterface::isIntegerNonBinary(), and solver_.
|
inline |
Return true if variable is binary and not fixed at either bound.
Definition at line 1260 of file CbcModel.hpp.
References OsiSolverInterface::isFreeBinary(), and solver_.
|
inline |
Get pointer to row-wise copy of matrix.
Definition at line 1266 of file CbcModel.hpp.
References OsiSolverInterface::getMatrixByRow(), and solver_.
|
inline |
Get pointer to column-wise copy of matrix.
Definition at line 1272 of file CbcModel.hpp.
References OsiSolverInterface::getMatrixByCol(), and solver_.
|
inline |
Get solver's value for infinity.
Definition at line 1278 of file CbcModel.hpp.
References OsiSolverInterface::getInfinity(), and solver_.
|
inline |
Get pointer to array[getNumCols()] (for speed) of column lower bounds.
Definition at line 1283 of file CbcModel.hpp.
References cbcColLower_.
|
inline |
Get pointer to array[getNumCols()] (for speed) of column upper bounds.
Definition at line 1288 of file CbcModel.hpp.
References cbcColUpper_.
|
inline |
Get pointer to array[getNumRows()] (for speed) of row lower bounds.
Definition at line 1293 of file CbcModel.hpp.
References cbcRowLower_.
|
inline |
Get pointer to array[getNumRows()] (for speed) of row upper bounds.
Definition at line 1298 of file CbcModel.hpp.
References cbcRowUpper_.
|
inline |
Get pointer to array[getNumCols()] (for speed) of primal solution vector.
Definition at line 1303 of file CbcModel.hpp.
References cbcColSolution_.
|
inline |
Get pointer to array[getNumRows()] (for speed) of dual prices.
Definition at line 1308 of file CbcModel.hpp.
References cbcRowPrice_.
|
inline |
Get a pointer to array[getNumCols()] (for speed) of reduced costs.
Definition at line 1313 of file CbcModel.hpp.
References cbcReducedCost_.
|
inline |
Get pointer to array[getNumRows()] (for speed) of row activity levels.
Definition at line 1318 of file CbcModel.hpp.
References cbcRowActivity_.
|
inline |
Holds solution at continuous (after cuts if branchAndBound called)
Definition at line 1327 of file CbcModel.hpp.
|
inline |
Array marked whenever a solution is found if non-zero.
Code marks if heuristic returns better so heuristic need only mark if it wants to on solutions which are worse than current
Definition at line 1335 of file CbcModel.hpp.
References usedInSolution_.
void CbcModel::incrementUsed | ( | const double * | solution | ) |
Increases usedInSolution for nonzeros.
void CbcModel::setBestSolution | ( | CBC_Message | how, |
double & | objectiveValue, | ||
const double * | solution, | ||
int | fixVariables = 0 |
||
) |
Record a new incumbent solution and update objectiveValue.
void CbcModel::setBestObjectiveValue | ( | double | objectiveValue | ) |
Just update objectiveValue.
CbcEventHandler::CbcAction CbcModel::dealWithEventHandler | ( | CbcEventHandler::CbcEvent | event, |
double | objValue, | ||
const double * | solution | ||
) |
Deals with event handler and solution.
|
virtual |
Call this to really test if a valid solution can be feasible Solution is number columns in size.
If fixVariables true then bounds of continuous solver updated. Returns objective value (worse than cutoff if not feasible) Previously computed objective value is now passed in (in case user does not do solve)
virtual so user can override
bool CbcModel::feasibleSolution | ( | int & | numberIntegerInfeasibilities, |
int & | numberObjectInfeasibilities | ||
) | const |
Test the current solution for feasiblility.
Scan all objects for indications of infeasibility. This is broken down into simple integer infeasibility (numberIntegerInfeasibilities
) and all other reports of infeasibility (numberObjectInfeasibilities
).
|
inline |
Solution to the most recent lp relaxation.
The solver's solution to the most recent lp relaxation.
Definition at line 1375 of file CbcModel.hpp.
References currentSolution_.
|
inline |
For testing infeasibilities - will point to currentSolution_ or solver–>getColSolution()
Definition at line 1382 of file CbcModel.hpp.
References testSolution_.
|
inline |
Holds solution at continuous (after cuts if branchAndBound called)
Definition at line 1386 of file CbcModel.hpp.
References testSolution_.
void CbcModel::reserveCurrentSolution | ( | const double * | solution = NULL | ) |
Make sure region there and optionally copy solution.
|
inline |
Get pointer to array[getNumCols()] of primal solution vector.
Definition at line 1394 of file CbcModel.hpp.
References OsiSolverInterface::getColSolution(), and solver_.
|
inline |
Get pointer to array[getNumRows()] of dual prices.
Definition at line 1400 of file CbcModel.hpp.
References OsiSolverInterface::getRowPrice(), and solver_.
|
inline |
Get a pointer to array[getNumCols()] of reduced costs.
Definition at line 1406 of file CbcModel.hpp.
References OsiSolverInterface::getReducedCost(), and solver_.
|
inline |
Get pointer to array[getNumRows()] of row activity levels.
Definition at line 1412 of file CbcModel.hpp.
References OsiSolverInterface::getRowActivity(), and solver_.
|
inline |
Get current objective function value.
Definition at line 1418 of file CbcModel.hpp.
References CbcCurrentObjectiveValue, and dblParam_.
|
inline |
Get current minimization objective function value.
Definition at line 1423 of file CbcModel.hpp.
References CbcCurrentMinimizationObjectiveValue, and dblParam_.
|
inline |
Get best objective function value as minimization.
Definition at line 1429 of file CbcModel.hpp.
References bestObjective_.
|
inline |
Set best objective function value as minimization.
Definition at line 1434 of file CbcModel.hpp.
References bestObjective_.
|
inline |
Get best objective function value.
Definition at line 1440 of file CbcModel.hpp.
References bestObjective_, OsiSolverInterface::getObjSense(), and solver_.
double CbcModel::getBestPossibleObjValue | ( | ) | const |
Get best possible objective function value.
This is better of best possible left on tree and best solution found. If called from within branch and cut may be optimistic.
|
inline |
Set best objective function value.
Definition at line 1451 of file CbcModel.hpp.
References bestObjective_, OsiSolverInterface::getObjSense(), and solver_.
|
inline |
Get solver objective function value (as minimization)
Definition at line 1456 of file CbcModel.hpp.
References OsiSolverInterface::getObjSense(), OsiSolverInterface::getObjValue(), and solver_.
|
inline |
The best solution to the integer programming problem.
The best solution to the integer programming problem found during the search. If no solution is found, the method returns null.
Definition at line 1467 of file CbcModel.hpp.
References bestSolution_.
void CbcModel::setBestSolution | ( | const double * | solution, |
int | numberColumns, | ||
double | objectiveValue, | ||
bool | check = false |
||
) |
User callable setBestSolution.
If check false does not check valid If true then sees if feasible and warns if objective value worse than given (so just set to COIN_DBL_MAX if you don't care). If check true then does not save solution if not feasible
|
inline |
|
inline |
Set number of solutions (so heuristics will be different)
Definition at line 1487 of file CbcModel.hpp.
References numberSolutions_.
int CbcModel::numberSavedSolutions | ( | ) | const |
Number of saved solutions (including best)
|
inline |
Maximum number of extra saved solutions.
Definition at line 1494 of file CbcModel.hpp.
References maximumSavedSolutions_.
void CbcModel::setMaximumSavedSolutions | ( | int | value | ) |
Set maximum number of extra saved solutions.
const double* CbcModel::savedSolution | ( | int | which | ) | const |
Return a saved solution (0==best) - NULL if off end.
double CbcModel::savedSolutionObjective | ( | int | which | ) | const |
Return a saved solution objective (0==best) - COIN_DBL_MAX if off end.
void CbcModel::deleteSavedSolution | ( | int | which | ) |
Delete a saved solution and move others up.
|
inline |
Current phase (so heuristics etc etc can find out).
0 - initial solve 1 - solve with cuts at root 2 - solve with cuts 3 - other e.g. strong branching 4 - trying to validate a solution 5 - at end of search
Definition at line 1515 of file CbcModel.hpp.
References phase_.
|
inline |
Get number of heuristic solutions.
Definition at line 1521 of file CbcModel.hpp.
References numberHeuristicSolutions_.
|
inline |
Set number of heuristic solutions.
Definition at line 1526 of file CbcModel.hpp.
References numberHeuristicSolutions_.
|
inline |
Set objective function sense (1 for min (default), -1 for max,)
Definition at line 1532 of file CbcModel.hpp.
References CbcOptimizationDirection, dblParam_, OsiSolverInterface::setObjSense(), and solver_.
|
inline |
Value of objective at continuous.
Definition at line 1539 of file CbcModel.hpp.
References originalContinuousObjective_.
|
inline |
Holds solution at continuous (after cuts if branchAndBound called)
Definition at line 1543 of file CbcModel.hpp.
References originalContinuousObjective_.
|
inline |
Number of infeasibilities at continuous.
Definition at line 1548 of file CbcModel.hpp.
References continuousInfeasibilities_.
|
inline |
Holds solution at continuous (after cuts if branchAndBound called)
Definition at line 1552 of file CbcModel.hpp.
References continuousInfeasibilities_.
|
inline |
Value of objective after root node cuts added.
Definition at line 1557 of file CbcModel.hpp.
References continuousObjective_.
|
inline |
Sum of Changes to objective by first solve.
Definition at line 1562 of file CbcModel.hpp.
References sumChangeObjective1_.
|
inline |
Number of times global cuts violated.
When global cut pool then this should be kept for each cut and type of cut
Definition at line 1568 of file CbcModel.hpp.
References numberGlobalViolations_.
|
inline |
Holds solution at continuous (after cuts if branchAndBound called)
Definition at line 1572 of file CbcModel.hpp.
References numberGlobalViolations_.
|
inline |
Whether to force a resolve after takeOffCuts.
Definition at line 1577 of file CbcModel.hpp.
References resolveAfterTakeOffCuts_.
|
inline |
Holds solution at continuous (after cuts if branchAndBound called)
Definition at line 1581 of file CbcModel.hpp.
References resolveAfterTakeOffCuts_.
|
inline |
|
inline |
Work basis for temporary use.
Definition at line 1591 of file CbcModel.hpp.
References workingBasis_.
|
inline |
Get number of "iterations" to stop after.
Definition at line 1596 of file CbcModel.hpp.
References stopNumberIterations_.
|
inline |
Set number of "iterations" to stop after.
Definition at line 1601 of file CbcModel.hpp.
References stopNumberIterations_.
|
inline |
A pointer to model from CbcHeuristic.
Definition at line 1606 of file CbcModel.hpp.
References heuristicModel_.
|
inline |
Set a pointer to model from CbcHeuristic.
Definition at line 1611 of file CbcModel.hpp.
References heuristicModel_.
|
inline |
Definition at line 1620 of file CbcModel.hpp.
References nodeCompare_.
void CbcModel::setNodeComparison | ( | CbcCompareBase * | compare | ) |
void CbcModel::setNodeComparison | ( | CbcCompareBase & | compare | ) |
|
inline |
Definition at line 1631 of file CbcModel.hpp.
References problemFeasibility_.
void CbcModel::setProblemFeasibility | ( | CbcFeasibilityBase * | feasibility | ) |
void CbcModel::setProblemFeasibility | ( | CbcFeasibilityBase & | feasibility | ) |
|
inline |
Tree method e.g. heap (which may be overridden by inheritance)
Definition at line 1642 of file CbcModel.hpp.
void CbcModel::passInTreeHandler | ( | CbcTree & | tree | ) |
For modifying tree handling (original is cloned)
void CbcModel::passInSubTreeModel | ( | CbcModel & | model | ) |
For passing in an CbcModel to do a sub Tree (with derived tree handlers).
Passed in model must exist for duration of branch and bound
CbcModel* CbcModel::subTreeModel | ( | OsiSolverInterface * | solver = NULL | ) | const |
For retrieving a copy of subtree model with given OsiSolver.
If no subtree model will use self (up to user to reset cutoff etc). If solver NULL uses current
|
inline |
Returns number of times any subtree stopped on nodes, time etc.
Definition at line 1658 of file CbcModel.hpp.
References numberStoppedSubTrees_.
|
inline |
Says a sub tree was stopped.
Definition at line 1663 of file CbcModel.hpp.
References numberStoppedSubTrees_.
|
inline |
Whether to automatically do presolve before branch and bound (subTrees).
0 - no 1 - ordinary presolve 2 - integer presolve (dodgy)
Definition at line 1672 of file CbcModel.hpp.
References presolve_.
|
inline |
Tree method e.g. heap (which may be overridden by inheritance)
Definition at line 1676 of file CbcModel.hpp.
References presolve_.
|
inline |
Get the current branching decision method.
Definition at line 1690 of file CbcModel.hpp.
References branchingMethod_.
|
inline |
Set the branching decision method.
Definition at line 1695 of file CbcModel.hpp.
References branchingMethod_, and CbcBranchDecision::clone().
|
inline |
Set the branching method.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Definition at line 1704 of file CbcModel.hpp.
References branchingMethod_, and CbcBranchDecision::clone().
|
inline |
Get the current cut modifier method.
Definition at line 1710 of file CbcModel.hpp.
References cutModifier_.
void CbcModel::setCutModifier | ( | CbcCutModifier * | modifier | ) |
Set the cut modifier method.
void CbcModel::setCutModifier | ( | CbcCutModifier & | modifier | ) |
Set the cut modifier method.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
|
inline |
State of search 0 - no solution 1 - only heuristic solutions 2 - branched to a solution 3 - no solution but many nodes.
Definition at line 1732 of file CbcModel.hpp.
References stateOfSearch_.
|
inline |
State of search 0 - no solution 1 - only heuristic solutions 2 - branched to a solution 3 - no solution but many nodes.
Definition at line 1736 of file CbcModel.hpp.
References stateOfSearch_.
|
inline |
Strategy worked out - mainly at root node for use by CbcNode.
Definition at line 1741 of file CbcModel.hpp.
References searchStrategy_.
|
inline |
Set strategy worked out - mainly at root node for use by CbcNode.
Definition at line 1746 of file CbcModel.hpp.
References searchStrategy_.
|
inline |
|
inline |
Set strong branching strategy.
Definition at line 1756 of file CbcModel.hpp.
References strongStrategy_.
|
inline |
Get the number of cut generators.
Definition at line 1762 of file CbcModel.hpp.
References numberCutGenerators_.
|
inline |
Get the list of cut generators.
Definition at line 1767 of file CbcModel.hpp.
References generator_.
|
inline |
Get the specified cut generator.
Definition at line 1772 of file CbcModel.hpp.
References generator_.
|
inline |
Get the specified cut generator before any changes.
Definition at line 1777 of file CbcModel.hpp.
References virginGenerator_.
void CbcModel::addCutGenerator | ( | CglCutGenerator * | generator, |
int | howOften = 1 , |
||
const char * | name = NULL , |
||
bool | normal = true , |
||
bool | atSolution = false , |
||
bool | infeasible = false , |
||
int | howOftenInSub = -100 , |
||
int | whatDepth = -1 , |
||
int | whatDepthInSub = -1 |
||
) |
Add one generator - up to user to delete generators.
howoften affects how generator is used. 0 or 1 means always, >1 means every that number of nodes. Negative values have same meaning as positive but they may be switched off (-> -100) by code if not many cuts generated at continuous. -99 is just done at root. Name is just for printout. If depth >0 overrides how often generator is called (if howOften==-1 or >0).
|
inline |
Get the current strategy.
Definition at line 1802 of file CbcModel.hpp.
References strategy_.
Referenced by setStrategy().
void CbcModel::setStrategy | ( | CbcStrategy & | strategy | ) |
Set the strategy. Clones.
|
inline |
Set the strategy. assigns.
Definition at line 1809 of file CbcModel.hpp.
References strategy(), and strategy_.
|
inline |
Get the current parent model.
Definition at line 1814 of file CbcModel.hpp.
References parentModel_.
Referenced by setParentModel().
|
inline |
Set the parent model.
Definition at line 1819 of file CbcModel.hpp.
References parentModel(), and parentModel_.
void CbcModel::addHeuristic | ( | CbcHeuristic * | generator, |
const char * | name = NULL , |
||
int | before = -1 |
||
) |
Add one heuristic - up to user to delete.
The name is just used for print messages.
|
inline |
|
inline |
Get the number of heuristics.
Definition at line 1839 of file CbcModel.hpp.
References numberHeuristics_.
|
inline |
Set the number of heuristics.
Definition at line 1844 of file CbcModel.hpp.
References numberHeuristics_.
|
inline |
Pointer to heuristic solver which found last solution (or NULL)
Definition at line 1849 of file CbcModel.hpp.
References lastHeuristic_.
|
inline |
set last heuristic which found a solution
Definition at line 1854 of file CbcModel.hpp.
References lastHeuristic_.
void CbcModel::passInPriorities | ( | const int * | priorities, |
bool | ifNotSimpleIntegers | ||
) |
Pass in branching priorities.
If ifClique then priorities are on cliques otherwise priorities are on integer variables. Other type (if exists set to default) 1 is highest priority. (well actually -INT_MAX is but that's ugly) If hotstart > 0 then branches are created to force the variable to the value given by best solution. This enables a sort of hot start. The node choice should be greatest depth and hotstart should normally be switched off after a solution.
If ifNotSimpleIntegers true then appended to normal integers
This is now deprecated except for simple usage. If user creates Cbcobjects then set priority in them
|
inline |
Returns priority level for an object (or 1000 if no priorities exist)
Definition at line 1880 of file CbcModel.hpp.
References object_, and OsiObject::priority().
void CbcModel::passInEventHandler | ( | const CbcEventHandler * | eventHandler | ) |
Set an event handler.
A clone of the handler passed as a parameter is stored in CbcModel.
|
inline |
Retrieve a pointer to the event handler.
Definition at line 1892 of file CbcModel.hpp.
References eventHandler_.
void CbcModel::setApplicationData | ( | void * | appData | ) |
Set application data.
This is a pointer that the application can store into and retrieve from the solver interface. This field is available for the application to optionally define and use.
void* CbcModel::getApplicationData | ( | ) | const |
Get application data.
void CbcModel::passInSolverCharacteristics | ( | OsiBabSolver * | solverCharacteristics | ) |
For advanced applications you may wish to modify the behavior of Cbc e.g.
if the solver is a NLP solver then you may not have an exact optimum solution at each step. Information could be built into OsiSolverInterface but this is an alternative so that that interface does not have to be changed. If something similar is useful to enough solvers then it could be migrated You can also pass in by using solver->setAuxiliaryInfo. You should do that if solver is odd - if solver is normal simplex then use this. NOTE - characteristics are not cloned
|
inline |
Get solver characteristics.
Definition at line 1926 of file CbcModel.hpp.
References solverCharacteristics_.
void CbcModel::passInMessageHandler | ( | CoinMessageHandler * | handler | ) |
Pass in Message handler (not deleted at end)
void CbcModel::newLanguage | ( | CoinMessages::Language | language | ) |
Set language.
Referenced by setLanguage().
|
inline |
Pass in Message handler (not deleted at end)
Definition at line 1940 of file CbcModel.hpp.
References newLanguage().
|
inline |
|
inline |
|
inline |
void CbcModel::setLogLevel | ( | int | value | ) |
Set log level.
|
inline |
Get log level.
Definition at line 1962 of file CbcModel.hpp.
References handler_, and CoinMessageHandler::logLevel().
|
inline |
Set flag to say if handler_ is the default handler.
The default handler is deleted when the model is deleted. Other handlers (supplied by the client) will not be deleted.
Definition at line 1971 of file CbcModel.hpp.
References defaultHandler_.
|
inline |
|
inline |
Set special options 0 bit (1) - check if cuts valid (if on debugger list) 1 bit (2) - use current basis to check integer solution (rather than all slack) 2 bit (4) - don't check integer solution (by solving LP) 3 bit (8) - fast analyze 4 bit (16) - non-linear model - so no well defined CoinPackedMatrix 5 bit (32) - keep names 6 bit (64) - try for dominated columns 7 bit (128) - SOS type 1 but all declared integer 8 bit (256) - Set to say solution just found, unset by doing cuts 9 bit (512) - Try reduced model after 100 nodes 10 bit (1024) - Switch on some heuristics even if seems unlikely 11 bit (2048) - Mark as in small branch and bound 12 bit (4096) - Funny cuts so do slow way (in some places) 13 bit (8192) - Funny cuts so do slow way (in other places) 14 bit (16384) - Use Cplex! for fathoming 15 bit (32768) - Try reduced model after 0 nodes 16 bit (65536) - Original model had integer bounds 17 bit (131072) - Perturbation switched off 18 bit (262144) - donor CbcModel 19 bit (524288) - recipient CbcModel 20 bit (1048576) - waiting for sub model to return
22 bit (4194304) - do not initialize random seed in solver (user has) 23 bit (8388608) - leave solver_ with cuts 24 bit (16777216) - just get feasible if no cutoff 25 bit (33554432) - feasibility pump after root cuts 26 bit (67108864) - child model but going for complete search
Definition at line 2014 of file CbcModel.hpp.
References specialOptions_.
|
inline |
|
inline |
|
inline |
|
inline |
Set multiple root tries.
Definition at line 2034 of file CbcModel.hpp.
References multipleRootTries_.
|
inline |
Get multiple root tries.
Definition at line 2039 of file CbcModel.hpp.
References multipleRootTries_.
|
inline |
Tell model to stop on event.
Definition at line 2044 of file CbcModel.hpp.
References eventHappened_.
|
inline |
Says if normal solver i.e. has well defined CoinPackedMatrix.
Definition at line 2049 of file CbcModel.hpp.
References specialOptions_.
|
inline |
Says if model is sitting there waiting for mini branch and bound to finish This is because an event handler may only have access to parent model in mini branch and bound.
Definition at line 2057 of file CbcModel.hpp.
References specialOptions_.
|
inline |
Set more special options at present bottom 6 bits used for shadow price mode 1024 for experimental hotstart 2048,4096 breaking out of cuts 8192 slowly increase minimum drop 16384 gomory 32768 more heuristics in sub trees 65536 no cuts in preprocessing 131072 Time limits elapsed 18 bit (262144) - Perturb fathom nodes 19 bit (524288) - No limit on fathom nodes 20 bit (1048576) - Reduce sum of infeasibilities before cuts 21 bit (2097152) - Reduce sum of infeasibilities after cuts 22 bit (4194304) - Conflict analysis 23 bit (8388608) - Conflict analysis - temporary bit 24 bit (16777216) - Add cutoff as LP constraint (out) 25 bit (33554432) - diving/reordering 26 bit (67108864) - load global cuts from file 27 bit (134217728) - append binding global cuts to file 28 bit (268435456) - idiot branching 29 bit (536870912) - don't make fake objective 30 bit (1073741824) - Funny SOS or similar - be careful.
Definition at line 2084 of file CbcModel.hpp.
References moreSpecialOptions_.
|
inline |
Get more special options.
Definition at line 2089 of file CbcModel.hpp.
References moreSpecialOptions_.
|
inline |
Set more more special options 0 bit (1) - find switching variables 1 bit (2) - using fake objective until solution 2 bit (4) - switching variables exist 3 bit (8) - skip most of setBestSolution checks 4 bit (16) - very lightweight preprocessing in smallB&B 5 bit (32) - event handler needs to be cloned when parallel 6 bit (64) - testing - use probing to make cliques 7/8 bit (128) - try orbital branching (if nauty) 9 bit (512) - branching on objective (later) 10 bit (1024) - branching on constraints (later) 11/12 bit 2048 - intermittent cuts 13/14 bit 8192 - go to bitter end in strong branching (first time) 15 bit 32768 - take care of very very small values for Integer/SOS variables.
Definition at line 2108 of file CbcModel.hpp.
References moreSpecialOptions2_.
|
inline |
Get more special options2.
Definition at line 2113 of file CbcModel.hpp.
References moreSpecialOptions2_.
|
inline |
Set cutoff as constraint.
Definition at line 2118 of file CbcModel.hpp.
References cutoffRowNumber_.
|
inline |
|
inline |
|
inline |
Get useful temporary pointer.
Definition at line 2136 of file CbcModel.hpp.
References temporaryPointer_.
|
inline |
Set useful temporary pointer.
Definition at line 2141 of file CbcModel.hpp.
References temporaryPointer_.
void CbcModel::goToDantzig | ( | int | numberNodes, |
ClpDualRowPivot *& | savePivotMethod | ||
) |
Go to dantzig pivot selection if easy problem (clp only)
|
inline |
Now we may not own objects - just point to solver's objects.
Definition at line 2148 of file CbcModel.hpp.
References ownObjects_.
void CbcModel::checkModel | ( | ) |
Check original model before it gets messed up.
void CbcModel::assignSolver | ( | OsiSolverInterface *& | solver, |
bool | deleteSolver = true |
||
) |
Assign a solver to the model (model assumes ownership)
On return, solver
will be NULL. If deleteSolver then current solver deleted (if model owned)
|
inline |
Set ownership of solver.
A parameter of false tells CbcModel it does not own the solver and should not delete it. Once you claim ownership of the solver, you're responsible for eventually deleting it. Note that CbcModel clones solvers with abandon. Unless you have a deep understanding of the workings of CbcModel, the only time you want to claim ownership is when you're about to delete the CbcModel object but want the solver to continue to exist (as, for example, when branchAndBound has finished and you want to hang on to the answer).
Definition at line 2186 of file CbcModel.hpp.
References ownership_.
|
inline |
Get ownership of solver.
A return value of true means that CbcModel owns the solver and will take responsibility for deleting it when that becomes necessary.
Definition at line 2196 of file CbcModel.hpp.
References ownership_.
|
virtual |
Clone.
|
inline |
Returns solver - has current state.
Definition at line 2216 of file CbcModel.hpp.
References solver_.
Referenced by OsiCbcSolverInterface::getRealSolverPtr(), and swapSolver().
|
inline |
Returns current solver - sets new one.
Definition at line 2222 of file CbcModel.hpp.
|
inline |
Returns solver with continuous state.
Definition at line 2230 of file CbcModel.hpp.
References continuousSolver_.
|
inline |
Create solver with continuous state.
Definition at line 2236 of file CbcModel.hpp.
References OsiSolverInterface::clone(), continuousSolver_, and solver_.
|
inline |
Clear solver with continuous state.
Definition at line 2241 of file CbcModel.hpp.
References continuousSolver_.
|
inline |
A copy of the solver, taken at constructor or by saveReferenceSolver.
Definition at line 2248 of file CbcModel.hpp.
References referenceSolver_.
void CbcModel::saveReferenceSolver | ( | ) |
Save a copy of the current solver so can be reset to.
void CbcModel::resetToReferenceSolver | ( | ) |
Uses a copy of reference solver to be current solver.
Because of possible mismatches all exotic integer information is loat (apart from normal information in OsiSolverInterface) so SOS etc and priorities will have to be redone
void CbcModel::gutsOfDestructor | ( | ) |
Clears out as much as possible (except solver)
void CbcModel::gutsOfDestructor2 | ( | ) |
Clears out enough to reset CbcModel as if no branch and bound done.
void CbcModel::resetModel | ( | ) |
Clears out enough to reset CbcModel cutoff etc.
void CbcModel::gutsOfCopy | ( | const CbcModel & | rhs, |
int | mode = 0 |
||
) |
Most of copy constructor mode - 0 copy but don't delete before 1 copy and delete before 2 copy and delete before (but use virgin generators)
void CbcModel::moveInfo | ( | const CbcModel & | rhs | ) |
Move status, nodes etc etc across.
|
static |
Indicates whether Cbc library has been compiled with multithreading support.
|
inline |
Get pointer to masterthread.
Definition at line 2286 of file CbcModel.hpp.
References masterThread_.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Set thread mode always use numberThreads for branching 1 set then deterministic 2 set then use numberThreads for root cuts 4 set then use numberThreads in root mini branch and bound 8 set and numberThreads - do heuristics numberThreads at a time 8 set and numberThreads==0 do all heuristics at once default is 0.
Definition at line 2319 of file CbcModel.hpp.
References threadMode_.
|
inline |
Return -2 if deterministic threaded and main thread -1 if deterministic threaded and serial thread 0 if serial 1 if opportunistic threaded.
Definition at line 2329 of file CbcModel.hpp.
References numberThreads_, and threadMode_.
|
inline |
bool CbcModel::isLocked | ( | ) | const |
From here to end of section - code in CbcThread.cpp until class changed Returns true if locked.
|
inline |
Get pointer to masterthread.
Definition at line 2363 of file CbcModel.hpp.
|
inline |
Get pointer to masterthread.
Definition at line 2366 of file CbcModel.hpp.
void CbcModel::setInfoInChild | ( | int | type, |
CbcThread * | info | ||
) |
Set information in a child -3 pass pointer to child thread info -2 just stop -1 delete simple child stuff 0 delete opportunistic child stuff 1 delete deterministic child stuff.
void CbcModel::moveToModel | ( | CbcModel * | baseModel, |
int | mode | ||
) |
Move/copy information from one model to another -1 - initialization 0 - from base model 1 - to base model (and reset) 2 - add in final statistics etc (and reset so can do clean destruction)
int CbcModel::splitModel | ( | int | numberModels, |
CbcModel ** | model, | ||
int | numberNodes | ||
) |
Split up nodes.
void CbcModel::startSplitModel | ( | int | numberIterations | ) |
Start threads.
void CbcModel::mergeModels | ( | int | numberModel, |
CbcModel ** | model, | ||
int | numberNodes | ||
) |
Merge models.
|
inline |
Get how many Nodes it took to solve the problem.
Definition at line 2396 of file CbcModel.hpp.
void CbcModel::setPointers | ( | const OsiSolverInterface * | solver | ) |
Set pointers for speed.
int CbcModel::reducedCostFix | ( | ) |
Perform reduced cost fixing.
Fixes integer variables at their current value based on reduced cost penalties. Returns number fixed
void CbcModel::synchronizeHandlers | ( | int | makeDefault | ) |
Makes all handlers same.
If makeDefault 1 then makes top level default and rest point to that. If 2 then each is copy
void CbcModel::saveExtraSolution | ( | const double * | solution, |
double | objectiveValue | ||
) |
Save a solution to saved list.
void CbcModel::saveBestSolution | ( | const double * | solution, |
double | objectiveValue | ||
) |
Save a solution to best and move current to saved.
void CbcModel::deleteSolutions | ( | ) |
Delete best and saved solutions.
int CbcModel::resolve | ( | OsiSolverInterface * | solver | ) |
Encapsulates solver resolve.
int CbcModel::chooseBranch | ( | CbcNode *& | newNode, |
int | numberPassesLeft, | ||
CbcNode * | oldNode, | ||
OsiCuts & | cuts, | ||
bool & | resolved, | ||
CoinWarmStartBasis * | lastws, | ||
const double * | lowerBefore, | ||
const double * | upperBefore, | ||
OsiSolverBranch *& | branches | ||
) |
Encapsulates choosing a variable - anyAction -2, infeasible (-1 round again), 0 done.
int CbcModel::chooseBranch | ( | CbcNode * | newNode, |
int | numberPassesLeft, | ||
bool & | resolved | ||
) |
Get how many Nodes it took to solve the problem.
CoinWarmStartBasis* CbcModel::getEmptyBasis | ( | int | ns = 0 , |
int | na = 0 |
||
) | const |
Return an empty basis object of the specified size.
A useful utility when constructing a basis for a subproblem from scratch. The object returned will be of the requested capacity and appropriate for the solver attached to the model.
int CbcModel::takeOffCuts | ( | OsiCuts & | cuts, |
bool | allowResolve, | ||
OsiCuts * | saveCuts, | ||
int | numberNewCuts = 0 , |
||
const OsiRowCut ** | newCuts = NULL |
||
) |
Remove inactive cuts from the model.
An OsiSolverInterface is expected to maintain a valid basis, but not a valid solution, when loose cuts are deleted. Restoring a valid solution requires calling the solver to reoptimise. If it's certain the solution will not be required, set allowResolve to false to suppress reoptimisation. If saveCuts then slack cuts will be saved On input current cuts are cuts and newCuts on exit current cuts will be correct. Returns number dropped
int CbcModel::addCuts | ( | CbcNode * | node, |
CoinWarmStartBasis *& | lastws | ||
) |
Determine and install the active cuts that need to be added for the current subproblem.
The whole truth is a bit more complicated. The first action is a call to addCuts1(). addCuts() then sorts through the list, installs the tight cuts in the model, and does bookkeeping (adjusts reference counts). The basis returned from addCuts1() is adjusted accordingly.
If it turns out that the node should really be fathomed by bound, addCuts() simply treats all the cuts as loose as it does the bookkeeping.
bool CbcModel::addCuts1 | ( | CbcNode * | node, |
CoinWarmStartBasis *& | lastws | ||
) |
Traverse the tree from node to root and prep the model.
addCuts1() begins the job of prepping the model to match the current subproblem. The model is stripped of all cuts, and the search tree is traversed from node to root to determine the changes required. Appropriate bounds changes are installed, a list of cuts is collected but not installed, and an appropriate basis (minus the cuts, but big enough to accommodate them) is constructed.
Returns true if new problem similar to old
void CbcModel::previousBounds | ( | CbcNode * | node, |
CbcNodeInfo * | where, | ||
int | iColumn, | ||
double & | lower, | ||
double & | upper, | ||
int | force | ||
) |
Returns bounds just before where - initially original bounds.
Also sets downstream nodes (lower if force 1, upper if 2)
Set objective value in a node.
This is separated out so that odd solvers can use. It may look at extra information in solverCharacteriscs_ and will also use bound from parent node
void CbcModel::convertToDynamic | ( | ) |
If numberBeforeTrust >0 then we are going to use CbcBranchDynamic.
Scan and convert CbcSimpleInteger objects
void CbcModel::synchronizeNumberBeforeTrust | ( | int | type = 0 | ) |
Set numberBeforeTrust in all objects.
void CbcModel::zapIntegerInformation | ( | bool | leaveObjects = true | ) |
Zap integer information in problem (may leave object info)
int CbcModel::cliquePseudoCosts | ( | int | doStatistics | ) |
Use cliques for pseudocost information - return nonzero if infeasible.
void CbcModel::pseudoShadow | ( | int | type | ) |
Fill in useful estimates.
void CbcModel::fillPseudoCosts | ( | double * | downCosts, |
double * | upCosts, | ||
int * | priority = NULL , |
||
int * | numberDown = NULL , |
||
int * | numberUp = NULL , |
||
int * | numberDownInfeasible = NULL , |
||
int * | numberUpInfeasible = NULL |
||
) | const |
Return pseudo costs If not all integers or not pseudo costs - returns all zero Length of arrays are numberIntegers() and entries correspond to integerVariable()[i] User must allocate arrays before call.
void CbcModel::doHeuristicsAtRoot | ( | int | deleteHeuristicsAfterwards = 0 | ) |
Do heuristics at root.
0 - don't delete 1 - delete 2 - just delete - don't even use
void CbcModel::adjustHeuristics | ( | ) |
Adjust heuristics based on model.
|
inline |
Get the hotstart solution.
Definition at line 2532 of file CbcModel.hpp.
References hotstartSolution_.
|
inline |
Get the hotstart priorities.
Definition at line 2537 of file CbcModel.hpp.
References hotstartPriorities_.
|
inline |
Return the list of cuts initially collected for this subproblem.
Definition at line 2543 of file CbcModel.hpp.
References addedCuts_.
|
inline |
Number of entries in the list returned by addedCuts()
Definition at line 2548 of file CbcModel.hpp.
References currentNumberCuts_.
|
inline |
|
inline |
void CbcModel::setNextRowCut | ( | const OsiRowCut & | cut | ) |
Copy and set a pointer to a row cut which will be added instead of normal branching.
|
inline |
Get a pointer to current node (be careful)
Definition at line 2565 of file CbcModel.hpp.
References currentNode_.
|
inline |
Get a pointer to probing info.
Definition at line 2570 of file CbcModel.hpp.
References probingInfo_.
|
inline |
Thread specific random number generator.
Definition at line 2575 of file CbcModel.hpp.
References randomNumberGenerator_.
|
inline |
Set the number of iterations done in strong branching.
Definition at line 2580 of file CbcModel.hpp.
References numberStrongIterations_.
|
inline |
Get the number of iterations done in strong branching.
Definition at line 2585 of file CbcModel.hpp.
References numberStrongIterations_.
|
inline |
Get maximum number of iterations (designed to be used in heuristics)
Definition at line 2590 of file CbcModel.hpp.
References maximumNumberIterations_.
|
inline |
Set maximum number of iterations (designed to be used in heuristics)
Definition at line 2595 of file CbcModel.hpp.
References maximumNumberIterations_.
|
inline |
Set depth for fast nodes.
Definition at line 2609 of file CbcModel.hpp.
|
inline |
|
inline |
Get anything with priority >= this can be treated as continuous.
Definition at line 2619 of file CbcModel.hpp.
References continuousPriority_.
|
inline |
Set anything with priority >= this can be treated as continuous.
Definition at line 2624 of file CbcModel.hpp.
References continuousPriority_.
|
inline |
Get how many Nodes it took to solve the problem.
Definition at line 2628 of file CbcModel.hpp.
References numberExtraIterations_, numberExtraNodes_, and numberFathoms_.
|
inline |
Zero extra.
Definition at line 2635 of file CbcModel.hpp.
References numberExtraIterations_, numberExtraNodes_, and numberFathoms_.
|
inline |
Number of extra iterations.
Definition at line 2642 of file CbcModel.hpp.
References numberExtraIterations_.
void CbcModel::incrementStrongInfo | ( | int | numberTimes, |
int | numberIterations, | ||
int | numberFixed, | ||
bool | ifInfeasible | ||
) |
Increment strong info.
|
inline |
|
inline |
|
inline |
Get stored row cuts for donor/recipient CbcModel.
Definition at line 2661 of file CbcModel.hpp.
References storedRowCuts_.
|
inline |
Set stored row cuts for donor/recipient CbcModel.
Definition at line 2666 of file CbcModel.hpp.
References storedRowCuts_.
|
inline |
Says whether all dynamic integers.
Definition at line 2671 of file CbcModel.hpp.
References ownership_.
void CbcModel::generateCpp | ( | FILE * | fp, |
int | options | ||
) |
Create C++ lines to get to current state.
OsiBranchingInformation CbcModel::usefulInformation | ( | ) | const |
Generate an OsiBranchingInformation object.
|
inline |
Warm start object produced by heuristic or strong branching.
If get a valid integer solution outside branch and bound then it can take a reasonable time to solve LP which produces clean solution. If this object has any size then it will be used in solve.
Definition at line 2685 of file CbcModel.hpp.
References bestSolutionBasis_.
void CbcModel::redoWalkBack | ( | ) |
Redo walkback arrays.
|
inline |
Definition at line 2693 of file CbcModel.hpp.
References mipStart_.
|
inline |
if original column names will be preserved in preprocessed problem
Definition at line 2700 of file CbcModel.hpp.
References keepNamesPreproc.
|
inline |
Definition at line 2705 of file CbcModel.hpp.
References keepNamesPreproc.
void CbcModel::setMIPStart | ( | int | count, |
const char ** | colNames, | ||
const double | colValues[] | ||
) |
may be safer to use this overload method: c++ string libraries implementation may not be binary compatible
|
inline |
Definition at line 2715 of file CbcModel.hpp.
References mipStart_.
|
private |
The solver associated with this model.
Definition at line 2727 of file CbcModel.hpp.
Referenced by createContinuousSolver(), getColLower(), getColSolution(), getColUpper(), getInfinity(), getMatrixByCol(), getMatrixByRow(), getNumCols(), getNumElements(), getNumRows(), getObjCoefficients(), getObjValue(), getReducedCost(), getRightHandSide(), getRowActivity(), getRowLower(), getRowPrice(), getRowRange(), getRowSense(), getRowUpper(), getSolverObjValue(), isBinary(), isContinuous(), isFreeBinary(), isInteger(), isIntegerNonBinary(), setObjSense(), setObjValue(), solver(), and swapSolver().
|
private |
Ownership of objects and other stuff.
0x80000000 model owns solver 0x40000000 all variables CbcDynamicPseudoCost
Definition at line 2734 of file CbcModel.hpp.
Referenced by allDynamic(), modelOwnsSolver(), and setModelOwnsSolver().
|
private |
A copy of the solver, taken at the continuous (root) node.
Definition at line 2737 of file CbcModel.hpp.
Referenced by clearContinuousSolver(), continuousSolver(), and createContinuousSolver().
|
private |
A copy of the solver, taken at constructor or by saveReferenceSolver.
Definition at line 2740 of file CbcModel.hpp.
Referenced by referenceSolver().
|
private |
Message handler.
Definition at line 2743 of file CbcModel.hpp.
Referenced by logLevel(), and messageHandler().
|
private |
Flag to say if handler_ is the default handler.
The default handler is deleted when the model is deleted. Other handlers (supplied by the client) will not be deleted.
Definition at line 2750 of file CbcModel.hpp.
Referenced by defaultHandler(), and setDefaultHandler().
|
private |
Cbc messages.
Definition at line 2753 of file CbcModel.hpp.
Referenced by messages(), and messagesPointer().
|
private |
Array for integer parameters.
Definition at line 2756 of file CbcModel.hpp.
Referenced by getIntParam().
|
private |
Array for double parameters.
Definition at line 2759 of file CbcModel.hpp.
Referenced by getCurrentMinimizationObjValue(), getCurrentObjValue(), getCutoff(), getDblParam(), getObjSense(), setDblParam(), and setObjSense().
|
mutableprivate |
Pointer to an empty warm start object.
It turns out to be useful to have this available as a base from which to build custom warm start objects. This is typed as CoinWarmStart rather than CoinWarmStartBasis to allow for the possibility that a client might want to apply a solver that doesn't use a basis-based warm start. See getEmptyBasis for an example of how this field can be used.
Definition at line 2769 of file CbcModel.hpp.
|
private |
Best objective.
Definition at line 2772 of file CbcModel.hpp.
Referenced by getMinimizationObjValue(), getObjValue(), setMinimizationObjValue(), and setObjValue().
|
private |
Best possible objective.
Definition at line 2774 of file CbcModel.hpp.
|
private |
Sum of Changes to objective by first solve.
Definition at line 2776 of file CbcModel.hpp.
Referenced by sumChangeObjective().
|
private |
Sum of Changes to objective by subsequent solves.
Definition at line 2778 of file CbcModel.hpp.
|
private |
Array holding the incumbent (best) solution.
Definition at line 2781 of file CbcModel.hpp.
Referenced by bestSolution().
|
private |
Arrays holding other solutions.
Definition at line 2783 of file CbcModel.hpp.
|
private |
Array holding the current solution.
This array is used more as a temporary.
Definition at line 2789 of file CbcModel.hpp.
Referenced by currentSolution().
|
mutableprivate |
For testing infeasibilities - will point to currentSolution_ or solver–>getColSolution()
Definition at line 2793 of file CbcModel.hpp.
Referenced by setTestSolution(), and testSolution().
|
private |
MIPstart values values for integer variables which will be converted to a complete integer initial feasible solution.
Definition at line 2797 of file CbcModel.hpp.
Referenced by getMIPStart(), and setMIPStart().
|
private |
keepNamesPreproc if variables names will be preserved in the pre-processed problem (usefull in callbacks)
Definition at line 2803 of file CbcModel.hpp.
Referenced by getKeepNamesPreproc(), and setKeepNamesPreproc().
|
private |
Warm start object produced by heuristic or strong branching.
If get a valid integer solution outside branch and bound then it can take a reasonable time to solve LP which produces clean solution. If this object has any size then it will be used in solve.
Definition at line 2811 of file CbcModel.hpp.
Referenced by setBestSolutionBasis().
|
private |
Global cuts.
Definition at line 2813 of file CbcModel.hpp.
Referenced by globalCuts(), and zapGlobalCuts().
|
private |
Global conflict cuts.
Definition at line 2815 of file CbcModel.hpp.
|
private |
Minimum degradation in objective value to continue cut generation.
Definition at line 2818 of file CbcModel.hpp.
Referenced by getMinimumDrop(), and setMinimumDrop().
|
private |
Number of solutions.
Definition at line 2820 of file CbcModel.hpp.
Referenced by getSolutionCount(), and setSolutionCount().
|
private |
Number of saved solutions.
Definition at line 2822 of file CbcModel.hpp.
|
private |
Maximum number of saved solutions.
Definition at line 2824 of file CbcModel.hpp.
Referenced by maximumSavedSolutions().
|
private |
State of search 0 - no solution 1 - only heuristic solutions 2 - branched to a solution 3 - no solution but many nodes.
Definition at line 2831 of file CbcModel.hpp.
Referenced by setStateOfSearch(), and stateOfSearch().
|
private |
At which depths to do cuts.
Definition at line 2833 of file CbcModel.hpp.
Referenced by setWhenCuts(), and whenCuts().
|
private |
|
private |
Hotstart priorities.
Definition at line 2837 of file CbcModel.hpp.
Referenced by hotstartPriorities().
|
private |
Number of heuristic solutions.
Definition at line 2839 of file CbcModel.hpp.
Referenced by getNumberHeuristicSolutions(), and setNumberHeuristicSolutions().
|
private |
Cumulative number of nodes.
Definition at line 2841 of file CbcModel.hpp.
Referenced by getNodeCount(), and incrementNodeCount().
|
private |
Cumulative number of nodes for statistics.
Must fix to match up
Definition at line 2845 of file CbcModel.hpp.
|
private |
Cumulative number of iterations.
Definition at line 2847 of file CbcModel.hpp.
Referenced by getIterationCount(), and incrementIterationCount().
|
private |
Cumulative number of solves.
Definition at line 2849 of file CbcModel.hpp.
|
private |
Status of problem - 0 finished, 1 stopped, 2 difficulties.
Definition at line 2851 of file CbcModel.hpp.
Referenced by setProblemStatus(), and status().
|
private |
Secondary status of problem -1 unset (status_ will also be -1) 0 search completed with solution 1 linear relaxation not feasible (or worse than cutoff) 2 stopped on gap 3 stopped on nodes 4 stopped on time 5 stopped on user event 6 stopped on solutions.
Definition at line 2862 of file CbcModel.hpp.
Referenced by secondaryStatus(), and setSecondaryStatus().
|
private |
Number of integers in problem.
Definition at line 2864 of file CbcModel.hpp.
Referenced by numberIntegers().
|
private |
Number of rows at continuous.
Definition at line 2866 of file CbcModel.hpp.
|
private |
-1 - cutoff as constraint not activated -2 - waiting to activate >=0 - activated
Definition at line 2872 of file CbcModel.hpp.
Referenced by setCutoffAsConstraint().
|
private |
Maximum number of cuts.
Definition at line 2874 of file CbcModel.hpp.
|
private |
Current phase (so heuristics etc etc can find out).
0 - initial solve 1 - solve with cuts at root 2 - solve with cuts 3 - other e.g. strong branching 4 - trying to validate a solution 5 - at end of search
Definition at line 2883 of file CbcModel.hpp.
Referenced by phase().
|
private |
Number of entries in addedCuts_.
Definition at line 2886 of file CbcModel.hpp.
Referenced by currentNumberCuts().
|
private |
Current limit on search tree depth.
The allocated size of walkback_. Increased as needed.
Definition at line 2892 of file CbcModel.hpp.
|
private |
Array used to assemble the path between a node and the search tree root.
The array is resized when necessary. maximumDepth_ is the current allocated size.
Definition at line 2898 of file CbcModel.hpp.
Referenced by walkback().
|
private |
preProcess used before branch and bound (optional)
Definition at line 2900 of file CbcModel.hpp.
Referenced by setPreProcess().
|
private |
The solver associated with this model.
Definition at line 2901 of file CbcModel.hpp.
|
private |
The solver associated with this model.
Definition at line 2902 of file CbcModel.hpp.
|
private |
The solver associated with this model.
Definition at line 2903 of file CbcModel.hpp.
|
private |
The solver associated with this model.
Definition at line 2904 of file CbcModel.hpp.
|
private |
The solver associated with this model.
Definition at line 2905 of file CbcModel.hpp.
|
private |
The solver associated with this model.
Definition at line 2906 of file CbcModel.hpp.
|
private |
The list of cuts initially collected for this subproblem.
When the subproblem at this node is rebuilt, a set of cuts is collected for inclusion in the constraint system. If any of these cuts are subsequently removed because they have become loose, the corresponding entry is set to NULL.
Definition at line 2915 of file CbcModel.hpp.
Referenced by addedCuts().
|
private |
A pointer to a row cut which will be added instead of normal branching.
After use it should be set to NULL.
Definition at line 2920 of file CbcModel.hpp.
|
private |
Current node so can be used elsewhere.
Definition at line 2923 of file CbcModel.hpp.
Referenced by currentNode().
|
private |
Indices of integer variables.
Definition at line 2926 of file CbcModel.hpp.
Referenced by integerVariable().
|
private |
|
private |
Holds solution at continuous (after cuts)
Definition at line 2930 of file CbcModel.hpp.
|
private |
Array marked whenever a solution is found if non-zero.
Definition at line 2932 of file CbcModel.hpp.
Referenced by usedInSolution().
|
private |
Special options 0 bit (1) - check if cuts valid (if on debugger list) 1 bit (2) - use current basis to check integer solution (rather than all slack) 2 bit (4) - don't check integer solution (by solving LP) 3 bit (8) - fast analyze 4 bit (16) - non-linear model - so no well defined CoinPackedMatrix 5 bit (32) - keep names 6 bit (64) - try for dominated columns 7 bit (128) - SOS type 1 but all declared integer 8 bit (256) - Set to say solution just found, unset by doing cuts 9 bit (512) - Try reduced model after 100 nodes 10 bit (1024) - Switch on some heuristics even if seems unlikely 11 bit (2048) - Mark as in small branch and bound 12 bit (4096) - Funny cuts so do slow way (in some places) 13 bit (8192) - Funny cuts so do slow way (in other places) 14 bit (16384) - Use Cplex! for fathoming 15 bit (32768) - Try reduced model after 0 nodes 16 bit (65536) - Original model had integer bounds 17 bit (131072) - Perturbation switched off 18 bit (262144) - donor CbcModel 19 bit (524288) - recipient CbcModel 20 bit (1048576) - waiting for sub model to return
22 bit (4194304) - do not initialize random seed in solver (user has) 23 bit (8388608) - leave solver_ with cuts 24 bit (16777216) - just get feasible if no cutoff
Definition at line 2960 of file CbcModel.hpp.
Referenced by normalSolver(), setSpecialOptions(), specialOptions(), and waitingForMiniBranchAndBound().
|
private |
More special options at present bottom 6 bits used for shadow price mode 1024 for experimental hotstart 2048,4096 breaking out of cuts 8192 slowly increase minimum drop 16384 gomory 32768 more heuristics in sub trees 65536 no cuts in preprocessing 131072 Time limits elapsed 18 bit (262144) - Perturb fathom nodes 19 bit (524288) - No limit on fathom nodes 20 bit (1048576) - Reduce sum of infeasibilities before cuts 21 bit (2097152) - Reduce sum of infeasibilities after cuts.
Definition at line 2975 of file CbcModel.hpp.
Referenced by moreSpecialOptions(), setMoreSpecialOptions(), setUseElapsedTime(), and useElapsedTime().
|
private |
More more special options 0 bit (1) - find switching variables 1 bit (2) - using fake objective until solution 2 bit (4) - switching variables exist 3 bit (8) - skip most of setBestSolution checks 4 bit (16) - very lightweight preprocessing in smallB&B 5 bit (32) - event handler needs to be cloned when parallel 6 bit (64) - testing - use probing to make cliques 7/8 bit (128) - try orbital branching (if nauty) 9 bit (512) - branching on objective (later) 10 bit (1024) - branching on constraints (later) 11/12 bit 2048 - intermittent cuts.
Definition at line 2989 of file CbcModel.hpp.
Referenced by moreSpecialOptions2(), and setMoreSpecialOptions2().
|
private |
User node comparison function.
Definition at line 2991 of file CbcModel.hpp.
Referenced by nodeComparison().
|
private |
User feasibility function (see CbcFeasibleBase.hpp)
Definition at line 2993 of file CbcModel.hpp.
Referenced by problemFeasibility().
|
private |
Tree.
Definition at line 2995 of file CbcModel.hpp.
|
private |
|
private |
A pointer to model to be used for subtrees.
Definition at line 2999 of file CbcModel.hpp.
|
private |
A pointer to model from CbcHeuristic.
Definition at line 3001 of file CbcModel.hpp.
Referenced by heuristicModel(), and setHeuristicModel().
|
private |
Number of times any subtree stopped on nodes, time etc.
Definition at line 3003 of file CbcModel.hpp.
Referenced by incrementSubTreeStopped(), and numberStoppedSubTrees().
|
private |
Variable selection function.
Definition at line 3005 of file CbcModel.hpp.
Referenced by branchingMethod(), and setBranchingMethod().
|
private |
|
private |
Strategy.
Definition at line 3009 of file CbcModel.hpp.
Referenced by setStrategy(), and strategy().
|
private |
Parent model.
Definition at line 3011 of file CbcModel.hpp.
Referenced by parentModel(), and setParentModel().
|
private |
Whether to automatically do presolve before branch and bound.
0 - no 1 - ordinary presolve 2 - integer presolve (dodgy)Pointer to array[getNumCols()] (for speed) of column lower bounds
Definition at line 3018 of file CbcModel.hpp.
Referenced by getCbcColLower().
|
private |
Pointer to array[getNumCols()] (for speed) of column upper bounds.
Definition at line 3020 of file CbcModel.hpp.
Referenced by getCbcColUpper().
|
private |
Pointer to array[getNumRows()] (for speed) of row lower bounds.
Definition at line 3022 of file CbcModel.hpp.
Referenced by getCbcRowLower().
|
private |
Pointer to array[getNumRows()] (for speed) of row upper bounds.
Definition at line 3024 of file CbcModel.hpp.
Referenced by getCbcRowUpper().
|
private |
Pointer to array[getNumCols()] (for speed) of primal solution vector.
Definition at line 3026 of file CbcModel.hpp.
Referenced by getCbcColSolution().
|
private |
Pointer to array[getNumRows()] (for speed) of dual prices.
Definition at line 3028 of file CbcModel.hpp.
Referenced by getCbcRowPrice().
|
private |
Get a pointer to array[getNumCols()] (for speed) of reduced costs.
Definition at line 3030 of file CbcModel.hpp.
Referenced by getCbcReducedCost().
|
private |
Pointer to array[getNumRows()] (for speed) of row activity levels.
Definition at line 3032 of file CbcModel.hpp.
Referenced by getCbcRowActivity().
|
private |
Pointer to user-defined data structure.
Definition at line 3034 of file CbcModel.hpp.
|
private |
Presolve for CbcTreeLocal.
Definition at line 3036 of file CbcModel.hpp.
Referenced by setTypePresolve(), and typePresolve().
|
private |
Maximum number of candidates to consider for strong branching.
To disable strong branching, set this to 0.
Definition at line 3040 of file CbcModel.hpp.
Referenced by numberStrong().
|
private |
The number of branches before pseudo costs believed in dynamic strong branching.
A value of 0 is off.
Definition at line 3046 of file CbcModel.hpp.
Referenced by numberBeforeTrust().
|
private |
The number of variables for which to compute penalties in dynamic strong branching.
Definition at line 3050 of file CbcModel.hpp.
Referenced by numberPenalties().
|
private |
For threads - stop after this many "iterations".
Definition at line 3052 of file CbcModel.hpp.
Referenced by getStopNumberIterations(), and setStopNumberIterations().
|
private |
Scale factor to make penalties match strong.
Should/will be computed
Definition at line 3055 of file CbcModel.hpp.
Referenced by penaltyScaleFactor().
|
private |
Number of analyze iterations to do.
Definition at line 3057 of file CbcModel.hpp.
Referenced by numberAnalyzeIterations(), and setNumberAnalyzeIterations().
|
private |
Arrays with analysis results.
Definition at line 3059 of file CbcModel.hpp.
|
private |
Useful temporary pointer.
Definition at line 3061 of file CbcModel.hpp.
Referenced by setTemporaryPointer(), and temporaryPointer().
|
private |
Number of nodes infeasible by normal branching (before cuts)
Definition at line 3063 of file CbcModel.hpp.
|
private |
Problem type as set by user or found by analysis.
This will be extended 0 - not known 1 - Set partitioning <= 2 - Set partitioning == 3 - Set covering
Definition at line 3070 of file CbcModel.hpp.
Referenced by problemType(), and setProblemType().
|
private |
Print frequency.
Definition at line 3072 of file CbcModel.hpp.
Referenced by printFrequency(), and setPrintFrequency().
|
private |
Number of cut generators.
Definition at line 3074 of file CbcModel.hpp.
Referenced by numberCutGenerators().
|
private |
The solver associated with this model.
Definition at line 3076 of file CbcModel.hpp.
Referenced by cutGenerator(), and cutGenerators().
|
private |
The solver associated with this model.
Definition at line 3078 of file CbcModel.hpp.
Referenced by virginCutGenerator().
|
private |
Number of heuristics.
Definition at line 3080 of file CbcModel.hpp.
Referenced by numberHeuristics(), and setNumberHeuristics().
|
private |
|
private |
Pointer to heuristic solver which found last solution (or NULL)
Definition at line 3084 of file CbcModel.hpp.
Referenced by lastHeuristic(), and setLastHeuristic().
|
private |
|
private |
Pointer to the event handler
Definition at line 3091 of file CbcModel.hpp.
Referenced by getEventHandler().
|
private |
Symmetry information.
Definition at line 3094 of file CbcModel.hpp.
|
private |
Total number of objects.
Definition at line 3096 of file CbcModel.hpp.
Referenced by numberObjects(), and setNumberObjects().
|
private |
Integer and Clique and ...
information
Definition at line 3108 of file CbcModel.hpp.
Referenced by modifiableObject(), object(), objects(), and priority().
|
private |
Now we may not own objects - just point to solver's objects.
Definition at line 3110 of file CbcModel.hpp.
Referenced by ownObjects().
|
private |
Original columns as created by integerPresolve or preprocessing.
Definition at line 3113 of file CbcModel.hpp.
Referenced by originalColumns().
|
private |
How often to scan global cuts.
Definition at line 3115 of file CbcModel.hpp.
Referenced by howOftenGlobalScan().
|
private |
Number of times global cuts violated.
When global cut pool then this should be kept for each cut and type of cut
Definition at line 3118 of file CbcModel.hpp.
Referenced by clearNumberGlobalViolations(), and numberGlobalViolations().
|
private |
Number of extra iterations in fast lp.
Definition at line 3120 of file CbcModel.hpp.
Referenced by incrementExtra(), numberExtraIterations(), and zeroExtra().
|
private |
Number of extra nodes in fast lp.
Definition at line 3122 of file CbcModel.hpp.
Referenced by getExtraNodeCount(), incrementExtra(), and zeroExtra().
|
private |
Number of times fast lp entered.
Definition at line 3124 of file CbcModel.hpp.
Referenced by getFathomCount(), incrementExtra(), and zeroExtra().
|
private |
Value of objective at continuous (Well actually after initial round of cuts)
Definition at line 3128 of file CbcModel.hpp.
Referenced by rootObjectiveAfterCuts().
|
private |
Value of objective before root node cuts added.
Definition at line 3131 of file CbcModel.hpp.
Referenced by getContinuousObjective(), and setContinuousObjective().
|
private |
Number of infeasibilities at continuous.
Definition at line 3133 of file CbcModel.hpp.
Referenced by getContinuousInfeasibilities(), and setContinuousInfeasibilities().
|
private |
Maximum number of cut passes at root.
Definition at line 3135 of file CbcModel.hpp.
Referenced by getMaximumCutPassesAtRoot(), and setMaximumCutPassesAtRoot().
|
private |
Maximum number of cut passes.
Definition at line 3137 of file CbcModel.hpp.
Referenced by getMaximumCutPasses(), and setMaximumCutPasses().
|
private |
Preferred way of branching.
Definition at line 3139 of file CbcModel.hpp.
Referenced by getPreferredWay(), and setPreferredWay().
|
private |
Current cut pass number.
Definition at line 3141 of file CbcModel.hpp.
Referenced by getCurrentPassNumber(), and setCurrentPassNumber().
|
private |
Maximum number of cuts (for whichGenerator_)
Definition at line 3143 of file CbcModel.hpp.
|
private |
|
private |
Random seed.
Definition at line 3147 of file CbcModel.hpp.
Referenced by getRandomSeed(), and setRandomSeed().
|
private |
Multiple root tries.
Definition at line 3149 of file CbcModel.hpp.
Referenced by getMultipleRootTries(), and setMultipleRootTries().
|
private |
|
mutableprivate |
Thread specific random number generator.
Definition at line 3153 of file CbcModel.hpp.
Referenced by randomNumberGenerator().
|
private |
Work basis for temporary use.
Definition at line 3155 of file CbcModel.hpp.
Referenced by workingBasis().
|
private |
Which cut generator generated this cut.
Definition at line 3157 of file CbcModel.hpp.
Referenced by whichGenerator().
|
private |
Maximum number of statistics.
Definition at line 3159 of file CbcModel.hpp.
|
private |
statistics
Definition at line 3161 of file CbcModel.hpp.
|
private |
Maximum depth reached.
Definition at line 3163 of file CbcModel.hpp.
|
private |
Number of reduced cost fixings.
Definition at line 3165 of file CbcModel.hpp.
|
private |
|
private |
Number of fixed by analyze at root.
Definition at line 3169 of file CbcModel.hpp.
|
private |
Number fixed by analyze so far.
Definition at line 3171 of file CbcModel.hpp.
|
private |
Whether stopping on gap.
Definition at line 3173 of file CbcModel.hpp.
|
mutableprivate |
Whether event happened.
Definition at line 3175 of file CbcModel.hpp.
Referenced by sayEventHappened().
|
private |
Number of long strong goes.
Definition at line 3177 of file CbcModel.hpp.
|
private |
Number of old active cuts.
Definition at line 3179 of file CbcModel.hpp.
|
private |
Number of new cuts.
Definition at line 3181 of file CbcModel.hpp.
|
private |
Strategy worked out - mainly at root node.
Definition at line 3183 of file CbcModel.hpp.
Referenced by searchStrategy(), and setSearchStrategy().
|
private |
Strategy for strong branching 0 - normal when to do all fractional 1 - root node 2 - depth less than modifier 4 - if objective == best possible 6 - as 2+4 when to do all including satisfied 10 - root node etc.
If >=100 then do when depth <= strategy/100 (otherwise 5)
Definition at line 3195 of file CbcModel.hpp.
Referenced by setStrongStrategy(), and strongStrategy().
|
private |
Number of iterations in strong branching.
Definition at line 3197 of file CbcModel.hpp.
Referenced by numberStrongIterations(), and setNumberStrongIterations().
|
private |
0 - number times strong branching done, 1 - number fixed, 2 - number infeasible Second group of three is a snapshot at node [6]
Definition at line 3200 of file CbcModel.hpp.
Referenced by mutableStrongInfo(), and strongInfo().
|
private |
For advanced applications you may wish to modify the behavior of Cbc e.g.
if the solver is a NLP solver then you may not have an exact optimum solution at each step. This gives characteristics - just for one BAB. For actually saving/restoring a solution you need the actual solver one.
Definition at line 3207 of file CbcModel.hpp.
Referenced by solverCharacteristics().
|
private |
Whether to force a resolve after takeOffCuts.
Definition at line 3209 of file CbcModel.hpp.
Referenced by resolveAfterTakeOffCuts(), and setResolveAfterTakeOffCuts().
|
private |
Maximum number of iterations (designed to be used in heuristics)
Definition at line 3211 of file CbcModel.hpp.
Referenced by maximumNumberIterations(), and setMaximumNumberIterations().
|
private |
Anything with priority >= this can be treated as continuous.
Definition at line 3213 of file CbcModel.hpp.
Referenced by continuousPriority(), and setContinuousPriority().
|
private |
Number of outstanding update information items.
Definition at line 3215 of file CbcModel.hpp.
|
private |
Maximum number of outstanding update information items.
Definition at line 3217 of file CbcModel.hpp.
|
private |
Update items.
Definition at line 3219 of file CbcModel.hpp.
|
private |
Stored row cuts for donor/recipient CbcModel.
Definition at line 3221 of file CbcModel.hpp.
Referenced by setStoredRowCuts(), and storedRowCuts().
|
private |
Parallel 0 - off 1 - testing 2-99 threads other special meanings.
Definition at line 3229 of file CbcModel.hpp.
Referenced by getNumberThreads(), parallelMode(), and setNumberThreads().
|
private |
thread mode always use numberThreads for branching 1 set then deterministic 2 set then use numberThreads for root cuts 4 set then use numberThreads in root mini branch and bound default is 0
Definition at line 3237 of file CbcModel.hpp.
Referenced by getThreadMode(), parallelMode(), and setThreadMode().
|
private |
Number of global cuts on entry to a node.
Definition at line 3239 of file CbcModel.hpp.
|
private |
|
private |
Pointer to masterthread.
Definition at line 3243 of file CbcModel.hpp.
Referenced by masterThread().