Changeset 17773 for branches/3073_IA_constraint_splitting/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/Interpreter
- Timestamp:
- 10/08/20 15:39:46 (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3073_IA_constraint_splitting/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/Interpreter/IABoundsEstimator.cs
r17768 r17773 474 474 var modelBound = Evaluate(instructions, ref instructionCounter, variableIntervals: occuringVariableRanges); 475 475 if (constraint.Interval.Contains(modelBound)) return 0.0; 476 return Math.Abs(modelBound.LowerBound - constraint.Interval.LowerBound) + 477 Math.Abs(modelBound.UpperBound - constraint.Interval.UpperBound); 476 477 478 var error = 0.0; 479 480 if (!constraint.Interval.Contains(modelBound.LowerBound)) { 481 error += Math.Abs(modelBound.LowerBound - constraint.Interval.LowerBound); 482 } 483 484 if (!constraint.Interval.Contains(modelBound.UpperBound)) { 485 error += Math.Abs(modelBound.UpperBound - constraint.Interval.UpperBound); 486 } 487 488 return error; 489 // return Math.Abs(modelBound.LowerBound - constraint.Interval.LowerBound) + 490 //Math.Abs(modelBound.UpperBound - constraint.Interval.UpperBound); 478 491 } 479 492
Note: See TracChangeset
for help on using the changeset viewer.