Index: branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/HeuristicLab.Analysis.SolutionCaching-3.3.csproj
===================================================================
--- branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/HeuristicLab.Analysis.SolutionCaching-3.3.csproj	(revision 10024)
+++ branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/HeuristicLab.Analysis.SolutionCaching-3.3.csproj	(revision 10025)
@@ -123,4 +123,7 @@
   </ItemGroup>
   <ItemGroup>
+    <Compile Include="PermutationEncoding\PermutationSolutionCache.cs" />
+    <Compile Include="PermutationEncoding\PermutationSolutionCachingAnalyzer.cs" />
+    <Compile Include="PermutationEncoding\PermutationSolutionInformation.cs" />
     <Compile Include="Plugin.cs" />
     <Compile Include="Properties\AssemblyInfo.cs" />
Index: branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/PermutationEncoding/PermutationSolutionCache.cs
===================================================================
--- branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/PermutationEncoding/PermutationSolutionCache.cs	(revision 10025)
+++ branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/PermutationEncoding/PermutationSolutionCache.cs	(revision 10025)
@@ -0,0 +1,47 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2013 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.Collections.Generic;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Encodings.PermutationEncoding;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Analysis.SolutionCaching.PermutationEncoding {
+  [Item("PermutationSolutionCache", "Stores Permutation solutions generated by an algorithm.")]
+  [StorableClass]
+  public class PermutationSolutionCache : SolutionCache<Permutation, PermutationSolutionInformation> {
+    [StorableConstructor]
+    protected PermutationSolutionCache(bool deserializing) : base(deserializing) { }
+    protected PermutationSolutionCache(PermutationSolutionCache original, Cloner cloner)
+      : base(original, cloner) {
+    }
+    public PermutationSolutionCache() : base() { }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new PermutationSolutionCache(this, cloner);
+    }
+
+    protected override void InitializeSolutionDictionary() {
+      solutionDictionary = new Dictionary<Permutation, List<PermutationSolutionInformation>>(new PermutationEqualityComparer());
+    }
+  }
+}
Index: branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/PermutationEncoding/PermutationSolutionCachingAnalyzer.cs
===================================================================
--- branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/PermutationEncoding/PermutationSolutionCachingAnalyzer.cs	(revision 10025)
+++ branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/PermutationEncoding/PermutationSolutionCachingAnalyzer.cs	(revision 10025)
@@ -0,0 +1,100 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2013 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.Encodings.PermutationEncoding;
+using HeuristicLab.Operators;
+using HeuristicLab.Optimization;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Analysis.SolutionCaching.PermutationEncoding {
+  [Item("PermutationSolutionCachingAnalyzer", "An operator that records all Permutation solutions every generation for GAs.")]
+  [StorableClass]
+  public class PermutationSolutionCachingAnalyzer : SingleSuccessorOperator, IAnalyzer {
+    private const string ResultsParameterName = "Results";
+
+    #region IAnalyzer Members
+    public bool EnabledByDefault {
+      get { return false; }
+    }
+    #endregion
+
+    #region Parameter properties
+    public ILookupParameter<ResultCollection> ResultsParameter {
+      get { return (ILookupParameter<ResultCollection>)Parameters[ResultsParameterName]; }
+    }
+    public ILookupParameter<IntValue> GenerationsParameter {
+      get { return (ILookupParameter<IntValue>)Parameters["Generations"]; }
+    }
+    public ScopeTreeLookupParameter<Permutation> SolutionParameter {
+      get { return (ScopeTreeLookupParameter<Permutation>)Parameters["Solution"]; }
+    }
+    #endregion
+
+    #region Properties
+    public ResultCollection Results {
+      get { return ResultsParameter.ActualValue; }
+    }
+    #endregion
+
+    [StorableConstructor]
+    private PermutationSolutionCachingAnalyzer(bool deserializing) : base(deserializing) { }
+
+    private PermutationSolutionCachingAnalyzer(PermutationSolutionCachingAnalyzer original, Cloner cloner)
+      : base(original, cloner) {
+    }
+
+    public PermutationSolutionCachingAnalyzer()
+      : base() {
+      Parameters.Add(new LookupParameter<ResultCollection>(ResultsParameterName, "The results collection where the analysis values should be stored."));
+      Parameters.Add(new LookupParameter<IntValue>("Generations", "Nr of generations."));
+      Parameters.Add(new ScopeTreeLookupParameter<Permutation>("Solution", "The solutions that should be stored.", "TSPTour", 1));
+    }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new PermutationSolutionCachingAnalyzer(this, cloner);
+    }
+
+    public override IOperation Apply() {
+      ItemArray<Permutation> solutions = SolutionParameter.ActualValue;
+      PermutationSolutionCache solDict;
+
+      if (!Results.ContainsKey("SolutionCache")) {
+        solDict = new PermutationSolutionCache();
+        Results.Add(new Result("SolutionCache", solDict));
+      } else {
+        solDict = (PermutationSolutionCache)Results["SolutionCache"].Value;
+      }
+
+      foreach (var sol in solutions) {
+        PermutationSolutionInformation info = new PermutationSolutionInformation();
+        info.Generation = GenerationsParameter.ActualValue.Value;
+        info.ProducedBy = ProducedBy.CrossoverAndMutation;
+
+        solDict.Add((Permutation)sol.Clone(new Cloner()), info);
+      }
+      return base.Apply();
+    }
+  }
+}
Index: branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/PermutationEncoding/PermutationSolutionInformation.cs
===================================================================
--- branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/PermutationEncoding/PermutationSolutionInformation.cs	(revision 10025)
+++ branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/PermutationEncoding/PermutationSolutionInformation.cs	(revision 10025)
@@ -0,0 +1,62 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2013 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.Collections.Generic;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Encodings.PermutationEncoding;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Analysis.SolutionCaching.PermutationEncoding {
+  [Item("PermutationSolutionInformation", "Displays information about a real vector solution.")]
+  [StorableClass]
+  public class PermutationSolutionInformation : SolutionInformation<Encodings.PermutationEncoding.Permutation> {
+    public PermutationSolutionInformation() {
+      ParentList = new List<Permutation>();
+    }
+    [StorableConstructor]
+    protected PermutationSolutionInformation(bool deserializing) : base(deserializing) { }
+
+    protected PermutationSolutionInformation(PermutationSolutionInformation original, Cloner cloner)
+      : base(original, cloner) {
+    }
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new PermutationSolutionInformation(this, cloner);
+    }
+
+    public override int GetHashCode() {
+      //use rotating hash, should be enough
+      //see: http://eternallyconfuzzled.com/tuts/algorithms/jsw_tut_hashing.aspx
+      var pweq = new PermutationEqualityComparer();
+      int h = 0;
+
+      h = (h << 4) ^ (h >> 28) ^ ProducedBy.GetHashCode();
+      h = (h << 4) ^ (h >> 28) ^ Generation.GetHashCode();
+
+      if (ParentList != null) {
+        foreach (var parent in ParentList) {
+          h = (h << 4) ^ (h >> 28) ^ pweq.GetHashCode(parent);
+        }
+      }
+      return h;
+    }
+  }
+}
