Skip to content

Commit c601007

Browse files
committed
Recovered IIS use of optionChangeAction
1 parent c9bc15b commit c601007

File tree

3 files changed

+8
-3
lines changed

3 files changed

+8
-3
lines changed

check/TestUserScale.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
#include "Highs.h"
55
#include "catch.hpp"
66

7-
const bool dev_run = true; // false;
7+
const bool dev_run = false;
88
const double inf = kHighsInf;
99

1010
bool doubleEqual0(const double v0, const double v1) {

highs/Highs.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1705,8 +1705,7 @@ class Highs {
17051705

17061706
HighsStatus handleInfCost();
17071707
void restoreInfCost(HighsStatus& return_status);
1708-
// Retain trivial optionChangeAction() in case it's useful later
1709-
HighsStatus optionChangeAction() const { return HighsStatus::kOk; };
1708+
HighsStatus optionChangeAction();
17101709

17111710
HighsStatus userScaleModel(HighsUserScaleData& data);
17121711
HighsStatus userScaleSolution(HighsUserScaleData& data,

highs/lp_data/HighsInterface.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2944,6 +2944,12 @@ HighsStatus Highs::handleInfCost() {
29442944
return HighsStatus::kOk;
29452945
}
29462946

2947+
HighsStatus Highs::optionChangeAction() {
2948+
if (this->iis_.valid_ && options_.iis_strategy != this->iis_.strategy_)
2949+
this->iis_.invalidate();
2950+
return HighsStatus::kOk;
2951+
}
2952+
29472953
void Highs::restoreInfCost(HighsStatus& return_status) {
29482954
HighsLp& lp = this->model_.lp_;
29492955
HighsBasis& basis = this->basis_;

0 commit comments

Comments
 (0)