Changeset 8086 for branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves
- Timestamp:
- 06/22/12 11:11:38 (13 years ago)
- Location:
- branches/ScatterSearch (trunk integration)
- Files:
-
- 2 edited
- 35 copied
Legend:
- Unmodified
- Added
- Removed
-
branches/ScatterSearch (trunk integration)
- Property svn:ignore
-
old new 20 20 bin 21 21 protoc.exe 22 _ReSharper.HeuristicLab 3.3 Tests
-
- Property svn:mergeinfo changed
- Property svn:ignore
-
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting
- Property svn:mergeinfo changed
/trunk/sources/HeuristicLab.Problems.VehicleRouting (added) merged: 7895,7900,7904,7906,7923,7934,7999,8006,8053
- Property svn:mergeinfo changed
-
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/AlbaMoveEvaluator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using System; 23 using System.Collections.Generic; 24 using System.Linq; 25 using System.Text; 26 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 22 using HeuristicLab.Common; 27 23 using HeuristicLab.Core; 28 24 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 29 using HeuristicLab. Common;25 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 30 26 31 27 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { 32 28 [Item("AlbaMoveEvaluator", "Evaluates an Alba VRP move.")] 33 29 [StorableClass] 34 public abstract class AlbaMoveEvaluator : VRPMoveEvaluator, IAlbaOperator {35 30 public abstract class AlbaMoveEvaluator : VRPMoveEvaluator, IAlbaOperator { 31 [StorableConstructor] 36 32 protected AlbaMoveEvaluator(bool deserializing) : base(deserializing) { } 37 33 38 34 public AlbaMoveEvaluator() 39 35 : base() { 40 36 } 41 37 42 43 44 38 protected AlbaMoveEvaluator(AlbaMoveEvaluator original, Cloner cloner) 39 : base(original, cloner) { 40 } 45 41 } 46 42 } -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/AlbaMoveGenerator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using System; 23 using System.Collections.Generic; 24 using System.Linq; 25 using System.Text; 26 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 22 using HeuristicLab.Common; 27 23 using HeuristicLab.Core; 28 24 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 25 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 29 26 using HeuristicLab.Problems.VehicleRouting.Interfaces; 30 using HeuristicLab.Common;31 27 32 28 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { 33 29 [Item("AlbaMoveGenerator", "Generates Alba VRP moves.")] 34 30 [StorableClass] 35 public abstract class AlbaMoveGenerator : VRPMoveGenerator, IAlbaOperator { 31 public abstract class AlbaMoveGenerator : VRPMoveGenerator, IAlbaOperator { 36 32 [StorableConstructor] 37 33 protected AlbaMoveGenerator(bool deserializing) : base(deserializing) { } … … 50 46 VRPToursParameter.ActualValue = AlbaEncoding.ConvertFrom(solution, ProblemInstance); 51 47 } 52 48 53 49 return base.Apply(); 54 50 } -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/AlbaMoveMaker.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using System; 23 using System.Collections.Generic; 24 using System.Linq; 25 using System.Text; 26 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 22 using HeuristicLab.Common; 27 23 using HeuristicLab.Core; 28 24 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 29 using HeuristicLab.Problems.VehicleRouting.Interfaces; 30 using HeuristicLab.Common; 25 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 31 26 32 27 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { 33 28 [Item("AlbaMoveMaker", "Makes an Alba VRP move.")] 34 29 [StorableClass] 35 public abstract class AlbaMoveMaker : VRPMoveMaker, IAlbaOperator { 30 public abstract class AlbaMoveMaker : VRPMoveMaker, IAlbaOperator { 36 31 [StorableConstructor] 37 32 protected AlbaMoveMaker(bool deserializing) : base(deserializing) { } -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/IntraRouteInversion/AlbaExhaustiveIntraRouteInversionMoveGenerator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using System; 22 using System.Collections.Generic; 23 using HeuristicLab.Common; 23 24 using HeuristicLab.Core; 24 25 using HeuristicLab.Optimization; 25 26 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Problems.VehicleRouting.Encodings.Alba;27 using HeuristicLab.Parameters;28 using System.Collections.Generic;29 27 using HeuristicLab.Problems.VehicleRouting.Interfaces; 30 using HeuristicLab.Common;31 28 32 29 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 54 51 int currentTourStart = 0; 55 52 int currentTourEnd = 0; 56 while (currentTourEnd != individual.Length) {53 while (currentTourEnd != individual.Length) { 57 54 currentTourEnd = currentTourStart; 58 while (individual[currentTourEnd] < problemInstance.Cities.Value && 55 while (individual[currentTourEnd] < problemInstance.Cities.Value && 59 56 currentTourEnd < individual.Length) { 60 57 currentTourEnd++; … … 63 60 int tourLength = currentTourEnd - currentTourStart; 64 61 if (tourLength >= 4) { 65 for (int i = 0; i <= tourLength - 4; i++ 62 for (int i = 0; i <= tourLength - 4; i++) { 66 63 for (int j = i + 2; j <= tourLength - 2; j++) { 67 64 AlbaIntraRouteInversionMove move = new AlbaIntraRouteInversionMove( 68 currentTourStart + i, 69 currentTourStart + j, 65 currentTourStart + i, 66 currentTourStart + j, 70 67 individual); 71 68 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/IntraRouteInversion/AlbaIntraRouteInversionEvaluator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using HeuristicLab.Common; 22 23 using HeuristicLab.Core; 23 using HeuristicLab.Encodings.PermutationEncoding;24 24 using HeuristicLab.Parameters; 25 25 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 26 using HeuristicLab.Problems.VehicleRouting.Encodings.Alba; 27 using HeuristicLab.Data;28 using HeuristicLab.Common;29 27 30 28 namespace HeuristicLab.Problems.VehicleRouting { … … 45 43 public AlbaIntraRouteInversionMoveEvaluator() 46 44 : base() { 47 45 Parameters.Add(new LookupParameter<AlbaIntraRouteInversionMove>("AlbaIntraRouteInversionMove", "The move to evaluate.")); 48 46 } 49 47 … … 61 59 62 60 UpdateEvaluation(newSolution); 63 } 61 } 64 62 } 65 63 } -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/IntraRouteInversion/AlbaIntraRouteInversionMove.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using HeuristicLab.Common; 22 23 using HeuristicLab.Core; 24 using HeuristicLab.Encodings.PermutationEncoding; 25 using HeuristicLab.Optimization; 23 26 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 24 using HeuristicLab.Encodings.PermutationEncoding;25 using HeuristicLab.Common;26 27 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 27 using HeuristicLab.Data;28 28 using HeuristicLab.Problems.VehicleRouting.Interfaces; 29 using HeuristicLab.Optimization;30 29 31 30 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 52 51 public AlbaIntraRouteInversionMove(int index1, int index2, AlbaEncoding permutation) 53 52 : base(index1, index2, null) { 54 55 53 this.Permutation = permutation.Clone() as AlbaEncoding; 54 } 56 55 57 56 public override IDeepCloneable Clone(Cloner cloner) { -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/IntraRouteInversion/AlbaIntraRouteInversionMoveGenerator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using System;22 using HeuristicLab.Common; 23 23 using HeuristicLab.Core; 24 24 using HeuristicLab.Optimization; 25 using HeuristicLab.Parameters; 25 26 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Problems.VehicleRouting.Encodings.Alba;27 using HeuristicLab.Parameters;28 using System.Collections.Generic;29 27 using HeuristicLab.Problems.VehicleRouting.Interfaces; 30 using HeuristicLab.Common;31 28 32 29 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 51 48 public AlbaIntraRouteInversionMoveGenerator() 52 49 : base() { 53 54 50 Parameters.Add(new LookupParameter<AlbaIntraRouteInversionMove>("AlbaIntraRouteInversionMove", "The moves that should be generated in subscopes.")); 51 Parameters.Add(new ScopeParameter("CurrentScope", "The current scope where the moves should be added as subscopes.")); 55 52 } 56 53 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/IntraRouteInversion/AlbaIntraRouteInversionMoveMaker.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using HeuristicLab.Common; 22 23 using HeuristicLab.Core; 23 using HeuristicLab.Data;24 using HeuristicLab.Operators;25 24 using HeuristicLab.Optimization; 26 25 using HeuristicLab.Parameters; 27 26 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 28 using HeuristicLab.Common;29 27 30 28 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/IntraRouteInversion/AlbaStochasticIntraRouteInversionMutliMoveGenerator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using System;22 using HeuristicLab.Common; 23 23 using HeuristicLab.Core; 24 using HeuristicLab.Data; 24 25 using HeuristicLab.Optimization; 26 using HeuristicLab.Parameters; 25 27 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Problems.VehicleRouting.Encodings.Alba; 27 using HeuristicLab.Parameters; 28 using System.Collections.Generic; 29 using HeuristicLab.Data; 28 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 30 29 using HeuristicLab.Problems.VehicleRouting.Interfaces; 31 using HeuristicLab.Common;32 using HeuristicLab.Problems.VehicleRouting.Encodings.General;33 30 34 31 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 44 41 get { return (IValueLookupParameter<IntValue>)Parameters["SampleSize"]; } 45 42 } 46 43 47 44 [StorableConstructor] 48 45 private AlbaStochasticIntraRouteInversionMultiMoveGenerator(bool deserializing) : base(deserializing) { } … … 50 47 public AlbaStochasticIntraRouteInversionMultiMoveGenerator() 51 48 : base() { 52 53 49 Parameters.Add(new LookupParameter<IRandom>("Random", "The random number generator.")); 50 Parameters.Add(new ValueLookupParameter<IntValue>("SampleSize", "The number of moves to generate.")); 54 51 } 55 52 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/IntraRouteInversion/AlbaStochasticIntraRouteInversionSingleMoveGenerator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using System; 22 using System.Collections.Generic; 23 using HeuristicLab.Common; 23 24 using HeuristicLab.Core; 24 25 using HeuristicLab.Optimization; 26 using HeuristicLab.Parameters; 25 27 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Problems.VehicleRouting.Encodings.Alba;27 using HeuristicLab.Parameters;28 using System.Collections.Generic;29 using HeuristicLab.Problems.VehicleRouting.Encodings.General;30 28 using HeuristicLab.Problems.VehicleRouting.Interfaces; 31 using HeuristicLab.Common;32 29 33 30 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 43 40 44 41 #endregion 45 42 46 43 public ILookupParameter<IRandom> RandomParameter { 47 44 get { return (ILookupParameter<IRandom>)Parameters["Random"]; } 48 45 } 49 46 50 47 [StorableConstructor] 51 48 private AlbaStochasticIntraRouteInversionSingleMoveGenerator(bool deserializing) : base(deserializing) { } … … 53 50 public AlbaStochasticIntraRouteInversionSingleMoveGenerator() 54 51 : base() { 55 52 Parameters.Add(new LookupParameter<IRandom>("Random", "The random number generator.")); 56 53 } 57 54 … … 103 100 104 101 AlbaIntraRouteInversionMove move = Apply(individual, problemInstance.Cities.Value, RandomParameter.ActualValue); 105 if (move != null)102 if (move != null) 106 103 moves.Add(move); 107 104 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/IntraRouteInversion/IAlbaIntraRouteInversionMoveOperator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 21 21 22 22 using HeuristicLab.Core; 23 using HeuristicLab.Encodings.PermutationEncoding;24 using HeuristicLab.Optimization;25 23 using HeuristicLab.Problems.VehicleRouting.Interfaces; 26 24 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/LambdaInterchange/AlbaExhaustiveLambdaInterchangeMoveGenerator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 21 21 22 22 using System; 23 using System.Collections.Generic; 24 using HeuristicLab.Common; 23 25 using HeuristicLab.Core; 24 26 using HeuristicLab.Optimization; 25 27 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Problems.VehicleRouting.Encodings.Alba;27 using HeuristicLab.Parameters;28 using System.Collections.Generic;29 28 using HeuristicLab.Problems.VehicleRouting.Interfaces; 30 using HeuristicLab.Common;31 29 32 30 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 61 59 for (int length1 = 0; length1 <= Math.Min(lambda, tour1.Stops.Count); length1++) { 62 60 for (int length2 = 0; length2 <= Math.Min(lambda, tour2.Stops.Count); length2++) { 63 if (length1 != 0 || length2 != 0) {61 if (length1 != 0 || length2 != 0) { 64 62 for (int index1 = 0; index1 < tour1.Stops.Count - length1 + 1; index1++) { 65 63 for (int index2 = 0; index2 < tour2.Stops.Count - length2 + 1; index2++) { 66 moves.Add(new AlbaLambdaInterchangeMove(tour1Index, index1, length1, 64 moves.Add(new AlbaLambdaInterchangeMove(tour1Index, index1, length1, 67 65 tour2Index, index2, length2, individual)); 68 66 } -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/LambdaInterchange/AlbaLambdaInterchangeMove.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using HeuristicLab.Common; 22 23 using HeuristicLab.Core; 24 using HeuristicLab.Optimization; 23 25 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 24 using HeuristicLab.Encodings.PermutationEncoding;25 using HeuristicLab.Common;26 using System.Collections.Generic;27 26 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 28 using HeuristicLab.Data;29 27 using HeuristicLab.Problems.VehicleRouting.Interfaces; 30 using HeuristicLab.Optimization;31 28 32 29 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { 33 30 [Item("AlbaLambdaInterchangeMove", "Item that describes a lambda move on a VRP representation. It is implemented as described in Alba, E. and Dorronsoro, B. (2004). Solving the Vehicle Routing Problem by Using Cellular Genetic Algorithms.")] 34 31 [StorableClass] 35 public class AlbaLambdaInterchangeMove : Item, IVRPMove {32 public class AlbaLambdaInterchangeMove : Item, IVRPMove { 36 33 [Storable] 37 34 public IVRPEncoding Individual { get; protected set; } 38 35 39 36 [Storable] 40 37 public int Tour1 { get; protected set; } … … 54 51 [Storable] 55 52 public int Length2 { get; protected set; } 56 57 public AlbaLambdaInterchangeMove(): base() { 53 54 public AlbaLambdaInterchangeMove() 55 : base() { 58 56 Tour1 = -1; 59 57 Position1 = -1; … … 67 65 } 68 66 69 public AlbaLambdaInterchangeMove(int tour1, int position1, int length1, 67 public AlbaLambdaInterchangeMove(int tour1, int position1, int length1, 70 68 int tour2, int position2, int length2, AlbaEncoding permutation) { 71 72 73 69 Tour1 = tour1; 70 Position1 = position1; 71 Length1 = length1; 74 72 75 76 77 73 Tour2 = tour2; 74 Position2 = position2; 75 Length2 = length2; 78 76 79 77 this.Individual = permutation.Clone() as AlbaEncoding; 80 78 } 81 79 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/LambdaInterchange/AlbaLambdaInterchangeMoveEvaluator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using HeuristicLab.Common; 22 23 using HeuristicLab.Core; 23 using HeuristicLab.Encodings.PermutationEncoding;24 24 using HeuristicLab.Parameters; 25 25 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 26 using HeuristicLab.Problems.VehicleRouting.Encodings.Alba; 27 using HeuristicLab.Data;28 using HeuristicLab.Common;29 27 30 28 namespace HeuristicLab.Problems.VehicleRouting { -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/LambdaInterchange/AlbaLambdaInterchangeMoveGenerator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using System;22 using HeuristicLab.Common; 23 23 using HeuristicLab.Core; 24 using HeuristicLab.Data; 24 25 using HeuristicLab.Optimization; 26 using HeuristicLab.Parameters; 25 27 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Problems.VehicleRouting.Encodings.Alba;27 using HeuristicLab.Parameters;28 using System.Collections.Generic;29 using HeuristicLab.Data;30 28 using HeuristicLab.Problems.VehicleRouting.Interfaces; 31 using HeuristicLab.Common;32 29 33 30 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 60 57 public AlbaLambdaInterchangeMoveGenerator() 61 58 : base() { 62 63 64 59 Parameters.Add(new LookupParameter<AlbaLambdaInterchangeMove>("AlbaLambdaInterchangeMove", "The moves that should be generated in subscopes.")); 60 Parameters.Add(new ScopeParameter("CurrentScope", "The current scope where the moves should be added as subscopes.")); 61 Parameters.Add(new ValueParameter<IntValue>("Lambda", "The lambda value.", new IntValue(1))); 65 62 } 66 63 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/LambdaInterchange/AlbaLambdaInterchangeMoveMaker.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using HeuristicLab.Common; 22 23 using HeuristicLab.Core; 23 using HeuristicLab.Data;24 using HeuristicLab.Operators;25 24 using HeuristicLab.Optimization; 26 25 using HeuristicLab.Parameters; 27 26 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 28 using System.Collections.Generic;29 using HeuristicLab.Common;30 27 31 28 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/LambdaInterchange/AlbaStochasticLambdaInterchangeMutliMoveGenerator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using System;22 using HeuristicLab.Common; 23 23 using HeuristicLab.Core; 24 using HeuristicLab.Data; 24 25 using HeuristicLab.Optimization; 26 using HeuristicLab.Parameters; 25 27 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Problems.VehicleRouting.Encodings.Alba; 27 using HeuristicLab.Parameters; 28 using System.Collections.Generic; 29 using HeuristicLab.Data; 28 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 30 29 using HeuristicLab.Problems.VehicleRouting.Interfaces; 31 using HeuristicLab.Common;32 using HeuristicLab.Problems.VehicleRouting.Encodings.General;33 30 34 31 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 44 41 get { return (IValueLookupParameter<IntValue>)Parameters["SampleSize"]; } 45 42 } 46 43 47 44 [StorableConstructor] 48 45 private AlbaStochasticLambdaInterchangeMultiMoveGenerator(bool deserializing) : base(deserializing) { } … … 50 47 public AlbaStochasticLambdaInterchangeMultiMoveGenerator() 51 48 : base() { 52 53 49 Parameters.Add(new LookupParameter<IRandom>("Random", "The random number generator.")); 50 Parameters.Add(new ValueLookupParameter<IntValue>("SampleSize", "The number of moves to generate.")); 54 51 } 55 52 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/LambdaInterchange/AlbaStochasticLambdaInterchangeSingleMoveGenerator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 21 21 22 22 using System; 23 using System.Collections.Generic; 24 using HeuristicLab.Common; 23 25 using HeuristicLab.Core; 24 26 using HeuristicLab.Optimization; 27 using HeuristicLab.Parameters; 25 28 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Problems.VehicleRouting.Encodings.Alba;27 using HeuristicLab.Parameters;28 using System.Collections.Generic;29 using HeuristicLab.Problems.VehicleRouting.Encodings.General;30 29 using HeuristicLab.Problems.VehicleRouting.Interfaces; 31 using HeuristicLab.Common;32 30 33 31 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 43 41 44 42 #endregion 45 43 46 44 public ILookupParameter<IRandom> RandomParameter { 47 45 get { return (ILookupParameter<IRandom>)Parameters["Random"]; } 48 46 } 49 47 50 48 [StorableConstructor] 51 49 private AlbaStochasticLambdaInterchangeSingleMoveGenerator(bool deserializing) : base(deserializing) { } … … 53 51 public AlbaStochasticLambdaInterchangeSingleMoveGenerator() 54 52 : base() { 55 53 Parameters.Add(new LookupParameter<IRandom>("Random", "The random number generator.")); 56 54 } 57 55 … … 96 94 97 95 AlbaLambdaInterchangeMove move = Apply(individual, problemInstance.Cities.Value, lambda, RandomParameter.ActualValue); 98 if (move != null)96 if (move != null) 99 97 moves.Add(move); 100 98 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/LambdaInterchange/IAlbaLambdaInterchangeMoveOperator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 21 21 22 22 using HeuristicLab.Core; 23 using HeuristicLab.Encodings.PermutationEncoding;24 using HeuristicLab.Optimization;25 23 using HeuristicLab.Problems.VehicleRouting.Interfaces; 26 24 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/ThreeOpt/AlbaStochasticTranslocationSingleMoveGenerator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using System.Collections.Generic;22 using HeuristicLab.Common; 23 23 using HeuristicLab.Core; 24 24 using HeuristicLab.Data; 25 25 using HeuristicLab.Encodings.PermutationEncoding; 26 using HeuristicLab.Optimization;27 using HeuristicLab.Parameters;28 26 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 29 27 using HeuristicLab.Problems.VehicleRouting.Interfaces; 30 using HeuristicLab.Problems.VehicleRouting.Encodings.General;31 using HeuristicLab.Common;32 28 33 29 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 37 33 [Storable] 38 34 private TranslocationMoveGenerator generator = new StochasticTranslocationSingleMoveGenerator(); 39 35 40 36 public ILookupParameter<TranslocationMove> TranslocationMoveParameter { 41 37 get { 42 38 return generator.TranslocationMoveParameter; 43 39 } 44 40 } -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/ThreeOpt/AlbaTranslocationMove.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using HeuristicLab.Common; 22 23 using HeuristicLab.Core; 24 using HeuristicLab.Encodings.PermutationEncoding; 25 using HeuristicLab.Optimization; 23 26 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 24 using HeuristicLab.Encodings.PermutationEncoding;25 using HeuristicLab.Common;26 using System.Collections.Generic;27 27 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 28 using HeuristicLab.Data;29 28 using HeuristicLab.Problems.VehicleRouting.Interfaces; 30 using HeuristicLab.Optimization;31 29 32 30 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { 33 31 [Item("AlbaTranslocationMove", "Item that describes a translocation move on a VRP representation. It is implemented as described in Alba, E. and Dorronsoro, B. (2004). Solving the Vehicle Routing Problem by Using Cellular Genetic Algorithms.")] 34 32 [StorableClass] 35 public class AlbaTranslocationMove : TranslocationMove, IVRPMove {33 public class AlbaTranslocationMove : TranslocationMove, IVRPMove { 36 34 public IVRPEncoding Individual { get { return Permutation as AlbaEncoding; } } 37 35 38 public AlbaTranslocationMove(int index1, int index2, int index3) :36 public AlbaTranslocationMove(int index1, int index2, int index3) : 39 37 base(index1, index2, index3) { 40 38 } 41 39 42 public AlbaTranslocationMove(int index1, int index2, int index3, AlbaEncoding individual) :43 base(index1, index2, index3, individual.Clone() as AlbaEncoding) {40 public AlbaTranslocationMove(int index1, int index2, int index3, AlbaEncoding individual) : 41 base(index1, index2, index3, individual.Clone() as AlbaEncoding) { 44 42 } 45 43 … … 53 51 protected AlbaTranslocationMove(AlbaTranslocationMove original, Cloner cloner) 54 52 : base(original, cloner) { 55 56 57 53 this.Index1 = original.Index1; 54 this.Index2 = original.Index2; 55 this.Index3 = original.Index3; 58 56 59 57 this.Permutation = cloner.Clone(Permutation) as AlbaEncoding; 60 58 } 61 59 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/ThreeOpt/AlbaTranslocationMoveEvaluator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using HeuristicLab.Common; 22 23 using HeuristicLab.Core; 23 24 using HeuristicLab.Encodings.PermutationEncoding; … … 25 26 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 27 using HeuristicLab.Problems.VehicleRouting.Encodings.Alba; 27 using HeuristicLab.Common;28 28 29 29 namespace HeuristicLab.Problems.VehicleRouting { -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/ThreeOpt/AlbaTranslocationMoveGenerator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using System.Collections.Generic;22 using HeuristicLab.Common; 23 23 using HeuristicLab.Core; 24 24 using HeuristicLab.Data; … … 28 28 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 29 29 using HeuristicLab.Problems.VehicleRouting.Interfaces; 30 using HeuristicLab.Common;31 30 32 31 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/ThreeOpt/AlbaTranslocationMoveHardTabuCriterion.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using HeuristicLab.Common; 22 23 using HeuristicLab.Core; 23 24 using HeuristicLab.Data; … … 27 28 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 28 29 using HeuristicLab.Problems.VehicleRouting.Interfaces; 29 using HeuristicLab.Common;30 30 31 31 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/ThreeOpt/AlbaTranslocationMoveMaker.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using HeuristicLab.Common; 22 23 using HeuristicLab.Core; 23 using HeuristicLab.Data;24 24 using HeuristicLab.Encodings.PermutationEncoding; 25 using HeuristicLab.Optimization;26 25 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 27 using HeuristicLab.Problems.VehicleRouting.Interfaces;28 using HeuristicLab.Common;29 26 30 27 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 61 58 private AlbaTranslocationMoveMaker(AlbaTranslocationMoveMaker original, Cloner cloner) 62 59 : base(original, cloner) { 63 60 moveMaker = cloner.Clone(original.moveMaker); 64 61 } 65 62 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/ThreeOpt/AlbaTranslocationMoveSoftTabuCriterion.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using HeuristicLab.Common; 22 23 using HeuristicLab.Core; 23 24 using HeuristicLab.Data; … … 27 28 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 28 29 using HeuristicLab.Problems.VehicleRouting.Interfaces; 29 using HeuristicLab.Common;30 30 31 31 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 78 78 private AlbaTranslocationMoveSoftTabuCriterion(AlbaTranslocationMoveSoftTabuCriterion original, Cloner cloner) 79 79 : base(original, cloner) { 80 80 tabuChecker = cloner.Clone(original.tabuChecker); 81 81 } 82 82 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/ThreeOpt/AlbaTranslocationMoveTabuMaker.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 20 20 #endregion 21 21 22 using HeuristicLab.Common; 22 23 using HeuristicLab.Core; 23 24 using HeuristicLab.Data; … … 27 28 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 28 29 using HeuristicLab.Problems.VehicleRouting.Interfaces; 29 using HeuristicLab.Common;30 30 31 31 namespace HeuristicLab.Problems.VehicleRouting.Encodings.Alba { … … 78 78 private AlbaTranslocationMoveTabuMaker(AlbaTranslocationMoveTabuMaker original, Cloner cloner) 79 79 : base(original, cloner) { 80 80 moveTabuMaker = cloner.Clone(original.moveTabuMaker); 81 81 } 82 82 -
branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Alba/Moves/ThreeOpt/IAlbaTranslocationMoveOperator.cs
r8052 r8086 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 0Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 22 22 using HeuristicLab.Core; 23 23 using HeuristicLab.Encodings.PermutationEncoding; 24 using HeuristicLab.Optimization;25 24 using HeuristicLab.Problems.VehicleRouting.Interfaces; 26 25
Note: See TracChangeset
for help on using the changeset viewer.