Changeset 5337 for branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization/3.3/Operators
- Timestamp:
- 01/20/11 01:30:44 (14 years ago)
- Location:
- branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization/3.3/Operators
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization/3.3/Operators/Crossovers/AverageDoubleValueCrossover.cs
r5277 r5337 34 34 public static void ApplyStatic(IRandom random, DoubleValue value, DoubleValue other, DoubleValueRange range) { 35 35 value.Value = (value.Value + other.Value) / 2; 36 range.ApplyStepSize(value);36 value.Value = range.ApplyStepSize(value.Value); 37 37 } 38 38 } -
branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization/3.3/Operators/Crossovers/NormalDoubleValueCrossover.cs
r5293 r5337 39 39 do { 40 40 offspring.Value = N.NextDouble(); 41 range.ApplyStepSize(offspring);41 offspring.Value = range.ApplyStepSize(offspring.Value); 42 42 } while (!range.IsInRange(offspring.Value)); 43 43 return offspring; -
branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization/3.3/Operators/Crossovers/NormalIntValueCrossover.cs
r5293 r5337 38 38 do { 39 39 offspring.Value = (int)N.NextDouble(); 40 range.ApplyStepSize(offspring);40 offspring.Value = range.ApplyStepSize(offspring.Value); 41 41 } while (!range.IsInRange(offspring.Value)); 42 42 return offspring; -
branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization/3.3/Operators/Manipulators/NormalDoubleValueManipulator.cs
r5293 r5337 45 45 NormalAllPositionsManipulator.Apply(random, vector, strategy); 46 46 value.Value = vector[0]; 47 range.ApplyStepSize(value);47 value.Value = range.ApplyStepSize(value.Value); 48 48 ok = range.IsInRange(value.Value); 49 49 } -
branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization/3.3/Operators/Manipulators/NormalIntValueManipulator.cs
r5293 r5337 47 47 NormalAllPositionsManipulator.Apply(random, vector, strategy); 48 48 value.Value = (int)vector[0]; 49 range.ApplyStepSize(value);49 value.Value = range.ApplyStepSize(value.Value); 50 50 ok = range.IsInRange(value.Value); 51 51 } -
branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization/3.3/Operators/Manipulators/UniformDoubleValueManipulator.cs
r5207 r5337 47 47 UniformOnePositionManipulator.Apply(random, vector, bounds); 48 48 value.Value = vector[0]; 49 range.ApplyStepSize(value);49 value.Value = range.ApplyStepSize(value.Value); 50 50 ok = range.IsInRange(value.Value); 51 51 } -
branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization/3.3/Operators/Manipulators/UniformIntValueManipulator.cs
r5207 r5337 45 45 UniformOnePositionManipulator.Apply(random, vector, range.LowerBound, new IntValue(range.UpperBound.Value + 1)); 46 46 value.Value = vector[0]; 47 range.ApplyStepSize(value);47 value.Value = range.ApplyStepSize(value.Value); 48 48 ok = range.IsInRange(value.Value); 49 49 }
Note: See TracChangeset
for help on using the changeset viewer.