@@ -796,3 +796,40 @@ TEST_CASE("write-iis_model-file", "[iis]") {
796796 std::remove (test_sol.c_str ());
797797 h.resetGlobalScheduler (true );
798798}
799+
800+ TEST_CASE (" iis-2867" , " [iis]" ) {
801+ std::string model = " 2867" ;
802+ std::string model_file =
803+ std::string (HIGHS_DIR) + " /check/instances/" + model + " .mps" ;
804+ Highs h;
805+ h.setOptionValue (" output_flag" , dev_run);
806+ REQUIRE (h.readModel (model_file) == HighsStatus::kOk );
807+ HighsLp lp = h.getLp ();
808+
809+ // The LP is very close to being feasible, as it has a primal
810+ // infeasibility of 4e-7
811+ //
812+ // The value causing infeasibility is the upper bound on row 40
813+ HighsInt rogue_row = 40 ;
814+ REQUIRE (lp.row_names_ [rogue_row] == " X115" );
815+ REQUIRE (lp.row_upper_ [rogue_row] == 1885.9734504 );
816+
817+ // No IIS is found, as the only positive elastic variable has value
818+ // 6e-09
819+ h.setOptionValue (" iis_strategy" , kIisStrategyIrreducible );
820+ HighsIis iis;
821+ REQUIRE (h.getIis (iis) == HighsStatus::kOk );
822+ REQUIRE (h.getModelStatus () == HighsModelStatus::kNotset );
823+ REQUIRE (iis.valid_ == true );
824+ REQUIRE (iis.status_ == kIisModelStatusFeasible );
825+
826+ // Tighten the upper bound on row 40
827+ lp.row_upper_ [rogue_row] = 1885.97 ;
828+ h.passModel (lp);
829+ REQUIRE (h.getIis (iis) == HighsStatus::kOk );
830+ REQUIRE (h.getModelStatus () == HighsModelStatus::kInfeasible );
831+ REQUIRE (iis.valid_ == true );
832+ REQUIRE (iis.status_ == kIisModelStatusIrreducible );
833+
834+ h.resetGlobalScheduler (true );
835+ }
0 commit comments