Rev | Line | |
---|
[37] | 1 | function [lb,ub,redundant] = detect_and_improve_bounds(Matrices,lb,ub,binary_var_index,options); |
---|
| 2 | |
---|
| 3 | A = [ Matrices.G -Matrices.E]; |
---|
| 4 | b = [ Matrices.W ]; |
---|
| 5 | |
---|
| 6 | [global_lower,global_upper,bound_rows] = find_variable_bounds(A,b,[Matrices.Aeq Matrices.Beq],Matrices.beq); |
---|
| 7 | global_lower(binary_var_index) = max(global_lower(binary_var_index),0); |
---|
| 8 | global_upper(binary_var_index) = min(global_upper(binary_var_index),1); |
---|
| 9 | |
---|
| 10 | if ~isempty(lb) |
---|
| 11 | global_lower = max([global_lower lb],[],2); |
---|
| 12 | end |
---|
| 13 | if ~isempty(ub) |
---|
| 14 | global_upper = min([global_upper ub],[],2); |
---|
| 15 | end |
---|
| 16 | |
---|
| 17 | [lb,ub,redundant,psstruct,infeasible] = tightenbounds(A,b,global_lower,global_upper,[],binary_var_index); |
---|
Note: See
TracBrowser
for help on using the repository browser.