Skip to content

Commit 5514563

Browse files
committed
fix re-recognition of ranged rows at end of OsiGrb::addRows(rowlb,rowub)
- rowlb should not be -infinity for a ranged row
1 parent b01612e commit 5514563

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

CHANGELOG

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
05/03/2026
2+
- fixed handling of ranged rows in OsiGrbSolverInterface::addRows() variant that passes row lhs and rhs
3+
14
21/03/2023
25
- remove use of std::bind2nd to improve compatibility with C++17, see #177
36

src/OsiGrb/OsiGrbSolverInterface.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2410,7 +2410,7 @@ void OsiGrbSolverInterface::addRows(const int numrows,
24102410
if (haverangedrows) {
24112411
int nr = getNumRows() - numrows;
24122412
for (i = 0; i < numrows; ++i)
2413-
if (rowlb[i] > getInfinity() && rowub[i] < getInfinity() && rowub[i] - rowlb[i] > 0.0)
2413+
if (rowlb[i] > -getInfinity() && rowub[i] < getInfinity() && rowub[i] - rowlb[i] > 0.0)
24142414
convertToRangedRow(nr + i, rowub[i], rowub[i] - rowlb[i]);
24152415
} else if (nauxcols)
24162416
resizeAuxColIndSpace();

0 commit comments

Comments
 (0)