From 2f97a4d4b37b6fa19978abeeb771e06d6ced281d Mon Sep 17 00:00:00 2001 From: John Forrest Date: Thu, 7 Dec 2023 21:43:33 +0000 Subject: [PATCH] maybe fix error that never ocurs with standalone clp --- src/ClpSimplexPrimal.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/ClpSimplexPrimal.cpp b/src/ClpSimplexPrimal.cpp index 33abcc9a..81eeaf02 100644 --- a/src/ClpSimplexPrimal.cpp +++ b/src/ClpSimplexPrimal.cpp @@ -1403,6 +1403,15 @@ void ClpSimplexPrimal::statusOfProblemInPrimal(int &lastCleaned, int type, printf("nonLinearCost says infeasible %d summing to %g\n", ninfeas, sum); #endif + // Need to increase infeasibility cost (keep Henning happy) + if (infeasibilityCost_ < 1.0e14) { + infeasibilityCost_ *= 5.0; + // reset looping criterion + progress->reset(); + if (handler_->logLevel() == 63) + printf("increasing weight to %g\n", infeasibilityCost_); + gutsOfSolution(NULL, NULL, ifValuesPass != 0); + } if (average > relaxedToleranceP) { sumOfRelaxedPrimalInfeasibilities_ = sum; numberPrimalInfeasibilities_ = ninfeas;