O= model.continuous_var_dict(idh,name="O",lb=-model.infinity)
should do the trick.
In CPLEX, the infinity is 1e+20. Default constructors of variables in CPLEX have a lower bound of 0.
------------------------------
Vincent Beraudier
------------------------------
Original Message:
Sent: Tue December 13, 2022 02:55 PM
From: andres montaña gavalo
Subject: Unrestricted variable in docplex pythin
Hello, community.
I would like your help to know how to declare an unrestricted variable. I currently use this:
idh = [(d, p) for d in days for p in periods]
O= model.continuous_var_dict(idh,name="O",lb=-1000)
but I would like something like this:
-inf <= O <= inf
That is, not to give a specific value to lb
------------------------------
andres montaña gavalo
------------------------------
#DecisionOptimization