Index: branches/DataAnalysis.IslandAlgorithms/DataAnalysis.IslandAlgorithms.sln
===================================================================
--- branches/DataAnalysis.IslandAlgorithms/DataAnalysis.IslandAlgorithms.sln	(revision 9066)
+++ branches/DataAnalysis.IslandAlgorithms/DataAnalysis.IslandAlgorithms.sln	(revision 9067)
@@ -10,14 +10,36 @@
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Algorithms.DataAnalysis.Symbolic", "HeuristicLab.Algorithms.DataAnalysis.Symbolic\3.3\HeuristicLab.Algorithms.DataAnalysis.Symbolic.csproj", "{F0D5AF15-76A8-4023-AB77-7B138D579860}"
 EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Algorithms.GeneticAlgorithm-3.3", "HeuristicLab.Algorithms.GeneticAlgorithm\3.3\HeuristicLab.Algorithms.GeneticAlgorithm-3.3.csproj", "{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}"
+EndProject
 Global
 	GlobalSection(SolutionConfigurationPlatforms) = preSolution
 		Debug|Any CPU = Debug|Any CPU
+		Debug|x64 = Debug|x64
+		Debug|x86 = Debug|x86
 		Release|Any CPU = Release|Any CPU
+		Release|x64 = Release|x64
+		Release|x86 = Release|x86
 	EndGlobalSection
 	GlobalSection(ProjectConfigurationPlatforms) = postSolution
 		{F0D5AF15-76A8-4023-AB77-7B138D579860}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{F0D5AF15-76A8-4023-AB77-7B138D579860}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{F0D5AF15-76A8-4023-AB77-7B138D579860}.Debug|x64.ActiveCfg = Debug|Any CPU
+		{F0D5AF15-76A8-4023-AB77-7B138D579860}.Debug|x86.ActiveCfg = Debug|Any CPU
 		{F0D5AF15-76A8-4023-AB77-7B138D579860}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{F0D5AF15-76A8-4023-AB77-7B138D579860}.Release|Any CPU.Build.0 = Release|Any CPU
+		{F0D5AF15-76A8-4023-AB77-7B138D579860}.Release|x64.ActiveCfg = Release|Any CPU
+		{F0D5AF15-76A8-4023-AB77-7B138D579860}.Release|x86.ActiveCfg = Release|Any CPU
+		{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+		{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}.Debug|x64.ActiveCfg = Debug|x64
+		{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}.Debug|x64.Build.0 = Debug|x64
+		{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}.Debug|x86.ActiveCfg = Debug|x86
+		{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}.Debug|x86.Build.0 = Debug|x86
+		{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}.Release|Any CPU.ActiveCfg = Release|Any CPU
+		{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}.Release|Any CPU.Build.0 = Release|Any CPU
+		{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}.Release|x64.ActiveCfg = Release|x64
+		{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}.Release|x64.Build.0 = Release|x64
+		{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}.Release|x86.ActiveCfg = Release|x86
+		{A51DA44F-CB35-4F6F-99F5-2A2E904AB93B}.Release|x86.Build.0 = Release|x86
 	EndGlobalSection
 	GlobalSection(SolutionProperties) = preSolution
Index: branches/DataAnalysis.IslandAlgorithms/HeuristicLab.Algorithms.DataAnalysis.Symbolic/3.3/HeuristicLab.Algorithms.DataAnalysis.Symbolic.csproj
===================================================================
--- branches/DataAnalysis.IslandAlgorithms/HeuristicLab.Algorithms.DataAnalysis.Symbolic/3.3/HeuristicLab.Algorithms.DataAnalysis.Symbolic.csproj	(revision 9066)
+++ branches/DataAnalysis.IslandAlgorithms/HeuristicLab.Algorithms.DataAnalysis.Symbolic/3.3/HeuristicLab.Algorithms.DataAnalysis.Symbolic.csproj	(revision 9067)
@@ -38,8 +38,4 @@
   </PropertyGroup>
   <ItemGroup>
-    <Reference Include="HeuristicLab.Algorithms.GeneticAlgorithm-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
-      <SpecificVersion>False</SpecificVersion>
-      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Algorithms.GeneticAlgorithm-3.3.dll</HintPath>
-    </Reference>
     <Reference Include="HeuristicLab.Analysis-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
       <SpecificVersion>False</SpecificVersion>
@@ -61,4 +57,8 @@
       <SpecificVersion>False</SpecificVersion>
       <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Data-3.3.dll</HintPath>
+    </Reference>
+    <Reference Include="HeuristicLab.Encodings.SymbolicExpressionTreeEncoding-3.4, Version=3.4.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Encodings.SymbolicExpressionTreeEncoding-3.4.dll</HintPath>
     </Reference>
     <Reference Include="HeuristicLab.Operators-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
@@ -101,4 +101,5 @@
     <Reference Include="System" />
     <Reference Include="System.Core" />
+    <Reference Include="System.Drawing" />
     <Reference Include="System.Xml.Linq" />
     <Reference Include="System.Data.DataSetExtensions" />
@@ -110,4 +111,5 @@
     <Compile Include="Plugin.cs" />
     <Compile Include="Properties\AssemblyInfo.cs" />
+    <Compile Include="SymbolicDataAnalysisIslandGAEvaluator.cs" />
     <Compile Include="SymbolicDataAnalysisIslandGeneticAlgorithm.cs" />
   </ItemGroup>
@@ -116,4 +118,10 @@
     <None Include="Plugin.cs.frame" />
     <None Include="Properties\AssemblyInfo.cs.frame" />
+  </ItemGroup>
+  <ItemGroup>
+    <ProjectReference Include="..\..\HeuristicLab.Algorithms.GeneticAlgorithm\3.3\HeuristicLab.Algorithms.GeneticAlgorithm-3.3.csproj">
+      <Project>{a51da44f-cb35-4f6f-99f5-2a2e904ab93b}</Project>
+      <Name>HeuristicLab.Algorithms.GeneticAlgorithm-3.3</Name>
+    </ProjectReference>
   </ItemGroup>
   <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
Index: branches/DataAnalysis.IslandAlgorithms/HeuristicLab.Algorithms.DataAnalysis.Symbolic/3.3/SymbolicDataAnalysisIslandGeneticAlgorithm.cs
===================================================================
--- branches/DataAnalysis.IslandAlgorithms/HeuristicLab.Algorithms.DataAnalysis.Symbolic/3.3/SymbolicDataAnalysisIslandGeneticAlgorithm.cs	(revision 9066)
+++ branches/DataAnalysis.IslandAlgorithms/HeuristicLab.Algorithms.DataAnalysis.Symbolic/3.3/SymbolicDataAnalysisIslandGeneticAlgorithm.cs	(revision 9067)
@@ -21,18 +21,13 @@
 
 using System;
+using System.Collections.Generic;
 using System.Linq;
 using HeuristicLab.Algorithms.GeneticAlgorithm;
-using HeuristicLab.Analysis;
 using HeuristicLab.Common;
 using HeuristicLab.Core;
 using HeuristicLab.Data;
-using HeuristicLab.Operators;
-using HeuristicLab.Optimization;
-using HeuristicLab.Optimization.Operators;
 using HeuristicLab.Parameters;
 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
-using HeuristicLab.PluginInfrastructure;
 using HeuristicLab.Problems.DataAnalysis.Symbolic;
-using HeuristicLab.Random;
 
 namespace HeuristicLab.Algorithms.DataAnalysis.Symbolic {
@@ -40,6 +35,8 @@
   [Creatable("Algorithms")]
   [StorableClass]
-  public sealed class SymbolicDataAnalysisIslandGeneticAlgorithm : HeuristicOptimizationEngineAlgorithm, IStorableContent {
-    public string Filename { get; set; }
+  public sealed class SymbolicDataAnalysisIslandGeneticAlgorithm : IslandGeneticAlgorithm {
+    private const string FixedSamplesParameterName = "NumberOfFixedSamples";
+    private const string FixedSamplesPartitionsParameterName = "FixedSamplesPartitions";
+    private const string RandomSamplesParameterName = "NumberOfRandomSamples";
 
     #region Problem Properties
@@ -53,143 +50,29 @@
     #endregion
 
-    #region Parameter Properties
-    private ValueParameter<IntValue> SeedParameter {
-      get { return (ValueParameter<IntValue>)Parameters["Seed"]; }
+    #region parameters
+    public IFixedValueParameter<IntValue> FixedSamplesParameter {
+      get { return (IFixedValueParameter<IntValue>)Parameters[FixedSamplesParameterName]; }
     }
-    private ValueParameter<BoolValue> SetSeedRandomlyParameter {
-      get { return (ValueParameter<BoolValue>)Parameters["SetSeedRandomly"]; }
+    public IValueParameter<ItemArray<IntRange>> FixedSamplesPartitionsParameter {
+      get { return (IValueParameter<ItemArray<IntRange>>)Parameters[FixedSamplesPartitionsParameterName]; }
     }
-    private ValueParameter<IntValue> NumberOfIslandsParameter {
-      get { return (ValueParameter<IntValue>)Parameters["NumberOfIslands"]; }
-    }
-    private ValueParameter<IntValue> MigrationIntervalParameter {
-      get { return (ValueParameter<IntValue>)Parameters["MigrationInterval"]; }
-    }
-    private ValueParameter<PercentValue> MigrationRateParameter {
-      get { return (ValueParameter<PercentValue>)Parameters["MigrationRate"]; }
-    }
-    public IConstrainedValueParameter<IMigrator> MigratorParameter {
-      get { return (IConstrainedValueParameter<IMigrator>)Parameters["Migrator"]; }
-    }
-    public IConstrainedValueParameter<ISelector> EmigrantsSelectorParameter {
-      get { return (IConstrainedValueParameter<ISelector>)Parameters["EmigrantsSelector"]; }
-    }
-    public IConstrainedValueParameter<IReplacer> ImmigrationReplacerParameter {
-      get { return (IConstrainedValueParameter<IReplacer>)Parameters["ImmigrationReplacer"]; }
-    }
-    private ValueParameter<IntValue> PopulationSizeParameter {
-      get { return (ValueParameter<IntValue>)Parameters["PopulationSize"]; }
-    }
-    private ValueParameter<IntValue> MaximumGenerationsParameter {
-      get { return (ValueParameter<IntValue>)Parameters["MaximumGenerations"]; }
-    }
-    public IConstrainedValueParameter<ISelector> SelectorParameter {
-      get { return (IConstrainedValueParameter<ISelector>)Parameters["Selector"]; }
-    }
-    public IConstrainedValueParameter<ICrossover> CrossoverParameter {
-      get { return (IConstrainedValueParameter<ICrossover>)Parameters["Crossover"]; }
-    }
-    private ValueParameter<PercentValue> MutationProbabilityParameter {
-      get { return (ValueParameter<PercentValue>)Parameters["MutationProbability"]; }
-    }
-    public IConstrainedValueParameter<IManipulator> MutatorParameter {
-      get { return (IConstrainedValueParameter<IManipulator>)Parameters["Mutator"]; }
-    }
-    private ValueParameter<IntValue> ElitesParameter {
-      get { return (ValueParameter<IntValue>)Parameters["Elites"]; }
-    }
-    private ValueParameter<MultiAnalyzer> AnalyzerParameter {
-      get { return (ValueParameter<MultiAnalyzer>)Parameters["Analyzer"]; }
-    }
-    private ValueParameter<MultiAnalyzer> IslandAnalyzerParameter {
-      get { return (ValueParameter<MultiAnalyzer>)Parameters["IslandAnalyzer"]; }
+    public IFixedValueParameter<IntValue> RandomSamplesParameter {
+      get { return (IFixedValueParameter<IntValue>)Parameters[RandomSamplesParameterName]; }
     }
     #endregion
 
-    #region Properties
-    public IntValue Seed {
-      get { return SeedParameter.Value; }
-      set { SeedParameter.Value = value; }
+    #region properties
+    public int FixedSamples {
+      get { return FixedSamplesParameter.Value.Value; }
+      set { FixedSamplesParameter.Value.Value = value; }
     }
-    public BoolValue SetSeedRandomly {
-      get { return SetSeedRandomlyParameter.Value; }
-      set { SetSeedRandomlyParameter.Value = value; }
+    public ItemArray<IntRange> FixedSamplesPartitions {
+      get { return FixedSamplesPartitionsParameter.Value; }
+      set { FixedSamplesPartitionsParameter.Value = value; }
     }
-    public IntValue NumberOfIslands {
-      get { return NumberOfIslandsParameter.Value; }
-      set { NumberOfIslandsParameter.Value = value; }
+    public int RandomSamples {
+      get { return RandomSamplesParameter.Value.Value; }
+      set { RandomSamplesParameter.Value.Value = value; }
     }
-    public IntValue MigrationInterval {
-      get { return MigrationIntervalParameter.Value; }
-      set { MigrationIntervalParameter.Value = value; }
-    }
-    public PercentValue MigrationRate {
-      get { return MigrationRateParameter.Value; }
-      set { MigrationRateParameter.Value = value; }
-    }
-    public IMigrator Migrator {
-      get { return MigratorParameter.Value; }
-      set { MigratorParameter.Value = value; }
-    }
-    public ISelector EmigrantsSelector {
-      get { return EmigrantsSelectorParameter.Value; }
-      set { EmigrantsSelectorParameter.Value = value; }
-    }
-    public IReplacer ImmigrationReplacer {
-      get { return ImmigrationReplacerParameter.Value; }
-      set { ImmigrationReplacerParameter.Value = value; }
-    }
-    public IntValue PopulationSize {
-      get { return PopulationSizeParameter.Value; }
-      set { PopulationSizeParameter.Value = value; }
-    }
-    public IntValue MaximumGenerations {
-      get { return MaximumGenerationsParameter.Value; }
-      set { MaximumGenerationsParameter.Value = value; }
-    }
-    public ISelector Selector {
-      get { return SelectorParameter.Value; }
-      set { SelectorParameter.Value = value; }
-    }
-    public ICrossover Crossover {
-      get { return CrossoverParameter.Value; }
-      set { CrossoverParameter.Value = value; }
-    }
-    public PercentValue MutationProbability {
-      get { return MutationProbabilityParameter.Value; }
-      set { MutationProbabilityParameter.Value = value; }
-    }
-    public IManipulator Mutator {
-      get { return MutatorParameter.Value; }
-      set { MutatorParameter.Value = value; }
-    }
-    public IntValue Elites {
-      get { return ElitesParameter.Value; }
-      set { ElitesParameter.Value = value; }
-    }
-    public MultiAnalyzer Analyzer {
-      get { return AnalyzerParameter.Value; }
-      set { AnalyzerParameter.Value = value; }
-    }
-    public MultiAnalyzer IslandAnalyzer {
-      get { return IslandAnalyzerParameter.Value; }
-      set { IslandAnalyzerParameter.Value = value; }
-    }
-    private RandomCreator RandomCreator {
-      get { return (RandomCreator)OperatorGraph.InitialOperator; }
-    }
-    private UniformSubScopesProcessor IslandProcessor {
-      get { return OperatorGraph.Iterate().OfType<UniformSubScopesProcessor>().First(x => x.Operator is SolutionsCreator); }
-    }
-    private SolutionsCreator SolutionsCreator {
-      get { return (SolutionsCreator)IslandProcessor.Operator; }
-    }
-    private IslandGeneticAlgorithmMainLoop MainLoop {
-      get { return FindMainLoop(IslandProcessor.Successor); }
-    }
-    [Storable]
-    private BestAverageWorstQualityAnalyzer islandQualityAnalyzer;
-    [Storable]
-    private BestAverageWorstQualityAnalyzer qualityAnalyzer;
     #endregion
 
@@ -198,11 +81,9 @@
     [StorableHook(HookType.AfterDeserialization)]
     private void AfterDeserialization() {
-      Initialize();
+      RegisterParameterEvents();
     }
     private SymbolicDataAnalysisIslandGeneticAlgorithm(SymbolicDataAnalysisIslandGeneticAlgorithm original, Cloner cloner)
       : base(original, cloner) {
-      islandQualityAnalyzer = cloner.Clone(original.islandQualityAnalyzer);
-      qualityAnalyzer = cloner.Clone(original.qualityAnalyzer);
-      Initialize();
+      RegisterParameterEvents();
     }
     public override IDeepCloneable Clone(Cloner cloner) {
@@ -212,351 +93,69 @@
     public SymbolicDataAnalysisIslandGeneticAlgorithm()
       : base() {
-      Parameters.Add(new ValueParameter<IntValue>("Seed", "The random seed used to initialize the new pseudo random number generator.", new IntValue(0)));
-      Parameters.Add(new ValueParameter<BoolValue>("SetSeedRandomly", "True if the random seed should be set to a random value, otherwise false.", new BoolValue(true)));
-      Parameters.Add(new ValueParameter<IntValue>("NumberOfIslands", "The number of islands.", new IntValue(5)));
-      Parameters.Add(new ValueParameter<IntValue>("MigrationInterval", "The number of generations that should pass between migration phases.", new IntValue(20)));
-      Parameters.Add(new ValueParameter<PercentValue>("MigrationRate", "The proportion of individuals that should migrate between the islands.", new PercentValue(0.15)));
-      Parameters.Add(new ConstrainedValueParameter<IMigrator>("Migrator", "The migration strategy."));
-      Parameters.Add(new ConstrainedValueParameter<ISelector>("EmigrantsSelector", "Selects the individuals that will be migrated."));
-      Parameters.Add(new ConstrainedValueParameter<IReplacer>("ImmigrationReplacer", "Selects the population from the unification of the original population and the immigrants."));
-      Parameters.Add(new ValueParameter<IntValue>("PopulationSize", "The size of the population of solutions.", new IntValue(100)));
-      Parameters.Add(new ValueParameter<IntValue>("MaximumGenerations", "The maximum number of generations that should be processed.", new IntValue(1000)));
-      Parameters.Add(new ConstrainedValueParameter<ISelector>("Selector", "The operator used to select solutions for reproduction."));
-      Parameters.Add(new ConstrainedValueParameter<ICrossover>("Crossover", "The operator used to cross solutions."));
-      Parameters.Add(new ValueParameter<PercentValue>("MutationProbability", "The probability that the mutation operator is applied on a solution.", new PercentValue(0.05)));
-      Parameters.Add(new OptionalConstrainedValueParameter<IManipulator>("Mutator", "The operator used to mutate solutions."));
-      Parameters.Add(new ValueParameter<IntValue>("Elites", "The numer of elite solutions which are kept in each generation.", new IntValue(1)));
-      Parameters.Add(new ValueParameter<MultiAnalyzer>("Analyzer", "The operator used to analyze the islands.", new MultiAnalyzer()));
-      Parameters.Add(new ValueParameter<MultiAnalyzer>("IslandAnalyzer", "The operator used to analyze each island.", new MultiAnalyzer()));
+      Parameters.Add(new FixedValueParameter<IntValue>(FixedSamplesParameterName, "The number of fixed samples used for fitness calculation in each island.", new IntValue(0)));
+      Parameters.Add(new ValueParameter<ItemArray<IntRange>>(FixedSamplesPartitionsParameterName, "The fixed samples partitions used for fitness calculation for every island."));
+      Parameters.Add(new FixedValueParameter<IntValue>(RandomSamplesParameterName, "The number of random samples used for fitness calculation in each island..", new IntValue(0)));
 
-      RandomCreator randomCreator = new RandomCreator();
-      UniformSubScopesProcessor ussp0 = new UniformSubScopesProcessor();
-      LocalRandomCreator localRandomCreator = new LocalRandomCreator();
-      RandomCreator globalRandomResetter = new RandomCreator();
-      SubScopesCreator populationCreator = new SubScopesCreator();
-      UniformSubScopesProcessor ussp1 = new UniformSubScopesProcessor();
-      SolutionsCreator solutionsCreator = new SolutionsCreator();
-      VariableCreator variableCreator = new VariableCreator();
-      UniformSubScopesProcessor ussp2 = new UniformSubScopesProcessor();
-      SubScopesCounter subScopesCounter = new SubScopesCounter();
-      ResultsCollector resultsCollector = new ResultsCollector();
-      IslandGeneticAlgorithmMainLoop mainLoop = new IslandGeneticAlgorithmMainLoop();
-      OperatorGraph.InitialOperator = randomCreator;
-
-      randomCreator.RandomParameter.ActualName = "GlobalRandom";
-      randomCreator.SeedParameter.ActualName = SeedParameter.Name;
-      randomCreator.SeedParameter.Value = null;
-      randomCreator.SetSeedRandomlyParameter.ActualName = SetSeedRandomlyParameter.Name;
-      randomCreator.SetSeedRandomlyParameter.Value = null;
-      randomCreator.Successor = populationCreator;
-
-      populationCreator.NumberOfSubScopesParameter.ActualName = NumberOfIslandsParameter.Name;
-      populationCreator.Successor = ussp0;
-
-      ussp0.Operator = localRandomCreator;
-      ussp0.Successor = globalRandomResetter;
-
-      // BackwardsCompatibility3.3
-      // the global random is resetted to ensure the same algorithm results
-      #region Backwards compatible code, remove with 3.4
-      globalRandomResetter.RandomParameter.ActualName = "GlobalRandom";
-      globalRandomResetter.SeedParameter.ActualName = SeedParameter.Name;
-      globalRandomResetter.SeedParameter.Value = null;
-      globalRandomResetter.SetSeedRandomlyParameter.Value = new BoolValue(false);
-      globalRandomResetter.Successor = ussp1;
-      #endregion
-
-      ussp1.Operator = solutionsCreator;
-      ussp1.Successor = variableCreator;
-
-      solutionsCreator.NumberOfSolutionsParameter.ActualName = PopulationSizeParameter.Name;
-      //don't create solutions in parallel because the hive engine would distribute these tasks
-      solutionsCreator.ParallelParameter.Value = new BoolValue(false);
-      solutionsCreator.Successor = null;
-
-      variableCreator.Name = "Initialize EvaluatedSolutions";
-      variableCreator.CollectedValues.Add(new ValueParameter<IntValue>("EvaluatedSolutions", new IntValue()));
-      variableCreator.Successor = ussp2;
-
-      ussp2.Operator = subScopesCounter;
-      ussp2.Successor = resultsCollector;
-
-      subScopesCounter.Name = "Count EvaluatedSolutions";
-      subScopesCounter.ValueParameter.ActualName = "EvaluatedSolutions";
-      subScopesCounter.Successor = null;
-
-      resultsCollector.CollectedValues.Add(new LookupParameter<IntValue>("Evaluated Solutions", null, "EvaluatedSolutions"));
-      resultsCollector.ResultsParameter.ActualName = "Results";
-      resultsCollector.Successor = mainLoop;
-
-      mainLoop.EmigrantsSelectorParameter.ActualName = EmigrantsSelectorParameter.Name;
-      mainLoop.ImmigrationReplacerParameter.ActualName = ImmigrationReplacerParameter.Name;
-      mainLoop.MaximumGenerationsParameter.ActualName = MaximumGenerationsParameter.Name;
-      mainLoop.MigrationIntervalParameter.ActualName = MigrationIntervalParameter.Name;
-      mainLoop.MigrationRateParameter.ActualName = MigrationRateParameter.Name;
-      mainLoop.MigratorParameter.ActualName = MigratorParameter.Name;
-      mainLoop.NumberOfIslandsParameter.ActualName = NumberOfIslandsParameter.Name;
-      mainLoop.SelectorParameter.ActualName = SelectorParameter.Name;
-      mainLoop.CrossoverParameter.ActualName = CrossoverParameter.Name;
-      mainLoop.ElitesParameter.ActualName = ElitesParameter.Name;
-      mainLoop.MutatorParameter.ActualName = MutatorParameter.Name;
-      mainLoop.MutationProbabilityParameter.ActualName = MutationProbabilityParameter.Name;
-      mainLoop.RandomParameter.ActualName = randomCreator.RandomParameter.ActualName;
-      mainLoop.ResultsParameter.ActualName = "Results";
-      mainLoop.AnalyzerParameter.ActualName = AnalyzerParameter.Name;
-      mainLoop.IslandAnalyzerParameter.ActualName = IslandAnalyzerParameter.Name;
-      mainLoop.EvaluatedSolutionsParameter.ActualName = "EvaluatedSolutions";
-      mainLoop.Successor = null;
-
-      foreach (ISelector selector in ApplicationManager.Manager.GetInstances<ISelector>().Where(x => !(x is IMultiObjectiveSelector)).OrderBy(x => x.Name))
-        SelectorParameter.ValidValues.Add(selector);
-      ISelector proportionalSelector = SelectorParameter.ValidValues.FirstOrDefault(x => x.GetType().Name.Equals("ProportionalSelector"));
-      if (proportionalSelector != null) SelectorParameter.Value = proportionalSelector;
-
-      foreach (ISelector selector in ApplicationManager.Manager.GetInstances<ISelector>().Where(x => !(x is IMultiObjectiveSelector)).OrderBy(x => x.Name))
-        EmigrantsSelectorParameter.ValidValues.Add(selector);
-
-      foreach (IReplacer replacer in ApplicationManager.Manager.GetInstances<IReplacer>().OrderBy(x => x.Name))
-        ImmigrationReplacerParameter.ValidValues.Add(replacer);
-
-      ParameterizeSelectors();
-
-      foreach (IMigrator migrator in ApplicationManager.Manager.GetInstances<IMigrator>().OrderBy(x => x.Name))
-        MigratorParameter.ValidValues.Add(migrator);
-
-      qualityAnalyzer = new BestAverageWorstQualityAnalyzer();
-      islandQualityAnalyzer = new BestAverageWorstQualityAnalyzer();
-      ParameterizeAnalyzers();
-      UpdateAnalyzers();
-
-      Initialize();
+      RegisterParameterEvents();
+      RecalculateFixedSamplesPartitions();
     }
 
-    public override void Prepare() {
-      if (Problem != null) base.Prepare();
+    private void RegisterParameterEvents() {
+      NumberOfIslandsParameter.ValueChanged += NumberOfIslandsParameter_ValueChanged;
+      NumberOfIslandsParameter.Value.ValueChanged += (o, ev) => RecalculateFixedSamplesPartitions();
+      FixedSamplesParameter.Value.ValueChanged += (o, e) => RecalculateFixedSamplesPartitions();
     }
 
-    #region Events
-    protected override void OnProblemChanged() {
-      ParameterizeStochasticOperator(Problem.SolutionCreator);
-      ParameterizeStochasticOperatorForIsland(Problem.Evaluator);
-      foreach (IOperator op in Problem.Operators.OfType<IOperator>()) ParameterizeStochasticOperator(op);
-      ParameterizeSolutionsCreator();
-      ParameterizeMainLoop();
-      ParameterizeSelectors();
-      ParameterizeAnalyzers();
-      ParameterizeIterationBasedOperators();
-      UpdateCrossovers();
-      UpdateMutators();
-      UpdateAnalyzers();
-      Problem.Evaluator.QualityParameter.ActualNameChanged += new EventHandler(Evaluator_QualityParameter_ActualNameChanged);
-      base.OnProblemChanged();
+    private void NumberOfIslandsParameter_ValueChanged(object sender, EventArgs e) {
+      NumberOfIslands.ValueChanged += (o, ev) => RecalculateFixedSamplesPartitions();
+      RecalculateFixedSamplesPartitions();
     }
 
-    protected override void Problem_SolutionCreatorChanged(object sender, EventArgs e) {
-      ParameterizeStochasticOperator(Problem.SolutionCreator);
-      ParameterizeSolutionsCreator();
-      base.Problem_SolutionCreatorChanged(sender, e);
+    protected override void Problem_Reset(object sender, EventArgs e) {
+      RecalculateFixedSamplesPartitions();
+      base.Problem_Reset(sender, e);
     }
-    protected override void Problem_EvaluatorChanged(object sender, EventArgs e) {
-      ParameterizeStochasticOperatorForIsland(Problem.Evaluator);
-      ParameterizeSolutionsCreator();
-      ParameterizeMainLoop();
-      ParameterizeSelectors();
-      ParameterizeAnalyzers();
-      Problem.Evaluator.QualityParameter.ActualNameChanged += new EventHandler(Evaluator_QualityParameter_ActualNameChanged);
-      base.Problem_EvaluatorChanged(sender, e);
+
+    protected override void OnProblemChanged() {
+      base.OnProblemChanged();
+      Problem.FitnessCalculationPartition.ValueChanged += (o, e) => RecalculateFixedSamplesPartitions();
+      RecalculateFixedSamplesPartitions();
     }
-    protected override void Problem_OperatorsChanged(object sender, EventArgs e) {
-      foreach (IOperator op in Problem.Operators.OfType<IOperator>()) ParameterizeStochasticOperator(op);
-      ParameterizeIterationBasedOperators();
-      UpdateCrossovers();
-      UpdateMutators();
-      UpdateAnalyzers();
-      base.Problem_OperatorsChanged(sender, e);
+
+    private void RecalculateFixedSamplesPartitions() {
+      if (Problem == null) {
+        FixedSamplesPartitions = new ItemArray<IntRange>(Enumerable.Repeat(new IntRange(), NumberOfIslands.Value));
+        return;
+      }
+      var samplesStart = Problem.FitnessCalculationPartition.Start;
+      var samplesEnd = Problem.FitnessCalculationPartition.End;
+      var totalSamples = Problem.FitnessCalculationPartition.Size;
+      var fixedSamples = FixedSamples;
+      var islands = NumberOfIslands.Value;
+
+      int offset = 0;
+      //fixed samples partition do not overlap
+      if (((double)totalSamples) / fixedSamples <= islands) {
+        offset = totalSamples / islands;
+      } else {
+        offset = (totalSamples - fixedSamples) / (islands - 1);
+      }
+
+      List<IntRange> partitions = new List<IntRange>();
+      for (int i = 0; i < islands; i++) {
+        var partitionStart = samplesStart + offset * i;
+        partitions.Add(new IntRange(partitionStart, partitionStart + fixedSamples));
+      }
+
+      //it can be the case that the last partitions exceeds the allowed samples
+      //move the last partition forward.
+      int exceedsSamples = partitions[partitions.Count - 1].End - samplesEnd;
+      if (exceedsSamples > 0) {
+        partitions[partitions.Count - 1].Start -= exceedsSamples;
+        partitions[partitions.Count - 1].End -= exceedsSamples;
+      }
+      FixedSamplesPartitions = new ItemArray<IntRange>(partitions);
     }
-    private void ElitesParameter_ValueChanged(object sender, EventArgs e) {
-      Elites.ValueChanged += new EventHandler(Elites_ValueChanged);
-      ParameterizeSelectors();
-    }
-    private void Elites_ValueChanged(object sender, EventArgs e) {
-      ParameterizeSelectors();
-    }
-    private void PopulationSizeParameter_ValueChanged(object sender, EventArgs e) {
-      NumberOfIslands.ValueChanged += new EventHandler(PopulationSize_ValueChanged);
-      ParameterizeSelectors();
-    }
-    private void PopulationSize_ValueChanged(object sender, EventArgs e) {
-      ParameterizeSelectors();
-    }
-    private void Evaluator_QualityParameter_ActualNameChanged(object sender, EventArgs e) {
-      ParameterizeMainLoop();
-      ParameterizeSelectors();
-      ParameterizeAnalyzers();
-    }
-    private void MigrationRateParameter_ValueChanged(object sender, EventArgs e) {
-      MigrationRate.ValueChanged += new EventHandler(MigrationRate_ValueChanged);
-      ParameterizeSelectors();
-    }
-    private void MigrationRate_ValueChanged(object sender, EventArgs e) {
-      ParameterizeSelectors();
-    }
-    #endregion
 
-    #region Helpers
-    private void Initialize() {
-      PopulationSizeParameter.ValueChanged += new EventHandler(PopulationSizeParameter_ValueChanged);
-      PopulationSize.ValueChanged += new EventHandler(PopulationSize_ValueChanged);
-      MigrationRateParameter.ValueChanged += new EventHandler(MigrationRateParameter_ValueChanged);
-      MigrationRate.ValueChanged += new EventHandler(MigrationRate_ValueChanged);
-      ElitesParameter.ValueChanged += new EventHandler(ElitesParameter_ValueChanged);
-      Elites.ValueChanged += new EventHandler(Elites_ValueChanged);
-      if (Problem != null) {
-        Problem.Evaluator.QualityParameter.ActualNameChanged += new EventHandler(Evaluator_QualityParameter_ActualNameChanged);
-      }
-    }
-    private void ParameterizeSolutionsCreator() {
-      SolutionsCreator.EvaluatorParameter.ActualName = Problem.EvaluatorParameter.Name;
-      SolutionsCreator.SolutionCreatorParameter.ActualName = Problem.SolutionCreatorParameter.Name;
-    }
-    private void ParameterizeMainLoop() {
-      MainLoop.BestKnownQualityParameter.ActualName = Problem.BestKnownQualityParameter.Name;
-      MainLoop.EvaluatorParameter.ActualName = Problem.EvaluatorParameter.Name;
-      MainLoop.MaximizationParameter.ActualName = Problem.MaximizationParameter.Name;
-      MainLoop.QualityParameter.ActualName = Problem.Evaluator.QualityParameter.ActualName;
-    }
-    private void ParameterizeStochasticOperator(IOperator op) {
-      IStochasticOperator stochasticOp = op as IStochasticOperator;
-      if (stochasticOp != null) {
-        stochasticOp.RandomParameter.ActualName = RandomCreator.RandomParameter.ActualName;
-        stochasticOp.RandomParameter.Hidden = true;
-      }
-    }
-    private void ParameterizeStochasticOperatorForIsland(IOperator op) {
-      IStochasticOperator stochasticOp = op as IStochasticOperator;
-      if (stochasticOp != null) {
-        stochasticOp.RandomParameter.ActualName = "LocalRandom";
-        stochasticOp.RandomParameter.Hidden = true;
-      }
-    }
-    private void ParameterizeSelectors() {
-      foreach (ISelector selector in SelectorParameter.ValidValues) {
-        selector.CopySelected = new BoolValue(true);
-        selector.NumberOfSelectedSubScopesParameter.Value = new IntValue(2 * (PopulationSize.Value - Elites.Value));
-        selector.NumberOfSelectedSubScopesParameter.Hidden = true;
-        ParameterizeStochasticOperatorForIsland(selector);
-      }
-      foreach (ISelector selector in EmigrantsSelectorParameter.ValidValues) {
-        selector.CopySelected = new BoolValue(true);
-        selector.NumberOfSelectedSubScopesParameter.Value = new IntValue((int)Math.Ceiling(PopulationSize.Value * MigrationRate.Value));
-        selector.NumberOfSelectedSubScopesParameter.Hidden = true;
-        ParameterizeStochasticOperator(selector);
-      }
-      foreach (IReplacer replacer in ImmigrationReplacerParameter.ValidValues) {
-        ParameterizeStochasticOperator(replacer);
-      }
-      if (Problem != null) {
-        foreach (ISingleObjectiveSelector selector in SelectorParameter.ValidValues.OfType<ISingleObjectiveSelector>()) {
-          selector.MaximizationParameter.ActualName = Problem.MaximizationParameter.Name;
-          selector.MaximizationParameter.Hidden = true;
-          selector.QualityParameter.ActualName = Problem.Evaluator.QualityParameter.ActualName;
-          selector.QualityParameter.Hidden = true;
-        }
-        foreach (ISingleObjectiveSelector selector in EmigrantsSelectorParameter.ValidValues.OfType<ISingleObjectiveSelector>()) {
-          selector.MaximizationParameter.ActualName = Problem.MaximizationParameter.Name;
-          selector.MaximizationParameter.Hidden = true;
-          selector.QualityParameter.ActualName = Problem.Evaluator.QualityParameter.ActualName;
-          selector.QualityParameter.Hidden = true;
-        }
-        foreach (ISingleObjectiveReplacer selector in ImmigrationReplacerParameter.ValidValues.OfType<ISingleObjectiveReplacer>()) {
-          selector.MaximizationParameter.ActualName = Problem.MaximizationParameter.Name;
-          selector.MaximizationParameter.Hidden = true;
-          selector.QualityParameter.ActualName = Problem.Evaluator.QualityParameter.ActualName;
-          selector.QualityParameter.Hidden = true;
-        }
-      }
-    }
-    private void ParameterizeAnalyzers() {
-      islandQualityAnalyzer.ResultsParameter.ActualName = "Results";
-      islandQualityAnalyzer.ResultsParameter.Hidden = true;
-      islandQualityAnalyzer.QualityParameter.Depth = 1;
-      qualityAnalyzer.ResultsParameter.ActualName = "Results";
-      qualityAnalyzer.ResultsParameter.Hidden = true;
-      qualityAnalyzer.QualityParameter.Depth = 2;
-
-      if (Problem != null) {
-        islandQualityAnalyzer.MaximizationParameter.ActualName = Problem.MaximizationParameter.Name;
-        islandQualityAnalyzer.MaximizationParameter.Hidden = true;
-        islandQualityAnalyzer.QualityParameter.ActualName = Problem.Evaluator.QualityParameter.ActualName;
-        islandQualityAnalyzer.QualityParameter.Hidden = true;
-        islandQualityAnalyzer.BestKnownQualityParameter.ActualName = Problem.BestKnownQualityParameter.Name;
-        islandQualityAnalyzer.BestKnownQualityParameter.Hidden = true;
-        qualityAnalyzer.MaximizationParameter.ActualName = Problem.MaximizationParameter.Name;
-        qualityAnalyzer.MaximizationParameter.Hidden = true;
-        qualityAnalyzer.QualityParameter.ActualName = Problem.Evaluator.QualityParameter.ActualName;
-        qualityAnalyzer.QualityParameter.Hidden = true;
-        qualityAnalyzer.BestKnownQualityParameter.ActualName = Problem.BestKnownQualityParameter.Name;
-        qualityAnalyzer.BestKnownQualityParameter.Hidden = true;
-      }
-    }
-    private void ParameterizeIterationBasedOperators() {
-      if (Problem != null) {
-        foreach (IIterationBasedOperator op in Problem.Operators.OfType<IIterationBasedOperator>()) {
-          op.IterationsParameter.ActualName = "Generations";
-          op.IterationsParameter.Hidden = true;
-          op.MaximumIterationsParameter.ActualName = "MaximumGenerations";
-          op.MaximumIterationsParameter.Hidden = true;
-        }
-      }
-    }
-    private void UpdateCrossovers() {
-      ICrossover oldCrossover = CrossoverParameter.Value;
-      ICrossover defaultCrossover = Problem.Operators.OfType<ICrossover>().FirstOrDefault();
-      CrossoverParameter.ValidValues.Clear();
-      foreach (ICrossover crossover in Problem.Operators.OfType<ICrossover>().OrderBy(x => x.Name)) {
-        ParameterizeStochasticOperatorForIsland(crossover);
-        CrossoverParameter.ValidValues.Add(crossover);
-      }
-      if (oldCrossover != null) {
-        ICrossover crossover = CrossoverParameter.ValidValues.FirstOrDefault(x => x.GetType() == oldCrossover.GetType());
-        if (crossover != null) CrossoverParameter.Value = crossover;
-        else oldCrossover = null;
-      }
-      if (oldCrossover == null && defaultCrossover != null)
-        CrossoverParameter.Value = defaultCrossover;
-    }
-    private void UpdateMutators() {
-      IManipulator oldMutator = MutatorParameter.Value;
-      MutatorParameter.ValidValues.Clear();
-      foreach (IManipulator mutator in Problem.Operators.OfType<IManipulator>().OrderBy(x => x.Name)) {
-        ParameterizeStochasticOperatorForIsland(mutator);
-        MutatorParameter.ValidValues.Add(mutator);
-      }
-      if (oldMutator != null) {
-        IManipulator mutator = MutatorParameter.ValidValues.FirstOrDefault(x => x.GetType() == oldMutator.GetType());
-        if (mutator != null) MutatorParameter.Value = mutator;
-      }
-    }
-    private void UpdateAnalyzers() {
-      IslandAnalyzer.Operators.Clear();
-      Analyzer.Operators.Clear();
-      IslandAnalyzer.Operators.Add(islandQualityAnalyzer, islandQualityAnalyzer.EnabledByDefault);
-      if (Problem != null) {
-        foreach (IAnalyzer analyzer in Problem.Operators.OfType<IAnalyzer>()) {
-          foreach (IScopeTreeLookupParameter param in analyzer.Parameters.OfType<IScopeTreeLookupParameter>())
-            param.Depth = 2;
-          Analyzer.Operators.Add(analyzer, analyzer.EnabledByDefault);
-        }
-      }
-      Analyzer.Operators.Add(qualityAnalyzer, qualityAnalyzer.EnabledByDefault);
-    }
-    private IslandGeneticAlgorithmMainLoop FindMainLoop(IOperator start) {
-      IOperator mainLoop = start;
-      while (mainLoop != null && !(mainLoop is IslandGeneticAlgorithmMainLoop))
-        mainLoop = ((SingleSuccessorOperator)mainLoop).Successor;
-      if (mainLoop == null) return null;
-      else return (IslandGeneticAlgorithmMainLoop)mainLoop;
-    }
-    #endregion
   }
 }
