I do not see any issues with implementing the VNS using Cooper's algorithm in JAMES. In fact, the way I see it, Cooper's algorithm is a kind of local search, since it starts from a given solution which is iteratively improved. In JAMES you could thus implement Cooper's algorithm by extending the abstract
class.
In each step you would re-allocate the fixed points to the nearest facility and update the facility locations using the exact method for a single facility per subset. This goes in the method
searchStep(). To update the current and best solution you should use
updateCurrentAndBestSolution(...). This method returns
false if no improvement is made, in which case you may call
stop() from within
searchStep() to terminate the algorithm. So something like this:
public class CooperAlgorithm extends LocalSearch<WeberSolution> {
public CooperAlgorithm(Problem<WeberSolution> problem){
super("Cooper", problem);
}
@Override
protected void searchStep(){
// retrieve and copy current solution
WeberSolution sol = Solution.checkedCopy(getCurrentSolution());
// re-allocate fixed points to nearest facility
// ...
// optimize locations by applying single-facility solution to each subset
// ...
// check for improvement
if(!updateCurrentAndBestSolution(sol)){
stop();
}
}
}