| 419 | } |
| 420 | |
| 421 | void LocalSearch::markRequiredMissingAsPromising() |
| 422 | { |
| 423 | for (auto client = data.numDepots(); client != data.numLocations(); |
| 424 | ++client) |
| 425 | { |
| 426 | if (solution_.nodes[client].route()) // then it's not missing, so |
| 427 | continue; // nothing to do |
| 428 | |
| 429 | ProblemData::Client const &clientData = data.location(client); |
| 430 | if (clientData.required) |
| 431 | { |
| 432 | searchSpace_.markPromising(client); |
| 433 | continue; |
| 434 | } |
| 435 | |
| 436 | if (clientData.group) // mark the group's first client as promising so |
| 437 | { // the group at least gets inserted if needed |
| 438 | auto const &group = data.group(clientData.group.value()); |
| 439 | if (group.required && group.clients().front() == client) |
| 440 | { |
| 441 | searchSpace_.markPromising(client); |
| 442 | continue; |
| 443 | } |
| 444 | } |
| 445 | } |
| 446 | } |
| 447 | |
| 448 | void LocalSearch::update(Route *U, Route *V) |
| 449 | { |
nothing calls this directly
no test coverage detected