- Timestamp:
- 09/29/11 15:51:56 (13 years ago)
- Location:
- branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/PickupDelivery
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/PickupDelivery/PDExchange/PotvinPDExchangeExhaustiveMoveGenerator.cs
r6773 r6851 62 62 if (k != i) { 63 63 int city1 = individual.Tours[i].Stops[j]; 64 if (pdp == null || pdp. Demand[city1]>= 0) {64 if (pdp == null || pdp.GetDemand(city1) >= 0) { 65 65 for (int l = 0; l < individual.Tours[k].Stops.Count; l++) { 66 66 int city2 = individual.Tours[k].Stops[l]; 67 if (pdp == null || pdp. Demand[city2]>= 0) {67 if (pdp == null || pdp.GetDemand(city2) >= 0) { 68 68 bool valid = pdp == null || 69 69 (pdp.PickupDeliveryLocation[city2] != pdp.PickupDeliveryLocation[city1] && -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/PickupDelivery/PDExchange/PotvinPDExchangeSingleMoveGenerator.cs
r6773 r6851 62 62 IPickupAndDeliveryProblemInstance pdp = problemInstance as IPickupAndDeliveryProblemInstance; 63 63 for (int i = 1; i <= individual.Cities; i++) { 64 if (pdp == null || pdp. Demand[i]>= 0)64 if (pdp == null || pdp.GetDemand(i) >= 0) 65 65 cities.Add(i); 66 66 } … … 84 84 foreach (int stop in newTour.Stops) { 85 85 if (pdp == null || 86 (pdp. Demand[stop]>= 0 &&86 (pdp.GetDemand(stop) >= 0 && 87 87 pdp.PickupDeliveryLocation[stop] != pdp.PickupDeliveryLocation[city] && 88 88 pdp.PickupDeliveryLocation[stop] != city && -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/PickupDelivery/PDRearrange/PotvinPDRearrangeExhaustiveMoveGenerator.cs
r6773 r6851 54 54 55 55 for (int i = 1; i <= problemInstance.Cities.Value; i++) { 56 if (pdp == null || pdp. Demand[i]>= 0) {56 if (pdp == null || pdp.GetDemand(i) >= 0) { 57 57 int tour = individual.Tours.FindIndex(t => t.Stops.Contains(i)); 58 58 -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/PickupDelivery/PDRearrange/PotvinPDRearrangeMoveMaker.cs
r6838 r6851 74 74 if (positionToAvoid != i || positionToAvoid2 != j || stops == 0) { 75 75 bool feasible; 76 double targetCosts = problemInstance.GetInsertionCosts(tourEval, target, 0, j, out feasible);76 double targetCosts = problemInstance.GetInsertionCosts(tourEval, solution, target, 0, j, out feasible); 77 77 78 78 double costs = sourceCosts + targetCosts; -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/PickupDelivery/PDRearrange/PotvinPDRearrangeSingleMoveGenerator.cs
r6773 r6851 62 62 IPickupAndDeliveryProblemInstance pdp = problemInstance as IPickupAndDeliveryProblemInstance; 63 63 for (int i = 1; i <= individual.Cities; i++) { 64 if(pdp == null || pdp. Demand[i]>= 0)64 if(pdp == null || pdp.GetDemand(i) >= 0) 65 65 cities.Add(i); 66 66 } -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/PickupDelivery/PDShift/PotvinPDShiftExhaustiveMoveGenerator.cs
r6773 r6851 62 62 if (k != i) { 63 63 int city = individual.Tours[i].Stops[j]; 64 if (pdp == null || pdp. Demand[city]>= 0) {64 if (pdp == null || pdp.GetDemand(city) >= 0) { 65 65 PotvinPDShiftMove move = new PotvinPDShiftMove( 66 66 city, i, k, individual); -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/PickupDelivery/PDShift/PotvinPDShiftSingleMoveGenerator.cs
r6773 r6851 62 62 IPickupAndDeliveryProblemInstance pdp = problemInstance as IPickupAndDeliveryProblemInstance; 63 63 for (int i = 1; i <= individual.Cities; i++) { 64 if(pdp == null || pdp. Demand[i]>= 0)64 if(pdp == null || pdp.GetDemand(i) >= 0) 65 65 cities.Add(i); 66 66 }
Note: See TracChangeset
for help on using the changeset viewer.