- Timestamp:
- 06/21/12 18:02:33 (13 years ago)
- Location:
- branches/GP-MoveOperators
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/GP-MoveOperators
- Property svn:ignore
-
old new 20 20 bin 21 21 protoc.exe 22 _ReSharper.HeuristicLab 3.3 Tests
-
- Property svn:mergeinfo changed
- Property svn:ignore
-
branches/GP-MoveOperators/HeuristicLab.Problems.TravelingSalesman/3.3/TravelingSalesmanProblem.cs
r7658 r8085 347 347 if (data.Coordinates == null && data.Distances == null) 348 348 throw new System.IO.InvalidDataException("The given instance specifies neither coordinates nor distances!"); 349 if (data.Dimension > DistanceMatrixSizeLimit && (data.DistanceMeasure == TSPDistanceMeasure.Att350 || data.DistanceMeasure == TSPDistanceMeasure.Manhattan351 || data.DistanceMeasure == TSPDistanceMeasure.Maximum352 || data.DistanceMeasure == TSPDistanceMeasure.UpperEuclidean))349 if (data.Dimension > DistanceMatrixSizeLimit && (data.DistanceMeasure == DistanceMeasure.Att 350 || data.DistanceMeasure == DistanceMeasure.Manhattan 351 || data.DistanceMeasure == DistanceMeasure.Maximum 352 || data.DistanceMeasure == DistanceMeasure.UpperEuclidean)) 353 353 throw new System.IO.InvalidDataException("The given instance uses an unsupported distance measure and is too large for using a distance matrix."); 354 354 if (data.Coordinates != null && data.Coordinates.GetLength(1) != 2) … … 363 363 364 364 TSPEvaluator evaluator; 365 if (data.DistanceMeasure == TSPDistanceMeasure.Att366 || data.DistanceMeasure == TSPDistanceMeasure.Manhattan367 || data.DistanceMeasure == TSPDistanceMeasure.Maximum368 || data.DistanceMeasure == TSPDistanceMeasure.UpperEuclidean) {365 if (data.DistanceMeasure == DistanceMeasure.Att 366 || data.DistanceMeasure == DistanceMeasure.Manhattan 367 || data.DistanceMeasure == DistanceMeasure.Maximum 368 || data.DistanceMeasure == DistanceMeasure.UpperEuclidean) { 369 369 evaluator = new TSPDistanceMatrixEvaluator(); 370 370 UseDistanceMatrix = new BoolValue(true); 371 371 DistanceMatrix = new DistanceMatrix(data.GetDistanceMatrix()); 372 } else if (data.DistanceMeasure == TSPDistanceMeasure.Direct && data.Distances != null) {372 } else if (data.DistanceMeasure == DistanceMeasure.Direct && data.Distances != null) { 373 373 evaluator = new TSPDistanceMatrixEvaluator(); 374 374 UseDistanceMatrix = new BoolValue(true); … … 378 378 UseDistanceMatrix = new BoolValue(data.Dimension <= DistanceMatrixSizeLimit); 379 379 switch (data.DistanceMeasure) { 380 case TSPDistanceMeasure.Euclidean:380 case DistanceMeasure.Euclidean: 381 381 evaluator = new TSPEuclideanPathEvaluator(); 382 382 break; 383 case TSPDistanceMeasure.RoundedEuclidean:383 case DistanceMeasure.RoundedEuclidean: 384 384 evaluator = new TSPRoundedEuclideanPathEvaluator(); 385 385 break; 386 case TSPDistanceMeasure.Geo:386 case DistanceMeasure.Geo: 387 387 evaluator = new TSPGeoPathEvaluator(); 388 388 break;
Note: See TracChangeset
for help on using the changeset viewer.