Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
07/19/16 13:46:15 (8 years ago)
Author:
mkommend
Message:

#1087: Fixed bugs in Spacing and Hypervolume calculation, corrected plugin dependencies and minor changes to the scatter plot view.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HeuristicLab.Problems.MultiObjectiveTestFunctions/HeuristicLab.Problems.MultiObjectiveTestFunctions/3.3/Calculators/Spacing.cs

    r14030 r14108  
    3737      if (!front.Any()) throw new ArgumentException("Front must  not be empty.");
    3838
    39       List<double> d = new List<double>();
    40       foreach (double[] r in front) {
     39      var points = front.ToList();
     40      var d = new List<double>();
     41
     42      foreach (double[] r in points) {
    4143        var point = r;
    42         var otherPoints = front.Where(p => p != point).DefaultIfEmpty(point);
     44        var otherPoints = points.Where(p => p != point).DefaultIfEmpty(point);
    4345        double dist = Utilities.MinimumDistance(point, otherPoints);
    4446        d.Add(dist);
Note: See TracChangeset for help on using the changeset viewer.