- Timestamp:
- 05/18/20 18:55:08 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2521_ProblemRefactoring/HeuristicLab.Problems.GraphColoring/3.3/GraphColoringProblem.cs
r17382 r17544 83 83 imat[i, 1] = defaultInstance[i].Item2 - 1; 84 84 } 85 Encoding.Length= defaultInstanceNodes;85 Dimension = defaultInstanceNodes; 86 86 AdjacencyListParameter.Value = imat; 87 87 BestKnownQualityParameter.Value = null; … … 121 121 if (FitnessFunction == FitnessFunction.Prioritized 122 122 && BestKnownColorsParameter.Value != null 123 && Encoding.Length> 0) {124 var mag = Math.Pow(10, -(int)Math.Ceiling(Math.Log10( Encoding.Length)));123 && Dimension > 0) { 124 var mag = Math.Pow(10, -(int)Math.Ceiling(Math.Log10(Dimension))); 125 125 // the value is e.g. 0.051 for 0 conflicts with 51 colors (and less than 1000 nodes) 126 126 BestKnownQuality = BestKnownColorsParameter.Value.Value * mag; … … 247 247 248 248 public void Load(GCPData data) { 249 Encoding.Length= data.Nodes;249 Dimension = data.Nodes; 250 250 AdjacencyListParameter.Value = new IntMatrix(data.Adjacencies); 251 251 if (data.BestKnownColoring != null) { … … 279 279 instance.Name = Name; 280 280 instance.Description = Description; 281 instance.Nodes = Encoding.Length;281 instance.Nodes = Dimension; 282 282 var adjList = AdjacencyListParameter.Value; 283 283 instance.Adjacencies = new int[adjList.Rows, 2];
Note: See TracChangeset
for help on using the changeset viewer.