Changeset 6450 for trunk/sources
- Timestamp:
- 06/20/11 13:53:07 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Problems.VehicleRouting/3.3/Encodings/Potvin/PotvinEncoding.cs
r6449 r6450 73 73 route = -1; 74 74 place = -1; 75 bool bestFeasible = false;76 75 double minDetour = 0; 77 76 … … 86 85 capacity, distMatrix); 87 86 88 if ( !bestFeasible ||feasible) {87 if (feasible) { 89 88 double newLength = Tours[tour].GetLength(distMatrix); 90 89 double detour = newLength - length; 91 90 92 if (route <= 0 || detour < minDetour || (!(bestFeasible && !feasible)) && detour < minDetour || (feasible && !bestFeasible)) {91 if (route <= 0 || detour < minDetour) { 93 92 route = tour; 94 93 place = i; 95 94 minDetour = detour; 96 97 if (feasible)98 bestFeasible = true;99 95 } 100 96 }
Note: See TracChangeset
for help on using the changeset viewer.