27 const std::string mpdDir );
99 virtual void generateCuts(
const OsiSolverInterface & si, OsiCuts & cs,
115 int snapshot (
const OsiSolverInterface & si,
116 char * possible=NULL,
117 bool withObjective=
true);
126 int minimumSize=2,
int maximumSize=100);
139 {
return tightenBounds_;}
210 {
return numberThisTime_;}
239 void tightenThese(
const OsiSolverInterface & solver,
int number,
const int * which);
275 int probe(
const OsiSolverInterface & si,
277 const OsiRowCutDebugger * debugger,
279 double * colLower,
double * colUpper, CoinPackedMatrix *rowCopy,
280 CoinPackedMatrix *columnCopy,
const CoinBigIndex * rowStartPos,
281 const int * realRow,
const double * rowLower,
const double * rowUpper,
282 const char * intVar,
double * minR,
double * maxR,
int * markR,
285 int probeCliques(
const OsiSolverInterface & si,
286 const OsiRowCutDebugger * debugger,
288 double * colLower,
double * colUpper, CoinPackedMatrix *rowCopy,
289 CoinPackedMatrix *columnCopy,
const int * realRow,
290 double * rowLower,
double * rowUpper,
291 char * intVar,
double * minR,
double * maxR,
int * markR,
294 int probeSlacks(
const OsiSolverInterface & si,
295 const OsiRowCutDebugger * debugger,
297 double * colLower,
double * colUpper, CoinPackedMatrix *rowCopy,
298 CoinPackedMatrix *columnCopy,
299 double * rowLower,
double * rowUpper,
300 char * intVar,
double * minR,
double * maxR,
int * markR,
304 int gutsOfGenerateCuts(
const OsiSolverInterface & si,
306 double * rowLower,
double * rowUpper,
307 double * colLower,
double * colUpper,
310 void setupRowCliqueInformation(
const OsiSolverInterface & si);
313 int tighten(
double *colLower,
double * colUpper,
314 const int *column,
const double *rowElements,
315 const CoinBigIndex *rowStart,
const CoinBigIndex * rowStartPos,
316 const int * rowLength,
317 double *rowLower,
double *rowUpper,
318 int nRows,
int nCols,
char * intVar,
int maxpass,
321 void tighten2(
double *colLower,
double * colUpper,
322 const int *column,
const double *rowElements,
323 const CoinBigIndex *rowStart,
324 const int * rowLength,
325 double *rowLower,
double *rowUpper,
326 double * minR,
double * maxR,
int * markR,
332 struct disaggregation_struct_tag ;
337 CoinPackedMatrix * rowCopy_;
340 CoinPackedMatrix * columnCopy_;
354 double primalTolerance_;
381 int maxElementsRoot_;
387 int number01Integers_;
391 int totalTimesCalled_;
395 typedef struct disaggregation_struct_tag {
401 disaggregation * cutVector_;
407 unsigned int equality:1;
409 cliqueType * cliqueType_;
430 int * cliqueRowStart_;
432 char * tightenBounds_;
446 { assert ((dis.
affected&0x80000000)!=0);
return true;}
451 {
return (dis.
affected&0x40000000)!=0;}
455 {
return (dis.
affected&0x20000000)!=0;}
457 { dis.
affected = (affectedToUB ? 0x20000000 : 0)|(dis.
affected&0xdfffffff);}
466 const std::string mpdDir );
477 virtual void generateCuts(
const OsiSolverInterface & si, OsiCuts & cs,
511 { probingInfo_=info;}
int getMaxPassRoot() const
Get maximum number of passes per node (root node)
int getMaxLook() const
Get maximum number of variables to look at in one probe.
This just uses implication info.
void setMaxElements(int value)
Set maximum number of elements in row for it to be considered.
int getMaxProbe() const
Get maximum number of unsatisfied variables to look at.
void setMaxLookRoot(int value)
Set maximum number of variables to look at in one probe (root node)
void setMaxPass(int value)
Set maximum number of passes per node.
virtual CglCutGenerator * clone() const
Clone.
void setWhenAtUBInDisaggregation(disaggregationAction &dis, bool whenAtUB)
const double * relaxedRowLower() const
Lower.
virtual std::string generateCpp(FILE *fp)
Create C++ lines to get to current state.
Information about where the cut generator is invoked from.
CglImplication & operator=(const CglImplication &rhs)
Assignment operator.
void setMode(int mode)
Set.
const int * lookedAt() const
Which ones looked at this time.
CglImplication()
Default constructor.
void setAffectedInDisaggregation(disaggregationAction &dis, int affected)
const char * tightenBounds() const
Array which says tighten continuous.
void deleteSnapshot()
Deletes snapshot.
int createCliques(OsiSolverInterface &si, int minimumSize=2, int maximumSize=100)
Creates cliques for use by probing.
const double * tightUpper() const
Upper.
Derived class to pick up probing info.
void setProbingInfo(CglTreeProbingInfo *info)
Set implication.
void setMaxLook(int value)
Set maximum number of variables to look at in one probe.
virtual CglCutGenerator * clone() const
Clone.
void setMaxElementsRoot(int value)
Set maximum number of elements in row for it to be considered (root node)
virtual void generateCuts(const OsiSolverInterface &si, OsiCuts &cs, const CglTreeInfo info=CglTreeInfo())
Generate cuts from implication table Insert generated cuts into the cut set cs.
bool zeroOneInDisaggregation(const disaggregationAction &dis)
void setMaxProbe(int value)
Set maximum number of unsatisfied variables to look at.
Cut Generator Base Class.
virtual bool mayGenerateRowCutsInTree() const
Returns true if may generate Row cuts in tree (rather than root node).
friend struct CglProbing::disaggregation_struct_tag
Only useful type of disaggregation is most normal For now just done for 0-1 variables Can be used for...
CglProbing()
Default constructor.
bool affectedToUBInDisaggregation(const disaggregationAction &dis)
const double * relaxedRowUpper() const
Upper.
int getUsingObjective() const
Get.
virtual std::string generateCpp(FILE *fp)
Create C++ lines to get to current state.
virtual void generateCuts(const OsiSolverInterface &si, OsiCuts &cs, const CglTreeInfo info=CglTreeInfo())
Generate probing/disaggregation cuts for the model of the solver interface, si.
void setZeroOneInDisaggregation(disaggregationAction &dis, bool zeroOne)
void CglProbingUnitTest(const OsiSolverInterface *siP, const std::string mpdDir)
A function that tests the methods in the CglProbing class.
int getMaxLookRoot() const
Get maximum number of variables to look at in one probe (root node)
int getMaxElements() const
Get maximum number of elements in row for it to be considered.
int numberThisTime() const
Number looked at this time.
const double * tightLower() const
Lower.
virtual ~CglImplication()
Destructor.
int getLogLevel() const
Get log level.
void setLogLevel(int value)
Set log level - 0 none, 1 - a bit, 2 - more details.
void setAffectedToUBInDisaggregation(disaggregationAction &dis, bool affectedToUB)
virtual void refreshSolver(OsiSolverInterface *solver)
This can be used to refresh any inforamtion.
void tightenThese(const OsiSolverInterface &solver, int number, const int *which)
Mark variables to be tightened.
int getMaxPass() const
Get maximum number of passes per node.
int snapshot(const OsiSolverInterface &si, char *possible=NULL, bool withObjective=true)
Create a copy of matrix which is to be used this is to speed up process and to give global cuts Can g...
void setUsingObjective(int yesNo)
Set 0 don't 1 do -1 don't even think about it.
friend void CglProbingUnitTest(const OsiSolverInterface *siP, const std::string mpdDir)
A function that tests the methods in the CglProbing class.
bool whenAtUBInDisaggregation(const disaggregationAction &dis)
int generateCutsAndModify(const OsiSolverInterface &si, OsiCuts &cs, CglTreeInfo *info)
void setMaxProbeRoot(int value)
Set maximum number of unsatisfied variables to look at (root node)
void setRowCuts(int type)
Set 0 no cuts, 1 just disaggregation type, 2 coefficient ( 3 both)
int getMaxElementsRoot() const
Get maximum number of elements in row for it to be considered (root node)
int affectedInDisaggregation(const disaggregationAction &dis)
virtual ~CglProbing()
Destructor.
Probing Cut Generator Class.
void setMaxPassRoot(int value)
Set maximum number of passes per node (root node)
CglProbing & operator=(const CglProbing &rhs)
Assignment operator.
void deleteCliques()
Delete all clique information.
int getMaxProbeRoot() const
Get maximum number of unsatisfied variables to look at (root node)