Ignore:
Timestamp:
03/01/19 12:51:59 (2 years ago)
Author:
bburlacu
Message:

#2987: Prevent updating the Ideal and Nadir points with NaN or Infinity values. Simplify algorithm code (use arrays instead of lists). Add missing StorableType attributes. Add hypervolume analysis for the pareto fronts.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2987_MOEAD_Algorithm/HeuristicLab.Algorithms.MOEAD/3.4/MOEADUtil.cs

    r16630 r16649  
    175175    public static void UpdateIdeal(this double[] idealPoint, double[] point) {
    176176      for (int i = 0; i < point.Length; ++i) {
     177        if (double.IsInfinity(point[i]) || double.IsNaN(point[i])) {
     178          continue;
     179        }
     180
    177181        if (idealPoint[i] > point[i]) {
    178182          idealPoint[i] = point[i];
     
    183187    public static void UpdateNadir(this double[] nadirPoint, double[] point) {
    184188      for (int i = 0; i < point.Length; ++i) {
     189        if (double.IsInfinity(point[i]) || double.IsNaN(point[i])) {
     190          continue;
     191        }
     192
    185193        if (nadirPoint[i] < point[i]) {
    186194          nadirPoint[i] = point[i];
Note: See TracChangeset for help on using the changeset viewer.