Cbc  2.10.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Classes | Friends | List of all members
CbcGenCtlBlk Class Reference

#include <CbcGenCtlBlk.hpp>

+ Collaboration diagram for CbcGenCtlBlk:

Classes

struct  babState_struct
 State of branch-and-cut. More...
 
struct  cbcParamsInfo_struct
 Start and end of CbcModel parameters in parameter vector. More...
 
struct  chooseStrongCtl_struct
 Control variables for a strong branching method. More...
 
struct  cliqueCtl_struct
 Control variable and prototype for clique cut generator. More...
 
struct  combineCtl_struct
 Control variable and prototype for combine heuristic. More...
 
struct  debugSolInfo_struct
 Array of primal variable values for debugging. More...
 
struct  djFixCtl_struct
 Control use of reduced cost fixing prior to B&C. More...
 
struct  flowCtl_struct
 Control variable and prototype for flow cover cut generator. More...
 
struct  fpumpCtl_struct
 Control variable and prototype for feasibility pump heuristic. More...
 
struct  genParamsInfo_struct
 Start and end of cbc-generic parameters in parameter vector. More...
 
struct  gomoryCtl_struct
 Control variable and prototype for Gomory cut generator. More...
 
struct  greedyCoverCtl_struct
 Control variable and prototype for greedy cover heuristic. More...
 
struct  greedyEqualityCtl_struct
 Control variable and prototype for greedy equality heuristic. More...
 
struct  knapsackCtl_struct
 Control variable and prototype for knapsack cover cut generator. More...
 
struct  localTreeCtl_struct
 Control variables for local tree. More...
 
struct  mirCtl_struct
 Control variable and prototype for MIR cut generator. More...
 
struct  oddHoleCtl_struct
 Control variable and prototype for odd hole cut generator. More...
 
struct  osiParamsInfo_struct
 Start and end of OsiSolverInterface parameters in parameter vector. More...
 
struct  probingCtl_struct
 Control variable and prototype for probing cut generator. More...
 
struct  redSplitCtl_struct
 Control variable and prototype for reduce-and-split cut generator. More...
 
struct  roundingCtl_struct
 Control variable and prototype for simple rounding heuristic. More...
 
struct  twomirCtl_struct
 Control variable and prototype for Two-MIR cut generator. More...
 

Public Types

Enumeration types used for cbc-generic control variables
enum  IPPControl {
  IPPOff = 0, IPPOn, IPPSave, IPPEqual,
  IPPSOS, IPPTrySOS, IPPEqualAll, IPPStrategy
}
 Codes to control integer preprocessing. More...
 
enum  CGControl {
  CGOff, CGOn, CGRoot, CGIfMove,
  CGForceOn, CGForceBut, CGMarker
}
 Codes to control the use of cut generators and heuristics. More...
 
enum  BPControl { BPOff, BPCost, BPOrder, BPExt }
 Codes to specify the assignment of branching priorities. More...
 
enum  BACMajor {
  BACInvalid = -1, BACFinish = 0, BACStop = 1, BACAbandon = 2,
  BACNotRun, BACUser = 5
}
 Major status codes for branch-and-cut. More...
 
enum  BACMinor {
  BACmInvalid = -1, BACmFinish = 0, BACmInfeas, BACmUbnd,
  BACmGap, BACmNodeLimit, BACmTimeLimit, BACmSolnLimit,
  BACmUser, BACmOther
}
 Minor status codes. More...
 
enum  BACWhere {
  BACwInvalid = -1, BACwNotStarted = 0, BACwBareRoot, BACwIPP,
  BACwIPPRelax, BACwBAC
}
 Codes to specify where branch-and-cut stopped. More...
 

Public Member Functions

Constructors and destructors
 CbcGenCtlBlk ()
 Default constructor. More...
 
 ~CbcGenCtlBlk ()
 Destructor. More...
 
Access and Control Functions for Cut Generators and Heuristics

Control functions, plus lazy creation functions for cut generators and heuristics

cbc-generic avoids creating objects for cut generators and heuristics unless they're actually used. For cut generators, a prototype is created and reused. For heuristics, the default is to create a new object with each call, because the model may have changed. The object is returned through the reference parameter. The return value of the function is the current action state.

Cut generator and heuristic objects created by these calls will be deleted with the destruction of the CbcGenCtlBlk object.

int getCutDepth ()
 Get cut depth setting. More...
 
void setCutDepth (int cutDepth)
 Set cut depth setting. More...
 
IPPControl getIPPAction ()
 
void setIPPAction (IPPControl action)
 Set action state for use of integer preprocessing. More...
 
CGControl getProbing (CglCutGenerator *&gen)
 Obtain a prototype for a probing cut generator. More...
 
void setProbingAction (CGControl action)
 Set action state for use of probing cut generator. More...
 
CGControl getClique (CglCutGenerator *&gen)
 Obtain a prototype for a clique cut generator. More...
 
void setCliqueAction (CGControl action)
 Set action state for use of clique cut generator. More...
 
CGControl getFlow (CglCutGenerator *&gen)
 Obtain a prototype for a flow cover cut generator. More...
 
void setFlowAction (CGControl action)
 Set action state for use of flow cover cut generator. More...
 
CGControl getGomory (CglCutGenerator *&gen)
 Obtain a prototype for a Gomory cut generator. More...
 
void setGomoryAction (CGControl action)
 Set action state for use of Gomory cut generator. More...
 
CGControl getKnapsack (CglCutGenerator *&gen)
 Obtain a prototype for a knapsack cover cut generator. More...
 
void setKnapsackAction (CGControl action)
 Set action state for use of knapsack cut generator. More...
 
CGControl getMir (CglCutGenerator *&gen)
 Obtain a prototype for a mixed integer rounding (MIR) cut generator. More...
 
void setMirAction (CGControl action)
 Set action state for use of MIR cut generator. More...
 
CGControl getRedSplit (CglCutGenerator *&gen)
 Obtain a prototype for a reduce and split cut generator. More...
 
void setRedSplitAction (CGControl action)
 Set action state for use of reduce and split cut generator. More...
 
CGControl getTwomir (CglCutGenerator *&gen)
 Obtain a prototype for a 2-MIR cut generator. More...
 
void setTwomirAction (CGControl action)
 Set action state for use of 2-MIR cut generator. More...
 
CGControl getFPump (CbcHeuristic *&gen, CbcModel *model, bool alwaysCreate=true)
 Obtain a feasibility pump heuristic. More...
 
void setFPumpAction (CGControl action)
 Set action state for use of feasibility pump heuristic. More...
 
CGControl getCombine (CbcHeuristic *&gen, CbcModel *model, bool alwaysCreate=true)
 Obtain a local search/combine heuristic. More...
 
void setCombineAction (CGControl action)
 Set action state for use of local search/combine heuristic. More...
 
CGControl getGreedyCover (CbcHeuristic *&gen, CbcModel *model, bool alwaysCreate=true)
 Obtain a greedy cover heuristic. More...
 
void setGreedyCoverAction (CGControl action)
 Set action state for use of greedy cover heuristic. More...
 
CGControl getGreedyEquality (CbcHeuristic *&gen, CbcModel *model, bool alwaysCreate=true)
 Obtain a greedy equality heuristic. More...
 
void setGreedyEqualityAction (CGControl action)
 Set action state for use of greedy equality heuristic. More...
 
CGControl getRounding (CbcHeuristic *&gen, CbcModel *model, bool alwaysCreate=true)
 Obtain a simple rounding heuristic. More...
 
void setRoundingAction (CGControl action)
 Set action state for use of simple rounding heuristic. More...
 
CGControl getTreeLocal (CbcTreeLocal *&localTree, CbcModel *model, bool alwaysCreate=true)
 Obtain a local search tree object. More...
 
void setTreeLocalAction (CGControl action)
 Set action state for use of local tree. More...
 
Status Functions

Convenience routines for status codes.

void setBaBStatus (BACMajor majorStatus, BACMinor minorStatus, BACWhere where, bool haveAnswer, OsiSolverInterface *answerSolver)
 Set the result of branch-and-cut search. More...
 
void setBaBStatus (const CbcModel *model, BACWhere where, bool haveAnswer=false, OsiSolverInterface *answerSolver=0)
 Set the result of branch-and-cut search. More...
 
BACMajor translateMajor (int status)
 Translate CbcModel major status to BACMajor. More...
 
BACMinor translateMinor (int status)
 Translate CbcModel minor status to BACMinor. More...
 
BACMinor translateMinor (const OsiSolverInterface *osi)
 Translate OsiSolverInterface status to BACMinor. More...
 
void printBaBStatus ()
 Print the status block. More...
 

Public Attributes

Parameter parsing and input/output.
std::string version_
 cbc-generic version More...
 
std::string dfltDirectory_
 Default directory prefix. More...
 
std::string lastMpsIn_
 Last MPS input file. More...
 
bool allowImportErrors_
 Allow/disallow errors when importing a model. More...
 
std::string lastSolnOut_
 Last solution output file. More...
 
int printMode_
 Solution printing mode. More...
 
std::string printMask_
 Print mask. More...
 
CoinParamVec * paramVec_
 The parameter vector. More...
 
struct
CbcGenCtlBlk::genParamsInfo_struct 
genParams_
 
struct
CbcGenCtlBlk::cbcParamsInfo_struct 
cbcParams_
 
struct
CbcGenCtlBlk::osiParamsInfo_struct 
osiParams_
 
int verbose_
 Verbosity level for help messages. More...
 
int paramsProcessed_
 Number of parameters processed. More...
 
std::vector< bool > setByUser_
 Record of parameters changed by user command. More...
 
bool defaultSettings_
 False if the user has made nontrivial modifications to the default control settings. More...
 
std::string debugCreate_
 Control debug file creation. More...
 
std::string debugFile_
 Last debug input file. More...
 
struct
CbcGenCtlBlk::debugSolInfo_struct 
debugSol_
 
double totalTime_
 Total elapsed time for this run. More...
 
Models of various flavours
CbcModelmodel_
 The reference CbcModel object. More...
 
OsiSolverInterfacedfltSolver_
 The current default LP solver. More...
 
bool goodModel_
 True if we have a valid model loaded, false otherwise. More...
 
struct
CbcGenCtlBlk::babState_struct 
bab_
 
Various algorithm control variables and settings
struct
CbcGenCtlBlk::djFixCtl_struct 
djFix_
 
BPControl priorityAction_
 Control the assignment of branching priorities to integer variables. More...
 
Branching Method Control

Usage control and prototypes for branching methods.

Looking to the future, this covers only OsiChoose methods.

struct
CbcGenCtlBlk::chooseStrongCtl_struct 
chooseStrong_
 

Private Attributes

Cut Generator and Heuristic Control

Usage control and prototypes for cut generators and heuristics.

IPPControl preProcess_
 Control integer preprocessing. More...
 
int cutDepth_
 Control cut generator activity. More...
 
struct
CbcGenCtlBlk::probingCtl_struct 
probing_
 
struct
CbcGenCtlBlk::cliqueCtl_struct 
clique_
 
struct CbcGenCtlBlk::flowCtl_struct flow_
 
struct
CbcGenCtlBlk::gomoryCtl_struct 
gomory_
 
struct
CbcGenCtlBlk::knapsackCtl_struct 
knapsack_
 
struct CbcGenCtlBlk::mirCtl_struct mir_
 
struct
CbcGenCtlBlk::oddHoleCtl_struct 
oddHole_
 
struct
CbcGenCtlBlk::redSplitCtl_struct 
redSplit_
 
struct
CbcGenCtlBlk::twomirCtl_struct 
twomir_
 
struct
CbcGenCtlBlk::fpumpCtl_struct 
fpump_
 
struct
CbcGenCtlBlk::combineCtl_struct 
combine_
 
struct
CbcGenCtlBlk::greedyCoverCtl_struct 
greedyCover_
 
struct
CbcGenCtlBlk::greedyEqualityCtl_struct 
greedyEquality_
 
struct
CbcGenCtlBlk::roundingCtl_struct 
rounding_
 
struct
CbcGenCtlBlk::localTreeCtl_struct 
localTree_
 
Messages and statistics (private)

Data and objects related to messages and statistics that should be protected from direct manipulation.

CoinMessageHandlermsgHandler_
 Message handler. More...
 
bool ourMsgHandler_
 Ownership of message handler. More...
 
CoinMessages::Language cur_lang_
 The current language. More...
 
CoinMessagesmsgs_
 The current set of messages. More...
 
int logLvl_
 The current log level. More...
 

Friends

void CbcGenParamUtils::addCbcGenParams (int &numParams, CoinParamVec &paramVec, CbcGenCtlBlk *ctlBlk)
 

Messages and statistics

int printOpt_
 When greater than 0, integer presolve gives more information and branch-and-cut provides statistics. More...
 
CoinMessageHandlermessage (CbcGenMsgCode inID)
 Print a message. More...
 
void passInMessageHandler (CoinMessageHandler *handler)
 Supply a new message handler. More...
 
CoinMessageHandlermessageHandler () const
 Return a pointer to the message handler. More...
 
void setMessages (CoinMessages::Language lang=CoinMessages::us_en)
 Set up messages in the specified language. More...
 
void setLogLevel (int lvl)
 Set log level. More...
 
int logLevel () const
 Get log level. More...
 

Detailed Description

Definition at line 67 of file CbcGenCtlBlk.hpp.

Member Enumeration Documentation

Codes to control integer preprocessing.

  • IPPOff: Integer preprocessing is off.
  • IPPOn: Integer preprocessing is on.
  • IPPSave: IPPOn, plus preprocessed system will be saved to presolved.mps.
  • IPPEqual: IPPOn, plus `<=' cliques are converted to `=' cliques.
  • IPPSOS: IPPOn, plus will create SOS sets (see below).
  • IPPTrySOS: IPPOn, plus will create SOS sets (see below).
  • IPPEqualAll: IPPOn, plus turns all valid inequalities into equalities with integer slacks.
  • IPPStrategy: look to CbcStrategy object for instructions.

IPPSOS will create SOS sets if all binary variables (except perhaps one) can be covered by SOS sets with no overlap between sets. IPPTrySOS will allow any number of binary variables to be uncovered.

Enumerator
IPPOff 
IPPOn 
IPPSave 
IPPEqual 
IPPSOS 
IPPTrySOS 
IPPEqualAll 
IPPStrategy 

Definition at line 98 of file CbcGenCtlBlk.hpp.

Codes to control the use of cut generators and heuristics.

  • CGOff: the cut generator will not be installed
  • CGOn: the cut generator will be installed; exactly how often it's activated depends on the settings at installation
  • CGRoot: the cut generator will be installed with settings that restrict it to activation at the root node only.
  • CGIfMove: the cut generator will be installed with settings that allow it to remain active only so long as it's generating cuts that tighten the relaxation.
  • CGForceOn: the cut generator will be installed with settings that force it to be called at every node
  • CGForceBut: the cut generator will be installed with settings that force it to be called at every node, but more active at root (probing only)
  • CGMarker: a convenience to mark the end of the codes.

The same codes are used for heuristics.

Enumerator
CGOff 
CGOn 
CGRoot 
CGIfMove 
CGForceOn 
CGForceBut 
CGMarker 

Definition at line 134 of file CbcGenCtlBlk.hpp.

Codes to specify the assignment of branching priorities.

  • BPOff: no priorities are passed to cbc
  • BPCost: a priority vector is constructed based on objective coefficients
  • BPOrder: a priority vector is constructed based on column order
  • BPExt: the user has provided a priority vector
Enumerator
BPOff 
BPCost 
BPOrder 
BPExt 

Definition at line 151 of file CbcGenCtlBlk.hpp.

Major status codes for branch-and-cut.

  • BACInvalid: status not yet set
  • BACNotRun: branch-and-cut has not yet run for the current problem
  • BACFinish: branch-and-cut has finished normally
  • BACStop: branch-and-cut has stopped on a limit
  • BACAbandon: branch-and-cut abandoned the problem
  • BACUser: branch-and-cut stopped on user signal

Consult minorStatus_ for details.

These codes are (mostly) set to match the codes used by CbcModel. Additions to CbcModel codes should be reflected here and in translateMajor.

Enumerator
BACInvalid 
BACFinish 
BACStop 
BACAbandon 
BACNotRun 
BACUser 

Definition at line 171 of file CbcGenCtlBlk.hpp.

Minor status codes.

  • BACmInvalid status not yet set
  • BACmFinish search exhausted the tree; optimal solution found
  • BACmInfeas problem is infeasible
  • BACmUbnd problem is unbounded
  • BACmGap stopped on integrality gap
  • BACmNodeLimit stopped on node limit
  • BACmTimeLimit stopped on time limit
  • BACmSolnLimit stopped on number of solutions limit
  • BACmUser stopped due to user event
  • BACmOther nothing else is appropriate

It's not possible to make these codes agree with CbcModel. The meaning varies according to context: if the BACWhere code specifies a relaxation, then the minor status reflects the underlying OSI solver. Otherwise, it reflects the integer problem.

Enumerator
BACmInvalid 
BACmFinish 
BACmInfeas 
BACmUbnd 
BACmGap 
BACmNodeLimit 
BACmTimeLimit 
BACmSolnLimit 
BACmUser 
BACmOther 

Definition at line 198 of file CbcGenCtlBlk.hpp.

Codes to specify where branch-and-cut stopped.

  • BACwNotStarted stopped before we ever got going
  • BACwBareRoot stopped after initial solve of root relaxation
  • BACwIPP stopped after integer preprocessing
  • BACwIPPRelax stopped after initial solve of preprocessed problem
  • BACwBAC stopped at some point in branch-and-cut
Enumerator
BACwInvalid 
BACwNotStarted 
BACwBareRoot 
BACwIPP 
BACwIPPRelax 
BACwBAC 

Definition at line 219 of file CbcGenCtlBlk.hpp.

Constructor & Destructor Documentation

CbcGenCtlBlk::CbcGenCtlBlk ( )

Default constructor.

CbcGenCtlBlk::~CbcGenCtlBlk ( )

Destructor.

Member Function Documentation

int CbcGenCtlBlk::getCutDepth ( )
inline

Get cut depth setting.

The name is a bit of a misnomer. Essentially, this overrides the `every so many nodes' control with `execute when (depth in tree) mod (cut depth) == 0'.

Definition at line 264 of file CbcGenCtlBlk.hpp.

void CbcGenCtlBlk::setCutDepth ( int  cutDepth)
inline

Set cut depth setting.

See comments for getCutDepth().

Definition at line 274 of file CbcGenCtlBlk.hpp.

IPPControl CbcGenCtlBlk::getIPPAction ( )
inline

Definition at line 281 of file CbcGenCtlBlk.hpp.

void CbcGenCtlBlk::setIPPAction ( IPPControl  action)
inline

Set action state for use of integer preprocessing.

Definition at line 288 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getProbing ( CglCutGenerator *&  gen)

Obtain a prototype for a probing cut generator.

void CbcGenCtlBlk::setProbingAction ( CGControl  action)
inline

Set action state for use of probing cut generator.

Definition at line 299 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getClique ( CglCutGenerator *&  gen)

Obtain a prototype for a clique cut generator.

void CbcGenCtlBlk::setCliqueAction ( CGControl  action)
inline

Set action state for use of clique cut generator.

Definition at line 310 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getFlow ( CglCutGenerator *&  gen)

Obtain a prototype for a flow cover cut generator.

void CbcGenCtlBlk::setFlowAction ( CGControl  action)
inline

Set action state for use of flow cover cut generator.

Definition at line 321 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getGomory ( CglCutGenerator *&  gen)

Obtain a prototype for a Gomory cut generator.

void CbcGenCtlBlk::setGomoryAction ( CGControl  action)
inline

Set action state for use of Gomory cut generator.

Definition at line 332 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getKnapsack ( CglCutGenerator *&  gen)

Obtain a prototype for a knapsack cover cut generator.

void CbcGenCtlBlk::setKnapsackAction ( CGControl  action)
inline

Set action state for use of knapsack cut generator.

Definition at line 343 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getMir ( CglCutGenerator *&  gen)

Obtain a prototype for a mixed integer rounding (MIR) cut generator.

void CbcGenCtlBlk::setMirAction ( CGControl  action)
inline

Set action state for use of MIR cut generator.

Definition at line 366 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getRedSplit ( CglCutGenerator *&  gen)

Obtain a prototype for a reduce and split cut generator.

void CbcGenCtlBlk::setRedSplitAction ( CGControl  action)
inline

Set action state for use of reduce and split cut generator.

Definition at line 377 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getTwomir ( CglCutGenerator *&  gen)

Obtain a prototype for a 2-MIR cut generator.

void CbcGenCtlBlk::setTwomirAction ( CGControl  action)
inline

Set action state for use of 2-MIR cut generator.

Definition at line 388 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getFPump ( CbcHeuristic *&  gen,
CbcModel model,
bool  alwaysCreate = true 
)

Obtain a feasibility pump heuristic.

By default, any existing object is deleted and a new object is created and loaded with model. Set alwaysCreate = false to return an existing object if one exists.

void CbcGenCtlBlk::setFPumpAction ( CGControl  action)
inline

Set action state for use of feasibility pump heuristic.

Definition at line 405 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getCombine ( CbcHeuristic *&  gen,
CbcModel model,
bool  alwaysCreate = true 
)

Obtain a local search/combine heuristic.

By default, any existing object is deleted and a new object is created and loaded with model. Set alwaysCreate = false to return an existing object if one exists.

void CbcGenCtlBlk::setCombineAction ( CGControl  action)
inline

Set action state for use of local search/combine heuristic.

Definition at line 422 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getGreedyCover ( CbcHeuristic *&  gen,
CbcModel model,
bool  alwaysCreate = true 
)

Obtain a greedy cover heuristic.

By default, any existing object is deleted and a new object is created and loaded with model. Set alwaysCreate = false to return an existing object if one exists.

void CbcGenCtlBlk::setGreedyCoverAction ( CGControl  action)
inline

Set action state for use of greedy cover heuristic.

Definition at line 439 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getGreedyEquality ( CbcHeuristic *&  gen,
CbcModel model,
bool  alwaysCreate = true 
)

Obtain a greedy equality heuristic.

By default, any existing object is deleted and a new object is created and loaded with model. Set alwaysCreate = false to return an existing object if one exists.

void CbcGenCtlBlk::setGreedyEqualityAction ( CGControl  action)
inline

Set action state for use of greedy equality heuristic.

Definition at line 456 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getRounding ( CbcHeuristic *&  gen,
CbcModel model,
bool  alwaysCreate = true 
)

Obtain a simple rounding heuristic.

By default, any existing object is deleted and a new object is created and loaded with model. Set alwaysCreate = false to return an existing object if one exists.

void CbcGenCtlBlk::setRoundingAction ( CGControl  action)
inline

Set action state for use of simple rounding heuristic.

Definition at line 473 of file CbcGenCtlBlk.hpp.

CGControl CbcGenCtlBlk::getTreeLocal ( CbcTreeLocal *&  localTree,
CbcModel model,
bool  alwaysCreate = true 
)

Obtain a local search tree object.

By default, any existing object is deleted and a new object is created and loaded with model. Set alwaysCreate = false to return an existing object if one exists.

void CbcGenCtlBlk::setTreeLocalAction ( CGControl  action)
inline

Set action state for use of local tree.

Definition at line 490 of file CbcGenCtlBlk.hpp.

void CbcGenCtlBlk::setBaBStatus ( BACMajor  majorStatus,
BACMinor  minorStatus,
BACWhere  where,
bool  haveAnswer,
OsiSolverInterface answerSolver 
)
inline

Set the result of branch-and-cut search.

Definition at line 504 of file CbcGenCtlBlk.hpp.

void CbcGenCtlBlk::setBaBStatus ( const CbcModel model,
BACWhere  where,
bool  haveAnswer = false,
OsiSolverInterface answerSolver = 0 
)

Set the result of branch-and-cut search.

This version will extract the necessary information from the CbcModel object and set appropriate status based on the value passed for where.

BACMajor CbcGenCtlBlk::translateMajor ( int  status)

Translate CbcModel major status to BACMajor.

See the BACMajor enum for details.

BACMinor CbcGenCtlBlk::translateMinor ( int  status)

Translate CbcModel minor status to BACMinor.

See the BACMinor enum for details.

BACMinor CbcGenCtlBlk::translateMinor ( const OsiSolverInterface osi)

Translate OsiSolverInterface status to BACMinor.

See the BACMinor enum for details. Optimal, infeasible, and unbounded get their own codes; everything else maps to BACmOther.

void CbcGenCtlBlk::printBaBStatus ( )

Print the status block.

CoinMessageHandler& CbcGenCtlBlk::message ( CbcGenMsgCode  inID)

Print a message.

Uses the current message handler and messages.

void CbcGenCtlBlk::passInMessageHandler ( CoinMessageHandler handler)

Supply a new message handler.

Replaces the current message handler. The current handler is destroyed if ourMsgHandler_ is true, and the call will set ourMsgHandler_ = true.

CoinMessageHandler* CbcGenCtlBlk::messageHandler ( ) const
inline

Return a pointer to the message handler.

Definition at line 566 of file CbcGenCtlBlk.hpp.

void CbcGenCtlBlk::setMessages ( CoinMessages::Language  lang = CoinMessages::us_en)

Set up messages in the specified language.

Building a set of messages in a given language implies rebuilding the whole set of messages, for reasons explained in the body of the code. Hence there's no separate setLanguage routine. Use this routine for the initial setup of messages and any subsequent change in language. Note that the constructor gives you a message handler by default, but not messages. You need to call setMessages explicitly.

The default value specified here for lang effectively sets the default language.

void CbcGenCtlBlk::setLogLevel ( int  lvl)
inline

Set log level.

Definition at line 586 of file CbcGenCtlBlk.hpp.

int CbcGenCtlBlk::logLevel ( ) const
inline

Get log level.

Definition at line 594 of file CbcGenCtlBlk.hpp.

Friends And Related Function Documentation

void CbcGenParamUtils::addCbcGenParams ( int &  numParams,
CoinParamVec &  paramVec,
CbcGenCtlBlk ctlBlk 
)
friend

Member Data Documentation

int CbcGenCtlBlk::printOpt_

When greater than 0, integer presolve gives more information and branch-and-cut provides statistics.

Definition at line 602 of file CbcGenCtlBlk.hpp.

std::string CbcGenCtlBlk::version_

cbc-generic version

Definition at line 610 of file CbcGenCtlBlk.hpp.

std::string CbcGenCtlBlk::dfltDirectory_

Default directory prefix.

Definition at line 614 of file CbcGenCtlBlk.hpp.

std::string CbcGenCtlBlk::lastMpsIn_

Last MPS input file.

Definition at line 618 of file CbcGenCtlBlk.hpp.

bool CbcGenCtlBlk::allowImportErrors_

Allow/disallow errors when importing a model.

Definition at line 621 of file CbcGenCtlBlk.hpp.

std::string CbcGenCtlBlk::lastSolnOut_

Last solution output file.

Definition at line 625 of file CbcGenCtlBlk.hpp.

int CbcGenCtlBlk::printMode_

Solution printing mode.

Controls the amount of information printed when printing a solution. Coding is set by the keyword declarations for the printingOptions command.

Definition at line 633 of file CbcGenCtlBlk.hpp.

std::string CbcGenCtlBlk::printMask_

Print mask.

Used to specify row/column names to be printed. Not implemented as of 060920.

Definition at line 640 of file CbcGenCtlBlk.hpp.

CoinParamVec* CbcGenCtlBlk::paramVec_

The parameter vector.

Definition at line 644 of file CbcGenCtlBlk.hpp.

struct CbcGenCtlBlk::genParamsInfo_struct CbcGenCtlBlk::genParams_
struct CbcGenCtlBlk::cbcParamsInfo_struct CbcGenCtlBlk::cbcParams_
struct CbcGenCtlBlk::osiParamsInfo_struct CbcGenCtlBlk::osiParams_
int CbcGenCtlBlk::verbose_

Verbosity level for help messages.

Interpretation is bitwise:

  • (0): short help
  • (1): long help
  • (2): unused (for compatibility with cbc; indicates AMPL)
  • (3): show parameters with display = false.

Definition at line 678 of file CbcGenCtlBlk.hpp.

int CbcGenCtlBlk::paramsProcessed_

Number of parameters processed.

Definition at line 682 of file CbcGenCtlBlk.hpp.

std::vector< bool > CbcGenCtlBlk::setByUser_

Record of parameters changed by user command.

Definition at line 686 of file CbcGenCtlBlk.hpp.

bool CbcGenCtlBlk::defaultSettings_

False if the user has made nontrivial modifications to the default control settings.

Initially true. Specifying DJFIX, TIGHTENFACTOR, or any cut or heuristic parameter will set this to false.

Definition at line 694 of file CbcGenCtlBlk.hpp.

std::string CbcGenCtlBlk::debugCreate_

Control debug file creation.

At the conclusion of branch-and-cut, dump the full solution in a binary format to debug.file in the current directory. When set to "createAfterPre", the solution is dumped before integer presolve transforms are removed. When set to "create", the solution is dumped after integer presolve transforms are backed out.

Definition at line 704 of file CbcGenCtlBlk.hpp.

std::string CbcGenCtlBlk::debugFile_

Last debug input file.

The file is expected to be in a binary format understood by activateRowCutDebugger.

Definition at line 712 of file CbcGenCtlBlk.hpp.

struct CbcGenCtlBlk::debugSolInfo_struct CbcGenCtlBlk::debugSol_
double CbcGenCtlBlk::totalTime_

Total elapsed time for this run.

Definition at line 730 of file CbcGenCtlBlk.hpp.

CbcModel* CbcGenCtlBlk::model_

The reference CbcModel object.

This is the CbcModel created when cbc-generic boots up. It holds the default solver with the current constraint system. CbcCbcParam parameters are applied here, and CbcOsiParam parameters are applied to the solver. Major modifications for branch-and-cut (integer preprocessing, installation of heuristics and cut generators) are performed on a clone. The solution is transferred back into this object.

Definition at line 747 of file CbcGenCtlBlk.hpp.

OsiSolverInterface* CbcGenCtlBlk::dfltSolver_

The current default LP solver.

This is a pointer to a reference copy. If you want the solver associated with model_, ask for it directly.

Definition at line 755 of file CbcGenCtlBlk.hpp.

bool CbcGenCtlBlk::goodModel_

True if we have a valid model loaded, false otherwise.

Definition at line 759 of file CbcGenCtlBlk.hpp.

struct CbcGenCtlBlk::babState_struct CbcGenCtlBlk::bab_
struct CbcGenCtlBlk::djFixCtl_struct CbcGenCtlBlk::djFix_
BPControl CbcGenCtlBlk::priorityAction_

Control the assignment of branching priorities to integer variables.

Definition at line 797 of file CbcGenCtlBlk.hpp.

struct CbcGenCtlBlk::chooseStrongCtl_struct CbcGenCtlBlk::chooseStrong_
IPPControl CbcGenCtlBlk::preProcess_
private

Control integer preprocessing.

Definition at line 830 of file CbcGenCtlBlk.hpp.

int CbcGenCtlBlk::cutDepth_
private

Control cut generator activity.

Generators that are active in the tree will be activated when (depth) mod (cutDepth) == 0.

Definition at line 838 of file CbcGenCtlBlk.hpp.

struct CbcGenCtlBlk::probingCtl_struct CbcGenCtlBlk::probing_
private
struct CbcGenCtlBlk::cliqueCtl_struct CbcGenCtlBlk::clique_
private
struct CbcGenCtlBlk::flowCtl_struct CbcGenCtlBlk::flow_
private
struct CbcGenCtlBlk::gomoryCtl_struct CbcGenCtlBlk::gomory_
private
struct CbcGenCtlBlk::knapsackCtl_struct CbcGenCtlBlk::knapsack_
private
struct CbcGenCtlBlk::mirCtl_struct CbcGenCtlBlk::mir_
private
struct CbcGenCtlBlk::oddHoleCtl_struct CbcGenCtlBlk::oddHole_
private
struct CbcGenCtlBlk::redSplitCtl_struct CbcGenCtlBlk::redSplit_
private
struct CbcGenCtlBlk::twomirCtl_struct CbcGenCtlBlk::twomir_
private
struct CbcGenCtlBlk::fpumpCtl_struct CbcGenCtlBlk::fpump_
private
struct CbcGenCtlBlk::combineCtl_struct CbcGenCtlBlk::combine_
private
struct CbcGenCtlBlk::greedyCoverCtl_struct CbcGenCtlBlk::greedyCover_
private
struct CbcGenCtlBlk::greedyEqualityCtl_struct CbcGenCtlBlk::greedyEquality_
private
struct CbcGenCtlBlk::roundingCtl_struct CbcGenCtlBlk::rounding_
private
struct CbcGenCtlBlk::localTreeCtl_struct CbcGenCtlBlk::localTree_
private
CoinMessageHandler* CbcGenCtlBlk::msgHandler_
private

Message handler.

Definition at line 977 of file CbcGenCtlBlk.hpp.

bool CbcGenCtlBlk::ourMsgHandler_
private

Ownership of message handler.

If true, the control block owns the message handler and it will be destroyed with the control block. If false, the client is responsible for the message handler.

Definition at line 985 of file CbcGenCtlBlk.hpp.

CoinMessages::Language CbcGenCtlBlk::cur_lang_
private

The current language.

Definition at line 988 of file CbcGenCtlBlk.hpp.

CoinMessages* CbcGenCtlBlk::msgs_
private

The current set of messages.

Definition at line 991 of file CbcGenCtlBlk.hpp.

int CbcGenCtlBlk::logLvl_
private

The current log level.

Definition at line 994 of file CbcGenCtlBlk.hpp.


The documentation for this class was generated from the following file: