- Timestamp:
- 06/19/12 13:17:29 (12 years ago)
- Location:
- trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/GVR
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/GVR/Crossovers/GVRCrossover.cs
r6851 r8053 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; 23 using HeuristicLab.Common; 22 24 using HeuristicLab.Core; 23 using HeuristicLab. Encodings.PermutationEncoding;25 using HeuristicLab.Optimization; 24 26 using HeuristicLab.Parameters; 25 27 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Data;27 using HeuristicLab.Optimization;28 using System.Collections.Generic;29 28 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.GVR { … … 61 59 int length = random.Next(1, tour.Stops.Count - breakPoint1 + 1); 62 60 List<int> subroute = tour.Stops.GetRange(breakPoint1, length); 63 61 64 62 //remove duplicates 65 63 List<Tour> toBeRemoved = new List<Tour>(); … … 104 102 return child; 105 103 } 106 104 107 105 public override IOperation Apply() { 108 106 ItemArray<IVRPEncoding> parents = new ItemArray<IVRPEncoding>(ParentsParameter.ActualValue.Length); -
trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/GVR/GVREncoding.cs
r7906 r8053 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 23 using HeuristicLab.Common; 23 24 using HeuristicLab.Core; 24 25 using HeuristicLab.Data; 25 using HeuristicLab.Encodings.PermutationEncoding;26 26 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 27 using System.Drawing;28 using System.Collections.Generic;29 27 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 30 28 using HeuristicLab.Problems.VehicleRouting.Interfaces; … … 36 34 public class GVREncoding : TourEncoding { 37 35 public override List<Tour> GetTours() { 38 List<Tour> tours = new List<Tour>(); 36 List<Tour> tours = new List<Tour>(); 39 37 40 38 foreach (Tour tour in base.Tours) { … … 73 71 74 72 tours.Remove(tour); 75 } 73 } 76 74 77 75 return tours; 78 76 } 79 77 80 78 public GVREncoding(IVRPProblemInstance problemInstance) 81 79 : base(problemInstance) { -
trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/GVR/IGVROperator.cs
r4379 r8053 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.Interfaces;27 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;28 using HeuristicLab.Core;29 using HeuristicLab.Parameters;30 using HeuristicLab.Operators;31 22 using HeuristicLab.Problems.VehicleRouting.Variants; 32 23 33 24 namespace HeuristicLab.Problems.VehicleRouting.Encodings.GVR { 34 public interface IGVROperator : 35 ISingleDepotOperator, IHomogenousCapacitatedOperator, ITimeWindowedOperator { 25 public interface IGVROperator : 26 ISingleDepotOperator, IHomogenousCapacitatedOperator, ITimeWindowedOperator { 36 27 } 37 28 } -
trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/GVR/Manipulators/GVRDisplacementManipulator.cs
r4752 r8053 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.Core;23 using HeuristicLab.Encodings.PermutationEncoding;24 using HeuristicLab.Parameters;25 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;26 using HeuristicLab.Data;27 22 using System.Collections.Generic; 28 23 using HeuristicLab.Common; 24 using HeuristicLab.Core; 25 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 29 26 30 27 namespace HeuristicLab.Problems.VehicleRouting.Encodings.GVR { … … 56 53 //with a probability of 1/(2*V) create a new tour, else insert at another position 57 54 if (individual.GetTours().Count > 0 && 58 individual.GetTours().Count < ProblemInstance.Vehicles.Value && 55 individual.GetTours().Count < ProblemInstance.Vehicles.Value && 59 56 random.Next(individual.GetTours().Count * 2) == 0) { 60 57 Tour newTour = new Tour(); -
trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/GVR/Manipulators/GVRInsertionManipulator.cs
r4752 r8053 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 using HeuristicLab.Parameters;25 24 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Data;27 using HeuristicLab.Common;28 25 29 26 namespace HeuristicLab.Problems.VehicleRouting.Encodings.GVR { … … 55 52 56 53 //with a probability of 1/(2*V) create a new tour, else insert at another position 57 if (individual.GetTours().Count > 0 && 58 individual.GetTours().Count < ProblemInstance.Vehicles.Value && 54 if (individual.GetTours().Count > 0 && 55 individual.GetTours().Count < ProblemInstance.Vehicles.Value && 59 56 random.Next(individual.GetTours().Count * 2) == 0) { 60 57 Tour newTour = new Tour(); 61 58 newTour.Stops.Add(customer); 62 59 63 60 individual.Tours.Add(newTour); 64 61 } else { -
trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/GVR/Manipulators/GVRInversionManipulator.cs
r4752 r8053 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 using HeuristicLab.Parameters;25 24 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Data;27 using HeuristicLab.Common;28 25 29 26 namespace HeuristicLab.Problems.VehicleRouting.Encodings.GVR { -
trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/GVR/Manipulators/GVRManipulator.cs
r4752 r8053 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 using HeuristicLab.Optimization; 24 25 using HeuristicLab.Parameters; 25 26 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Data;27 using HeuristicLab.Optimization;28 27 using HeuristicLab.Problems.VehicleRouting.Encodings.General; 29 28 using HeuristicLab.Problems.VehicleRouting.Interfaces; 30 using HeuristicLab.Common;31 29 32 30 namespace HeuristicLab.Problems.VehicleRouting.Encodings.GVR { … … 50 48 51 49 protected abstract void Manipulate(IRandom random, GVREncoding individual); 52 50 53 51 public override IOperation Apply() { 54 52 IVRPEncoding solution = VRPToursParameter.ActualValue; -
trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/GVR/Manipulators/GVRSwapManipulator.cs
r4752 r8053 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 using HeuristicLab.Parameters;25 24 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 26 using HeuristicLab.Data;27 using HeuristicLab.Common;28 25 29 26 namespace HeuristicLab.Problems.VehicleRouting.Encodings.GVR {
Note: See TracChangeset
for help on using the changeset viewer.