Index: branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Creators/IterativeInsertionCreator.cs
===================================================================
--- branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Creators/IterativeInsertionCreator.cs	(revision 6837)
+++ branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Creators/IterativeInsertionCreator.cs	(revision 6838)
@@ -101,4 +101,5 @@
 
       Tour currentTour = new Tour();
+      result.Tours.Add(currentTour);
 
       int j = random.Next(customers.Count);
@@ -114,5 +115,5 @@
         }
 
-        CVRPEvaluation evaluation = instance.Evaluate(currentTour) as CVRPEvaluation;
+        CVRPEvaluation evaluation = instance.EvaluateTour(currentTour, result) as CVRPEvaluation;
         if (result.Tours.Count < instance.Vehicles.Value && 
           ((adhereTimeWindows && !instance.Feasible(evaluation)) || ((!adhereTimeWindows) && evaluation.Overload > double.Epsilon))) {
@@ -132,6 +133,6 @@
       }
 
-      if (currentTour.Stops.Count > 0)
-        result.Tours.Add(currentTour);
+      if (currentTour.Stops.Count == 0)
+        result.Tours.Remove(currentTour);
 
       return result;
Index: branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Creators/PushForwardInsertionCreator.cs
===================================================================
--- branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Creators/PushForwardInsertionCreator.cs	(revision 6838)
+++ branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Creators/PushForwardInsertionCreator.cs	(revision 6838)
@@ -0,0 +1,229 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 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.Core;
+using HeuristicLab.Data;
+using HeuristicLab.Encodings.PermutationEncoding;
+using HeuristicLab.Optimization;
+using HeuristicLab.Parameters;
+using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
+using HeuristicLab.Common;
+using HeuristicLab.Problems.VehicleRouting.Interfaces;
+using HeuristicLab.Problems.VehicleRouting.ProblemInstances;
+using HeuristicLab.Problems.VehicleRouting.Variants;
+
+namespace HeuristicLab.Problems.VehicleRouting.Encodings.Potvin {
+  [Item("PushForwardInsertionCreator", "Creates a randomly initialized VRP solution.")]
+  [StorableClass]
+  public sealed class PushForwardInsertionCreator : PotvinCreator, IStochasticOperator {
+    #region IStochasticOperator Members
+    public ILookupParameter<IRandom> RandomParameter {
+      get { return (LookupParameter<IRandom>)Parameters["Random"]; }
+    }
+    #endregion
+
+    public IValueParameter<DoubleValue> Alpha {
+      get { return (IValueParameter<DoubleValue>)Parameters["Alpha"]; }
+    }
+    public IValueParameter<DoubleValue> AlphaVariance {
+      get { return (IValueParameter<DoubleValue>)Parameters["AlphaVariance"]; }
+    }
+    public IValueParameter<DoubleValue> Beta {
+      get { return (IValueParameter<DoubleValue>)Parameters["Beta"]; }
+    }
+    public IValueParameter<DoubleValue> BetaVariance {
+      get { return (IValueParameter<DoubleValue>)Parameters["BetaVariance"]; }
+    }
+    public IValueParameter<DoubleValue> Gamma {
+      get { return (IValueParameter<DoubleValue>)Parameters["Gamma"]; }
+    }
+    public IValueParameter<DoubleValue> GammaVariance {
+      get { return (IValueParameter<DoubleValue>)Parameters["GammaVariance"]; }
+    }
+
+    [StorableConstructor]
+    private PushForwardInsertionCreator(bool deserializing) : base(deserializing) { }
+
+    public PushForwardInsertionCreator()
+      : base() {
+      Parameters.Add(new LookupParameter<IRandom>("Random", "The pseudo random number generator."));
+      Parameters.Add(new ValueParameter<DoubleValue>("Alpha", "The alpha value.", new DoubleValue(0.7)));
+      Parameters.Add(new ValueParameter<DoubleValue>("AlphaVariance", "The alpha variance.", new DoubleValue(0.5)));
+      Parameters.Add(new ValueParameter<DoubleValue>("Beta", "The beta value.", new DoubleValue(0.1)));
+      Parameters.Add(new ValueParameter<DoubleValue>("BetaVariance", "The beta variance.", new DoubleValue(0.07)));
+      Parameters.Add(new ValueParameter<DoubleValue>("Gamma", "The gamma value.", new DoubleValue(0.2)));
+      Parameters.Add(new ValueParameter<DoubleValue>("GammaVariance", "The gamma variance.", new DoubleValue(0.14)));
+    }
+
+    public override IDeepCloneable Clone(Cloner cloner) {
+      return new PushForwardInsertionCreator(this, cloner);
+    }
+
+    private PushForwardInsertionCreator(PushForwardInsertionCreator original, Cloner cloner)
+      : base(original, cloner) {
+    }
+
+    // use the Box-Mueller transform in the polar form to generate a N(0,1) random variable out of two uniformly distributed random variables
+    private static double Gauss(IRandom random) {
+      double u = 0.0, v = 0.0, s = 0.0;
+      do {
+        u = (random.NextDouble() * 2) - 1;
+        v = (random.NextDouble() * 2) - 1;
+        s = Math.Sqrt(u * u + v * v);
+      } while (s < Double.Epsilon || s > 1);
+      return u * Math.Sqrt((-2.0 * Math.Log(s)) / s);
+    }
+
+    private static double N(double mu, double sigma, IRandom random) {
+      return mu + (sigma * Gauss(random)); // transform the random variable sampled from N(0,1) to N(mu,sigma)
+    }
+
+    private static double Distance(IVRPProblemInstance problemInstance, int start, int end) {
+      return problemInstance.GetDistance(start, end);
+    }
+
+    private static PotvinEncoding CreateSolution(IVRPProblemInstance problemInstance, IRandom random,
+      double alphaValue = 0.7, double betaValue = 0.1, double gammaValue = 0.2,
+      double alphaVariance = 0.5, double betaVariance = 0.07, double gammaVariance = 0.14) {
+      PotvinEncoding result = new PotvinEncoding(problemInstance);
+
+      double alpha, beta, gamma;
+      alpha = N(alphaValue, Math.Sqrt(alphaVariance), random);
+      beta = N(betaValue, Math.Sqrt(betaVariance), random);
+      gamma = N(gammaValue, Math.Sqrt(gammaVariance), random);
+
+      double x0 = problemInstance.Coordinates[0, 0];
+      double y0 = problemInstance.Coordinates[0, 1];
+      double distance = 0;
+      double cost = 0;
+      List<int> unroutedList = new List<int>();
+      List<double> costList = new List<double>();
+
+      IPickupAndDeliveryProblemInstance pdp = problemInstance as IPickupAndDeliveryProblemInstance;
+
+      /*-----------------------------------------------------------------------------
+       * generate cost list
+       *-----------------------------------------------------------------------------
+       */
+      for (int i = 1; i <= problemInstance.Cities.Value; i++) {
+        //only insert sources
+        if (pdp == null || problemInstance.Demand[i] >= 0) {
+          distance = Distance(problemInstance, i, 0);
+          if (problemInstance.Coordinates[i, 0] < x0) distance = -distance;
+
+          cost = -alpha * distance + // distance 0 <-> City[i]
+                 beta * (problemInstance as ITimeWindowedProblemInstance).DueTime[i] + // latest arrival time
+                 gamma * (Math.Asin((problemInstance.Coordinates[i, 1] - y0) / distance) / 360 * distance); // polar angle
+
+          int index = 0;
+          while (index < costList.Count && costList[index] < cost) index++;
+
+          costList.Insert(index, cost);
+
+          unroutedList.Insert(index, i);
+        }
+      }
+
+      double minimumCost = double.MaxValue;
+      int indexOfMinimumCost = -1;
+      int indexOfMinimumCost2 = -1;
+      int indexOfCustomer = -1;
+
+      Tour tour = new Tour();
+      result.Tours.Add(tour);
+      tour.Stops.Add(unroutedList[0]);
+      unroutedList.RemoveAt(0);
+
+      while (unroutedList.Count > 0) {
+        for (int c = 0; c < unroutedList.Count; c++) {
+          VRPEvaluation eval =
+          problemInstance.EvaluateTour(tour, result);
+          double originalCosts = eval.Quality;
+          int customer = unroutedList[c];
+
+          for (int i = 0; i <= tour.Stops.Count; i++) {
+            tour.Stops.Insert(i, customer);
+            eval = problemInstance.EvaluateTour(tour, result);
+            double tourCost = eval.Quality - originalCosts;
+
+            if (pdp != null) {
+              for (int j = i + 1; j <= tour.Stops.Count; j++) {
+                bool feasible;
+                cost = tourCost +
+                  problemInstance.GetInsertionCosts(eval, pdp.PickupDeliveryLocation[unroutedList[c]], 0, j, out feasible);
+                if (cost < minimumCost && feasible) {
+                  minimumCost = cost;
+                  indexOfMinimumCost = i;
+                  indexOfMinimumCost2 = j;
+                  indexOfCustomer = c;
+                }
+              }
+            } else {
+              cost = tourCost;
+              bool feasible = problemInstance.Feasible(eval);
+              if (cost < minimumCost && feasible) {
+                minimumCost = cost;
+                indexOfMinimumCost = i;
+                indexOfCustomer = c;
+              }
+            }
+
+            tour.Stops.RemoveAt(i);            
+          }
+        }
+
+        // insert customer if found
+        if (indexOfMinimumCost != -1) {
+          tour.Stops.Insert(indexOfMinimumCost, unroutedList[indexOfCustomer]);
+
+          if (pdp != null) {
+            tour.Stops.Insert(indexOfMinimumCost2, pdp.PickupDeliveryLocation[unroutedList[indexOfCustomer]]);
+          }
+
+          unroutedList.RemoveAt(indexOfCustomer);
+          costList.RemoveAt(indexOfCustomer);
+        } else { // no feasible customer found
+          tour = new Tour();
+          result.Tours.Add(tour);
+          tour.Stops.Add(unroutedList[0]);
+          unroutedList.RemoveAt(0);
+        }
+        // reset minimum		
+        minimumCost = double.MaxValue;
+        indexOfMinimumCost = -1;
+        indexOfMinimumCost2 = -1;
+        indexOfCustomer = -1;
+      }
+
+      return result;
+    }
+
+    public override IOperation Apply() {
+      VRPToursParameter.ActualValue = CreateSolution(ProblemInstance, RandomParameter.ActualValue,
+        Alpha.Value.Value, Beta.Value.Value, Gamma.Value.Value,
+        AlphaVariance.Value.Value, BetaVariance.Value.Value, GammaVariance.Value.Value);
+
+      return base.Apply();
+    }
+  }
+}
Index: branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Crossovers/PotvinInsertionBasedCrossover.cs
===================================================================
--- branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Crossovers/PotvinInsertionBasedCrossover.cs	(revision 6837)
+++ branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Crossovers/PotvinInsertionBasedCrossover.cs	(revision 6838)
@@ -149,4 +149,5 @@
 
     private bool FindRouteInsertionPlace(
+      PotvinEncoding individual,
       Tour tour,
       int city, bool allowInfeasible, out int place) {
@@ -162,5 +163,5 @@
 
       double minDetour = 0;
-      VRPEvaluation eval = ProblemInstance.Evaluate(tour);
+      VRPEvaluation eval = ProblemInstance.EvaluateTour(tour, individual);
       bool originalFeasible = ProblemInstance.Feasible(eval);
 
@@ -220,4 +221,5 @@
 
         Tour childTour = new Tour();
+        child.Tours.Add(childTour);
         childTour.Stops.AddRange(r1.Stops);
 
@@ -233,7 +235,4 @@
 
         while (count < maxCount && R2.Count != 0) {
-          PotvinEncoding newChild = child.Clone() as PotvinEncoding;
-          newChild.Tours.Add(childTour);
-
           int index = random.Next(R2.Count);
           int city = R2[index];
@@ -241,5 +240,5 @@
 
           int place = -1;
-          bool found = FindRouteInsertionPlace(childTour, city, allowInfeasible, out place); 
+          bool found = FindRouteInsertionPlace(child, childTour, city, allowInfeasible, out place); 
           if (found) {
             childTour.Stops.Insert(place, city);
@@ -253,5 +252,4 @@
         }
 
-        child.Tours.Add(childTour);
         Repair(random, child, childTour, ProblemInstance, allowInfeasible);
       }
Index: branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Manipulators/PotvinLocalSearchManipulator.cs
===================================================================
--- branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Manipulators/PotvinLocalSearchManipulator.cs	(revision 6837)
+++ branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Manipulators/PotvinLocalSearchManipulator.cs	(revision 6838)
@@ -69,5 +69,5 @@
           distance = individual.GetTourLength(individual.Tours[currentTour]);
           individual.Tours[currentTour].Stops.InsertRange(currentCity, toBeDeleted);
-          if (ProblemInstance.Feasible(individual.Tours[currentTour])) {
+          if (ProblemInstance.TourFeasible(individual.Tours[currentTour], individual)) {
             double lengthIncrease =
               individual.GetTourLength(individual.Tours[currentTour]) - distance;
Index: branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Manipulators/PotvinTwoLevelExchangeManipulator.cs
===================================================================
--- branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Manipulators/PotvinTwoLevelExchangeManipulator.cs	(revision 6837)
+++ branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Manipulators/PotvinTwoLevelExchangeManipulator.cs	(revision 6838)
@@ -66,5 +66,5 @@
               route1.Stops.RemoveAt(customer1Position);
 
-              if (ProblemInstance.Feasible(tour)) {
+              if (ProblemInstance.TourFeasible(tour, individual)) {
                 int routeIdx, place;
                 if (FindInsertionPlace(individual,
Index: branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/PickupDelivery/PDRearrange/PotvinPDRearrangeMoveMaker.cs
===================================================================
--- branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/PickupDelivery/PDRearrange/PotvinPDRearrangeMoveMaker.cs	(revision 6837)
+++ branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/PickupDelivery/PDRearrange/PotvinPDRearrangeMoveMaker.cs	(revision 6838)
@@ -61,5 +61,5 @@
     public static void InsertPair(PotvinEncoding solution, Tour tour, int source, int target, IVRPProblemInstance problemInstance, int positionToAvoid = -1, int positionToAvoid2 = -1) {
       int stops = tour.Stops.Count;
-      VRPEvaluation eval = problemInstance.Evaluate(tour);
+      VRPEvaluation eval = problemInstance.EvaluateTour(tour, solution);
       double minCosts = double.MaxValue;
       int sourceLocation = -1;
@@ -68,5 +68,5 @@
       for (int i = 0; i <= stops; i++) {
         tour.Stops.Insert(i, source);
-        VRPEvaluation tourEval = problemInstance.Evaluate(tour);
+        VRPEvaluation tourEval = problemInstance.EvaluateTour(tour, solution);
         double sourceCosts = tourEval.Quality - eval.Quality;
 
Index: branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/PotvinEncoding.cs
===================================================================
--- branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/PotvinEncoding.cs	(revision 6837)
+++ branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/PotvinEncoding.cs	(revision 6838)
@@ -82,5 +82,5 @@
       double minQuality = -1;
 
-      VRPEvaluation eval = ProblemInstance.Evaluate(tour);
+      VRPEvaluation eval = ProblemInstance.EvaluateTour(tour, this);
 
       for (int i = 0; i <= tour.Stops.Count; i++) {
