Originally posted by: prasr29
Hello,
Greetings. I am using concert technology in C++ and I am facing an issue with respect to the callback which I have written. Actually the problem is to as soon as an incumbent node has a integer value less than a particular value, the program should stop execution. The code I have written is as follows:
ILOMIPINFOCALLBACK3(abortingCallback,
IloCplex, cplex,
IloBool, aborted,
double, sol_cut1)
{
if ( !aborted && hasIncumbent()) {
cout<<"sol_cut"<<sol_cut1<<endl;
if(sol_cut1 > getIncumbentObjValue()){
//printf ("Obj at Incumbent\n", cplex.getObjValue);
aborted = IloTrue;
abort();
}
}
}
The value sol_cut is passed from the main program.
Cplex is giving results as follows:
After the callback is encountered it stops but in this stage I want the execution to stop but it solves still optimality. Is it something wrong that I am doing here ? Thanks for your help.
#CPLEXOptimizers#DecisionOptimization