Im trying to implement a heuristic callback in cplex for my MIP.
The variables in my model are represented by a twodimensional array:
IloArray
Conceptually I do the following in the callback:
IloNumArray x_a;
for ( a = 0; a
getValues ( x_a , design[a] );
// round the values of x_a
setSolution ( design[a], x_a);
}
but it seems that cplex never considers my solution as incumbent. Is
there anything wrong with multiple calls to setSolution()? The manual
says "Do not call this method multiple times. Calling it again will
overwrite any previously specified solution.", but i) Im calling it
for different variables design[0], design[1], etc .... and ii) I dont
see any other way to set the values of a twodimensional array of
variables but calling it multiple times.
Any comments would be appreciated.