Closed vgexl closed 4 years ago
Hi For an unknown reason it's now ok. Sorry for the inconvenience. Here my code
!pip install --user docplex
!pip install --user cplex
!python -c "import cplex; print(cplex.__version__)"
import cplex
print(cplex.__version__)
import sys
import cplex
from docplex.mp.model import Model
mdl = Model(name='buses')
nbbus40 = mdl.integer_var(name='nbBus40')
nbbus30 = mdl.integer_var(name='nbBus30')
mdl.add_constraint(nbbus40*40 + nbbus30*30 >= 300, 'kids')
mdl.minimize(nbbus40*460 + nbbus30*360)
sol=mdl.solve()
for v in mdl.iter_integer_vars():
print(v," = ",v.solution_value)
get : nbBus40 = 6.0 nbBus30 = 2.0
Hi,
I recently install Jupyter for Cognos Analytics which embed Jupyter in Cognos.
I got this error after trying code below. Could you help ?
thank you
DOcplexException Traceback (most recent call last)