Hi I am using java with cplex I am trying to maximize an equation and i want to consider the object even if it is a negative value. I declared about my object variable like that
when i use this code the object value will be zero because it is negative Do you have any suggestion to do that ? |
You should not put a lower bound of zero on your variable if you want it to take negative values as well. I don't know the java-API but I could imagine it should look something like
Thank you very much
(27 Oct '14, 09:00)
ibrahem
2
In the Java API, the way to represent infinity (signed) is Double.NEGATIVE_INFINITY or Double.POSITIVE_INFINITY.
(28 Oct '14, 16:24)
Paul Rubin ♦♦
|