Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
07/05/12 09:44:06 (12 years ago)
Author:
gkronber
Message:

#1784: fixed uniform sampling. Adapted Nguyen instances.

Location:
trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression
Files:
17 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Keijzer/KeijzerInstanceProvider.cs

    r8210 r8224  
    3535    }
    3636    public override string ReferencePublication {
    37       get { return ""; }
     37      get { return "McDermott et al., 2012 \"Genetic Programming Needs Better Benchmarks\", in Proc. of GECCO 2012."; }
    3838    }
    3939
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Korns/KornsInstanceProvider.cs

    r8210 r8224  
    3535    }
    3636    public override string ReferencePublication {
    37       get { return ""; }
     37      get { return "McDermott et al., 2012 \"Genetic Programming Needs Better Benchmarks\", in Proc. of GECCO 2012."; }
    3838    }
    3939
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenFunctionEight.cs

    r7849 r8224  
    3333        + "Authors: Nguyen Quang Uy · Nguyen Xuan Hoai · Michael O’Neill · R.I. McKay · Edgar Galvan-Lopez" + Environment.NewLine
    3434        + "Function: F8 = Sqrt(x)" + Environment.NewLine
    35         + "Fitcases: 20 random points [0, 4]" + Environment.NewLine
    36         + "Non-terminals: +, -, *, /, sin, cos, exp, log (protected version)" + Environment.NewLine
    37         + "Terminals: X, 1 for single variable problems, and X, Y for bivariable problems";
     35        + "Fitcases: 20 random points in [0, 4]" + Environment.NewLine
     36        + "Non-terminals: +, -, *, % (protected division), sin, cos, exp, ln(|x|) (protected log)" + Environment.NewLine
     37        + "Terminals: only variables (no random constants)";
    3838      }
    3939    }
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenFunctionEleven.cs

    r7849 r8224  
    3333        + "Authors: Nguyen Quang Uy · Nguyen Xuan Hoai · Michael O’Neill · R.I. McKay · Edgar Galvan-Lopez" + Environment.NewLine
    3434        + "Function: F11 = x^y" + Environment.NewLine
    35         + "Fitcases: 100 random points ⊆ [0, 1]x[0, 1]" + Environment.NewLine
    36         + "Non-terminals: +, -, *, /, sin, cos, exp, log (protected version)" + Environment.NewLine
    37         + "Terminals: X, 1 for single variable problems, and X, Y for bivariable problems";
     35        + "Fitcases: 20 random points in [0, 1]x[0, 1]" + Environment.NewLine
     36        + "Non-terminals: +, -, *, % (protected division), sin, cos, exp, ln(|x|) (protected log)" + Environment.NewLine
     37        + "Terminals: only variables (no random constants)";
    3838      }
    3939    }
     
    4242    protected override string[] AllowedInputVariables { get { return new string[] { "X", "Y" }; } }
    4343    protected override int TrainingPartitionStart { get { return 0; } }
    44     protected override int TrainingPartitionEnd { get { return 100; } }
     44    protected override int TrainingPartitionEnd { get { return 20; } }
    4545    protected override int TestPartitionStart { get { return 500; } }
    4646    protected override int TestPartitionEnd { get { return 1000; } }
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenFunctionFive.cs

    r7849 r8224  
    2727  public class NguyenFunctionFive : ArtificialRegressionDataDescriptor {
    2828
    29     public override string Name { get { return "Nguyen F5 = sin(x^2)cos(x) - 1"; } }
     29    public override string Name { get { return "Nguyen F5 = sin(x²)cos(x) - 1"; } }
    3030    public override string Description {
    3131      get {
    3232        return "Paper: Semantically-based Crossover in Genetic Programming: Application to Real-valued Symbolic Regression" + Environment.NewLine
    3333        + "Authors: Nguyen Quang Uy · Nguyen Xuan Hoai · Michael O’Neill · R.I. McKay · Edgar Galvan-Lopez" + Environment.NewLine
    34         + "Function: F5 = sin(x^2)cos(x) - 1" + Environment.NewLine
    35         + "Fitcases: 20 random points [-1, 1]" + Environment.NewLine
    36         + "Non-terminals: +, -, *, /, sin, cos, exp, log (protected version)" + Environment.NewLine
    37         + "Terminals: X, 1 for single variable problems, and X, Y for bivariable problems";
     34        + "Function: F5 = sin(x²)cos(x) - 1" + Environment.NewLine
     35        + "Fitcases: 20 random points in [-1, 1]" + Environment.NewLine
     36        + "Non-terminals: +, -, *, % (protected division), sin, cos, exp, ln(|x|) (protected log)" + Environment.NewLine
     37        + "Terminals: only variables (no random constants)";
    3838      }
    3939    }
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenFunctionFour.cs

    r7849 r8224  
    2727  public class NguyenFunctionFour : ArtificialRegressionDataDescriptor {
    2828
    29     public override string Name { get { return "Nguyen F4 = x^6 + x^5 + x^4 + x^3 + x^2 + x"; } }
     29    public override string Name { get { return "Nguyen F4 = x^6 + x^5 + x^4 + x³ + x² + x"; } }
    3030    public override string Description {
    3131      get {
    3232        return "Paper: Semantically-based Crossover in Genetic Programming: Application to Real-valued Symbolic Regression" + Environment.NewLine
    3333        + "Authors: Nguyen Quang Uy · Nguyen Xuan Hoai · Michael O’Neill · R.I. McKay · Edgar Galvan-Lopez" + Environment.NewLine
    34         + "Function: F4 = x^6 + x^5 + x^4 + x^3 + x^2 + x" + Environment.NewLine
    35         + "Fitcases: 20 random points [-1, 1]" + Environment.NewLine
    36         + "Non-terminals: +, -, *, /, sin, cos, exp, log (protected version)" + Environment.NewLine
    37         + "Terminals: X, 1 for single variable problems, and X, Y for bivariable problems";
     34        + "Function: F4 = x^6 + x^5 + x^4 + x³ + x² + x" + Environment.NewLine
     35        + "Fitcases: 20 random points in [-1, 1]" + Environment.NewLine
     36        + "Non-terminals: +, -, *, % (protected division), sin, cos, exp, ln(|x|) (protected log)" + Environment.NewLine
     37        + "Terminals: only variables (no random constants)";
    3838      }
    3939    }
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenFunctionNine.cs

    r7849 r8224  
    2727  public class NguyenFunctionNine : ArtificialRegressionDataDescriptor {
    2828
    29     public override string Name { get { return "Nguyen F9 = sin(x) + sin(y^2)"; } }
     29    public override string Name { get { return "Nguyen F9 = sin(x) + sin(y²)"; } }
    3030    public override string Description {
    3131      get {
    3232        return "Paper: Semantically-based Crossover in Genetic Programming: Application to Real-valued Symbolic Regression" + Environment.NewLine
    3333        + "Authors: Nguyen Quang Uy · Nguyen Xuan Hoai · Michael O’Neill · R.I. McKay · Edgar Galvan-Lopez" + Environment.NewLine
    34         + "Function: F9 = sin(x) + sin(y^2)" + Environment.NewLine
    35         + "Fitcases: 100 random points ⊆ [0, 1]x[0, 1]" + Environment.NewLine
    36         + "Non-terminals: +, -, *, /, sin, cos, exp, log (protected version)" + Environment.NewLine
    37         + "Terminals: X, 1 for single variable problems, and X, Y for bivariable problems";
     34        + "Function: F9 = sin(x) + sin(y²)" + Environment.NewLine
     35        + "Fitcases: 20 random points in [0, 1]x[0, 1]" + Environment.NewLine
     36        + "Non-terminals: +, -, *, % (protected division), sin, cos, exp, ln(|x|) (protected log)" + Environment.NewLine
     37        + "Terminals: only variables (no random constants)";
    3838      }
    3939    }
     
    4242    protected override string[] AllowedInputVariables { get { return new string[] { "X", "Y" }; } }
    4343    protected override int TrainingPartitionStart { get { return 0; } }
    44     protected override int TrainingPartitionEnd { get { return 100; } }
     44    protected override int TrainingPartitionEnd { get { return 20; } }
    4545    protected override int TestPartitionStart { get { return 500; } }
    4646    protected override int TestPartitionEnd { get { return 1000; } }
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenFunctionOne.cs

    r7849 r8224  
    2727  public class NguyenFunctionOne : ArtificialRegressionDataDescriptor {
    2828
    29     public override string Name { get { return "Nguyen F1 = x^3 + x^2 + x"; } }
     29    public override string Name { get { return "Nguyen F1 = x³ + x² + x"; } }
    3030    public override string Description {
    3131      get {
    3232        return "Paper: Semantically-based Crossover in Genetic Programming: Application to Real-valued Symbolic Regression" + Environment.NewLine
    3333        + "Authors: Nguyen Quang Uy · Nguyen Xuan Hoai · Michael O’Neill · R.I. McKay · Edgar Galvan-Lopez" + Environment.NewLine
    34         + "Function: F1 = x^3 + x^2 + x" + Environment.NewLine
    35         + "Fitcases: 20 random points [-1, 1]" + Environment.NewLine
    36         + "Non-terminals: +, -, *, /, sin, cos, exp, log (protected version)" + Environment.NewLine
    37         + "Terminals: X, 1 for single variable problems, and X, Y for bivariable problems";
     34        + "Function: F1 = x³ + x² + x" + Environment.NewLine
     35        + "Fitcases: 20 random points in [-1, 1]" + Environment.NewLine
     36        + "Non-terminals: +, -, *, % (protected division), sin, cos, exp, ln(|x|) (protected log)" + Environment.NewLine
     37        + "Terminals: only variables (no random constants)";
    3838      }
    3939    }
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenFunctionSeven.cs

    r7849 r8224  
    2727  public class NguyenFunctionSeven : ArtificialRegressionDataDescriptor {
    2828
    29     public override string Name { get { return "Nguyen F7 = log(x + 1) + log(x^2 + 1)"; } }
     29    public override string Name { get { return "Nguyen F7 = log(x + 1) + log(x² + 1)"; } }
    3030    public override string Description {
    3131      get {
    3232        return "Paper: Semantically-based Crossover in Genetic Programming: Application to Real-valued Symbolic Regression" + Environment.NewLine
    3333        + "Authors: Nguyen Quang Uy · Nguyen Xuan Hoai · Michael O’Neill · R.I. McKay · Edgar Galvan-Lopez" + Environment.NewLine
    34         + "Function: F7 = log(x + 1) + log(x^2 + 1)" + Environment.NewLine
    35         + "Fitcases: 20 random points [0, 2]" + Environment.NewLine
    36         + "Non-terminals: +, -, *, /, sin, cos, exp, log (protected version)" + Environment.NewLine
    37         + "Terminals: X, 1 for single variable problems, and X, Y for bivariable problems";
     34        + "Function: F7 = ln(x + 1) + ln(x² + 1)" + Environment.NewLine
     35        + "Fitcases: 20 random points in [0, 2]" + Environment.NewLine
     36        + "Non-terminals: +, -, *, % (protected division), sin, cos, exp, ln(|x|) (protected log)" + Environment.NewLine
     37        + "Terminals: only variables (no random constants)";
    3838      }
    3939    }
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenFunctionSix.cs

    r7849 r8224  
    2727  public class NguyenFunctionSix : ArtificialRegressionDataDescriptor {
    2828
    29     public override string Name { get { return "Nguyen F6 = sin(x) + sin(x + x^2)"; } }
     29    public override string Name { get { return "Nguyen F6 = sin(x) + sin(x + x²)"; } }
    3030    public override string Description {
    3131      get {
    3232        return "Paper: Semantically-based Crossover in Genetic Programming: Application to Real-valued Symbolic Regression" + Environment.NewLine
    3333        + "Authors: Nguyen Quang Uy · Nguyen Xuan Hoai · Michael O’Neill · R.I. McKay · Edgar Galvan-Lopez" + Environment.NewLine
    34         + "Function: F6 = sin(x) + sin(x + x^2)" + Environment.NewLine
    35         + "Fitcases: 20 random points [-1, 1]" + Environment.NewLine
    36         + "Non-terminals: +, -, *, /, sin, cos, exp, log (protected version)" + Environment.NewLine
    37         + "Terminals: X, 1 for single variable problems, and X, Y for bivariable problems";
     34        + "Function: F6 = sin(x) + sin(x + x²)" + Environment.NewLine
     35        + "Fitcases: 20 random points in [-1, 1]" + Environment.NewLine
     36        + "Non-terminals: +, -, *, % (protected division), sin, cos, exp, ln(|x|) (protected log)" + Environment.NewLine
     37        + "Terminals: only variables (no random constants)";
    3838      }
    3939    }
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenFunctionTen.cs

    r7849 r8224  
    3333        + "Authors: Nguyen Quang Uy · Nguyen Xuan Hoai · Michael O’Neill · R.I. McKay · Edgar Galvan-Lopez" + Environment.NewLine
    3434        + "Function: F10 = 2sin(x)cos(y)" + Environment.NewLine
    35         + "Fitcases: 100 random points ⊆ [0, 1]x[0, 1]" + Environment.NewLine
    36         + "Non-terminals: +, -, *, /, sin, cos, exp, log (protected version)" + Environment.NewLine
    37         + "Terminals: X, 1 for single variable problems, and X, Y for bivariable problems";
     35        + "Fitcases: 20 random points in [0, 1]x[0, 1]" + Environment.NewLine
     36        + "Non-terminals: +, -, *, % (protected division), sin, cos, exp, ln(|x|) (protected log)" + Environment.NewLine
     37        + "Terminals: only variables (no random constants)";
    3838      }
    3939    }
     
    4242    protected override string[] AllowedInputVariables { get { return new string[] { "X", "Y" }; } }
    4343    protected override int TrainingPartitionStart { get { return 0; } }
    44     protected override int TrainingPartitionEnd { get { return 100; } }
     44    protected override int TrainingPartitionEnd { get { return 20; } }
    4545    protected override int TestPartitionStart { get { return 500; } }
    4646    protected override int TestPartitionEnd { get { return 1000; } }
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenFunctionThree.cs

    r7849 r8224  
    2727  public class NguyenFunctionThree : ArtificialRegressionDataDescriptor {
    2828
    29     public override string Name { get { return "Nguyen F3 = x^5 + x^4 + x^3 + x^2 + x"; } }
     29    public override string Name { get { return "Nguyen F3 = x^5 + x^4 + x³ + x² + x"; } }
    3030    public override string Description {
    3131      get {
    3232        return "Paper: Semantically-based Crossover in Genetic Programming: Application to Real-valued Symbolic Regression" + Environment.NewLine
    3333        + "Authors: Nguyen Quang Uy · Nguyen Xuan Hoai · Michael O’Neill · R.I. McKay · Edgar Galvan-Lopez" + Environment.NewLine
    34         + "Function: F3 = x^5 + x^4 + x^3 + x^2 + x" + Environment.NewLine
    35         + "Fitcases: 20 random points [-1, 1]" + Environment.NewLine
    36         + "Non-terminals: +, -, *, /, sin, cos, exp, log (protected version)" + Environment.NewLine
    37         + "Terminals: X, 1 for single variable problems, and X, Y for bivariable problems";
     34        + "Function: F3 = x^5 + x^4 + x³ + x² + x" + Environment.NewLine
     35        + "Fitcases: 20 random points in [-1, 1]" + Environment.NewLine
     36        + "Non-terminals: +, -, *, % (protected division), sin, cos, exp, ln(|x|) (protected log)" + Environment.NewLine
     37        + "Terminals: only variables (no random constants)";
    3838      }
    3939    }
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenFunctionTwelve.cs

    r7849 r8224  
    2727  public class NguyenFunctionTwelve : ArtificialRegressionDataDescriptor {
    2828
    29     public override string Name { get { return "Nguyen F12 = x^4 - x^3 + y^2/2 - y"; } }
     29    public override string Name { get { return "Nguyen F12 = x^4 - x³ + y²/2 - y"; } }
    3030    public override string Description {
    3131      get {
    3232        return "Paper: Semantically-based Crossover in Genetic Programming: Application to Real-valued Symbolic Regression" + Environment.NewLine
    3333        + "Authors: Nguyen Quang Uy · Nguyen Xuan Hoai · Michael O’Neill · R.I. McKay · Edgar Galvan-Lopez" + Environment.NewLine
    34         + "Function: F12 = x^4 - x^3 + y^2/2 - y" + Environment.NewLine
    35         + "Fitcases: 100 random points ⊆ [0, 1]x[0, 1]" + Environment.NewLine
    36         + "Non-terminals: +, -, *, /, sin, cos, exp, log (protected version)" + Environment.NewLine
    37         + "Terminals: X, 1 for single variable problems, and X, Y for bivariable problems";
     34        + "Function: F12 = x^4 - x³ + y²/2 - y" + Environment.NewLine
     35        + "Fitcases: 20 random points in [0, 1]x[0, 1]" + Environment.NewLine
     36        + "Non-terminals: +, -, *, % (protected division), sin, cos, exp, ln(|x|) (protected log)" + Environment.NewLine
     37        + "Terminals: only variables (no random constants)";
    3838      }
    3939    }
     
    4242    protected override string[] AllowedInputVariables { get { return new string[] { "X", "Y" }; } }
    4343    protected override int TrainingPartitionStart { get { return 0; } }
    44     protected override int TrainingPartitionEnd { get { return 100; } }
     44    protected override int TrainingPartitionEnd { get { return 20; } }
    4545    protected override int TestPartitionStart { get { return 500; } }
    4646    protected override int TestPartitionEnd { get { return 1000; } }
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenFunctionTwo.cs

    r7849 r8224  
    2727  public class NguyenFunctionTwo : ArtificialRegressionDataDescriptor {
    2828
    29     public override string Name { get { return "Nguyen F2 = x^4 + x^3 + x^2 + x"; } }
     29    public override string Name { get { return "Nguyen F2 = x^4 + x³ + x² + x"; } }
    3030    public override string Description {
    3131      get {
    3232        return "Paper: Semantically-based Crossover in Genetic Programming: Application to Real-valued Symbolic Regression" + Environment.NewLine
    3333        + "Authors: Nguyen Quang Uy · Nguyen Xuan Hoai · Michael O’Neill · R.I. McKay · Edgar Galvan-Lopez" + Environment.NewLine
    34         + "Function: F2 = x^4 + x^3 + x^2 + x" + Environment.NewLine
    35         + "Fitcases: 20 random points [-1, 1]" + Environment.NewLine
    36         + "Non-terminals: +, -, *, /, sin, cos, exp, log (protected version)" + Environment.NewLine
    37         + "Terminals: X, 1 for single variable problems, and X, Y for bivariable problems";
     34        + "Function: F2 = x^4 + x³ + x² + x" + Environment.NewLine
     35        + "Fitcases: 20 random points in [-1, 1]" + Environment.NewLine
     36        + "Non-terminals: +, -, *, % (protected division), sin, cos, exp, ln(|x|) (protected log)" + Environment.NewLine
     37        + "Terminals: only variables (no random constants)";
    3838      }
    3939    }
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Nguyen/NguyenInstanceProvider.cs

    r8210 r8224  
    3535    }
    3636    public override string ReferencePublication {
    37       get { return ""; }
     37      get { return "McDermott et al., 2012 \"Genetic Programming Needs Better Benchmarks\", in Proc. of GECCO 2012."; }
    3838    }
    3939
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/ValueGenerator.cs

    r7849 r8224  
    2929    private static FastRandom rand = new FastRandom();
    3030
     31    /// <summary>
     32    /// Generates a sequence of evenly spaced points between start and end (inclusive!).
     33    /// </summary>
     34    /// <param name="start">The smallest and first value of the sequence.</param>
     35    /// <param name="end">The largest and last value of the sequence.</param>
     36    /// <param name="stepWidth">The step size between subsequent values.</param>
     37    /// <returns>An sequence of values from start to end (inclusive)</returns>
    3138    public static IEnumerable<double> GenerateSteps(double start, double end, double stepWidth) {
    32       int steps = (int)Math.Round(((end - start) / stepWidth) + 1);
    33       for (int i = 0; i < steps; i++)
    34         yield return start + i * stepWidth;
     39      if (start > end) throw new ArgumentException("start must be less than or equal end.");
     40      if (stepWidth <= 0) throw new ArgumentException("stepwith must be larger than zero.", "stepWidth");
     41      double x = start;
     42      while (x <= end) {
     43        yield return x;
     44        x += stepWidth;
     45      }
    3546    }
    3647
    37     public static IEnumerable<double> GenerateUniformDistributedValues(int amount, double start, double end) {
    38       for (int i = 0; i < amount; i++)
    39         yield return rand.NextDouble() * (end - start) + start;
     48    /// <summary>
     49    /// Generates uniformly distributed values between start and end (inclusive!)
     50    /// </summary>
     51    /// <param name="n">Number of values to generate.</param>
     52    /// <param name="start">The lower value (inclusive)</param>
     53    /// <param name="end">The upper value (inclusive)</param>
     54    /// <returns>An enumerable including n values in [start, end]</returns>
     55    public static IEnumerable<double> GenerateUniformDistributedValues(int n, double start, double end) {
     56      for (int i = 0; i < n; i++) {
     57        // we need to return a random value including end.
     58        // so we cannot use rand.NextDouble() as it returns a value strictly smaller than 1.
     59        double r = rand.NextUInt() / (double)uint.MaxValue;    // r \in [0,1]
     60        yield return r * (end - start) + start;
     61      }
    4062    }
    4163
    42     public static IEnumerable<double> GenerateNormalDistributedValues(int amount, double mu, double sigma) {
    43       for (int i = 0; i < amount; i++)
     64    /// <summary>
     65    /// Generates normally distributed values sampling from N(mu, sigma)
     66    /// </summary>
     67    /// <param name="n">Number of values to generate.</param>
     68    /// <param name="mu">The mu parameter of the normal distribution</param>
     69    /// <param name="sigma">The sigma parameter of the normal distribution</param>
     70    /// <returns>An enumerable including n values ~ N(mu, sigma)</returns>
     71    public static IEnumerable<double> GenerateNormalDistributedValues(int n, double mu, double sigma) {
     72      for (int i = 0; i < n; i++)
    4473        yield return NormalDistributedRandom.NextDouble(rand, mu, sigma);
    4574    }
     
    82111      }
    83112    }
    84 
    85     //recursive approach
    86     /*public static IEnumerable<IEnumerable<double>> GenerateAllCombinationsOfValuesInLists(List<List<double>> lists) {
    87       int cur = 0;
    88       List<double> curCombination = new List<double>();
    89       List<List<double>> allCombinations = new List<List<double>>();
    90       for (int i = 0; i < lists.Count; i++) {
    91         allCombinations.Add(new List<double>());
    92       }
    93       if (lists.Count() > cur) {
    94         foreach (var item in lists[cur]) {
    95           curCombination.Clear();
    96           curCombination.Add(item);
    97           GetCombination(lists, cur + 1, curCombination, allCombinations);
    98         }
    99       }
    100       return allCombinations;
    101     }
    102 
    103     private static void GetCombination(List<List<double>> lists, int cur, List<double> curCombinations, List<List<double>> allCombinations) {
    104       if (lists.Count > cur) {
    105         foreach (var item in lists[cur]) {
    106           if (curCombinations.Count > cur) {
    107             curCombinations.RemoveAt(cur);
    108           }
    109           curCombinations.Add(item);
    110           GetCombination(lists, cur + 1, curCombinations, allCombinations);
    111         }
    112       } else {
    113         for (int i = 0; i < curCombinations.Count; i++) {
    114           allCombinations[i].Add(curCombinations[i]);
    115         }
    116       }
    117     }         */
    118 
    119     //original
    120     /*public static IEnumerable<IEnumerable<double>> GenerateAllCombinationsOfValuesInLists(List<List<double>> sets) {
    121 
    122       var combinations = new List<List<double>>();
    123 
    124       foreach (var value in sets[0])
    125         combinations.Add(new List<double> { value });
    126 
    127       foreach (var set in sets.Skip(1))
    128         combinations = AddListToCombinations(combinations, set);
    129 
    130       IEnumerable<IEnumerable<double>> res = (from i in Enumerable.Range(0, sets.Count)
    131                                               select (from list in combinations
    132                                                       select list.ElementAt(i)));
    133 
    134       return res;
    135     }
    136 
    137     private static List<List<double>> AddListToCombinations
    138          (List<List<double>> combinations, List<double> set) {
    139       var newCombinations = from value in set
    140                             from combination in combinations
    141                             select new List<double>(combination) { value };
    142 
    143       return newCombinations.ToList();
    144     }    */
    145113  }
    146114}
  • trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Vladislavleva/VladislavlevaInstanceProvider.cs

    r8210 r8224  
    3535    }
    3636    public override string ReferencePublication {
    37       get { return ""; }
     37      get { return "McDermott et al., 2012 \"Genetic Programming Needs Better Benchmarks\", in Proc. of GECCO 2012."; }
    3838    }
    3939
Note: See TracChangeset for help on using the changeset viewer.