From cbefa8d2b0d2da8ba67f9a760e3c0da06324abc2 Mon Sep 17 00:00:00 2001 From: Lev Nachmanson Date: Wed, 4 Mar 2020 11:59:35 -0800 Subject: [PATCH] fix in gomory cut Signed-off-by: Lev Nachmanson --- src/math/lp/gomory.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/math/lp/gomory.cpp b/src/math/lp/gomory.cpp index 9f497fb09..7720c5f2f 100644 --- a/src/math/lp/gomory.cpp +++ b/src/math/lp/gomory.cpp @@ -45,7 +45,8 @@ class create_cut { const impq & get_value(unsigned j) const { return lia.get_value(j); } bool is_int(unsigned j) const { return lia.column_is_int(j) || (lia.is_fixed(j) && lia.lra.column_lower_bound(j).is_int()); } - bool is_real(unsigned j) const { return !is_int(j); } + bool is_real(unsigned j) const { return lia.is_real(j) && (! (lia.is_fixed(j) && + lia.lra.column_lower_bound(j).is_int())); } bool at_lower(unsigned j) const { return lia.at_lower(j); } bool at_upper(unsigned j) const { return lia.at_upper(j); } const impq & lower_bound(unsigned j) const { return lia.lower_bound(j); } @@ -54,6 +55,8 @@ class create_cut { constraint_index column_upper_bound_constraint(unsigned j) const { return lia.column_upper_bound_constraint(j); } bool column_is_fixed(unsigned j) const { return lia.lra.column_is_fixed(j); } + + void int_case_in_gomory_cut(unsigned j) { lp_assert(is_int(j) && m_fj.is_pos()); TRACE("gomory_cut_detail",