9 private readonly Dictionary<int, double> _values =
12 private readonly List<MathematicalSolutionProjectionIssue> _issues =
19 public IReadOnlyDictionary<int, double>
Values =>
25 public IReadOnlyList<MathematicalSolutionProjectionIssue>
Issues =>
52 throw new ArgumentOutOfRangeException(
55 "A mathematical variable identifier must be positive.");
58 if (!
double.IsFinite(value))
60 throw new ArgumentOutOfRangeException(
63 "A projected mathematical value must be finite.");
70 throw new InvalidOperationException(
71 $
"A projected value already exists for mathematical " +
72 $
"variable '{variableId}'.");
83 ArgumentNullException.ThrowIfNull(issue);
96 return _values.TryGetValue(
Describes one issue encountered while projecting a business solution onto mathematical-model variable...
Contains mathematical-variable values projected from one normalized lot-sizing solution.
bool IsSuccessful
Gets whether every mathematical variable was projected successfully.
IReadOnlyList< MathematicalSolutionProjectionIssue > Issues
Gets all projection diagnostics.
int ProjectedVariableCount
Gets the number of projected variables.
void AddIssue(MathematicalSolutionProjectionIssue issue)
Adds one projection issue.
void AddValue(int variableId, double value)
Adds one projected mathematical-variable value.
IReadOnlyDictionary< int, double > Values
Gets the projected values indexed by mathematical variable identifier.
bool TryGetValue(int variableId, out double value)
Attempts to get the projected value of one mathematical variable.