Exemple #1
0
        public static void Main(string[] args)
        {
            Utils.Parse.CSV <Category>(FILE_CATEGORY);
            Utils.Parse.CSV <Location>(FILE_LOCATION);
            Distances.Parse(FILE_DISTANCES);

            GRASP GRASP = new GRASP(Location.Instance("Plaza del Adelantado"));
            SimulatedAnnealing         SA  = new SimulatedAnnealing(50, .05, Location.Instance("Plaza del Adelantado"));
            TabuSearch                 TS  = new TabuSearch(7, Location.Instance("Plaza del Adelantado"));
            VariableNeighborhoodSearch VNS = new VariableNeighborhoodSearch(5, Location.Instance("Plaza del Adelantado"));

            Console.WriteLine("GRASP:");
            Run(GRASP, 20);
            Console.WriteLine("\nSA:");
            //Run(SA, 20);
            Console.WriteLine("\nTS:");
            Run(TS, 20);
            //Console.WriteLine("\nVNS:");
            //Run(VNS, 20);
        }
 protected override int[] InitialSolution()
 {
     GRASP.Run(GRASPIterations, RunType.IterationsLimit);
     return(GRASP.BestSolution);
 }