Changeset 16171 for branches/2943_MOBasicProblem_MOCMAES/HeuristicLab.Problems.TestFunctions.MultiObjective/3.3/TestFunctions/IHR/IHR2.cs
- Timestamp:
- 09/21/18 09:18:49 (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2943_MOBasicProblem_MOCMAES/HeuristicLab.Problems.TestFunctions.MultiObjective/3.3/TestFunctions/IHR/IHR2.cs
r15583 r16171 31 31 public class IHR2 : IHR { 32 32 protected override IEnumerable<double[]> GetOptimalParetoFront(int objectives) { 33 List<double[]>res = new List<double[]>();34 for ( inti = 0; i <= 500; i++) {35 RealVector r = new RealVector(objectives);33 var res = new List<double[]>(); 34 for (var i = 0; i <= 500; i++) { 35 var r = new RealVector(objectives); 36 36 r[0] = 1 / 500.0 * i; 37 37 … … 39 39 } 40 40 return res; 41 }42 43 protected override double GetBestKnownHypervolume(int objectives) {44 return Hypervolume.Calculate(GetOptimalParetoFront(objectives), GetReferencePoint(objectives), GetMaximization(objectives));45 41 } 46 42 … … 66 62 67 63 protected override double G(RealVector y) { 68 doublesum = 0.0;69 for ( inti = 1; i < y.Length; i++) {64 var sum = 0.0; 65 for (var i = 1; i < y.Length; i++) { 70 66 sum += HG(y[i]); 71 67 }
Note: See TracChangeset
for help on using the changeset viewer.