I'm currently using CyLP package in Python for mixed-integer linear programming. However, I'm not able to initialize integer variables. According to the documentation, I have passed isInt = True to addVariable method but it does nothing.
A minimal example of my program is shown below. The optimal value should be 2 when x = y = 1, but the result is not as expected.
import cylp
from cylp.cy import CyClpSimplex
print(cylp.__version__) # 0.91.0
s = CyClpSimplex()
x = s.addVariable('x', 1, isInt = True)
y = s.addVariable('y', 1, isInt = True)
s += x >= 0.5
s += y >= 0.7
s.objective = x + y
s.optimizationDirection = 'min'
s.primal()
# Clp3002W Empty problem - 0 rows, 2 columns and 0 elements
# Clp0000I Optimal - objective value 1.2
x_opt = s.primalVariableSolution['x'][0]
y_opt = s.primalVariableSolution['y'][0]
print(x_opt, y_opt) # 0.5, 0.7
Is there any other way to initialize integer variables in CyLP? Or I'm missing something about addVariable method?
By the way, I wonder what Clp3002W Empty problem means in the output of s.primal().
Thanks in advance.