Free cookie consent management tool by TermsFeed Policy Generator

source: stable/HeuristicLab.Algorithms.ALPS/3.3/AlpsOffspringSelectionGeneticAlgorithmMainOperator.cs @ 17883

Last change on this file since 17883 was 17181, checked in by swagner, 5 years ago

#2875: Merged r17180 from trunk to stable

File size: 21.7 KB
RevLine 
[3611]1#region License Information
2/* HeuristicLab
[17181]3 * Copyright (C) Heuristic and Evolutionary Algorithms Laboratory (HEAL)
[3611]4 *
5 * This file is part of HeuristicLab.
6 *
7 * HeuristicLab is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation, either version 3 of the License, or
10 * (at your option) any later version.
11 *
12 * HeuristicLab is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
19 */
20#endregion
21
[17149]22using HEAL.Attic;
[4722]23using HeuristicLab.Common;
[3611]24using HeuristicLab.Core;
25using HeuristicLab.Data;
26using HeuristicLab.Operators;
27using HeuristicLab.Optimization.Operators;
28using HeuristicLab.Parameters;
29using HeuristicLab.Selection;
30
[13402]31namespace HeuristicLab.Algorithms.ALPS {
[3611]32  /// <summary>
33  /// An operator which represents the main loop of an offspring selection genetic algorithm.
34  /// </summary>
[13402]35  [Item("AlpsOffspringSelectionGeneticAlgorithmMainOperator", "An operator that represents the core of an alps offspring selection genetic algorithm.")]
[17097]36  [StorableType("4DBAA32D-84EB-40C0-838D-ACCF9A9C41FA")]
[13402]37  public sealed class AlpsOffspringSelectionGeneticAlgorithmMainOperator : AlgorithmOperator {
[3611]38    #region Parameter properties
[13402]39    public IValueLookupParameter<IRandom> RandomParameter {
40      get { return (IValueLookupParameter<IRandom>)Parameters["Random"]; }
[3611]41    }
[13402]42    public IValueLookupParameter<IOperator> EvaluatorParameter {
43      get { return (IValueLookupParameter<IOperator>)Parameters["Evaluator"]; }
[3611]44    }
[13402]45    public ILookupParameter<IntValue> EvaluatedSolutionsParameter {
46      get { return (ILookupParameter<IntValue>)Parameters["EvaluatedSolutions"]; }
[3611]47    }
[13402]48    public IScopeTreeLookupParameter<DoubleValue> QualityParameter {
49      get { return (IScopeTreeLookupParameter<DoubleValue>)Parameters["Quality"]; }
[3611]50    }
[13402]51    public IValueLookupParameter<BoolValue> MaximizationParameter {
52      get { return (IValueLookupParameter<BoolValue>)Parameters["Maximization"]; }
[3611]53    }
[13402]54
55    public ILookupParameter<IntValue> PopulationSizeParameter {
56      get { return (ILookupParameter<IntValue>)Parameters["PopulationSize"]; }
[3611]57    }
[13402]58
59    public IValueLookupParameter<IOperator> SelectorParameter {
60      get { return (IValueLookupParameter<IOperator>)Parameters["Selector"]; }
[3611]61    }
[13402]62    public IValueLookupParameter<IOperator> CrossoverParameter {
63      get { return (IValueLookupParameter<IOperator>)Parameters["Crossover"]; }
[3611]64    }
[13402]65    public IValueLookupParameter<IOperator> MutatorParameter {
66      get { return (IValueLookupParameter<IOperator>)Parameters["Mutator"]; }
[3611]67    }
[13402]68    public IValueLookupParameter<PercentValue> MutationProbabilityParameter {
69      get { return (IValueLookupParameter<PercentValue>)Parameters["MutationProbability"]; }
[3611]70    }
[13402]71    public IValueLookupParameter<IntValue> ElitesParameter {
72      get { return (IValueLookupParameter<IntValue>)Parameters["Elites"]; }
73    }
[9569]74    public IValueLookupParameter<BoolValue> ReevaluateElitesParameter {
75      get { return (IValueLookupParameter<BoolValue>)Parameters["ReevaluateElites"]; }
76    }
[13402]77
78    public ILookupParameter<DoubleValue> ComparisonFactorParameter {
79      get { return (ILookupParameter<DoubleValue>)Parameters["ComparisonFactor"]; }
[3611]80    }
[13402]81    public ILookupParameter<DoubleValue> CurrentSuccessRatioParameter {
82      get { return (ILookupParameter<DoubleValue>)Parameters["CurrentSuccessRatio"]; }
[3611]83    }
[13402]84    public IValueLookupParameter<DoubleValue> SuccessRatioParameter {
85      get { return (IValueLookupParameter<DoubleValue>)Parameters["SuccessRatio"]; }
[3611]86    }
[13402]87    public ILookupParameter<DoubleValue> SelectionPressureParameter {
88      get { return (ILookupParameter<DoubleValue>)Parameters["SelectionPressure"]; }
[3611]89    }
[13402]90    public IValueLookupParameter<DoubleValue> MaximumSelectionPressureParameter {
91      get { return (IValueLookupParameter<DoubleValue>)Parameters["MaximumSelectionPressure"]; }
[3611]92    }
[13402]93    public IValueLookupParameter<BoolValue> OffspringSelectionBeforeMutationParameter {
94      get { return (IValueLookupParameter<BoolValue>)Parameters["OffspringSelectionBeforeMutation"]; }
[3611]95    }
[10643]96    public IValueLookupParameter<BoolValue> FillPopulationWithParentsParameter {
97      get { return (IValueLookupParameter<BoolValue>)Parameters["FillPopulationWithParents"]; }
98    }
[13402]99
100    public IScopeTreeLookupParameter<DoubleValue> AgeParameter {
101      get { return (IScopeTreeLookupParameter<DoubleValue>)Parameters["Age"]; }
102    }
103    public IValueLookupParameter<DoubleValue> AgeInheritanceParameter {
104      get { return (IValueLookupParameter<DoubleValue>)Parameters["AgeInheritance"]; }
105    }
106    public IValueLookupParameter<DoubleValue> AgeIncrementParameter {
107      get { return (IValueLookupParameter<DoubleValue>)Parameters["AgeIncrement"]; }
108    }
[3611]109    #endregion
110
111    [StorableConstructor]
[17097]112    private AlpsOffspringSelectionGeneticAlgorithmMainOperator(StorableConstructorFlag _) : base(_) { }
[13402]113    private AlpsOffspringSelectionGeneticAlgorithmMainOperator(AlpsOffspringSelectionGeneticAlgorithmMainOperator original, Cloner cloner)
[4722]114      : base(original, cloner) {
115    }
116    public override IDeepCloneable Clone(Cloner cloner) {
[13402]117      return new AlpsOffspringSelectionGeneticAlgorithmMainOperator(this, cloner);
[4722]118    }
[13402]119    public AlpsOffspringSelectionGeneticAlgorithmMainOperator()
[3611]120      : base() {
121      Initialize();
122    }
123
124    private void Initialize() {
125      Parameters.Add(new ValueLookupParameter<IRandom>("Random", "A pseudo random number generator."));
[13402]126
127      Parameters.Add(new ValueLookupParameter<IOperator>("Evaluator", "The operator used to evaluate solutions. This operator is executed in parallel, if an engine is used which supports parallelization."));
128      Parameters.Add(new LookupParameter<IntValue>("EvaluatedSolutions", "The number of evaluated solutions."));
129      Parameters.Add(new ScopeTreeLookupParameter<DoubleValue>("Quality", "The value which represents the quality of a solution."));
[3611]130      Parameters.Add(new ValueLookupParameter<BoolValue>("Maximization", "True if the problem is a maximization problem, otherwise false."));
[13402]131
132      Parameters.Add(new ValueLookupParameter<IntValue>("PopulationSize", "The size of the population of solutions in each layer."));
[3611]133      Parameters.Add(new ValueLookupParameter<IOperator>("Selector", "The operator used to select solutions for reproduction."));
134      Parameters.Add(new ValueLookupParameter<IOperator>("Crossover", "The operator used to cross solutions."));
[13402]135      Parameters.Add(new ValueLookupParameter<IOperator>("Mutator", "The operator used to mutate solutions."));
[3611]136      Parameters.Add(new ValueLookupParameter<PercentValue>("MutationProbability", "The probability that the mutation operator is applied on a solution."));
137      Parameters.Add(new ValueLookupParameter<IntValue>("Elites", "The numer of elite solutions which are kept in each generation."));
[9569]138      Parameters.Add(new ValueLookupParameter<BoolValue>("ReevaluateElites", "Flag to determine if elite individuals should be reevaluated (i.e., if stochastic fitness functions are used.)"));
[13402]139
[3611]140      Parameters.Add(new LookupParameter<DoubleValue>("ComparisonFactor", "The comparison factor is used to determine whether the offspring should be compared to the better parent, the worse parent or a quality value linearly interpolated between them. It is in the range [0;1]."));
141      Parameters.Add(new LookupParameter<DoubleValue>("CurrentSuccessRatio", "The current success ratio."));
142      Parameters.Add(new ValueLookupParameter<DoubleValue>("SuccessRatio", "The ratio of successful to total children that should be achieved."));
143      Parameters.Add(new LookupParameter<DoubleValue>("SelectionPressure", "The actual selection pressure."));
144      Parameters.Add(new ValueLookupParameter<DoubleValue>("MaximumSelectionPressure", "The maximum selection pressure that terminates the algorithm."));
145      Parameters.Add(new ValueLookupParameter<BoolValue>("OffspringSelectionBeforeMutation", "True if the offspring selection step should be applied before mutation, false if it should be applied after mutation."));
[10643]146      Parameters.Add(new ValueLookupParameter<BoolValue>("FillPopulationWithParents", "True if the population should be filled with parent individual or false if worse children should be used when the maximum selection pressure is exceeded."));
[3611]147
[13402]148      Parameters.Add(new ScopeTreeLookupParameter<DoubleValue>("Age", "The age of individuals."));
149      Parameters.Add(new ValueLookupParameter<DoubleValue>("AgeInheritance", "A weight that determines the age of a child after crossover based on the older (1.0) and younger (0.0) parent."));
150      Parameters.Add(new ValueLookupParameter<DoubleValue>("AgeIncrement", "The value the age the individuals is incremented if they survives a generation."));
[4068]151
[13402]152
153      var selector = new Placeholder();
154      var subScopesProcessor1 = new SubScopesProcessor();
155      var childrenCreator = new ChildrenCreator();
156      var osBeforeMutationBranch = new ConditionalBranch();
157      var uniformSubScopesProcessor1 = new UniformSubScopesProcessor();
158      var crossover1 = new Placeholder();
159      var uniformSubScopesProcessor2 = new UniformSubScopesProcessor();
160      var evaluator1 = new Placeholder();
161      var subScopesCounter1 = new SubScopesCounter();
162      var qualityComparer1 = new WeightedParentsQualityComparator();
163      var ageCalculator1 = new WeightingReducer() { Name = "Calculate Age" };
164      var subScopesRemover1 = new SubScopesRemover();
165      var uniformSubScopesProcessor3 = new UniformSubScopesProcessor();
166      var mutationBranch1 = new StochasticBranch();
167      var mutator1 = new Placeholder();
168      var variableCreator1 = new VariableCreator();
169      var variableCreator2 = new VariableCreator();
170      var conditionalSelector = new ConditionalSelector();
171      var subScopesProcessor2 = new SubScopesProcessor();
172      var uniformSubScopesProcessor4 = new UniformSubScopesProcessor();
173      var evaluator2 = new Placeholder();
174      var subScopesCounter2 = new SubScopesCounter();
175      var mergingReducer1 = new MergingReducer();
176      var uniformSubScopesProcessor5 = new UniformSubScopesProcessor();
177      var crossover2 = new Placeholder();
178      var mutationBranch2 = new StochasticBranch();
179      var mutator2 = new Placeholder();
180      var uniformSubScopesProcessor6 = new UniformSubScopesProcessor();
181      var evaluator3 = new Placeholder();
182      var subScopesCounter3 = new SubScopesCounter();
183      var qualityComparer2 = new WeightedParentsQualityComparator();
184      var ageCalculator2 = new WeightingReducer() { Name = "Calculate Age" };
185      var subScopesRemover2 = new SubScopesRemover();
186      var offspringSelector = new AlpsOffspringSelector();
187      var subScopesProcessor3 = new SubScopesProcessor();
188      var bestSelector = new BestSelector();
189      var worstSelector = new WorstSelector();
190      var rightReducer = new RightReducer();
191      var leftReducer = new LeftReducer();
192      var mergingReducer2 = new MergingReducer();
193      var reevaluateElitesBranch = new ConditionalBranch();
194      var uniformSubScopesProcessor7 = new UniformSubScopesProcessor();
195      var evaluator4 = new Placeholder();
196      var subScopesCounter4 = new SubScopesCounter();
197      var incrementAgeProcessor = new UniformSubScopesProcessor();
198      var ageIncrementor = new DoubleCounter() { Name = "Increment Age" };
199
200
201      OperatorGraph.InitialOperator = selector;
202
[3611]203      selector.Name = "Selector (placeholder)";
204      selector.OperatorParameter.ActualName = SelectorParameter.Name;
[13402]205      selector.Successor = subScopesProcessor1;
[3611]206
[13402]207      subScopesProcessor1.Operators.Add(new EmptyOperator());
208      subScopesProcessor1.Operators.Add(childrenCreator);
209      subScopesProcessor1.Successor = offspringSelector;
210
[3611]211      childrenCreator.ParentsPerChild = new IntValue(2);
[13402]212      childrenCreator.Successor = osBeforeMutationBranch;
[3611]213
214      osBeforeMutationBranch.Name = "Apply OS before mutation?";
215      osBeforeMutationBranch.ConditionParameter.ActualName = OffspringSelectionBeforeMutationParameter.Name;
[13402]216      osBeforeMutationBranch.TrueBranch = uniformSubScopesProcessor1;
217      osBeforeMutationBranch.FalseBranch = uniformSubScopesProcessor5;
218      osBeforeMutationBranch.Successor = null;
[3611]219
[13402]220      uniformSubScopesProcessor1.Operator = crossover1;
221      uniformSubScopesProcessor1.Successor = uniformSubScopesProcessor2;
222
[5208]223      crossover1.Name = "Crossover (placeholder)";
224      crossover1.OperatorParameter.ActualName = CrossoverParameter.Name;
[13402]225      crossover1.Successor = null;
[5208]226
227      uniformSubScopesProcessor2.Parallel.Value = true;
[13402]228      uniformSubScopesProcessor2.Operator = evaluator1;
229      uniformSubScopesProcessor2.Successor = subScopesCounter1;
[5208]230
[3611]231      evaluator1.Name = "Evaluator (placeholder)";
232      evaluator1.OperatorParameter.ActualName = EvaluatorParameter.Name;
[13402]233      evaluator1.Successor = qualityComparer1;
[3611]234
[5356]235      subScopesCounter1.Name = "Increment EvaluatedSolutions";
236      subScopesCounter1.ValueParameter.ActualName = EvaluatedSolutionsParameter.Name;
[13402]237      subScopesCounter1.Successor = uniformSubScopesProcessor3;
[3611]238
[13402]239      uniformSubScopesProcessor3.Operator = mutationBranch1;
240      uniformSubScopesProcessor3.Successor = conditionalSelector;
241
[3611]242      qualityComparer1.ComparisonFactorParameter.ActualName = ComparisonFactorParameter.Name;
243      qualityComparer1.LeftSideParameter.ActualName = QualityParameter.Name;
244      qualityComparer1.MaximizationParameter.ActualName = MaximizationParameter.Name;
245      qualityComparer1.RightSideParameter.ActualName = QualityParameter.Name;
246      qualityComparer1.ResultParameter.ActualName = "SuccessfulOffspring";
[13402]247      qualityComparer1.Successor = ageCalculator1;
[3611]248
[13402]249      ageCalculator1.ParameterToReduce.ActualName = AgeParameter.Name;
250      ageCalculator1.TargetParameter.ActualName = AgeParameter.Name;
251      ageCalculator1.WeightParameter.ActualName = AgeInheritanceParameter.Name;
252      ageCalculator1.Successor = subScopesRemover1;
253
[5208]254      subScopesRemover1.RemoveAllSubScopes = true;
[13402]255      subScopesRemover1.Successor = null;
[5208]256
[3611]257      mutationBranch1.ProbabilityParameter.ActualName = MutationProbabilityParameter.Name;
258      mutationBranch1.RandomParameter.ActualName = RandomParameter.Name;
[13402]259      mutationBranch1.FirstBranch = mutator1;
260      mutationBranch1.SecondBranch = variableCreator2;
261      mutationBranch1.Successor = null;
[3611]262
263      mutator1.Name = "Mutator (placeholder)";
264      mutator1.OperatorParameter.ActualName = MutatorParameter.Name;
[13402]265      mutator1.Successor = variableCreator1;
[3611]266
[5208]267      variableCreator1.Name = "MutatedOffspring = true";
[17149]268      variableCreator1.CollectedValues.Add(new ValueParameter<BoolValue>("MutatedOffspring", null, new BoolValue(true)) { GetsCollected = false });
[13402]269      variableCreator1.Successor = null;
[5208]270
271      variableCreator2.Name = "MutatedOffspring = false";
[17149]272      variableCreator2.CollectedValues.Add(new ValueParameter<BoolValue>("MutatedOffspring", null, new BoolValue(false)) { GetsCollected = false });
[13402]273      variableCreator2.Successor = null;
[5208]274
275      conditionalSelector.ConditionParameter.ActualName = "MutatedOffspring";
276      conditionalSelector.ConditionParameter.Depth = 1;
277      conditionalSelector.CopySelected.Value = false;
[13402]278      conditionalSelector.Successor = subScopesProcessor2;
[5208]279
[13402]280      subScopesProcessor2.Operators.Add(new EmptyOperator());
281      subScopesProcessor2.Operators.Add(uniformSubScopesProcessor4);
282      subScopesProcessor2.Successor = mergingReducer1;
283
284      mergingReducer1.Successor = null;
285
[5208]286      uniformSubScopesProcessor4.Parallel.Value = true;
[13402]287      uniformSubScopesProcessor4.Operator = evaluator2;
288      uniformSubScopesProcessor4.Successor = subScopesCounter2;
[5208]289
[3611]290      evaluator2.Name = "Evaluator (placeholder)";
291      evaluator2.OperatorParameter.ActualName = EvaluatorParameter.Name;
[13402]292      evaluator2.Successor = null;
[3611]293
[5356]294      subScopesCounter2.Name = "Increment EvaluatedSolutions";
295      subScopesCounter2.ValueParameter.ActualName = EvaluatedSolutionsParameter.Name;
[13402]296      subScopesCounter2.Successor = null;
[3611]297
[13402]298      uniformSubScopesProcessor5.Operator = crossover2;
299      uniformSubScopesProcessor5.Successor = uniformSubScopesProcessor6;
300
[5208]301      crossover2.Name = "Crossover (placeholder)";
302      crossover2.OperatorParameter.ActualName = CrossoverParameter.Name;
[13402]303      crossover2.Successor = mutationBranch2;
[5208]304
[3611]305      mutationBranch2.ProbabilityParameter.ActualName = MutationProbabilityParameter.Name;
306      mutationBranch2.RandomParameter.ActualName = RandomParameter.Name;
[13402]307      mutationBranch2.FirstBranch = mutator2;
308      mutationBranch2.SecondBranch = null;
309      mutationBranch2.Successor = null;
[3611]310
311      mutator2.Name = "Mutator (placeholder)";
312      mutator2.OperatorParameter.ActualName = MutatorParameter.Name;
[13402]313      mutator2.Successor = null;
[3611]314
[5208]315      uniformSubScopesProcessor6.Parallel.Value = true;
[13402]316      uniformSubScopesProcessor6.Operator = evaluator3;
317      uniformSubScopesProcessor6.Successor = subScopesCounter3;
[5208]318
[3611]319      evaluator3.Name = "Evaluator (placeholder)";
320      evaluator3.OperatorParameter.ActualName = EvaluatorParameter.Name;
[13402]321      evaluator3.Successor = qualityComparer2;
[3611]322
[5356]323      subScopesCounter3.Name = "Increment EvaluatedSolutions";
324      subScopesCounter3.ValueParameter.ActualName = EvaluatedSolutionsParameter.Name;
[3611]325
326      qualityComparer2.ComparisonFactorParameter.ActualName = ComparisonFactorParameter.Name;
327      qualityComparer2.LeftSideParameter.ActualName = QualityParameter.Name;
328      qualityComparer2.MaximizationParameter.ActualName = MaximizationParameter.Name;
329      qualityComparer2.RightSideParameter.ActualName = QualityParameter.Name;
330      qualityComparer2.ResultParameter.ActualName = "SuccessfulOffspring";
[13402]331      qualityComparer2.Successor = ageCalculator2;
[3611]332
[13402]333      ageCalculator2.ParameterToReduce.ActualName = AgeParameter.Name;
334      ageCalculator2.TargetParameter.ActualName = AgeParameter.Name;
335      ageCalculator2.WeightParameter.ActualName = AgeInheritanceParameter.Name;
336      ageCalculator2.Successor = subScopesRemover2;
337
[5208]338      subScopesRemover2.RemoveAllSubScopes = true;
[13402]339      subScopesRemover2.Successor = null;
[3611]340
[13402]341      subScopesCounter3.Successor = null;
342
[3611]343      offspringSelector.CurrentSuccessRatioParameter.ActualName = CurrentSuccessRatioParameter.Name;
344      offspringSelector.MaximumSelectionPressureParameter.ActualName = MaximumSelectionPressureParameter.Name;
345      offspringSelector.SelectionPressureParameter.ActualName = SelectionPressureParameter.Name;
346      offspringSelector.SuccessRatioParameter.ActualName = SuccessRatioParameter.Name;
[3740]347      offspringSelector.OffspringPopulationParameter.ActualName = "OffspringPopulation";
348      offspringSelector.OffspringPopulationWinnersParameter.ActualName = "OffspringPopulationWinners";
349      offspringSelector.SuccessfulOffspringParameter.ActualName = "SuccessfulOffspring";
[10643]350      offspringSelector.FillPopulationWithParentsParameter.ActualName = FillPopulationWithParentsParameter.Name;
[13402]351      offspringSelector.PopulationSizeParameter.ActualName = PopulationSizeParameter.Name;
352      offspringSelector.OffspringCreator = selector;
353      offspringSelector.Successor = subScopesProcessor3;
[3611]354
[13402]355      subScopesProcessor3.Operators.Add(bestSelector);
356      subScopesProcessor3.Operators.Add(worstSelector);
357      subScopesProcessor3.Successor = mergingReducer2;
358
[3713]359      bestSelector.CopySelected = new BoolValue(false);
360      bestSelector.MaximizationParameter.ActualName = MaximizationParameter.Name;
361      bestSelector.NumberOfSelectedSubScopesParameter.ActualName = ElitesParameter.Name;
362      bestSelector.QualityParameter.ActualName = QualityParameter.Name;
[13402]363      bestSelector.Successor = rightReducer;
[3699]364
[13402]365      rightReducer.Successor = reevaluateElitesBranch;
[9569]366
367      reevaluateElitesBranch.ConditionParameter.ActualName = "ReevaluateElites";
368      reevaluateElitesBranch.Name = "Reevaluate elites ?";
[13402]369      reevaluateElitesBranch.TrueBranch = uniformSubScopesProcessor7;
370      reevaluateElitesBranch.FalseBranch = null;
371      reevaluateElitesBranch.Successor = null;
[9569]372
373      uniformSubScopesProcessor7.Parallel.Value = true;
[13402]374      uniformSubScopesProcessor7.Operator = evaluator4;
375      uniformSubScopesProcessor7.Successor = subScopesCounter4;
[9569]376
377      evaluator4.Name = "Evaluator (placeholder)";
378      evaluator4.OperatorParameter.ActualName = EvaluatorParameter.Name;
379
380      subScopesCounter4.Name = "Increment EvaluatedSolutions";
381      subScopesCounter4.ValueParameter.ActualName = EvaluatedSolutionsParameter.Name;
[13402]382      subScopesCounter4.Successor = null;
[3611]383
[13402]384      worstSelector.CopySelected = new BoolValue(false);
385      worstSelector.MaximizationParameter.ActualName = MaximizationParameter.Name;
386      worstSelector.NumberOfSelectedSubScopesParameter.ActualName = ElitesParameter.Name;
387      worstSelector.QualityParameter.ActualName = QualityParameter.Name;
[3713]388      worstSelector.Successor = leftReducer;
[13402]389
[3699]390      leftReducer.Successor = null;
[13402]391
392      mergingReducer2.Successor = incrementAgeProcessor;
393
394      incrementAgeProcessor.Operator = ageIncrementor;
395      incrementAgeProcessor.Successor = null;
396
397      ageIncrementor.ValueParameter.ActualName = AgeParameter.Name;
398      ageIncrementor.IncrementParameter.Value = null;
399      ageIncrementor.IncrementParameter.ActualName = AgeIncrementParameter.Name;
400      ageIncrementor.Successor = null;
[3611]401    }
[3715]402
403    public override IOperation Apply() {
404      if (CrossoverParameter.ActualValue == null)
405        return null;
406      return base.Apply();
407    }
[3611]408  }
409}
Note: See TracBrowser for help on using the repository browser.