mirror of
https://github.com/graphhopper/jsprit.git
synced 2020-01-24 07:45:05 +01:00
consider initial routes when calculating initial solution
This commit is contained in:
parent
b8ef9a55a1
commit
bd5adcd0f1
1 changed files with 1 additions and 0 deletions
|
|
@ -52,6 +52,7 @@ public final class InsertionInitialSolutionFactory implements InitialSolutionFac
|
|||
public VehicleRoutingProblemSolution createSolution(final VehicleRoutingProblem vrp) {
|
||||
logger.info("create initial solution.");
|
||||
List<VehicleRoute> vehicleRoutes = new ArrayList<VehicleRoute>();
|
||||
vehicleRoutes.addAll(vrp.getInitialVehicleRoutes());
|
||||
insertion.insertJobs(vehicleRoutes, getUnassignedJobs(vrp));
|
||||
VehicleRoutingProblemSolution solution = new VehicleRoutingProblemSolution(vehicleRoutes, Double.MAX_VALUE);
|
||||
double costs = solutionCostsCalculator.getCosts(solution);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue