Skip to content

Commit

Permalink
minor change to improve reliability
Browse files Browse the repository at this point in the history
  • Loading branch information
jjhforrest committed Jan 24, 2025
1 parent 989cc14 commit 9d9fb28
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/CbcModel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14804,7 +14804,8 @@ nPartiallyFixed %d , nPartiallyFixedBut %d , nUntouched %d\n",
moreSpecialOptions2_ &= ~2;
}
// This is not correct - that way cutoff can go up if maximization
double direction = !modelFlipped() ? solver_->getObjSense() : 1.0;
double direction = !modelFlipped() ? solver_->getObjSense() : 1.0;
cutoff += 0.001; // relax
setCutoff(cutoff*direction);
// change cutoff as constraint if wanted
if (cutoffRowNumber_ >= 0) {
Expand Down
1 change: 1 addition & 0 deletions src/CbcSolver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2528,6 +2528,7 @@ int CbcMain1(std::deque<std::string> inputQueue, CbcModel &model,
if (!mode) {
// switch off clique strengthening
clqstrMode = "off";
cgraphMode = "off";
}
break;
case CbcParam::HEURISTICSTRATEGY:
Expand Down
2 changes: 2 additions & 0 deletions src/CbcStrategy.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,8 @@ void CbcStrategyDefault::setupCutGenerators(CbcModel &model)
int nNodes = model.getMaximumNodes();
if (nNodes >= 190000 && nNodes < 190064)
genFlags = nNodes - 190000;
#else
genFlags=0;
#endif

CglProbing generator1;
Expand Down

0 comments on commit 9d9fb28

Please sign in to comment.