Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
08/29/19 13:53:26 (5 years ago)
Author:
mkommend
Message:

#2521: Integrated changes of #2943 into problem refactoring branch.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2521_ProblemRefactoring/HeuristicLab.Problems.TestFunctions.MultiObjective/3.3/TestFunctions/Misc/SchafferN1.cs

    r16723 r17225  
    2424using HeuristicLab.Core;
    2525using HeuristicLab.Encodings.RealVectorEncoding;
     26using HeuristicLab.Optimization;
    2627using HEAL.Attic;
    2728
     
    3132  public class SchafferN1 : MultiObjectiveTestFunction {
    3233    protected override double[,] GetBounds(int objectives) {
    33       return new double[,] { { -1e5, 1e5 } };
     34      return new double[,] {{-1e5, 1e5}};
    3435    }
    3536
     
    3940
    4041    protected override double[] GetReferencePoint(int objectives) {
    41       return new double[] { 1e5, 1e5 };
     42      return new double[] {1e5, 1e5};
    4243    }
    4344
    4445
    45     protected override IEnumerable<double[]> GetOptimalParetoFront(int objectives) {
     46    protected override IList<double[]> GetOptimalParetoFront(int objectives) {
    4647      return ParetoFrontStore.GetParetoFront("Misc.ParetoFronts." + "SchafferN1");
    4748    }
    4849
    4950    protected override double GetBestKnownHypervolume(int objectives) {
    50       return Hypervolume.Calculate(GetOptimalParetoFront(objectives), GetReferencePoint(objectives), GetMaximization(objectives));
     51      return HypervolumeCalculator.CalculateHypervolume(GetOptimalParetoFront(objectives), GetReferencePoint(objectives), GetMaximization(objectives));
    5152    }
    5253
     
    7273      f1 *= f1;
    7374
    74       return new double[] { f0, f1 };
     75      return new double[] {f0, f1};
    7576    }
    7677  }
Note: See TracChangeset for help on using the changeset viewer.