Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
01/05/12 10:55:39 (13 years ago)
Author:
svonolfe
Message:

Improved incremental evaluation (#1177)

Location:
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/ProblemInstances/SingleDepotVRP/CVRP/CVRPTW
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/ProblemInstances/SingleDepotVRP/CVRP/CVRPTW/CVRPPDTW/CVRPPDTWEvaluator.cs

    r6883 r7276  
    5050      TourInsertionInfo tourInfo = new TourInsertionInfo(solution.GetVehicleAssignment(solution.GetTourIndex(tour)));
    5151      eval.InsertionInfo.AddTourInsertionInfo(tourInfo);
     52      double originalQuality = eval.Quality;
    5253
    5354      IHomogenousCapacitatedProblemInstance cvrpInstance = instance as IHomogenousCapacitatedProblemInstance;
     
    168169      eval.Quality += time * vrptw.TimeFactor.Value;
    169170      tourInfo.Penalty = tourPenalty;
     171      tourInfo.Quality = eval.Quality - originalQuality;
    170172    }
    171173
  • branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/ProblemInstances/SingleDepotVRP/CVRP/CVRPTW/CVRPTWEvaluator.cs

    r6883 r7276  
    5454      TourInsertionInfo tourInfo = new TourInsertionInfo(solution.GetVehicleAssignment(solution.GetTourIndex(tour)));
    5555      eval.InsertionInfo.AddTourInsertionInfo(tourInfo);
     56      double originalQuality = eval.Quality;
    5657     
    5758      IHomogenousCapacitatedProblemInstance cvrpInstance = instance as IHomogenousCapacitatedProblemInstance;
     
    151152      eval.Quality += time * vrptw.TimeFactor.Value;
    152153      tourInfo.Penalty = tourPenalty;
     154      tourInfo.Quality = eval.Quality - originalQuality;
    153155    }
    154156
Note: See TracChangeset for help on using the changeset viewer.