Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Creators/RandomLinearLinkageCreator.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Creators/RandomLinearLinkageCreator.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Creators/RandomLinearLinkageCreator.cs	(revision 12285)
@@ -0,0 +1,51 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding.Creators {
+  [Item("Random Linear Linkage Creator", "Creates a random linear linkage LLE-e encoded solution.")]
+  [StorableClass]
+  public sealed class RandomLinearLinkageCreator : LinearLinkageCreator {
+
+    [StorableConstructor]
+    private RandomLinearLinkageCreator(bool deserializing) : base(deserializing) { }
+    private RandomLinearLinkageCreator(RandomLinearLinkageCreator original, Cloner cloner) : base(original, cloner) { }
+    public RandomLinearLinkageCreator() { }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new RandomLinearLinkageCreator(this, cloner);
+    }
+
+    protected override LinearLinkage Create(IRandom random, int length) {
+      var solution = new LinearLinkage(length);
+      var groups = Enumerable.Range(0, length).Select(x => Tuple.Create(x, random.Next(length)))
+                                              .GroupBy(x => x.Item2)
+                                              .Select(x => x.Select(y => y.Item1).ToList());
+      solution.SetGroups(groups);
+      return solution;
+    }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/GreedyPartitionCrossover.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/GreedyPartitionCrossover.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/GreedyPartitionCrossover.cs	(revision 12285)
@@ -0,0 +1,79 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.Collections.Generic;
+using System.Linq;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+using HeuristicLab.Random;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  [Item("Greedy Partition Crossover", "The Greedy Partition Crossover (GPX) is implemented as described in Ülker, Ö., Özcan, E., Korkmaz, E. E. 2007. Linear linkage encoding in grouping problems: applications on graph coloring and timetabling. In Practice and Theory of Automated Timetabling VI, pp. 347-363. Springer Berlin Heidelberg.")]
+  [StorableClass]
+  public sealed class GreedyPartitionCrossover : LinearLinkageCrossover {
+
+    [StorableConstructor]
+    private GreedyPartitionCrossover(bool deserializing) : base(deserializing) { }
+    private GreedyPartitionCrossover(GreedyPartitionCrossover original, Cloner cloner) : base(original, cloner) { }
+    public GreedyPartitionCrossover() { }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new GreedyPartitionCrossover(this, cloner);
+    }
+
+    public static LinearLinkage Apply(IRandom random, ItemArray<LinearLinkage> parents) {
+      var len = parents[0].Length;
+
+      var child = new LinearLinkage(len);
+      var childGroup = new List<HashSet<int>>();
+      var currentParent = random.Next(parents.Length);
+      var groups = parents.Select(x => x.GetGroups().Select(y => new HashSet<int>(y)).ToList()).ToList();
+      bool remaining;
+      do {
+        var maxGroup = groups[currentParent].Select((v, i) => Tuple.Create(i, v))
+          .MaxItems(x => x.Item2.Count)
+          .SampleRandom(random).Item1;
+        var group = groups[currentParent][maxGroup];
+        groups[currentParent].RemoveAt(maxGroup);
+        childGroup.Add(group);
+
+        remaining = false;
+        for (var p = 0; p < groups.Count; p++) {
+          for (var j = 0; j < groups[p].Count; j++) {
+            foreach (var elem in group) groups[p][j].Remove(elem);
+            if (!remaining && groups[p][j].Count > 0) remaining = true;
+          }
+        }
+
+        currentParent = (currentParent + 1) % parents.Length;
+      } while (remaining);
+
+      child.SetGroups(childGroup);
+      return child;
+    }
+
+    protected override LinearLinkage Cross(IRandom random, ItemArray<LinearLinkage> parents) {
+      return Apply(random, parents);
+    }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/GroupCrossover.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/GroupCrossover.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/GroupCrossover.cs	(revision 12285)
@@ -0,0 +1,87 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.Collections.Generic;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  [Item("Group Crossover", "The Group Crossover is implemented as described in Korkmaz, E.E. 2010. Multi-objective Genetic Algorithms for grouping problems. Applied Intelligence 33(2), pp. 179-192.")]
+  [StorableClass]
+  public sealed class GroupCrossover : LinearLinkageCrossover {
+
+    [StorableConstructor]
+    private GroupCrossover(bool deserializing) : base(deserializing) { }
+    private GroupCrossover(GroupCrossover original, Cloner cloner) : base(original, cloner) { }
+    public GroupCrossover() { }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new GroupCrossover(this, cloner);
+    }
+
+    public static LinearLinkage Apply(IRandom random, LinearLinkage p1, LinearLinkage p2) {
+      var length = p1.Length;
+      var child = new LinearLinkage(length);
+      var endNodes = new HashSet<int>();
+      for (var i = 0; i < length; i++) {
+        if ((p1[i] == i && p2[i] == i)
+          || ((p1[i] == i || p2[i] == i) && random.NextDouble() < 0.5)) {
+          child[i] = i;
+          endNodes.Add(i);
+        }
+      }
+      for (var i = 0; i < length; i++) {
+        if (endNodes.Contains(i)) continue;
+        if (endNodes.Contains(p1[i]) && endNodes.Contains(p2[i])) {
+          child[i] = random.NextDouble() < 0.5 ? p1[i] : p2[i];
+        } else if (endNodes.Contains(p1[i])) {
+          child[i] = p1[i];
+        } else if (endNodes.Contains(p2[i])) {
+          child[i] = p2[i];
+        } else {
+          var a = p1[i];
+          var b = p2[i];
+          while (true) {
+            if (endNodes.Contains(p2[a])) {
+              child[i] = p2[a];
+              break;
+            }
+            if (endNodes.Contains(p1[b])) {
+              child[i] = p1[b];
+              break;
+            }
+            var tmp = b;
+            b = p2[a];
+            a = p1[tmp];
+          }
+        }
+      }
+      return child;
+    }
+
+    protected override LinearLinkage Cross(IRandom random, ItemArray<LinearLinkage> parents) {
+      if (parents.Length != 2) throw new InvalidOperationException(Name + ": Can only cross exactly two parents.");
+      return Apply(random, parents[0], parents[1]);
+    }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/LargestGroupFirstCrossover.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/LargestGroupFirstCrossover.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/LargestGroupFirstCrossover.cs	(revision 12285)
@@ -0,0 +1,104 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.Collections.Generic;
+using System.Linq;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  [Item("Largest Group First Crossover", "")]
+  [StorableClass]
+  public sealed class LargestGroupFirstCrossover : LinearLinkageCrossover {
+
+    [StorableConstructor]
+    private LargestGroupFirstCrossover(bool deserializing) : base(deserializing) { }
+    private LargestGroupFirstCrossover(LargestGroupFirstCrossover original, Cloner cloner) : base(original, cloner) { }
+    public LargestGroupFirstCrossover() { }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new LargestGroupFirstCrossover(this, cloner);
+    }
+
+    public static LinearLinkage Apply(IRandom random, LinearLinkage p1, LinearLinkage p2) {
+      var len = p1.Length;
+      var groups1 = p1.GetGroups().ToList();
+      var groups2 = p2.GetGroups().ToList();
+      var childGroup = new List<HashSet<int>>();
+
+      var total = 0;
+      do {
+        var leastLinks = int.MaxValue;
+        var g1 = -1;
+        var g2 = -1;
+        var comparisons = 0;
+        // find those two groups in both parents that could be merged with least amount of new links
+        // put a bias on bigger groups in parent 1
+        for (var i = 0; i < groups1.Count; i++) {
+          var set1 = new HashSet<int>(groups1[i]);
+          for (var j = 0; j < groups2.Count; j++) {
+            var set2 = new HashSet<int>(groups2[j]);
+            var newLinks = set1.Except(set2).Count() * set2.Except(set1).Count();
+            if (newLinks < leastLinks || newLinks == leastLinks && groups1[i].Count > groups1[g1].Count) {
+              leastLinks = newLinks;
+              g1 = i;
+              g2 = j;
+              comparisons = 1;
+            } else if (newLinks == leastLinks && groups1[i].Count == groups1[g1].Count &&
+                       random.NextDouble() < 1.0 / (++comparisons)) {
+              leastLinks = newLinks;
+              g1 = i;
+              g2 = j;
+            }
+          }
+        }
+        var crossedGroup = new HashSet<int>(groups1[g1].Concat(groups2[g2]));
+        groups1.RemoveAt(g1);
+        groups2.RemoveAt(g2);
+        for (var i = 0; i < groups1.Count; i++) {
+          groups1[i] = groups1[i].Except(crossedGroup).ToList();
+          if (groups1[i].Count != 0) continue;
+          groups1.RemoveAt(i);
+          i--;
+        }
+        for (var i = 0; i < groups2.Count; i++) {
+          groups2[i] = groups2[i].Except(crossedGroup).ToList();
+          if (groups2[i].Count != 0) continue;
+          groups2.RemoveAt(i);
+          i--;
+        }
+        childGroup.Add(crossedGroup);
+        total += crossedGroup.Count;
+      } while (total < len);
+
+      var child = new LinearLinkage(len);
+      child.SetGroups(childGroup);
+      return child;
+    }
+
+    protected override LinearLinkage Cross(IRandom random, ItemArray<LinearLinkage> parents) {
+      if (parents.Length != 2) throw new InvalidOperationException(Name + ": Can only cross exactly two parents.");
+      return Apply(random, parents[0], parents[1]);
+    }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/LowestIndexFirstCrossover.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/LowestIndexFirstCrossover.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/LowestIndexFirstCrossover.cs	(revision 12285)
@@ -0,0 +1,65 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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 System.Linq;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  [Item("Lowest Index First Crossover", "The Lowest Index First Crossover (LIFX) is implemented as described in Ülker, Ö., Özcan, E., Korkmaz, E. E. 2007. Linear linkage encoding in grouping problems: applications on graph coloring and timetabling. In Practice and Theory of Automated Timetabling VI, pp. 347-363. Springer Berlin Heidelberg.")]
+  [StorableClass]
+  public sealed class LowestIndexFirstCrossover : LinearLinkageCrossover {
+
+    [StorableConstructor]
+    private LowestIndexFirstCrossover(bool deserializing) : base(deserializing) { }
+    private LowestIndexFirstCrossover(LowestIndexFirstCrossover original, Cloner cloner) : base(original, cloner) { }
+    public LowestIndexFirstCrossover() { }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new LowestIndexFirstCrossover(this, cloner);
+    }
+
+    public static LinearLinkage Apply(IRandom random, ItemArray<LinearLinkage> parents) {
+      var len = parents[0].Length;
+      var child = new LinearLinkage(len);
+      var childGroup = new List<HashSet<int>>();
+      var currentParent = random.Next(parents.Length);
+      var remaining = new HashSet<int>(Enumerable.Range(0, len));
+      do {
+        var i = remaining.Min();
+        var group = new HashSet<int>(parents[currentParent].GetGroupForward(i));
+        group.IntersectWith(remaining);
+        childGroup.Add(group);
+        remaining.ExceptWith(group);
+        currentParent = (currentParent + 1) % parents.Length;
+      } while (remaining.Count > 0);
+
+      child.SetGroups(childGroup);
+      return child;
+    }
+
+    protected override LinearLinkage Cross(IRandom random, ItemArray<LinearLinkage> parents) {
+      return Apply(random, parents);
+    }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/LowestIndexMaxCrossover.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/LowestIndexMaxCrossover.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Crossovers/LowestIndexMaxCrossover.cs	(revision 12285)
@@ -0,0 +1,68 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.Collections.Generic;
+using System.Linq;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+using HeuristicLab.Random;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  [Item("Lowest Index Max Crossover", "The Lowest Index Max Crossover (LIMX) is implemented as described in Ülker, Ö., Özcan, E., Korkmaz, E. E. 2007. Linear linkage encoding in grouping problems: applications on graph coloring and timetabling. In Practice and Theory of Automated Timetabling VI, pp. 347-363. Springer Berlin Heidelberg.")]
+  [StorableClass]
+  public sealed class LowestIndexMaxCrossover : LinearLinkageCrossover {
+
+    [StorableConstructor]
+    private LowestIndexMaxCrossover(bool deserializing) : base(deserializing) { }
+    private LowestIndexMaxCrossover(LowestIndexMaxCrossover original, Cloner cloner) : base(original, cloner) { }
+    public LowestIndexMaxCrossover() { }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new LowestIndexMaxCrossover(this, cloner);
+    }
+
+    public static LinearLinkage Apply(IRandom random, ItemArray<LinearLinkage> parents) {
+      var len = parents[0].Length;
+      var child = new LinearLinkage(len);
+      var childGroup = new List<HashSet<int>>();
+      var remaining = new HashSet<int>(Enumerable.Range(0, len));
+      do {
+        var i = remaining.Min();
+        var groups = parents.Select(x => new HashSet<int>(x.GetGroupForward(i))).ToList();
+        for (var k = 0; k < groups.Count; k++)
+          groups[k].IntersectWith(remaining);
+
+        var maxGroup = groups.Select((v, idx) => Tuple.Create(idx, v)).MaxItems(x => x.Item2.Count).SampleRandom(random).Item1;
+        childGroup.Add(groups[maxGroup]);
+        remaining.ExceptWith(groups[maxGroup]);
+      } while (remaining.Count > 0);
+
+      child.SetGroups(childGroup);
+      return child;
+    }
+
+    protected override LinearLinkage Cross(IRandom random, ItemArray<LinearLinkage> parents) {
+      return Apply(random, parents);
+    }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/HeuristicLab.Encodings.LinearLinkageEncoding-3.3.csproj
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/HeuristicLab.Encodings.LinearLinkageEncoding-3.3.csproj	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/HeuristicLab.Encodings.LinearLinkageEncoding-3.3.csproj	(revision 12285)
@@ -0,0 +1,146 @@
+﻿<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
+  <PropertyGroup>
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
+    <ProjectGuid>{BE698769-975A-429E-828C-72BB2B6182C8}</ProjectGuid>
+    <OutputType>Library</OutputType>
+    <AppDesignerFolder>Properties</AppDesignerFolder>
+    <RootNamespace>HeuristicLab.Encodings.LinearLinkageEncoding</RootNamespace>
+    <AssemblyName>HeuristicLab.Encodings.LinearLinkageEncoding-3.3</AssemblyName>
+    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
+    <FileAlignment>512</FileAlignment>
+  </PropertyGroup>
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
+    <DebugSymbols>true</DebugSymbols>
+    <DebugType>full</DebugType>
+    <Optimize>false</Optimize>
+    <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath>
+    <DefineConstants>DEBUG;TRACE</DefineConstants>
+    <ErrorReport>prompt</ErrorReport>
+    <WarningLevel>4</WarningLevel>
+  </PropertyGroup>
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
+    <DebugType>pdbonly</DebugType>
+    <Optimize>true</Optimize>
+    <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath>
+    <DefineConstants>TRACE</DefineConstants>
+    <ErrorReport>prompt</ErrorReport>
+    <WarningLevel>4</WarningLevel>
+  </PropertyGroup>
+  <PropertyGroup>
+    <SignAssembly>true</SignAssembly>
+  </PropertyGroup>
+  <PropertyGroup>
+    <AssemblyOriginatorKeyFile>HeuristicLab.snk</AssemblyOriginatorKeyFile>
+  </PropertyGroup>
+  <ItemGroup>
+    <Reference Include="HeuristicLab.Collections-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Collections-3.3.dll</HintPath>
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="HeuristicLab.Common-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Common-3.3.dll</HintPath>
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="HeuristicLab.Core-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Core-3.3.dll</HintPath>
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="HeuristicLab.Data-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Data-3.3.dll</HintPath>
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="HeuristicLab.Operators-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Operators-3.3.dll</HintPath>
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="HeuristicLab.Optimization-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Optimization-3.3.dll</HintPath>
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="HeuristicLab.Optimization.Operators-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Optimization.Operators-3.3.dll</HintPath>
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="HeuristicLab.Parameters-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Parameters-3.3.dll</HintPath>
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="HeuristicLab.Persistence-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Persistence-3.3.dll</HintPath>
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="HeuristicLab.PluginInfrastructure-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.PluginInfrastructure-3.3.dll</HintPath>
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="HeuristicLab.Random-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Random-3.3.dll</HintPath>
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="System" />
+    <Reference Include="System.Core" />
+    <Reference Include="System.Drawing" />
+    <Reference Include="System.Xml.Linq" />
+    <Reference Include="System.Data.DataSetExtensions" />
+    <Reference Include="Microsoft.CSharp" />
+    <Reference Include="System.Data" />
+    <Reference Include="System.Xml" />
+  </ItemGroup>
+  <ItemGroup>
+    <Compile Include="Creators\RandomLinearLinkageCreator.cs" />
+    <Compile Include="Crossovers\GreedyPartitionCrossover.cs" />
+    <Compile Include="Crossovers\GroupCrossover.cs" />
+    <Compile Include="Crossovers\LowestIndexMaxCrossover.cs" />
+    <Compile Include="Interfaces\ILinearLinkageCreator.cs" />
+    <Compile Include="LinearLinkage.cs" />
+    <Compile Include="LinearLinkageCreator.cs" />
+    <Compile Include="LinearLinkageEncoding.cs" />
+    <Compile Include="LinearLinkageManipulator.cs" />
+    <Compile Include="LinearLinkageCrossover.cs" />
+    <Compile Include="ShakingOperators\SplitGroupShakingOperator.cs" />
+    <Compile Include="ShakingOperators\SwapNShakingOperator.cs" />
+    <None Include="HeuristicLab.snk" />
+    <None Include="Plugin.cs.frame" />
+    <Compile Include="Crossovers\LargestGroupFirstCrossover.cs" />
+    <Compile Include="Crossovers\LowestIndexFirstCrossover.cs" />
+    <Compile Include="Interfaces\ILinearLinkageCrossover.cs" />
+    <Compile Include="Interfaces\ILinearLinkageManipulator.cs" />
+    <Compile Include="Interfaces\ILinearLinkageOperator.cs" />
+    <Compile Include="Interfaces\ILinearLinkageShakingOperator.cs" />
+    <Compile Include="Manipulators\SplitGroupManipulator.cs" />
+    <Compile Include="Manipulators\SwapNManipulator.cs" />
+    <Compile Include="Plugin.cs" />
+    <None Include="Properties\AssemblyInfo.cs.frame" />
+    <Compile Include="Properties\AssemblyInfo.cs" />
+  </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.
+  <Target Name="BeforeBuild">
+  </Target>
+  <Target Name="AfterBuild">
+  </Target>
+  -->
+</Project>
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageCreator.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageCreator.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageCreator.cs	(revision 12285)
@@ -0,0 +1,31 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.Core;
+using HeuristicLab.Data;
+using HeuristicLab.Optimization;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  public interface ILinearLinkageCreator : ISolutionCreator, ILinearLinkageOperator {
+    IValueLookupParameter<IntValue> LengthParameter { get; }
+    ILookupParameter<LinearLinkage> LLEParameter { get; }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageCrossover.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageCrossover.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageCrossover.cs	(revision 12285)
@@ -0,0 +1,9 @@
+﻿using HeuristicLab.Core;
+using HeuristicLab.Optimization;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  public interface ILinearLinkageCrossover : ICrossover, ILinearLinkageOperator {
+    ILookupParameter<LinearLinkage> ChildParameter { get; }
+    IScopeTreeLookupParameter<LinearLinkage> ParentsParameter { get; }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageManipulator.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageManipulator.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageManipulator.cs	(revision 12285)
@@ -0,0 +1,8 @@
+﻿using HeuristicLab.Core;
+using HeuristicLab.Optimization;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  public interface ILinearLinkageManipulator : IManipulator, ILinearLinkageOperator {
+    ILookupParameter<LinearLinkage> LLEParameter { get; }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageOperator.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageOperator.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageOperator.cs	(revision 12285)
@@ -0,0 +1,7 @@
+﻿
+using HeuristicLab.Core;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  public interface ILinearLinkageOperator : IOperator {
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageShakingOperator.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageShakingOperator.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Interfaces/ILinearLinkageShakingOperator.cs	(revision 12285)
@@ -0,0 +1,8 @@
+﻿using HeuristicLab.Core;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  public interface ILinearLinkageShakingOperator : ILinearLinkageOperator {
+    ILookupParameter<LinearLinkage> LLEParameter { get; }
+    ICheckedItemList<ILinearLinkageManipulator> Shakers { get; }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkage.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkage.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkage.cs	(revision 12285)
@@ -0,0 +1,220 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.Collections.Generic;
+using System.Linq;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Data;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  [Item("LinearLinkage", "Represents an LLE-e grouping of items.")]
+  [StorableClass]
+  public sealed class LinearLinkage : IntArray {
+
+    [StorableConstructor]
+    private LinearLinkage(bool deserializing) : base(deserializing) { }
+    private LinearLinkage(LinearLinkage original, Cloner cloner) : base(original, cloner) { }
+    public LinearLinkage() { }
+    public LinearLinkage(int length) : base(length) { }
+    public LinearLinkage(int[] elements) : base(elements) { }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new LinearLinkage(this, cloner);
+    }
+
+    /// <summary>
+    /// This method parses the encoded array and calculates the membership of each element to the groups.
+    /// It starts at the lowest element.
+    /// </summary>
+    /// <remarks>
+    /// Runtime complexity of this method is O(n) where n is the length of the array.
+    /// </remarks>
+    /// <returns>An enumeration of all groups.</returns>
+    public IEnumerable<List<int>> GetGroups() {
+      var len = array.Length;
+      var dict = new Dictionary<int, List<int>>();
+      for (var i = 0; i < len; i++) {
+        var end = array[i];
+        if (end < i || end >= len || array[end] != end)
+          throw new ArgumentException("Array is malformed and does not represent a valid LLE-e encoding.");
+        List<int> list;
+        if (!dict.TryGetValue(end, out list))
+          dict.Add(end, new List<int>() { i });
+        else list.Add(i);
+      }
+      return dict.Values;
+      /* This code implements group extraction from LLE forward encoding
+       * var len = array.Length;
+      var remaining = new HashSet<int>(Enumerable.Range(0, len));
+      // iterate from lowest to highest index
+      for (var i = 0; i < len; i++) {
+        if (!remaining.Contains(i)) continue;
+        var group = new List<int> { i };
+        remaining.Remove(i);
+        var next = array[i];
+        if (next != i) {
+          int prev;
+          do {
+            group.Add(next);
+            if (!remaining.Remove(next))
+              throw new ArgumentException("Array is malformed and does not represent a valid LLE forward encoding.");
+            prev = next;
+            next = array[next];
+          } while (next != prev);
+        }
+        yield return group;
+      }*/
+    }
+
+    /// <summary>
+    /// This method parses the encoded array and gathers all items that belong to the same group as element <paramref name="index"/>.
+    /// </summary>
+    /// <param name="index">The element whose group should be returned.</param>
+    /// <returns>The element at <paramref name="index"/> and all other elements in the same group.</returns>
+    public IEnumerable<int> GetGroup(int index) {
+      yield return index;
+      var gn = array[index];
+      for (var i = index + 1; i <= gn; i++) {
+        if (array[i] == gn) yield return i;
+      }
+      for (var i = index - 1; i >= 0; i++) {
+        if (array[i] == gn) yield return i;
+      }
+      /* This code implements group extraction from LLE forward encoding
+      // return current element
+      yield return index;
+      var next = array[index];
+      if (next == index) yield break;
+      int prev;
+      // return succeeding elements in group
+      do {
+        yield return next;
+        prev = next;
+        next = array[next];
+      } while (next != prev);
+      next = array[index];
+      // return preceding elements in group
+      for (prev = index - 1; prev >= 0; prev--) {
+        if (array[prev] != next) continue;
+        next = prev;
+        yield return next;
+      }*/
+    }
+
+    /// <summary>
+    /// This method parses the encoded array and gathers the item itself as well as subsequent items that belong to the same group as element <paramref name="index"/>.
+    /// </summary>
+    /// <param name="index">The element from which items in the group should be returned.</param>
+    /// <returns>The element at <paramref name="index"/> and all subsequent elements in the same group.</returns>
+    public IEnumerable<int> GetGroupForward(int index) {
+      yield return index;
+      var gn = array[index];
+      for (var i = index + 1; i <= gn; i++) {
+        if (array[i] == gn) yield return i;
+      }
+      /* This code implements group extraction from LLE forward encoding
+      yield return index;
+      var next = array[index];
+      if (next == index) yield break;
+      int prev;
+      do {
+        yield return next;
+        prev = next;
+        next = array[next];
+      } while (next != prev);*/
+    }
+
+    /// <summary>
+    /// This method translates an enumeration of groups into the underlying array representation.
+    /// </summary>
+    /// <remarks>
+    /// Throws an ArgumentException when there is an element assigned to multiple groups or elements that
+    /// are not assigned to any group.
+    /// </remarks>
+    /// <param name="grouping">The grouping of the elements, each element must be part of exactly one group.</param>
+    public void SetGroups(IEnumerable<IEnumerable<int>> grouping) {
+      var len = array.Length;
+      var remaining = new HashSet<int>(Enumerable.Range(0, len));
+      foreach (var group in grouping) {
+        var max = -1;
+        foreach (var g in group.OrderByDescending(x => x)) {
+          if (max < 0) max = g;
+          array[g] = max;
+          remaining.Remove(g);
+        }
+      }
+      if (remaining.Count > 0)
+        throw new ArgumentException(string.Format("Elements are not assigned a group: {0}", string.Join(", ", remaining)));
+      /* This code implements group setting for LLE forward encoding
+      var len = array.Length;
+      var remaining = new HashSet<int>(Enumerable.Range(0, len));
+      foreach (var group in grouping) {
+        var prev = -1;
+        foreach (var g in group.OrderBy(x => x)) {
+          if (prev >= 0) array[prev] = g;
+          prev = g;
+          if (!remaining.Remove(prev))
+            throw new ArgumentException(string.Format("Element {0} is contained at least twice.", prev), "grouping");
+        }
+        if (prev >= 0) array[prev] = prev;
+      }
+      if (remaining.Count > 0)
+        throw new ArgumentException(string.Format("Elements are not assigned a group: {0}", string.Join(", ", remaining)));
+       */
+    }
+
+    /// <summary>
+    /// Performs a check whether the array represents a valid LLE-e encoding.
+    /// </summary>
+    /// <remarks>
+    /// The runtime complexity of this method is O(n) where n is the length of the array.
+    /// </remarks>
+    /// <returns>True if the encoding is valid.</returns>
+    public bool Validate() {
+      var len = array.Length;
+      for (var i = 0; i < len; i++) {
+        var end = array[i];
+        if (end < i || end >= len || array[end] != end)
+          return false;
+      }
+      return true;
+      /* This code implements group setting for LLE forward encoding
+      var len = array.Length;
+      var remaining = new HashSet<int>(Enumerable.Range(0, len));
+      for (var i = 0; i < len; i++) {
+        if (!remaining.Contains(i)) continue;
+        remaining.Remove(i);
+        var next = array[i];
+        if (next == i) continue;
+        int prev;
+        do {
+          if (!remaining.Remove(next)) return false;
+          prev = next;
+          next = array[next];
+        } while (next != prev);
+      }
+      return remaining.Count == 0;*/
+    }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkageCreator.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkageCreator.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkageCreator.cs	(revision 12285)
@@ -0,0 +1,64 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.Optimization;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  [Item("Linear Linkage Creator", "Base class for LLE-e creators.")]
+  [StorableClass]
+  public abstract class LinearLinkageCreator : InstrumentedOperator, ILinearLinkageCreator, IStochasticOperator {
+
+    public ILookupParameter<IRandom> RandomParameter {
+      get { return (ILookupParameter<IRandom>)Parameters["Random"]; }
+    }
+
+    public ILookupParameter<LinearLinkage> LLEParameter {
+      get { return (ILookupParameter<LinearLinkage>)Parameters["LLE"]; }
+    }
+
+    public IValueLookupParameter<IntValue> LengthParameter {
+      get { return (IValueLookupParameter<IntValue>)Parameters["Length"]; }
+    }
+
+    [StorableConstructor]
+    protected LinearLinkageCreator(bool deserializing) : base(deserializing) { }
+    protected LinearLinkageCreator(LinearLinkageCreator original, Cloner cloner) : base(original, cloner) { }
+    protected LinearLinkageCreator() {
+      Parameters.Add(new LookupParameter<IRandom>("Random", "The random number generator to use."));
+      Parameters.Add(new LookupParameter<LinearLinkage>("LLE", "The encoding vector that is to be created.") { Hidden = false });
+      Parameters.Add(new ValueLookupParameter<IntValue>("Length", "The length of the vector that is to be created."));
+    }
+
+    public override IOperation InstrumentedApply() {
+      var random = RandomParameter.ActualValue;
+      LLEParameter.ActualValue = Create(random, LengthParameter.ActualValue.Value);
+      return base.InstrumentedApply();
+    }
+
+    protected abstract LinearLinkage Create(IRandom random, int length);
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkageCrossover.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkageCrossover.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkageCrossover.cs	(revision 12285)
@@ -0,0 +1,67 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.Operators;
+using HeuristicLab.Optimization;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  [Item("Linear Linkage Crossover", "Base class for linear linkage crossovers.")]
+  [StorableClass]
+  public abstract class LinearLinkageCrossover : InstrumentedOperator, ILinearLinkageCrossover, IStochasticOperator {
+
+    public ILookupParameter<IRandom> RandomParameter {
+      get { return (ILookupParameter<IRandom>)Parameters["Random"]; }
+    }
+
+    public ILookupParameter<LinearLinkage> ChildParameter {
+      get { return (ILookupParameter<LinearLinkage>)Parameters["Child"]; }
+    }
+
+    public IScopeTreeLookupParameter<LinearLinkage> ParentsParameter {
+      get { return (IScopeTreeLookupParameter<LinearLinkage>)Parameters["Parents"]; }
+    }
+
+    [StorableConstructor]
+    protected LinearLinkageCrossover(bool deserializing) : base(deserializing) { }
+    protected LinearLinkageCrossover(LinearLinkageCrossover original, Cloner cloner) : base(original, cloner) { }
+    protected LinearLinkageCrossover() {
+      Parameters.Add(new LookupParameter<IRandom>("Random", "The random number generator to use."));
+      Parameters.Add(new LookupParameter<LinearLinkage>("Child", "The child that is to be created."));
+      Parameters.Add(new ScopeTreeLookupParameter<LinearLinkage>("Parents", "The parents that are to be crossed."));
+    }
+
+    public override IOperation InstrumentedApply() {
+      var random = RandomParameter.ActualValue;
+      var parents = ParentsParameter.ActualValue;
+      if (parents == null) throw new InvalidOperationException(Name + ": Parents could not be found.");
+      var child = Cross(random, parents);
+      ChildParameter.ActualValue = child;
+      return base.InstrumentedApply();
+    }
+
+    protected abstract LinearLinkage Cross(IRandom random, ItemArray<LinearLinkage> parents);
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkageEncoding.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkageEncoding.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkageEncoding.cs	(revision 12285)
@@ -0,0 +1,167 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.Collections.Generic;
+using System.Linq;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Data;
+using HeuristicLab.Encodings.LinearLinkageEncoding.Creators;
+using HeuristicLab.Optimization;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+using HeuristicLab.PluginInfrastructure;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  [Item("Linear Linkage Encoding", "Describes a linear linkage (LLE-e) encoding.")]
+  [StorableClass]
+  public sealed class LinearLinkageEncoding : Encoding<ILinearLinkageCreator> {
+    #region encoding parameters
+    [Storable]
+    private IFixedValueParameter<IntValue> lengthParameter;
+    public IFixedValueParameter<IntValue> LengthParameter {
+      get { return lengthParameter; }
+      set {
+        if (value == null) throw new ArgumentNullException("Length parameter must not be null.");
+        if (value.Value == null) throw new ArgumentNullException("Length parameter value must not be null.");
+        if (lengthParameter == value) return;
+
+        if (lengthParameter != null) Parameters.Remove(lengthParameter);
+        lengthParameter = value;
+        Parameters.Add(lengthParameter);
+        OnLengthParameterChanged();
+      }
+    }
+    #endregion
+
+    public int Length {
+      get { return LengthParameter.Value.Value; }
+      set { LengthParameter.Value.Value = value; }
+    }
+
+    [StorableConstructor]
+    private LinearLinkageEncoding(bool deserializing) : base(deserializing) { }
+    [StorableHook(HookType.AfterDeserialization)]
+    private void AfterDeserialization() {
+      RegisterParameterEvents();
+      DiscoverOperators();
+    }
+
+    public override IDeepCloneable Clone(Cloner cloner) { return new LinearLinkageEncoding(this, cloner); }
+    private LinearLinkageEncoding(LinearLinkageEncoding original, Cloner cloner)
+      : base(original, cloner) {
+      lengthParameter = cloner.Clone(original.lengthParameter);
+      RegisterParameterEvents();
+    }
+
+
+    public LinearLinkageEncoding() : this("LLE", 10) { }
+    public LinearLinkageEncoding(string name) : this(name, 10) { }
+    public LinearLinkageEncoding(int length) : this("LLE", length) { }
+    public LinearLinkageEncoding(string name, int length)
+      : base(name) {
+      lengthParameter = new FixedValueParameter<IntValue>(Name + ".Length", new IntValue(length));
+      Parameters.Add(lengthParameter);
+
+      SolutionCreator = new RandomLinearLinkageCreator();
+      RegisterParameterEvents();
+      DiscoverOperators();
+    }
+
+    private void OnLengthParameterChanged() {
+      RegisterLengthParameterEvents();
+      ConfigureOperators(Operators);
+    }
+
+    private void RegisterParameterEvents() {
+      RegisterLengthParameterEvents();
+    }
+    private void RegisterLengthParameterEvents() {
+      LengthParameter.Value.ValueChanged += (o, s) => ConfigureOperators(Operators);
+    }
+
+    #region Operator Discovery
+    private static readonly IEnumerable<Type> encodingSpecificOperatorTypes;
+    static LinearLinkageEncoding() {
+      encodingSpecificOperatorTypes = new List<Type>() {
+          typeof (ILinearLinkageOperator),
+          typeof (ILinearLinkageCreator),
+          typeof (ILinearLinkageCrossover),
+          typeof (ILinearLinkageManipulator),
+          typeof (ILinearLinkageShakingOperator)
+      };
+    }
+    private void DiscoverOperators() {
+      var assembly = typeof(ILinearLinkageOperator).Assembly;
+      var discoveredTypes = ApplicationManager.Manager.GetTypes(encodingSpecificOperatorTypes, assembly, true, false, false);
+      var operators = discoveredTypes.Select(t => (IOperator)Activator.CreateInstance(t));
+      var newOperators = operators.Except(Operators, new TypeEqualityComparer<IOperator>()).ToList();
+
+      ConfigureOperators(newOperators);
+      foreach (var @operator in newOperators)
+        AddOperator(@operator);
+    }
+    #endregion
+
+    public override void ConfigureOperators(IEnumerable<IOperator> operators) {
+      ConfigureCreators(operators.OfType<ILinearLinkageCreator>());
+      ConfigureCrossovers(operators.OfType<ILinearLinkageCrossover>());
+      ConfigureManipulators(operators.OfType<ILinearLinkageManipulator>());
+      ConfigureShakingOperators(operators.OfType<ILinearLinkageShakingOperator>());
+    }
+
+    #region specific operator wiring
+    private void ConfigureCreators(IEnumerable<ILinearLinkageCreator> creators) {
+      foreach (var creator in creators) {
+        creator.LengthParameter.ActualName = LengthParameter.Name;
+        creator.LLEParameter.ActualName = Name;
+      }
+    }
+    private void ConfigureCrossovers(IEnumerable<ILinearLinkageCrossover> crossovers) {
+      foreach (var crossover in crossovers) {
+        crossover.ChildParameter.ActualName = Name;
+        crossover.ParentsParameter.ActualName = Name;
+      }
+    }
+    private void ConfigureManipulators(IEnumerable<ILinearLinkageManipulator> manipulators) {
+      foreach (var manipulator in manipulators) {
+        manipulator.LLEParameter.ActualName = Name;
+      }
+    }
+    private void ConfigureShakingOperators(IEnumerable<ILinearLinkageShakingOperator> shakingOperators) {
+      foreach (var shakingOperator in shakingOperators) {
+        shakingOperator.LLEParameter.ActualName = Name;
+      }
+    }
+    #endregion
+  }
+
+  public static class IndividualExtensionMethods {
+    public static LinearLinkage LinearLinkage(this Individual individual) {
+      var encoding = individual.GetEncoding<LinearLinkageEncoding>();
+      return individual.LinearLinkage(encoding.Name);
+    }
+    public static LinearLinkage LinearLinkage(this Individual individual, string name) {
+      return (LinearLinkage)individual[name];
+    }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkageManipulator.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkageManipulator.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/LinearLinkageManipulator.cs	(revision 12285)
@@ -0,0 +1,58 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.Operators;
+using HeuristicLab.Optimization;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  [Item("Linear Linkage Manipulator", "Base class for manipulators of the linear linkage encoding.")]
+  [StorableClass]
+  public abstract class LinearLinkageManipulator : InstrumentedOperator, ILinearLinkageManipulator, IStochasticOperator {
+    public ILookupParameter<IRandom> RandomParameter {
+      get { return (ILookupParameter<IRandom>)Parameters["Random"]; }
+    }
+
+    public ILookupParameter<LinearLinkage> LLEParameter {
+      get { return (ILookupParameter<LinearLinkage>)Parameters["LLE"]; }
+    }
+
+    [StorableConstructor]
+    protected LinearLinkageManipulator(bool deserializing) : base(deserializing) { }
+    protected LinearLinkageManipulator(LinearLinkageManipulator original, Cloner cloner) : base(original, cloner) { }
+    protected LinearLinkageManipulator() {
+      Parameters.Add(new LookupParameter<IRandom>("Random", "The random number generator to use."));
+      Parameters.Add(new LookupParameter<LinearLinkage>("LLE", "The encoding vector that is to be manipulated."));
+    }
+
+    public override IOperation InstrumentedApply() {
+      var random = RandomParameter.ActualValue;
+      var lle = LLEParameter.ActualValue;
+      Manipulate(random, lle);
+      return base.InstrumentedApply();
+    }
+
+    protected abstract void Manipulate(IRandom random, LinearLinkage lle);
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Manipulators/SplitGroupManipulator.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Manipulators/SplitGroupManipulator.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Manipulators/SplitGroupManipulator.cs	(revision 12285)
@@ -0,0 +1,91 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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 System.Linq;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Data;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+using HeuristicLab.Random;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  [Item("Split Group Manipulator", "Performs a maximum of N split operations on the groups. Groups may be split multiple times.")]
+  [StorableClass]
+  public sealed class SplitGroupManipulator : LinearLinkageManipulator {
+
+    public IValueLookupParameter<IntValue> NParameter {
+      get { return (IValueLookupParameter<IntValue>)Parameters["N"]; }
+    }
+
+    [StorableConstructor]
+    private SplitGroupManipulator(bool deserializing) : base(deserializing) { }
+    private SplitGroupManipulator(SplitGroupManipulator original, Cloner cloner) : base(original, cloner) { }
+    public SplitGroupManipulator() {
+      Parameters.Add(new ValueLookupParameter<IntValue>("N", "The number of groups to split.", new IntValue(1)));
+    }
+    public SplitGroupManipulator(int n)
+      : this() {
+      NParameter.Value = new IntValue(n);
+    }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new SplitGroupManipulator(this, cloner);
+    }
+
+    protected override void Manipulate(IRandom random, LinearLinkage lle) {
+      var N = NParameter.ActualValue.Value;
+
+      // shuffle here to avoid bias due to lowest-index-first encoding
+      var grouping = lle.GetGroups().Select(x => x.ToList()).Shuffle(random).ToList();
+      var groupsLargerOne = grouping.Count(x => x.Count > 1);
+      if (groupsLargerOne == 0) return;
+
+      var i = -1;
+      while (N > 0) {
+        i = (i + 1) % grouping.Count;
+        if (grouping[i].Count <= 1) continue;
+        if (random.NextDouble() < N / (double)groupsLargerOne) {
+          var idx = random.Next(1, grouping[i].Count);
+          // shuffle here to avoid a potential bias of grouping smaller and larger numbers together
+          var tmp = grouping[i].Shuffle(random);
+          var before = new List<int>();
+          var after = new List<int>();
+          foreach (var t in tmp) {
+            if (idx > 0) before.Add(t);
+            else after.Add(t);
+            idx--;
+          }
+          grouping.Add(before);
+          grouping.Add(after);
+          grouping.RemoveAt(i);
+          i--;
+          N--;
+          if (before.Count > 1 && after.Count > 1) groupsLargerOne++;
+          else if (before.Count == 1 && after.Count == 1) groupsLargerOne--;
+        }
+        if (groupsLargerOne == 0) break;
+      }
+      lle.SetGroups(grouping);
+    }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Manipulators/SwapNManipulator.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Manipulators/SwapNManipulator.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Manipulators/SwapNManipulator.cs	(revision 12285)
@@ -0,0 +1,96 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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 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.LinearLinkageEncoding {
+  [Item("Swap-n Manipulator", "")]
+  [StorableClass]
+  public sealed class SwapNManipulator : InstrumentedOperator, ILinearLinkageManipulator, IStochasticOperator {
+    public ILookupParameter<IRandom> RandomParameter {
+      get { return (ILookupParameter<IRandom>)Parameters["Random"]; }
+    }
+
+    public ILookupParameter<LinearLinkage> LLEParameter {
+      get { return (ILookupParameter<LinearLinkage>)Parameters["LLE"]; }
+    }
+
+    public IValueLookupParameter<IntValue> NParameter {
+      get { return (IValueLookupParameter<IntValue>)Parameters["N"]; }
+    }
+
+    [StorableConstructor]
+    private SwapNManipulator(bool deserializing) : base(deserializing) { }
+    private SwapNManipulator(SwapNManipulator original, Cloner cloner) : base(original, cloner) { }
+    public SwapNManipulator() {
+      Parameters.Add(new LookupParameter<IRandom>("Random", "The random number generator to use."));
+      Parameters.Add(new LookupParameter<LinearLinkage>("LLE", "The encoding vector that is to be manipulated."));
+      Parameters.Add(new ValueLookupParameter<IntValue>("N", "The number of swaps to perform.", new IntValue(2)));
+    }
+    public SwapNManipulator(int n)
+      : this() {
+      NParameter.Value = new IntValue(n);
+    }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new SwapNManipulator(this, cloner);
+    }
+
+    public override IOperation InstrumentedApply() {
+      var random = RandomParameter.ActualValue;
+      var vector = LLEParameter.ActualValue;
+      var N = NParameter.ActualValue.Value;
+
+      var grouping = vector.GetGroups().Select(x => x.ToList()).ToList();
+      if (grouping.Count == 1) return base.InstrumentedApply(); // nothing can be changed
+      var touched = new HashSet<int>();
+      var prevGroup = random.Next(grouping.Count);
+      var prevItem = random.Next(grouping[prevGroup].Count);
+      touched.Add(grouping[prevGroup][prevItem]);
+      for (var i = 0; i < N; i++) {
+        int nextGroup = -1, nextItem = -1, tries = 0;
+        do {
+          if (tries >= 100) break;
+          nextGroup = random.Next(grouping.Count);
+          nextItem = random.Next(grouping[nextGroup].Count);
+          tries++;
+        } while (nextGroup == prevGroup || touched.Contains(grouping[nextGroup][nextItem]));
+        if (tries >= 100) break;
+        var h = grouping[nextGroup][nextItem];
+        grouping[nextGroup][nextItem] = grouping[prevGroup][prevItem];
+        grouping[prevGroup][prevItem] = h;
+        touched.Add(h);
+        prevGroup = nextGroup;
+        prevItem = nextItem;
+      }
+      vector.SetGroups(grouping);
+      return base.InstrumentedApply();
+    }
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Plugin.cs.frame
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Plugin.cs.frame	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Plugin.cs.frame	(revision 12285)
@@ -0,0 +1,38 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.PluginInfrastructure;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  [Plugin("HeuristicLab.Encodings.LinearLinkageEncoding", "Provides data structures and operators for the linear linkage encoding (LLE-e).", "3.3.11.$WCREV$")]
+  [PluginFile("HeuristicLab.Encodings.LinearLinkageEncoding-3.3.dll", PluginFileType.Assembly)]
+  [PluginDependency("HeuristicLab.Collections", "3.3")]
+  [PluginDependency("HeuristicLab.Common", "3.3")]
+  [PluginDependency("HeuristicLab.Core", "3.3")]
+  [PluginDependency("HeuristicLab.Data", "3.3")]
+  [PluginDependency("HeuristicLab.Operators", "3.3")]
+  [PluginDependency("HeuristicLab.Optimization", "3.3")]
+  [PluginDependency("HeuristicLab.Optimization.Operators", "3.3")]
+  [PluginDependency("HeuristicLab.Parameters", "3.3")]
+  [PluginDependency("HeuristicLab.Persistence", "3.3")]
+  [PluginDependency("HeuristicLab.Random", "3.3")]
+  public class HeuristicLabEncodingsLinearLinkageEncodingPlugin : PluginBase { }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Properties/AssemblyInfo.cs.frame
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Properties/AssemblyInfo.cs.frame	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/Properties/AssemblyInfo.cs.frame	(revision 12285)
@@ -0,0 +1,56 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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.Reflection;
+using System.Runtime.InteropServices;
+
+// General Information about an assembly is controlled through the following 
+// set of attributes. Change these attribute values to modify the information
+// associated with an assembly.
+[assembly: AssemblyTitle("HeuristicLab.Encodings.LinearLinkage")]
+[assembly: AssemblyDescription("Linear linkage encoding (LLE) for HeuristicLab")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("HEAL")]
+[assembly: AssemblyProduct("HeuristicLab")]
+[assembly: AssemblyCopyright("(c) 2002-2015 HEAL")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Setting ComVisible to false makes the types in this assembly not visible 
+// to COM components.  If you need to access a type in this assembly from 
+// COM, set the ComVisible attribute to true on that type.
+[assembly: ComVisible(false)]
+
+// The following GUID is for the ID of the typelib if this project is exposed to COM
+[assembly: Guid("1fb5c9e2-42ac-441a-ae79-bfdf261a7262")]
+
+// Version information for an assembly consists of the following four values:
+//
+//      Major Version
+//      Minor Version 
+//      Build Number
+//      Revision
+//
+// You can specify all the values or you can default the Build and Revision Numbers 
+// by using the '*' as shown below:
+// [assembly: AssemblyVersion("1.0.*")]
+[assembly: AssemblyVersion("3.3.0.0")]
+[assembly: AssemblyFileVersion("3.3.11.$WCREV$")]
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/ShakingOperators/SplitGroupShakingOperator.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/ShakingOperators/SplitGroupShakingOperator.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/ShakingOperators/SplitGroupShakingOperator.cs	(revision 12285)
@@ -0,0 +1,86 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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 System.Linq;
+using HeuristicLab.Collections;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Optimization;
+using HeuristicLab.Optimization.Operators;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  /// <summary>
+  /// A shaking operator for VNS.
+  /// </summary>
+  [Item("Split Group Shaking Operator", "A shaking operator for VNS which uses split group manipulators to perform the shaking.")]
+  [StorableClass]
+  public class SplitGroupShakingOperator : ShakingOperator<ILinearLinkageManipulator>, IStochasticOperator, ILinearLinkageShakingOperator {
+
+    public ILookupParameter<IRandom> RandomParameter {
+      get { return (LookupParameter<IRandom>)Parameters["Random"]; }
+    }
+
+    public ILookupParameter<LinearLinkage> LLEParameter {
+      get { return (ILookupParameter<LinearLinkage>)Parameters["LLE"]; }
+    }
+
+    public ICheckedItemList<ILinearLinkageManipulator> Shakers {
+      get { return Operators; }
+    }
+
+    [StorableConstructor]
+    protected SplitGroupShakingOperator(bool deserializing) : base(deserializing) { }
+    protected SplitGroupShakingOperator(SplitGroupShakingOperator original, Cloner cloner) : base(original, cloner) { }
+    public SplitGroupShakingOperator()
+      : base() {
+      Parameters.Add(new LookupParameter<LinearLinkage>("LLE", "The encoding to shake."));
+      Parameters.Add(new LookupParameter<IRandom>("Random", "The random number generator that will be used for stochastic shaking operators."));
+      for (var i = 1; i < 6; i++) Operators.Add(new SplitGroupManipulator(i));
+    }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new SplitGroupShakingOperator(this, cloner);
+    }
+
+    #region Wiring of some parameters
+    protected override void Operators_ItemsAdded(object sender, CollectionItemsChangedEventArgs<IndexedItem<ILinearLinkageManipulator>> e) {
+      base.Operators_ItemsAdded(sender, e);
+      ParameterizeOperators(e.Items);
+    }
+
+    protected override void Operators_ItemsReplaced(object sender, CollectionItemsChangedEventArgs<IndexedItem<ILinearLinkageManipulator>> e) {
+      base.Operators_ItemsReplaced(sender, e);
+      ParameterizeOperators(e.Items);
+    }
+
+    private void ParameterizeOperators(IEnumerable<IndexedItem<ILinearLinkageManipulator>> items) {
+      if (!items.Any()) return;
+      foreach (var op in items.Select(x => x.Value).OfType<IStochasticOperator>())
+        op.RandomParameter.ActualName = RandomParameter.Name;
+      foreach (var op in items.Select(x => x.Value))
+        op.LLEParameter.ActualName = LLEParameter.Name;
+    }
+    #endregion
+  }
+}
Index: /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/ShakingOperators/SwapNShakingOperator.cs
===================================================================
--- /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/ShakingOperators/SwapNShakingOperator.cs	(revision 12285)
+++ /branches/LinearLinkage/HeuristicLab.Encodings.LinearLinkageEncoding/3.3/ShakingOperators/SwapNShakingOperator.cs	(revision 12285)
@@ -0,0 +1,86 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2015 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 System.Linq;
+using HeuristicLab.Collections;
+using HeuristicLab.Common;
+using HeuristicLab.Core;
+using HeuristicLab.Optimization;
+using HeuristicLab.Optimization.Operators;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+
+namespace HeuristicLab.Encodings.LinearLinkageEncoding {
+  /// <summary>
+  /// A shaking operator for VNS.
+  /// </summary>
+  [Item("SwapNShakingOperator", "A shaking operator for VNS which uses swap-n operators to perform the shaking.")]
+  [StorableClass]
+  public class SwapNShakingOperator : ShakingOperator<ILinearLinkageManipulator>, IStochasticOperator, ILinearLinkageShakingOperator {
+
+    public ILookupParameter<IRandom> RandomParameter {
+      get { return (LookupParameter<IRandom>)Parameters["Random"]; }
+    }
+
+    public ILookupParameter<LinearLinkage> LLEParameter {
+      get { return (ILookupParameter<LinearLinkage>)Parameters["LLE"]; }
+    }
+
+    public ICheckedItemList<ILinearLinkageManipulator> Shakers {
+      get { return Operators; }
+    }
+
+    [StorableConstructor]
+    protected SwapNShakingOperator(bool deserializing) : base(deserializing) { }
+    protected SwapNShakingOperator(SwapNShakingOperator original, Cloner cloner) : base(original, cloner) { }
+    public SwapNShakingOperator()
+      : base() {
+      Parameters.Add(new LookupParameter<LinearLinkage>("LLE", "The encoding to shake."));
+      Parameters.Add(new LookupParameter<IRandom>("Random", "The random number generator that will be used for stochastic shaking operators."));
+      for (var i = 2; i < 5; i++) Operators.Add(new SwapNManipulator(i));
+    }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new SwapNShakingOperator(this, cloner);
+    }
+
+    #region Wiring of some parameters
+    protected override void Operators_ItemsAdded(object sender, CollectionItemsChangedEventArgs<IndexedItem<ILinearLinkageManipulator>> e) {
+      base.Operators_ItemsAdded(sender, e);
+      ParameterizeOperators(e.Items);
+    }
+
+    protected override void Operators_ItemsReplaced(object sender, CollectionItemsChangedEventArgs<IndexedItem<ILinearLinkageManipulator>> e) {
+      base.Operators_ItemsReplaced(sender, e);
+      ParameterizeOperators(e.Items);
+    }
+
+    private void ParameterizeOperators(IEnumerable<IndexedItem<ILinearLinkageManipulator>> items) {
+      if (!items.Any()) return;
+      foreach (var op in items.Select(x => x.Value).OfType<IStochasticOperator>())
+        op.RandomParameter.ActualName = RandomParameter.Name;
+      foreach (var op in items.Select(x => x.Value))
+        op.LLEParameter.ActualName = LLEParameter.Name;
+    }
+    #endregion
+  }
+}
Index: /branches/LinearLinkage/LinearLinkage.sln
===================================================================
--- /branches/LinearLinkage/LinearLinkage.sln	(revision 12285)
+++ /branches/LinearLinkage/LinearLinkage.sln	(revision 12285)
@@ -0,0 +1,22 @@
+﻿
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio 2013
+VisualStudioVersion = 12.0.31101.0
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Encodings.LinearLinkageEncoding-3.3", "HeuristicLab.Encodings.LinearLinkageEncoding\3.3\HeuristicLab.Encodings.LinearLinkageEncoding-3.3.csproj", "{BE698769-975A-429E-828C-72BB2B6182C8}"
+EndProject
+Global
+	GlobalSection(SolutionConfigurationPlatforms) = preSolution
+		Debug|Any CPU = Debug|Any CPU
+		Release|Any CPU = Release|Any CPU
+	EndGlobalSection
+	GlobalSection(ProjectConfigurationPlatforms) = postSolution
+		{BE698769-975A-429E-828C-72BB2B6182C8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+		{BE698769-975A-429E-828C-72BB2B6182C8}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{BE698769-975A-429E-828C-72BB2B6182C8}.Release|Any CPU.ActiveCfg = Release|Any CPU
+		{BE698769-975A-429E-828C-72BB2B6182C8}.Release|Any CPU.Build.0 = Release|Any CPU
+	EndGlobalSection
+	GlobalSection(SolutionProperties) = preSolution
+		HideSolutionNode = FALSE
+	EndGlobalSection
+EndGlobal
Index: /branches/LinearLinkage/PreBuildEvent.cmd
===================================================================
--- /branches/LinearLinkage/PreBuildEvent.cmd	(revision 12285)
+++ /branches/LinearLinkage/PreBuildEvent.cmd	(revision 12285)
@@ -0,0 +1,11 @@
+IF EXIST "%ProjectDir%\Properties\AssemblyInfo.cs.frame" SubWCRev "%ProjectDir%\" "%ProjectDir%\Properties\AssemblyInfo.cs.frame" "%ProjectDir%\Properties\AssemblyInfo.cs"
+IF %ERRORLEVEL% NEQ 0 GOTO Error_Handling
+IF EXIST "%ProjectDir%\Plugin.cs.frame" SubWCRev "%ProjectDir%\" "%ProjectDir%\Plugin.cs.frame" "%ProjectDir%\Plugin.cs"
+IF %ERRORLEVEL% NEQ 0 GOTO Error_Handling
+GOTO Done
+
+:Error_Handling
+ECHO There was an error while running subwcrev. Please verify that the *.cs.frame files have been correctly converted to *.cs files, otherwise HeuristicLab won't build. 
+exit 0
+
+:Done
