Originally posted by: DinuN
Hi Faisal,
Thanks a lot. I tried it on some simple cases and it worked. But I'm a little new to OPL, so I have a few questions regarding the code:
1. I have never used the
main method in OPL before, so based on the code I'm guessing when you say
thisOplModel.generate() , you are referring to the model defined before the
main method.
2. In this part of the code, I guess you are using the same model definition as the previous one. But how does it make sure that it searches only in the pool of alternate solutions from the first model/solution?
var opl1 = new IloOplModel(thisOplModel.modelDefinition, cplex);
var data1 = thisOplModel.dataElements;
data1.a = 0;
data1.b = 1;
data1.obj1Val = obj1_val;
opl1.addDataSource(data1);
opl1.generate();
Thank you again for your time,
Dinakar
#DecisionOptimization#OPLusingCPLEXOptimizer