- Timestamp:
- 11/09/10 09:55:31 (14 years ago)
- Location:
- branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Prins
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Prins/Crossovers/PrinsCrossover.cs
r4379 r4752 28 28 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 29 29 using HeuristicLab.Problems.VehicleRouting.Interfaces; 30 using HeuristicLab.Common; 30 31 31 32 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Prins { … … 44 45 : base() { 45 46 Parameters.Add(new LookupParameter<IRandom>("Random", "The pseudo random number generator which should be used for stochastic manipulation operators.")); 47 } 48 49 protected PrinsCrossover(PrinsCrossover original, Cloner cloner) 50 : base(original, cloner) { 46 51 } 47 52 -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Prins/Crossovers/PrinsPermutationCrossover.cs
r4379 r4752 25 25 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 26 using HeuristicLab.Data; 27 using HeuristicLab.Common; 27 28 28 29 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Prins { … … 40 41 : base() { 41 42 Parameters.Add(new ValueLookupParameter<IPermutationCrossover>("InnerCrossover", "The permutation crossover.", new OrderCrossover())); 43 } 44 45 public override IDeepCloneable Clone(Cloner cloner) { 46 return new PrinsPermutationCrossover(this, cloner); 47 } 48 49 private PrinsPermutationCrossover(PrinsPermutationCrossover original, Cloner cloner) 50 : base(original, cloner) { 42 51 } 43 52 -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Prins/Manipulators/PrinsExhaustiveLSManipulator.cs
r4379 r4752 26 26 using HeuristicLab.Data; 27 27 using System.Collections.Generic; 28 using HeuristicLab.Common; 28 29 29 30 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Prins { … … 36 37 public PrinsExhaustiveLSManipulator() 37 38 : base() { 39 } 40 41 public override IDeepCloneable Clone(Cloner cloner) { 42 return new PrinsExhaustiveLSManipulator(this, cloner); 43 } 44 45 private PrinsExhaustiveLSManipulator(PrinsExhaustiveLSManipulator original, Cloner cloner) 46 : base(original, cloner) { 38 47 } 39 48 -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Prins/Manipulators/PrinsLSManipulator.cs
r4379 r4752 26 26 using HeuristicLab.Data; 27 27 using System.Collections.Generic; 28 using HeuristicLab.Common; 28 29 29 30 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Prins { … … 41 42 : base() { 42 43 Parameters.Add(new ValueParameter<IntValue>("Iterations", "The number of max iterations.", new IntValue(5))); 44 } 45 46 protected PrinsLSManipulator(PrinsLSManipulator original, Cloner cloner) 47 : base(original, cloner) { 43 48 } 44 49 -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Prins/Manipulators/PrinsManipulator.cs
r4379 r4752 28 28 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 29 29 using HeuristicLab.Problems.VehicleRouting.Interfaces; 30 using HeuristicLab.Common; 30 31 31 32 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Prins { … … 45 46 } 46 47 48 protected PrinsManipulator(PrinsManipulator original, Cloner cloner) 49 : base(original, cloner) { 50 } 51 47 52 protected abstract void Manipulate(IRandom random, PrinsEncoding individual); 48 53 -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Prins/Manipulators/PrinsPermutationManipulator.cs
r4379 r4752 25 25 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 26 using HeuristicLab.Data; 27 using HeuristicLab.Common; 27 28 28 29 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Prins { … … 42 43 } 43 44 45 public override IDeepCloneable Clone(Cloner cloner) { 46 return new PrinsPermutationManipulator(this, cloner); 47 } 48 49 private PrinsPermutationManipulator(PrinsPermutationManipulator original, Cloner cloner) 50 : base(original, cloner) { 51 } 52 44 53 protected override void Manipulate(IRandom random, PrinsEncoding individual) { 45 54 InnerManipulatorParameter.ActualValue.PermutationParameter.ActualName = VRPToursParameter.ActualName; -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Prins/Manipulators/PrinsStochasticLSManipulator.cs
r4379 r4752 26 26 using HeuristicLab.Data; 27 27 using System.Collections.Generic; 28 using HeuristicLab.Common; 28 29 29 30 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Prins { … … 41 42 : base() { 42 43 Parameters.Add(new ValueParameter<IntValue>("SampleSize", "The sample size.", new IntValue(200))); 44 } 45 46 public override IDeepCloneable Clone(Cloner cloner) { 47 return new PrinsStochasticLSManipulator(this, cloner); 48 } 49 50 private PrinsStochasticLSManipulator(PrinsStochasticLSManipulator original, Cloner cloner) 51 : base(original, cloner) { 43 52 } 44 53 -
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Prins/PrinsEncoding.cs
r4379 r4752 132 132 } 133 133 #endregion 134 135 public override IDeepCloneable Clone(HeuristicLab.Common.Cloner cloner) {136 PrinsEncoding clone = new PrinsEncoding(137 new Permutation(this.PermutationType, this.array), ProblemInstance);138 139 cloner.RegisterClonedObject(this, clone);140 clone.readOnly = readOnly;141 return clone;142 }143 144 134 public PrinsEncoding(Permutation permutation, IVRPProblemInstance problemInstance) 145 135 : base(permutation, problemInstance) { … … 149 139 private PrinsEncoding(bool serializing) 150 140 : base(serializing) { 141 } 142 143 public override IDeepCloneable Clone(Cloner cloner) { 144 return new PrinsEncoding(this, cloner); 145 } 146 147 protected PrinsEncoding(PrinsEncoding original, Cloner cloner) 148 : base(original, cloner) { 151 149 } 152 150
Note: See TracChangeset
for help on using the changeset viewer.