Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
06/19/12 13:17:29 (12 years ago)
Author:
ascheibe
Message:

#1722 fixed more licensing information and source formatting

Location:
trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/TwoOptStar
Files:
11 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/TwoOptStar/IPotvinTwoOptStarMoveOperator.cs

    r7865 r8053  
    11#region License Information
    22/* HeuristicLab
    3  * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    44 *
    55 * This file is part of HeuristicLab.
     
    2121
    2222using HeuristicLab.Core;
    23 using HeuristicLab.Encodings.PermutationEncoding;
    24 using HeuristicLab.Optimization;
    2523using HeuristicLab.Problems.VehicleRouting.Interfaces;
    2624
  • trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/TwoOptStar/PotvinTwoOptStarExhaustiveMoveGenerator.cs

    r7906 r8053  
    11#region License Information
    22/* HeuristicLab
    3  * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    44 *
    55 * This file is part of HeuristicLab.
     
    2020#endregion
    2121
    22 using System;
     22using System.Collections.Generic;
     23using HeuristicLab.Common;
    2324using HeuristicLab.Core;
    2425using HeuristicLab.Optimization;
    2526using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    26 using HeuristicLab.Parameters;
    27 using System.Collections.Generic;
    2827using HeuristicLab.Problems.VehicleRouting.Interfaces;
    29 using HeuristicLab.Common;
    3028
    3129namespace HeuristicLab.Problems.VehicleRouting.Encodings.Potvin {
     
    5553          for (int index1 = 0; index1 <= individual.Tours[tour1].Stops.Count; index1++) {
    5654            for (int index2 = 0; index2 <= individual.Tours[tour2].Stops.Count; index2++) {
    57               if ((index1 != individual.Tours[tour1].Stops.Count || index2 != individual.Tours[tour2].Stops.Count) && 
     55              if ((index1 != individual.Tours[tour1].Stops.Count || index2 != individual.Tours[tour2].Stops.Count) &&
    5856                  (index1 != 0 || index2 != 0))
    5957                result.Add(new PotvinTwoOptStarMove(tour1, index1, tour2, index2, individual));
  • trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/TwoOptStar/PotvinTwoOptStarMove.cs

    r7906 r8053  
    11#region License Information
    22/* HeuristicLab
    3  * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    44 *
    55 * This file is part of HeuristicLab.
     
    2020#endregion
    2121
     22using HeuristicLab.Common;
    2223using HeuristicLab.Core;
     24using HeuristicLab.Optimization;
    2325using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    24 using HeuristicLab.Encodings.PermutationEncoding;
    25 using HeuristicLab.Common;
    26 using System.Collections.Generic;
    2726using HeuristicLab.Problems.VehicleRouting.Encodings.General;
    28 using HeuristicLab.Data;
    2927using HeuristicLab.Problems.VehicleRouting.Interfaces;
    30 using HeuristicLab.Optimization;
    3128
    3229namespace HeuristicLab.Problems.VehicleRouting.Encodings.Potvin {
    3330  [Item("PotvinTwoOptStarMove", "Item that describes a two opt star move on a VRP representation.")]
    3431  [StorableClass]
    35   public class PotvinTwoOptStarMove: Item, IVRPMove {
     32  public class PotvinTwoOptStarMove : Item, IVRPMove {
    3633    [Storable]
    3734    public IVRPEncoding Individual { get; protected set; }
    38    
     35
    3936    [Storable]
    4037    public int Tour1 { get; protected set; }
     
    4845    [Storable]
    4946    public int X2 { get; protected set; }
    50    
    51     public PotvinTwoOptStarMove(): base() {
     47
     48    public PotvinTwoOptStarMove()
     49      : base() {
    5250      X1 = -1;
    5351      Tour1 = -1;
  • trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/TwoOptStar/PotvinTwoOptStarMoveAttribute.cs

    r7865 r8053  
    11#region License Information
    22/* HeuristicLab
    3  * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    44 *
    55 * This file is part of HeuristicLab.
     
    4545    protected PotvinTwoOptStarMoveAttribute(PotvinTwoOptStarMoveAttribute original, Cloner cloner)
    4646      : base(original, cloner) {
    47         this.Tour = original.Tour;
    48         this.City = original.City;
    49         this.Distance = original.Distance;
    50         this.Overload = original.Overload;
    51         this.Tardiness = original.Tardiness;
     47      this.Tour = original.Tour;
     48      this.City = original.City;
     49      this.Distance = original.Distance;
     50      this.Overload = original.Overload;
     51      this.Tardiness = original.Tardiness;
    5252    }
    53     public PotvinTwoOptStarMoveAttribute(double moveQuality, int tour, int city, 
     53    public PotvinTwoOptStarMoveAttribute(double moveQuality, int tour, int city,
    5454      double distance, double overload, double tardiness)
    5555      : base(moveQuality) {
  • trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/TwoOptStar/PotvinTwoOptStarMoveEvaluator.cs

    r7865 r8053  
    11#region License Information
    22/* HeuristicLab
    3  * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    44 *
    55 * This file is part of HeuristicLab.
     
    2020#endregion
    2121
     22using HeuristicLab.Common;
    2223using HeuristicLab.Core;
    23 using HeuristicLab.Encodings.PermutationEncoding;
    2424using HeuristicLab.Parameters;
    2525using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    26 using HeuristicLab.Data;
    27 using HeuristicLab.Common;
    28 using HeuristicLab.Optimization;
    2926
    3027namespace HeuristicLab.Problems.VehicleRouting.Encodings.Potvin {
     
    4441    public PotvinTwoOptStarMoveEvaluator()
    4542      : base() {
    46        Parameters.Add(new LookupParameter<PotvinTwoOptStarMove>("PotvinTwoOptStarMove", "The move that should be evaluated."));
     43      Parameters.Add(new LookupParameter<PotvinTwoOptStarMove>("PotvinTwoOptStarMove", "The move that should be evaluated."));
    4744    }
    4845
     
    6259
    6360      UpdateEvaluation(newSolution);
    64     } 
     61    }
    6562  }
    6663}
  • trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/TwoOptStar/PotvinTwoOptStarMoveGenerator.cs

    r7865 r8053  
    11#region License Information
    22/* HeuristicLab
    3  * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    44 *
    55 * This file is part of HeuristicLab.
     
    2020#endregion
    2121
    22 using System;
     22using HeuristicLab.Common;
    2323using HeuristicLab.Core;
    24 using HeuristicLab.Optimization;
     24using HeuristicLab.Parameters;
    2525using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    26 using HeuristicLab.Parameters;
    27 using System.Collections.Generic;
    2826using HeuristicLab.Problems.VehicleRouting.Interfaces;
    29 using HeuristicLab.Common;
    3027
    3128namespace HeuristicLab.Problems.VehicleRouting.Encodings.Potvin {
     
    5047    public PotvinTwoOptStarMoveGenerator()
    5148      : base() {
    52         Parameters.Add(new LookupParameter<PotvinTwoOptStarMove>("PotvinTwoOptStarMove", "The moves that should be generated in subscopes."));
    53         Parameters.Add(new ScopeParameter("CurrentScope", "The current scope where the moves should be added as subscopes."));
     49      Parameters.Add(new LookupParameter<PotvinTwoOptStarMove>("PotvinTwoOptStarMove", "The moves that should be generated in subscopes."));
     50      Parameters.Add(new ScopeParameter("CurrentScope", "The current scope where the moves should be added as subscopes."));
    5451    }
    5552
  • trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/TwoOptStar/PotvinTwoOptStarMoveMaker.cs

    r7906 r8053  
    11#region License Information
    22/* HeuristicLab
    3  * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    44 *
    55 * This file is part of HeuristicLab.
     
    2020#endregion
    2121
     22using System.Collections.Generic;
     23using HeuristicLab.Common;
    2224using HeuristicLab.Core;
    23 using HeuristicLab.Data;
    24 using HeuristicLab.Operators;
    2525using HeuristicLab.Optimization;
    2626using HeuristicLab.Parameters;
    2727using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    28 using HeuristicLab.Common;
    29 using HeuristicLab.Problems.VehicleRouting.ProblemInstances;
    3028using HeuristicLab.Problems.VehicleRouting.Interfaces;
    31 using HeuristicLab.Problems.VehicleRouting.Variants;
    32 using System.Collections.Generic;
    3329
    3430namespace HeuristicLab.Problems.VehicleRouting.Encodings.Potvin {
     
    4137
    4238    public override ILookupParameter VRPMoveParameter {
    43          get { return TwoOptStarMoveParameter; }
     39      get { return TwoOptStarMoveParameter; }
    4440    }
    4541
     
    6258    public static void GetSegments(PotvinTwoOptStarMove move, out List<int> segmentX1, out List<int> segmentX2) {
    6359      PotvinEncoding solution = move.Individual as PotvinEncoding;
    64      
     60
    6561      Tour route1 = solution.Tours[move.Tour1];
    6662      Tour route2 = solution.Tours[move.Tour2];
     
    9894      route2.Stops.AddRange(segmentX1);
    9995    }
    100        
     96
    10197    protected override void PerformMove() {
    10298      PotvinTwoOptStarMove move = TwoOptStarMoveParameter.ActualValue;
  • trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/TwoOptStar/PotvinTwoOptStarMoveTabuCriterion.cs

    r7865 r8053  
    11#region License Information
    22/* HeuristicLab
    3  * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    44 *
    55 * This file is part of HeuristicLab.
     
    2020#endregion
    2121
     22using System.Collections.Generic;
    2223using HeuristicLab.Common;
    2324using HeuristicLab.Core;
     
    2829using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    2930using HeuristicLab.Problems.VehicleRouting.Interfaces;
    30 using System.Collections.Generic;
    3131using HeuristicLab.Problems.VehicleRouting.Variants;
    3232
     
    5050    public ILookupParameter<IVRPProblemInstance> ProblemInstanceParameter {
    5151      get { return (LookupParameter<IVRPProblemInstance>)Parameters["ProblemInstance"]; }
    52     } 
     52    }
    5353
    5454    public ILookupParameter<ItemList<IItem>> TabuListParameter {
     
    159159        }
    160160      }
    161      
     161
    162162      MoveTabuParameter.ActualValue = new BoolValue(isTabu);
    163163      return base.Apply();
  • trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/TwoOptStar/PotvinTwoOptStarMoveTabuMaker.cs

    r7865 r8053  
    11#region License Information
    22/* HeuristicLab
    3  * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    44 *
    55 * This file is part of HeuristicLab.
     
    2020#endregion
    2121
     22using System.Collections.Generic;
    2223using HeuristicLab.Common;
    2324using HeuristicLab.Core;
    24 using HeuristicLab.Optimization.Operators;
     25using HeuristicLab.Data;
     26using HeuristicLab.Operators;
     27using HeuristicLab.Optimization;
    2528using HeuristicLab.Parameters;
    2629using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    2730using HeuristicLab.Problems.VehicleRouting.Interfaces;
    28 using HeuristicLab.Operators;
    29 using HeuristicLab.Data;
    30 using HeuristicLab.Optimization;
    31 using System.Collections.Generic;
    3231
    3332namespace HeuristicLab.Problems.VehicleRouting.Encodings.Potvin {
     
    140139        tabuList.Add(new PotvinTwoOptStarMoveAttribute(baseQuality, move.Tour2, city, distance, overload, tardiness));
    141140      }
    142      
     141
    143142      return base.Apply();
    144143    }
  • trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/TwoOptStar/PotvinTwoOptStarMultiMoveGenerator.cs

    r7906 r8053  
    11#region License Information
    22/* HeuristicLab
    3  * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    44 *
    55 * This file is part of HeuristicLab.
     
    2020#endregion
    2121
    22 using System;
     22using System.Collections.Generic;
     23using HeuristicLab.Common;
    2324using HeuristicLab.Core;
     25using HeuristicLab.Data;
    2426using HeuristicLab.Optimization;
     27using HeuristicLab.Parameters;
    2528using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    26 using HeuristicLab.Parameters;
    27 using System.Collections.Generic;
     29using HeuristicLab.Problems.VehicleRouting.Encodings.General;
    2830using HeuristicLab.Problems.VehicleRouting.Interfaces;
    29 using HeuristicLab.Common;
    30 using HeuristicLab.Data;
    31 using HeuristicLab.Problems.VehicleRouting.Encodings.General;
    3231
    3332namespace HeuristicLab.Problems.VehicleRouting.Encodings.Potvin {
  • trunk/sources/HeuristicLab.Problems.VehicleRouting/3.4/Encodings/Potvin/Moves/TwoOptStar/PotvinTwoOptStarSingleMoveGenerator.cs

    r7906 r8053  
    11#region License Information
    22/* HeuristicLab
    3  * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    44 *
    55 * This file is part of HeuristicLab.
     
    2020#endregion
    2121
    22 using System;
     22using System.Collections.Generic;
     23using HeuristicLab.Common;
    2324using HeuristicLab.Core;
    2425using HeuristicLab.Optimization;
     26using HeuristicLab.Parameters;
    2527using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    26 using HeuristicLab.Parameters;
    27 using System.Collections.Generic;
    2828using HeuristicLab.Problems.VehicleRouting.Interfaces;
    29 using HeuristicLab.Common;
    30 using HeuristicLab.Data;
    31 using HeuristicLab.Problems.VehicleRouting.Encodings.General;
    3229
    3330namespace HeuristicLab.Problems.VehicleRouting.Encodings.Potvin {
     
    4340
    4441    #endregion
    45    
     42
    4643    public ILookupParameter<IRandom> RandomParameter {
    4744      get { return (ILookupParameter<IRandom>)Parameters["Random"]; }
Note: See TracChangeset for help on using the changeset viewer.