Changeset 17698 for branches/2521_ProblemRefactoring/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Zhu/Crossovers/ZhuPermutationCrossover.cs
- Timestamp:
- 07/24/20 00:58:42 (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2521_ProblemRefactoring/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Zhu/Crossovers/ZhuPermutationCrossover.cs
r17226 r17698 50 50 } 51 51 52 protected override ZhuEncod ing Crossover(IRandom random, ZhuEncoding parent1, ZhuEncodingparent2) {52 protected override ZhuEncodedSolution Crossover(IRandom random, ZhuEncodedSolution parent1, ZhuEncodedSolution parent2) { 53 53 //note - the inner crossover is called here and the result is converted to a prins representation 54 54 //some refactoring should be done here in the future - the crossover operation should be called directly 55 55 if (parent1.Length != parent2.Length) 56 return parent1.Clone() as ZhuEncod ing;56 return parent1.Clone() as ZhuEncodedSolution; 57 57 58 58 InnerCrossoverParameter.ActualValue.ParentsParameter.ActualName = ParentsParameter.ActualName; … … 66 66 ExecutionContext.Scope.Variables.Remove(childName); 67 67 68 return new ZhuEncod ing(permutation, ProblemInstance);68 return new ZhuEncodedSolution(permutation, ProblemInstance); 69 69 } else 70 70 return null;
Note: See TracChangeset
for help on using the changeset viewer.