ryanjoneil / python-zibopt

Automatically exported from code.google.com/p/python-zibopt
2 stars 1 forks source link

single-variable objectives fail when they are constrained #33

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
The following should not check for lower or upper bounds on objectives of a 
single variable.  Currently, this does not work:

max_val = solver.variable()
max_val >= foo # some other variable
solver.minimize(objective=max_val)

giving the error: "_scip.error: objective functions should not have bounds"

But if we turn it into an expression it works:

solver.minimize(objective=max_val+0)

We can just forgo the bounds check on single-variable objectives.

Original issue reported on code.google.com by ryanjoneil on 12 Jan 2012 at 4:03

GoogleCodeExporter commented 9 years ago
fixed in python-algebraic

Original comment by ryanjoneil on 12 Jan 2012 at 6:54