Hello everyone
I need a small help. I am C++ user and trying to solve my MIP model by calling Cplex. I built an model called "modelu" in a function like this.
double modelu (....)
{
IloEnv env;
IloModel mdl(env);
IloCplex cub(env);
IloRangeArray constr1(env);
IloRangeArray constr2(env);
IloRangeArray constr3(env);
IloRangeArray constr4(env);
//decsion variables//
//
//add the constraints and objective function//.
}
This part is ok for me . I want to remove constr1 from the model "mdl" I created in the function above and do some other things in another function
double anotherfunction(....)
{
mdl.remove(constr1);
//do the other tasks//
}
int main()
{
double anotherfunction(....)
}
I do not know how can I call "mdl" model and the constraint that will be removed to the anotherfunction(), what should I write exactly? and how should I define them in the main block before anotherfunction().
I checked the files but could not find the answer I looked for , thank you in advance
------------------------------
milena kafka
------------------------------
#DecisionOptimization