Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
09/30/11 11:36:05 (13 years ago)
Author:
svonolfe
Message:

Added support for the multi depot CVRP with time windows (#1177)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/ProblemInstances/MultiDepotVRP/MultiDepotVRPProblemInstance.cs

    r6851 r6854  
    150150    }
    151151
    152     public override double GetInsertionDistance(int start, int customer, int end, IVRPEncoding solution) {
     152    public override double GetInsertionDistance(int start, int customer, int end, IVRPEncoding solution,
     153      out double startDistance, out double endDistance) {
    153154      if (start == 0) {
    154155        start = GetDepot(end, solution);
     
    164165     
    165166      double distance = base.GetDistance(start, end, solution);
    166       double newDistance =
    167         base.GetDistance(start, customer, solution) +
    168         base.GetDistance(customer, end, solution);
     167
     168      startDistance = base.GetDistance(start, customer, solution);
     169      endDistance = base.GetDistance(customer, end, solution);
     170
     171      double newDistance = startDistance + endDistance;
    169172
    170173      return newDistance - distance;
Note: See TracChangeset for help on using the changeset viewer.