MixedIntegerLinearProgram.set_max bug?

asked 2012-07-19 08:54:23 -0500

Jeremy Martin gravatar image

updated 2016-01-04 19:48:06 -0500

The set_max method in MixedIntegerLinearProgram() does not seem to work correctly if the maximum value specified is 0. Specifically, the input....

Q = MixedIntegerLinearProgram();
xx = Q['xx'];
Q.set_min(xx,0);
Q.get_min(xx)

... returns null, but ....

Q = MixedIntegerLinearProgram();
xx = Q['xx'];
Q.set_min(xx,3);
Q.get_min(xx)

... works fine. Anyone know what's going on here?

edit retag flag offensive close merge delete

Comments

This problem seems to be fixed on Sage 5.9, since i get 0 as an answer to your first query as expected. Could you still reproduce it ?

tmonteil gravatar imagetmonteil ( 2013-04-17 10:52:22 -0500 )edit