[13672] | 1 | #region License Information
|
---|
| 2 | /* HeuristicLab
|
---|
| 3 | * Copyright (C) 2002-2016 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
|
---|
| 4 | *
|
---|
| 5 | * This file is part of HeuristicLab.
|
---|
| 6 | *
|
---|
| 7 | * HeuristicLab is free software: you can redistribute it and/or modify
|
---|
| 8 | * it under the terms of the GNU General Public License as published by
|
---|
| 9 | * the Free Software Foundation, either version 3 of the License, or
|
---|
| 10 | * (at your option) any later version.
|
---|
| 11 | *
|
---|
| 12 | * HeuristicLab is distributed in the hope that it will be useful,
|
---|
| 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
| 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
---|
| 15 | * GNU General Public License for more details.
|
---|
| 16 | *
|
---|
| 17 | * You should have received a copy of the GNU General Public License
|
---|
| 18 | * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
|
---|
| 19 | */
|
---|
| 20 | #endregion
|
---|
| 21 | using System;
|
---|
[13622] | 22 | using System.Drawing;
|
---|
[14092] | 23 | using System.Linq;
|
---|
[13622] | 24 | using HeuristicLab.Common;
|
---|
[14092] | 25 | using HeuristicLab.Core;
|
---|
[13622] | 26 | using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
|
---|
| 27 |
|
---|
[14111] | 28 | namespace HeuristicLab.Problems.TestFunctions.MultiObjective {
|
---|
[13988] | 29 | [StorableClass]
|
---|
[14097] | 30 | [Item("ScatterPlot", "The optimal front, current front and its associated Points in the searchspace")]
|
---|
[14092] | 31 | public class ScatterPlotContent : Item {
|
---|
[13622] | 32 |
|
---|
[14092] | 33 | [Storable]
|
---|
[13988] | 34 | private double[][] qualities;
|
---|
| 35 | public double[][] Qualities {
|
---|
| 36 | get {
|
---|
| 37 | return qualities;
|
---|
| 38 | }
|
---|
[13622] | 39 |
|
---|
[14097] | 40 | private set {
|
---|
[13988] | 41 | qualities = value;
|
---|
| 42 | }
|
---|
| 43 | }
|
---|
[13622] | 44 |
|
---|
[14092] | 45 | [Storable]
|
---|
[13988] | 46 | private int objectives;
|
---|
| 47 | public int Objectives {
|
---|
| 48 | get {
|
---|
| 49 | return objectives;
|
---|
| 50 | }
|
---|
[13622] | 51 |
|
---|
[14097] | 52 | private set {
|
---|
[13988] | 53 | objectives = value;
|
---|
| 54 | }
|
---|
| 55 | }
|
---|
[13622] | 56 |
|
---|
[14092] | 57 | [Storable]
|
---|
[13988] | 58 | private double[][] solutions;
|
---|
| 59 | public double[][] Solutions {
|
---|
| 60 | get {
|
---|
| 61 | return solutions;
|
---|
| 62 | }
|
---|
[13622] | 63 |
|
---|
[14097] | 64 | private set {
|
---|
[13988] | 65 | solutions = value;
|
---|
| 66 | }
|
---|
| 67 | }
|
---|
[13622] | 68 |
|
---|
[14092] | 69 | [Storable]
|
---|
[13988] | 70 | private double[][] paretoFront;
|
---|
| 71 | public double[][] ParetoFront {
|
---|
| 72 | get {
|
---|
| 73 | return paretoFront;
|
---|
| 74 | }
|
---|
[13622] | 75 |
|
---|
[14097] | 76 | private set {
|
---|
[13988] | 77 | paretoFront = value;
|
---|
| 78 | }
|
---|
| 79 | }
|
---|
[13622] | 80 |
|
---|
[13988] | 81 | [StorableConstructor]
|
---|
[14092] | 82 | protected ScatterPlotContent(bool deserializing) : base() { }
|
---|
[13729] | 83 |
|
---|
[14092] | 84 | protected ScatterPlotContent(ScatterPlotContent original, Cloner cloner) : this() {
|
---|
| 85 | this.qualities = original.qualities.Select(s => s.ToArray()).ToArray();
|
---|
| 86 | this.solutions = original.solutions.Select(s => s.ToArray()).ToArray();
|
---|
| 87 | this.paretoFront = original.paretoFront.Select(s => s.ToArray()).ToArray();
|
---|
[13988] | 88 | this.objectives = original.objectives;
|
---|
| 89 | }
|
---|
[14092] | 90 | protected ScatterPlotContent() : base() { }
|
---|
| 91 | public ScatterPlotContent(double[][] qualities, double[][] solutions, double[][] paretoFront, int objectives) {
|
---|
[13988] | 92 | this.qualities = qualities;
|
---|
| 93 | this.solutions = solutions;
|
---|
| 94 | this.paretoFront = paretoFront;
|
---|
| 95 | this.objectives = objectives;
|
---|
| 96 | }
|
---|
[13622] | 97 |
|
---|
[14092] | 98 | public override IDeepCloneable Clone(Cloner cloner) {
|
---|
[14093] | 99 | return new ScatterPlotContent(this, cloner);
|
---|
[13988] | 100 | }
|
---|
| 101 | }
|
---|
[13622] | 102 | }
|
---|