Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Covering/CoveringOperator.cs
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Covering/CoveringOperator.cs	(revision 9090)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Covering/CoveringOperator.cs	(revision 9105)
@@ -53,4 +53,7 @@
       get { return (ILookupParameter<IRandom>)Parameters["Random"]; }
     }
+    public ILookupParameter<IntValue> CurrentPopulationSizeParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["CurrentPopulationSize"]; }
+    }
     public IValueLookupParameter<BoolValue> ParallelParameter {
       get { return (IValueLookupParameter<BoolValue>)Parameters["Parallel"]; }
@@ -83,4 +86,5 @@
       Parameters.Add(new ValueLookupParameter<BoolValue>("Parallel", "True if the operator should be applied in parallel on all sub-scopes, otherwise false.", new BoolValue(true)));
       Parameters.Add(new ScopeParameter("CurrentScope", "The current scope to which the new solutions are added as sub-scopes."));
+      Parameters.Add(new LookupParameter<IntValue>("CurrentPopulationSize"));
     }
 
@@ -97,4 +101,6 @@
         throw new ArgumentException("More classifiers with unique actions shall be created than unique actions are available.");
       }
+
+      CurrentPopulationSizeParameter.ActualValue.Value += count;
 
       int current = CurrentScope.SubScopes.Count;
Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Covering/DoDeletionBeforeCovering.cs
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Covering/DoDeletionBeforeCovering.cs	(revision 9105)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Covering/DoDeletionBeforeCovering.cs	(revision 9105)
@@ -0,0 +1,87 @@
+#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Data;
+using HeuristicLab.Operators;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.ConditionActionEncoding {
+  [Item("DoDeletionBeforeCoveringOperator", "Description missing")]
+  [StorableClass]
+  public class DoDeletionBeforeCoveringOperator : SingleSuccessorOperator {
+
+    #region Parameter Properties
+    public ILookupParameter<IntValue> MinimalNumberOfUniqueActionsParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["MinimalNumberOfUniqueActions"]; }
+    }
+    public ILookupParameter<IntValue> NumberOfUniqueActionsParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["NumberOfUniqueActions"]; }
+    }
+    public ILookupParameter<IntValue> CurrentPopulationSizeParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["CurrentPopulationSize"]; }
+    }
+    public ILookupParameter<IntValue> PopulationSizeParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["PopulationSize"]; }
+    }
+    public IValueLookupParameter<BoolValue> DoDeletionParameter {
+      get { return (IValueLookupParameter<BoolValue>)Parameters["DoDeletion"]; }
+    }
+    public IValueLookupParameter<IntValue> NumberToDeleteParameter {
+      get { return (IValueLookupParameter<IntValue>)Parameters["NumberToDelete"]; }
+    }
+    #endregion
+
+    [StorableConstructor]
+    protected DoDeletionBeforeCoveringOperator(bool deserializing) : base(deserializing) { }
+    protected DoDeletionBeforeCoveringOperator(DoDeletionBeforeCoveringOperator original, Cloner cloner)
+      : base(original, cloner) {
+    }
+    public DoDeletionBeforeCoveringOperator()
+      : base() {
+      Parameters.Add(new LookupParameter<IntValue>("MinimalNumberOfUniqueActions"));
+      Parameters.Add(new LookupParameter<IntValue>("NumberOfUniqueActions"));
+      Parameters.Add(new LookupParameter<IntValue>("CurrentPopulationSize"));
+      Parameters.Add(new LookupParameter<IntValue>("PopulationSize"));
+      Parameters.Add(new ValueLookupParameter<BoolValue>("DoDeletion"));
+      Parameters.Add(new ValueLookupParameter<IntValue>("NumberToDelete"));
+    }
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new DoDeletionBeforeCoveringOperator(this, cloner);
+    }
+
+    public override IOperation Apply() {
+      int populationAfterCovering = MinimalNumberOfUniqueActionsParameter.ActualValue.Value
+                                    - NumberOfUniqueActionsParameter.ActualValue.Value
+                                    + CurrentPopulationSizeParameter.ActualValue.Value;
+      BoolValue doDeletion = new BoolValue(populationAfterCovering > PopulationSizeParameter.ActualValue.Value);
+      if (doDeletion.Value) {
+        NumberToDeleteParameter.ActualValue = new IntValue(populationAfterCovering - PopulationSizeParameter.ActualValue.Value);
+      } else {
+        NumberToDeleteParameter.ActualValue = new IntValue(0);
+      }
+      DoDeletionParameter.ActualValue = doDeletion;
+      return base.Apply();
+    }
+  }
+}
Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Covering/ICovering.cs
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Covering/ICovering.cs	(revision 9090)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Covering/ICovering.cs	(revision 9105)
@@ -33,4 +33,6 @@
     IValueLookupParameter<ICoveringSolutionCreator> SolutionCreatorParameter { get; }
     IValueLookupParameter<BoolValue> ParallelParameter { get; }
+
+    ILookupParameter<IntValue> CurrentPopulationSizeParameter { get; }
   }
 }
Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Deletion/CalculateNumberOfDeletionsOperator.cs
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Deletion/CalculateNumberOfDeletionsOperator.cs	(revision 9105)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Deletion/CalculateNumberOfDeletionsOperator.cs	(revision 9105)
@@ -0,0 +1,71 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Data;
+using HeuristicLab.Operators;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.ConditionActionEncoding {
+  [Item("CalculateNumberOfDeletionsOperator", "Description missing")]
+  [StorableClass]
+  public class CalculateNumberOfDeletionsOperator : SingleSuccessorOperator {
+
+    #region Parameter Properties
+    public ILookupParameter<IntValue> PopulationSizeParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["PopulationSize"]; }
+    }
+    public ILookupParameter<IntValue> CurrentPopulationSizeParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["CurrentPopulationSize"]; }
+    }
+    public IValueLookupParameter<IntValue> NumberOfDeletionsParameter {
+      get { return (IValueLookupParameter<IntValue>)Parameters["NumberOfDeletions"]; }
+    }
+    #endregion
+
+    [StorableConstructor]
+    protected CalculateNumberOfDeletionsOperator(bool deserializing) : base(deserializing) { }
+    protected CalculateNumberOfDeletionsOperator(CalculateNumberOfDeletionsOperator original, Cloner cloner)
+      : base(original, cloner) {
+    }
+    public CalculateNumberOfDeletionsOperator()
+      : base() {
+      Parameters.Add(new LookupParameter<IntValue>("CurrentPopulationSize"));
+      Parameters.Add(new LookupParameter<IntValue>("PopulationSize"));
+      Parameters.Add(new ValueLookupParameter<IntValue>("NumberOfDeletions"));
+    }
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new CalculateNumberOfDeletionsOperator(this, cloner);
+    }
+
+    public override IOperation Apply() {
+      int numberOfDeletions = CurrentPopulationSizeParameter.ActualValue.Value - PopulationSizeParameter.ActualValue.Value;
+      if (numberOfDeletions > 0) {
+        NumberOfDeletionsParameter.ActualValue = new IntValue(numberOfDeletions);
+      } else {
+        NumberOfDeletionsParameter.ActualValue = new IntValue(0);
+      }
+      return base.Apply();
+    }
+  }
+}
Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Deletion/XCSDeletionOperator.cs
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Deletion/XCSDeletionOperator.cs	(revision 9105)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Deletion/XCSDeletionOperator.cs	(revision 9105)
@@ -0,0 +1,161 @@
+#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System;
+using System.Linq;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Data;
+using HeuristicLab.Operators;
+using HeuristicLab.Optimization;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.ConditionActionEncoding {
+  [Item("XCSDeletionOperator", "Description missing")]
+  [StorableClass]
+  public class XCSDeletionOperator : SingleSuccessorOperator, IStochasticOperator {
+
+    #region Parameter Properties
+    public ILookupParameter<IntValue> NumberToDeleteParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["NumberToDelete"]; }
+    }
+    public ILookupParameter<ItemArray<IntValue>> NumerositiesParameter {
+      get { return (ILookupParameter<ItemArray<IntValue>>)Parameters["Numerosities"]; }
+    }
+    public ILookupParameter<ItemArray<DoubleValue>> AverageActionSetSizesParameter {
+      get { return (ILookupParameter<ItemArray<DoubleValue>>)Parameters["AverageActionSetSizes"]; }
+    }
+    public ILookupParameter<ItemArray<DoubleValue>> FitnessesParameter {
+      get { return (ILookupParameter<ItemArray<DoubleValue>>)Parameters["Fitnesses"]; }
+    }
+    public ILookupParameter<ItemArray<IntValue>> ExperiencesParameter {
+      get { return (ILookupParameter<ItemArray<IntValue>>)Parameters["Experiences"]; }
+    }
+    public ILookupParameter<IntValue> ThetaDeletionParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["ThetaDeletion"]; }
+    }
+    public ILookupParameter<PercentValue> DeltaParameter {
+      get { return (ILookupParameter<PercentValue>)Parameters["Delta"]; }
+    }
+    public ILookupParameter<IRandom> RandomParameter {
+      get { return (ILookupParameter<IRandom>)Parameters["Random"]; }
+    }
+    public ILookupParameter<IntValue> CurrentPopulationSizeParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["CurrentPopulationSize"]; }
+    }
+    protected ScopeParameter CurrentScopeParameter {
+      get { return (ScopeParameter)Parameters["CurrentScope"]; }
+    }
+    public IScope CurrentScope {
+      get { return CurrentScopeParameter.ActualValue; }
+    }
+    public string HasToBeDeletedVariableName { get { return "HasToBeDeleted"; } }
+    #endregion
+
+    #region Parameter Properties
+    private double Delta { get { return DeltaParameter.ActualValue.Value; } }
+    private int ThetaDeletion { get { return ThetaDeletionParameter.ActualValue.Value; } }
+    #endregion
+
+    [StorableConstructor]
+    protected XCSDeletionOperator(bool deserializing) : base(deserializing) { }
+    protected XCSDeletionOperator(XCSDeletionOperator original, Cloner cloner)
+      : base(original, cloner) {
+    }
+    public XCSDeletionOperator()
+      : base() {
+      Parameters.Add(new LookupParameter<IntValue>("NumberToDelete"));
+      Parameters.Add(new ScopeTreeLookupParameter<IntValue>("Numerosities"));
+      Parameters.Add(new ScopeTreeLookupParameter<DoubleValue>("AverageActionSetSizes"));
+      Parameters.Add(new ScopeTreeLookupParameter<DoubleValue>("Fitnesses"));
+      Parameters.Add(new ScopeTreeLookupParameter<IntValue>("Experiences"));
+      Parameters.Add(new LookupParameter<IntValue>("ThetaDeletion"));
+      Parameters.Add(new LookupParameter<PercentValue>("Delta"));
+      Parameters.Add(new LookupParameter<IRandom>("Random"));
+      Parameters.Add(new ScopeParameter("CurrentScope"));
+      Parameters.Add(new LookupParameter<IntValue>("CurrentPopulationSize"));
+    }
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new XCSDeletionOperator(this, cloner);
+    }
+
+    public override IOperation Apply() {
+      var fitnesses = FitnessesParameter.ActualValue;
+      var numerosities = NumerositiesParameter.ActualValue;
+      var experiences = ExperiencesParameter.ActualValue;
+      var averageActionSetSizes = AverageActionSetSizesParameter.ActualValue;
+      var subscopes = CurrentScope.SubScopes;
+      double fitnessSum = fitnesses.Select(x => x.Value).Sum();
+      double numerositySum = numerosities.Select(x => x.Value).Sum();
+
+      if (fitnesses.Length != numerosities.Length && fitnesses.Length != experiences.Length && fitnesses.Length != subscopes.Count) {
+        throw new ArgumentException("Different number of fitness, numerosity and experience values.");
+      }
+
+      for (int cl = 0; cl < fitnesses.Length; cl++) {
+        if (subscopes[cl].Variables.ContainsKey(HasToBeDeletedVariableName)) {
+          ((BoolValue)subscopes[cl].Variables[HasToBeDeletedVariableName].Value).Value = false;
+        } else {
+          subscopes[cl].Variables.Add(new Variable(HasToBeDeletedVariableName, new BoolValue(false)));
+        }
+      }
+
+      for (int i = 0; i < NumberToDeleteParameter.ActualValue.Value; i++) {
+        double voteSum = 0;
+        double averageFitnessInPopulation = fitnessSum / numerositySum;
+        for (int cl = 0; cl < fitnesses.Length; cl++) {
+          if (numerosities[cl].Value > 0) {
+            voteSum += DeletionVote(averageFitnessInPopulation, averageActionSetSizes[cl].Value, numerosities[cl].Value, fitnesses[cl].Value, experiences[cl].Value);
+          }
+        }
+        double choicePoint = RandomParameter.ActualValue.NextDouble() * voteSum;
+        voteSum = 0;
+        for (int cl = 0; cl < fitnesses.Length; cl++) {
+          if (numerosities[cl].Value > 0) {
+            voteSum += DeletionVote(averageFitnessInPopulation, averageActionSetSizes[cl].Value, numerosities[cl].Value, fitnesses[cl].Value, experiences[cl].Value);
+            if (voteSum > choicePoint) {
+              if (numerosities[cl].Value <= 1) {
+                ((BoolValue)subscopes[cl].Variables[HasToBeDeletedVariableName].Value).Value = true;
+                fitnessSum -= fitnesses[cl].Value;
+              }
+              numerosities[cl].Value--;
+              numerositySum--;
+              break;
+            }
+          }
+        }
+      }
+
+      CurrentPopulationSizeParameter.ActualValue.Value -= NumberToDeleteParameter.ActualValue.Value;
+
+      return base.Apply();
+    }
+
+    private double DeletionVote(double averageFitnessInPopulation, double ass, int num, double f, int exp) {
+      double vote = ass * num;
+      if (exp > ThetaDeletion && (f / num) < Delta * averageFitnessInPopulation) {
+        vote *= averageFitnessInPopulation / (f / num);
+      }
+      return vote;
+    }
+  }
+}
Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/GA/XCSAfterCrossoverOperator.cs
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/GA/XCSAfterCrossoverOperator.cs	(revision 9105)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/GA/XCSAfterCrossoverOperator.cs	(revision 9105)
@@ -0,0 +1,113 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Linq;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Data;
+using HeuristicLab.Operators;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.ConditionActionEncoding {
+  [Item("XCSAfterCrossoverOperator", "Description missing")]
+  [StorableClass]
+  public class XCSAfterCrossoverOperator : SingleSuccessorOperator {
+
+    #region Parameter Properties
+    public IValueLookupParameter<IntValue> NumerosityParameter {
+      get { return (IValueLookupParameter<IntValue>)Parameters["Numerosity"]; }
+    }
+    public IValueLookupParameter<IntValue> ExperienceParameter {
+      get { return (IValueLookupParameter<IntValue>)Parameters["Experience"]; }
+    }
+    public IValueLookupParameter<IntValue> TimestampParameter {
+      get { return (IValueLookupParameter<IntValue>)Parameters["Timestamp"]; }
+    }
+    public IValueLookupParameter<DoubleValue> PredictionParameter {
+      get { return (IValueLookupParameter<DoubleValue>)Parameters["Prediction"]; }
+    }
+    public IValueLookupParameter<DoubleValue> AverageActionSetSizeParameter {
+      get { return (IValueLookupParameter<DoubleValue>)Parameters["AverageActionSetSize"]; }
+    }
+    public IValueLookupParameter<DoubleValue> ErrorParameter {
+      get { return (IValueLookupParameter<DoubleValue>)Parameters["Error"]; }
+    }
+    public IValueLookupParameter<DoubleValue> FitnessParameter {
+      get { return (IValueLookupParameter<DoubleValue>)Parameters["Fitness"]; }
+    }
+    public ILookupParameter<IntValue> CurrentIterationParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["CurrentIteration"]; }
+    }
+    public ILookupParameter<ItemArray<DoubleValue>> ParentAverageActionSetSizeParameter {
+      get { return (ILookupParameter<ItemArray<DoubleValue>>)Parameters["ParentAverageActionSetSize"]; }
+    }
+    public ILookupParameter<ItemArray<DoubleValue>> ParentPredictionParameter {
+      get { return (ILookupParameter<ItemArray<DoubleValue>>)Parameters["ParentPrediction"]; }
+    }
+    public ILookupParameter<ItemArray<DoubleValue>> ParentErrorParameter {
+      get { return (ILookupParameter<ItemArray<DoubleValue>>)Parameters["ParentError"]; }
+    }
+    public ILookupParameter<ItemArray<DoubleValue>> ParentFitnessParameter {
+      get { return (ILookupParameter<ItemArray<DoubleValue>>)Parameters["ParentFitness"]; }
+    }
+    #endregion
+
+    [StorableConstructor]
+    protected XCSAfterCrossoverOperator(bool deserializing) : base(deserializing) { }
+    protected XCSAfterCrossoverOperator(XCSAfterCrossoverOperator original, Cloner cloner)
+      : base(original, cloner) {
+    }
+    public XCSAfterCrossoverOperator()
+      : base() {
+      Parameters.Add(new ValueLookupParameter<IntValue>("Numerosity"));
+      Parameters.Add(new ValueLookupParameter<IntValue>("Experience"));
+      Parameters.Add(new ValueLookupParameter<IntValue>("Timestamp"));
+      Parameters.Add(new ValueLookupParameter<DoubleValue>("AverageActionSetSize"));
+      Parameters.Add(new ValueLookupParameter<DoubleValue>("Prediction"));
+      Parameters.Add(new ValueLookupParameter<DoubleValue>("Error"));
+      Parameters.Add(new ValueLookupParameter<DoubleValue>("Fitness"));
+      Parameters.Add(new LookupParameter<IntValue>("CurrentIteration"));
+      Parameters.Add(new ScopeTreeLookupParameter<DoubleValue>("ParentAverageActionSetSize"));
+      Parameters.Add(new ScopeTreeLookupParameter<DoubleValue>("ParentPrediction"));
+      Parameters.Add(new ScopeTreeLookupParameter<DoubleValue>("ParentError"));
+      Parameters.Add(new ScopeTreeLookupParameter<DoubleValue>("ParentFitness"));
+    }
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new XCSAfterCrossoverOperator(this, cloner);
+    }
+
+    public override IOperation Apply() {
+      NumerosityParameter.ActualValue = new IntValue(1);
+      ExperienceParameter.ActualValue = new IntValue(0);
+      TimestampParameter.ActualValue = new IntValue(CurrentIterationParameter.ActualValue.Value);
+      var parentAverageActionSetSize = ParentAverageActionSetSizeParameter.ActualValue;
+      var parentPrecision = ParentPredictionParameter.ActualValue;
+      var parentPrecisionError = ParentErrorParameter.ActualValue;
+      var parentFitness = ParentFitnessParameter.ActualValue;
+      AverageActionSetSizeParameter.ActualValue = new DoubleValue(parentAverageActionSetSize.Select(x => x.Value).Average());
+      PredictionParameter.ActualValue = new DoubleValue(parentPrecision.Select(x => x.Value).Average());
+      ErrorParameter.ActualValue = new DoubleValue(0.25 * parentPrecisionError.Select(x => x.Value).Average());
+      FitnessParameter.ActualValue = new DoubleValue(0.1 * parentFitness.Select(x => x.Value).Average());
+      return base.Apply();
+    }
+  }
+}
Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/GA/XCSCheckIfGAShouldBeApplied.cs
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/GA/XCSCheckIfGAShouldBeApplied.cs	(revision 9105)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/GA/XCSCheckIfGAShouldBeApplied.cs	(revision 9105)
@@ -0,0 +1,93 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Data;
+using HeuristicLab.Operators;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.ConditionActionEncoding {
+  [Item("CheckIfGAShouldBeApplied", "Description missing")]
+  [StorableClass]
+  public class XCSCheckIfGAShouldBeApplied : SingleSuccessorOperator {
+
+    #region Parameter Properties
+    public ILookupParameter<IntValue> ThetaGAParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["ThetaGA"]; }
+    }
+    public ILookupParameter<IntValue> IterationParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["Iteration"]; }
+    }
+    public ILookupParameter<ItemArray<IntValue>> TimeStampsParameter {
+      get { return (ILookupParameter<ItemArray<IntValue>>)Parameters["TimeStamps"]; }
+    }
+    public ILookupParameter<ItemArray<IntValue>> NumerositiesParameter {
+      get { return (ILookupParameter<ItemArray<IntValue>>)Parameters["Numerosities"]; }
+    }
+    public IValueLookupParameter<BoolValue> RunGAParameter {
+      get { return (IValueLookupParameter<BoolValue>)Parameters["RunGA"]; }
+    }
+    #endregion
+
+    [StorableConstructor]
+    protected XCSCheckIfGAShouldBeApplied(bool deserializing) : base(deserializing) { }
+    protected XCSCheckIfGAShouldBeApplied(XCSCheckIfGAShouldBeApplied original, Cloner cloner)
+      : base(original, cloner) {
+    }
+    public XCSCheckIfGAShouldBeApplied()
+      : base() {
+      Parameters.Add(new LookupParameter<IntValue>("ThetaGA"));
+      Parameters.Add(new LookupParameter<IntValue>("Iteration"));
+      Parameters.Add(new ScopeTreeLookupParameter<IntValue>("TimeStamps"));
+      Parameters.Add(new ScopeTreeLookupParameter<IntValue>("Numerosities"));
+      Parameters.Add(new ValueLookupParameter<BoolValue>("RunGA"));
+    }
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new XCSCheckIfGAShouldBeApplied(this, cloner);
+    }
+
+    public override IOperation Apply() {
+      int numerositySum = 0;
+      int timestamNumerositySum = 0;
+
+      var timestamps = TimeStampsParameter.ActualValue;
+      var numerosities = NumerositiesParameter.ActualValue;
+      int actualtime = IterationParameter.ActualValue.Value;
+      int thetaGA = ThetaGAParameter.ActualValue.Value;
+
+      if (timestamps.Length != numerosities.Length) {
+        throw new ArgumentException("The number of timestamps and numerosities is not the same.");
+      }
+
+      for (int i = 0; i < numerosities.Length; i++) {
+        numerositySum += numerosities[i].Value;
+        timestamNumerositySum += timestamps[i].Value * numerosities[i].Value;
+      }
+
+      RunGAParameter.ActualValue = new BoolValue(actualtime - (timestamNumerositySum / numerositySum) > thetaGA);
+
+      return base.Apply();
+    }
+  }
+}
Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/HeuristicLab.Encodings.ConditionActionEncoding-3.3.csproj
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/HeuristicLab.Encodings.ConditionActionEncoding-3.3.csproj	(revision 9090)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/HeuristicLab.Encodings.ConditionActionEncoding-3.3.csproj	(revision 9105)
@@ -71,4 +71,5 @@
     <Reference Include="System" />
     <Reference Include="System.Core" />
+    <Reference Include="System.Drawing" />
     <Reference Include="System.Xml.Linq" />
     <Reference Include="System.Data.DataSetExtensions" />
@@ -83,17 +84,23 @@
     <Compile Include="ActionSelection\RandomActionSelector.cs" />
     <Compile Include="Covering\CoveringOperator.cs" />
+    <Compile Include="Covering\DoDeletionBeforeCovering.cs" />
     <Compile Include="Covering\ICovering.cs" />
     <Compile Include="Covering\ICoveringSolutionCreator.cs" />
+    <Compile Include="Deletion\CalculateNumberOfDeletionsOperator.cs" />
+    <Compile Include="Deletion\XCSDeletionOperator.cs" />
     <Compile Include="Evaluators\XCSEvaluator.cs" />
     <Compile Include="Evaluators\IConditionActionEvaluator.cs" />
     <Compile Include="Evaluators\IXCSEvaluator.cs" />
+    <Compile Include="GA\XCSAfterCrossoverOperator.cs" />
     <Compile Include="IClassifier.cs" />
     <Compile Include="Interfaces\IConditionActionProblem.cs" />
     <Compile Include="Interfaces\IConditionActionProblemData.cs" />
     <Compile Include="Operator\CalculateAccuracy.cs" />
+    <Compile Include="GA\XCSCheckIfGAShouldBeApplied.cs" />
     <Compile Include="Operator\CountNumberOfUniqueActions.cs" />
     <Compile Include="Operator\PredictionArrayCalculator.cs" />
     <Compile Include="Operator\MatchActionOperator.cs" />
     <Compile Include="Operator\MatchConditionOperator.cs" />
+    <Compile Include="Operator\SubScopeVariableCopier.cs" />
     <Compile Include="Operator\SumAccuracy.cs" />
     <Compile Include="Properties\AssemblyInfo.cs" />
@@ -104,4 +111,6 @@
     <Compile Include="Selectors\IMatchSelector.cs" />
     <Compile Include="Selectors\MatchSelector.cs" />
+    <Compile Include="Subsumption\ActionSetSubsumptionoperator.cs" />
+    <Compile Include="Subsumption\IActionSetSubsumption.cs" />
     <None Include="Properties\AssemblyInfo.cs.frame" />
   </ItemGroup>
@@ -112,4 +121,13 @@
   <ItemGroup />
   <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
+  <PropertyGroup>
+    <PreBuildEvent>set Path=%25Path%25;$(ProjectDir);$(SolutionDir)
+set ProjectDir=$(ProjectDir)
+set SolutionDir=$(SolutionDir)
+set Outdir=$(Outdir)
+
+call PreBuildEvent.cmd
+</PreBuildEvent>
+  </PropertyGroup>
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
        Other similar extension points exist, see Microsoft.Common.targets.
Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/IClassifier.cs
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/IClassifier.cs	(revision 9090)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/IClassifier.cs	(revision 9105)
@@ -35,4 +35,5 @@
     bool MatchCondition(IClassifier target);
     bool MatchAction(IClassifier target);
+    bool IsMoreGeneral(IClassifier target);
 
     //to use IMatching as key in a dictionary, Equals and GetHashCode have to be override. 
Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Interfaces/IConditionActionProblem.cs
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Interfaces/IConditionActionProblem.cs	(revision 9090)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Interfaces/IConditionActionProblem.cs	(revision 9105)
@@ -39,4 +39,7 @@
     IParameter CoveringSolutionCreatorParameter { get; }
 
+    IParameter ActionSetSubsumptionOperatorParameter { get; }
+    IActionSetSubsumption ActionSetSubsumptionOperator { get; }
+
     new IXCSEvaluator Evaluator { get; }
   }
Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Operator/SubScopeVariableCopier.cs
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Operator/SubScopeVariableCopier.cs	(revision 9105)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Operator/SubScopeVariableCopier.cs	(revision 9105)
@@ -0,0 +1,72 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Data;
+using HeuristicLab.Operators;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.ConditionActionEncoding {
+  [Item("SubScopeVariableCopier", "Description missing")]
+  [StorableClass]
+  public class SubScopeVariableCopier : SingleSuccessorOperator {
+
+    #region Parameter Properties
+    public IValueLookupParameter<IntValue> SubScopeIndexParameter {
+      get { return (IValueLookupParameter<IntValue>)Parameters["SubScopeIndex"]; }
+    }
+    private ScopeParameter CurrentScopeParameter {
+      get { return (ScopeParameter)Parameters["CurrentScope"]; }
+    }
+    public IScope CurrentScope {
+      get { return CurrentScopeParameter.ActualValue; }
+    }
+    #endregion
+
+    [StorableConstructor]
+    protected SubScopeVariableCopier(bool deserializing) : base(deserializing) { }
+    protected SubScopeVariableCopier(SubScopeVariableCopier original, Cloner cloner)
+      : base(original, cloner) {
+    }
+    public SubScopeVariableCopier()
+      : base() {
+      Parameters.Add(new ValueLookupParameter<IntValue>("SubScopeIndex"));
+      Parameters.Add(new ScopeParameter("CurrentScope"));
+    }
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new SubScopeVariableCopier(this, cloner);
+    }
+
+    public override IOperation Apply() {
+      IScope subscope = CurrentScope.SubScopes[SubScopeIndexParameter.ActualValue.Value];
+      foreach (var variable in subscope.Variables) {
+        if (CurrentScope.Variables.ContainsKey(variable.Name)) {
+          CurrentScope.Variables[variable.Name].Value = variable.Value;
+        } else {
+          CurrentScope.Variables.Add((Variable)variable.Clone());
+        }
+      }
+      return base.Apply();
+    }
+  }
+}
Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Subsumption/ActionSetSubsumptionoperator.cs
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Subsumption/ActionSetSubsumptionoperator.cs	(revision 9105)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Subsumption/ActionSetSubsumptionoperator.cs	(revision 9105)
@@ -0,0 +1,136 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Data;
+using HeuristicLab.Operators;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.ConditionActionEncoding {
+  [Item("ActionSetSubsumptionoperator", "Description missing")]
+  [StorableClass]
+  public class ActionSetSubsumptionoperator : SingleSuccessorOperator, IActionSetSubsumption {
+
+    #region Parameter Properties
+    public ILookupParameter<ItemArray<IClassifier>> ClassifiersParameter {
+      get { return (ILookupParameter<ItemArray<IClassifier>>)Parameters["Classifiers"]; }
+    }
+    public ILookupParameter<ItemArray<IntValue>> NumerositiesParameter {
+      get { return (ILookupParameter<ItemArray<IntValue>>)Parameters["Numerosities"]; }
+    }
+    public ILookupParameter<ItemArray<IntValue>> ExperiencesParameter {
+      get { return (ILookupParameter<ItemArray<IntValue>>)Parameters["Experiences"]; }
+    }
+    public ILookupParameter<ItemArray<DoubleValue>> ErrorsParameter {
+      get { return (ILookupParameter<ItemArray<DoubleValue>>)Parameters["Errors"]; }
+    }
+    public ILookupParameter<DoubleValue> ErrorZeroParameter {
+      get { return (ILookupParameter<DoubleValue>)Parameters["ErrorZero"]; }
+    }
+    public ILookupParameter<IntValue> ThetaSubsumptionParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["ThetaSubsumption"]; }
+    }
+    protected ScopeParameter CurrentScopeParameter {
+      get { return (ScopeParameter)Parameters["CurrentScope"]; }
+    }
+    public IScope CurrentScope {
+      get { return CurrentScopeParameter.ActualValue; }
+    }
+
+    public string HasBeenSubsumedParameterName {
+      get { return "HasBeenSubsumed"; }
+    }
+    #endregion
+
+    [StorableConstructor]
+    protected ActionSetSubsumptionoperator(bool deserializing) : base(deserializing) { }
+    protected ActionSetSubsumptionoperator(ActionSetSubsumptionoperator original, Cloner cloner)
+      : base(original, cloner) {
+    }
+    public ActionSetSubsumptionoperator()
+      : base() {
+      Parameters.Add(new ScopeTreeLookupParameter<IClassifier>("Classifiers"));
+      Parameters.Add(new ScopeTreeLookupParameter<IntValue>("Numerosities"));
+      Parameters.Add(new ScopeTreeLookupParameter<IntValue>("Experiences"));
+      Parameters.Add(new ScopeTreeLookupParameter<DoubleValue>("Errors"));
+      Parameters.Add(new LookupParameter<DoubleValue>("ErrorZero"));
+      Parameters.Add(new LookupParameter<IntValue>("ThetaSubsumption"));
+      Parameters.Add(new ScopeParameter("CurrentScope"));
+    }
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new ActionSetSubsumptionoperator(this, cloner);
+    }
+
+    public override IOperation Apply() {
+      var subscopes = CurrentScope.SubScopes;
+      var classifiers = ClassifiersParameter.ActualValue;
+      var numerosities = NumerositiesParameter.ActualValue;
+      var experiences = ExperiencesParameter.ActualValue;
+      var errors = ErrorsParameter.ActualValue;
+      if (subscopes.Count != classifiers.Length || subscopes.Count != numerosities.Length
+        || subscopes.Count != experiences.Length || subscopes.Count != errors.Length) {
+        throw new ArgumentException("The number of subscopes is not equal to the number of classifiers.");
+      }
+
+      int subsumptionClassifier = -1;
+
+      for (int i = 0; i < classifiers.Length; i++) {
+        if (CouldSubsume(experiences[i], errors[i])) {
+          if (subsumptionClassifier == -1 || classifiers[i].IsMoreGeneral(classifiers[subsumptionClassifier])) {
+            subsumptionClassifier = i;
+          }
+        }
+      }
+
+      if (subsumptionClassifier != -1) {
+        for (int i = 0; i < classifiers.Length; i++) {
+          if (classifiers[subsumptionClassifier].IsMoreGeneral(classifiers[i])) {
+            numerosities[subsumptionClassifier].Value += numerosities[i].Value;
+            AddVariableToScope(subscopes[i], new BoolValue(true));
+          } else {
+            AddVariableToScope(subscopes[i], new BoolValue(false));
+          }
+        }
+      } else {
+        for (int i = 0; i < classifiers.Length; i++) {
+          AddVariableToScope(subscopes[i], new BoolValue(false));
+        }
+      }
+
+      return base.Apply();
+    }
+
+    private void AddVariableToScope(IScope scope, BoolValue boolValue) {
+      if (scope.Variables.ContainsKey(HasBeenSubsumedParameterName)) {
+        scope.Variables[HasBeenSubsumedParameterName].Value = boolValue;
+      } else {
+        scope.Variables.Add(new Variable(HasBeenSubsumedParameterName, boolValue));
+      }
+    }
+
+    private bool CouldSubsume(IntValue exp, DoubleValue error) {
+      return exp.Value > ThetaSubsumptionParameter.ActualValue.Value && error.Value < ErrorZeroParameter.ActualValue.Value;
+    }
+  }
+}
Index: branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Subsumption/IActionSetSubsumption.cs
===================================================================
--- branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Subsumption/IActionSetSubsumption.cs	(revision 9105)
+++ branches/LearningClassifierSystems/HeuristicLab.Encodings.ConditionActionEncoding/3.3/Subsumption/IActionSetSubsumption.cs	(revision 9105)
@@ -0,0 +1,38 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Data;
+
+namespace HeuristicLab.Encodings.ConditionActionEncoding {
+  public interface IActionSetSubsumption : IOperator, IParameterizedNamedItem, INamedItem, IParameterizedItem, IItem, IContent, IDeepCloneable, ICloneable {
+    ILookupParameter<ItemArray<IClassifier>> ClassifiersParameter { get; }
+    ILookupParameter<ItemArray<IntValue>> NumerositiesParameter { get; }
+    ILookupParameter<ItemArray<IntValue>> ExperiencesParameter { get; }
+    ILookupParameter<ItemArray<DoubleValue>> ErrorsParameter { get; }
+    ILookupParameter<DoubleValue> ErrorZeroParameter { get; }
+    ILookupParameter<IntValue> ThetaSubsumptionParameter { get; }
+
+    string HasBeenSubsumedParameterName { get; }
+  }
+}
