Index: /branches/ParameterConfigurationEncoding/HeuristicLab.Encodings.ParameterConfigurationEncoding/3.3/Crossovers/ParameterConfigurationCrossover.cs
===================================================================
--- /branches/ParameterConfigurationEncoding/HeuristicLab.Encodings.ParameterConfigurationEncoding/3.3/Crossovers/ParameterConfigurationCrossover.cs	(revision 8664)
+++ /branches/ParameterConfigurationEncoding/HeuristicLab.Encodings.ParameterConfigurationEncoding/3.3/Crossovers/ParameterConfigurationCrossover.cs	(revision 8665)
@@ -21,4 +21,5 @@
 
 using System;
+using System.Linq;
 using HeuristicLab.Common;
 using HeuristicLab.Core;
@@ -118,22 +119,29 @@
 
     public static void Cross(IRandom random, IOptimizable configuration, IOptimizable other, IIntValueCrossover intValueCrossover, IDoubleValueCrossover doubleValueCrossover) {
-      var vc = configuration as RangeValueConfiguration;
-      var pc = configuration as IParameterConfiguration;
-      if (vc != null) {
-        var value = vc.ActualValue.Value;
-        var range = vc.RangeConstraint;
-
-        if (value is IntValue) {
+      if (configuration is ParameterizedValueConfiguration) {
+        var configVc = (ParameterizedValueConfiguration)configuration;
+        var otherVc = (ParameterizedValueConfiguration)other;
+        for (int i = 0; i < configVc.ParameterConfigurations.Count; i++)
+          Cross(random, configVc.ParameterConfigurations.ElementAt(i), otherVc.ParameterConfigurations.ElementAt(i), intValueCrossover, doubleValueCrossover);
+      } else if (configuration is ParameterConfiguration) {
+        var configPc = (IParameterConfiguration)configuration;
+        if (configPc.Optimize) {
+          var otherPc = (IParameterConfiguration)other;
+          for (int i = 0; i < configPc.ValueConfigurations.Count; i++)
+            if (configPc.ValueConfigurations.ItemChecked(configPc.ValueConfigurations[i]))
+              if (configPc.ValueConfigurations[i].Optimize) Cross(random, configPc.ValueConfigurations[i], otherPc.ValueConfigurations[i], intValueCrossover, doubleValueCrossover);
+          if (random.NextDouble() > 0.5) configPc.ActualValueConfigurationIndex = otherPc.ActualValueConfigurationIndex;
+          configPc.ActualValue = configPc.ValueConfigurations[configPc.ActualValueConfigurationIndex].ActualValue;
+        }
+      } else if (configuration is RangeValueConfiguration) {
+        var configVc = (RangeValueConfiguration)configuration;
+        var value = configVc.ActualValue.Value;
+        var range = configVc.RangeConstraint;
+        if (value is IntValue)
           intValueCrossover.Apply(random, (IntValue)value, (IntValue)other.ActualValue.Value, (IntValueRange)range);
-        } else if (value is PercentValue) {
+        else if (value is PercentValue)
           doubleValueCrossover.Apply(random, (PercentValue)value, (DoubleValue)other.ActualValue.Value, ((PercentValueRange)range).AsDoubleValueRange());
-        } else if (value is DoubleValue) {
+        else if (value is DoubleValue)
           doubleValueCrossover.Apply(random, (DoubleValue)value, (DoubleValue)other.ActualValue.Value, (DoubleValueRange)range);
-        }
-      } else if (pc != null) {
-        if (random.NextDouble() > 0.5) {
-          pc.ActualValueConfigurationIndex = ((ParameterConfiguration)other).ActualValueConfigurationIndex;
-        }
-        pc.ActualValue = pc.ValueConfigurations[pc.ActualValueConfigurationIndex].ActualValue;
       }
     }
Index: /branches/ParameterConfigurationEncoding/HeuristicLab.Encodings.ParameterConfigurationEncoding/3.3/Manipulators/ParameterConfigurationManipulator.cs
===================================================================
--- /branches/ParameterConfigurationEncoding/HeuristicLab.Encodings.ParameterConfigurationEncoding/3.3/Manipulators/ParameterConfigurationManipulator.cs	(revision 8664)
+++ /branches/ParameterConfigurationEncoding/HeuristicLab.Encodings.ParameterConfigurationEncoding/3.3/Manipulators/ParameterConfigurationManipulator.cs	(revision 8665)
@@ -77,22 +77,28 @@
 
     public static void Mutate(IRandom random, IOptimizable configuration, IIntValueManipulator intValueManipulator, IDoubleValueManipulator doubleValueManipulator) {
-      var vc = configuration as RangeValueConfiguration;
-      var pc = configuration as IParameterConfiguration;
-
-      if (vc != null) {
-        var value = vc.ActualValue.Value;
-        var range = vc.RangeConstraint;
-        if (value is IntValue) {
+      if (configuration is ParameterizedValueConfiguration) {
+        var configVc = (ParameterizedValueConfiguration)configuration;
+        for (int i = 0; i < configVc.ParameterConfigurations.Count; i++)
+          Mutate(random, configVc.ParameterConfigurations.ElementAt(i), intValueManipulator, doubleValueManipulator);
+      } else if (configuration is ParameterConfiguration) {
+        var configPc = (IParameterConfiguration)configuration;
+        if (configPc.Optimize) {
+          foreach (var vc in configPc.ValueConfigurations)
+            if (configPc.ValueConfigurations.ItemChecked(vc))
+              if (vc.Optimize) Mutate(random, vc, intValueManipulator, doubleValueManipulator);
+          do configPc.ActualValueConfigurationIndex = random.Next(configPc.ValueConfigurations.Count);
+          while (!configPc.ValueConfigurations.ItemChecked(configPc.ValueConfigurations[configPc.ActualValueConfigurationIndex]));
+          configPc.ActualValue = configPc.ValueConfigurations[configPc.ActualValueConfigurationIndex].ActualValue;
+        }
+      } else if (configuration is RangeValueConfiguration) {
+        var configVc = (RangeValueConfiguration)configuration;
+        var value = configVc.ActualValue.Value;
+        var range = configVc.RangeConstraint;
+        if (value is IntValue)
           intValueManipulator.Apply(random, (IntValue)value, (IntValueRange)range);
-        } else if (value is PercentValue) {
+        else if (value is PercentValue)
           doubleValueManipulator.Apply(random, (PercentValue)value, ((PercentValueRange)range).AsDoubleValueRange());
-        } else if (value is DoubleValue) {
+        else if (value is DoubleValue)
           doubleValueManipulator.Apply(random, (DoubleValue)value, (DoubleValueRange)range);
-        }
-      } else if (pc != null) {
-        do {
-          pc.ActualValueConfigurationIndex = random.Next(pc.ValueConfigurations.Count());
-        } while (!pc.ValueConfigurations.ItemChecked(pc.ValueConfigurations[pc.ActualValueConfigurationIndex]));
-        pc.ActualValue = pc.ValueConfigurations[pc.ActualValueConfigurationIndex].ActualValue;
       }
     }
