1using LotSizingDataModel.Core.DecisionModel.Scheduling;
26 throw new ArgumentNullException(
27 nameof(extensionAnalyzer));
34 ArgumentNullException.ThrowIfNull(descriptor);
35 ArgumentNullException.ThrowIfNull(definition);
40 .DiscreteLotSizingAndScheduling and not
42 .ContinuousSetupLotSizing and not
44 .ProportionalLotSizingAndScheduling)
52 "SmallBucketSchedulingAnalyzer:UnsupportedClass"
56 List<string> incomplete =
59 List<string> contradictions =
68 "Scheduling:Integrated");
74 "Scheduling:SmallBucket");
80 "Structure:ItemCount");
85 "Structure:MultiItem");
91 "Structure:SingleLevel");
97 "Scheduling:ResourceCount");
102 "Scheduling:SingleResource");
114 "Demand:Deterministic");
120 "Production:Present");
126 "Capacity:Production");
137 SmallBucketProductionMode.Unspecified)
140 "Scheduling:ProductionMode");
146 "Scheduling:MaximumProducedItemCount");
149 if (contradictions.Count > 0)
158 if (incomplete.Count > 0)
167 return definition.Id
switch
170 .DiscreteLotSizingAndScheduling =>
176 .ContinuousSetupLotSizing =>
182 .ProportionalLotSizingAndScheduling =>
188 throw new InvalidOperationException(
189 "Unexpected small-bucket scheduling problem class.")
199 SmallBucketProductionMode.AllOrNothing ||
202 return NotApplicable(
204 "DLSP:AllOrNothingAndAtMostOneItemPerBucket");
214 .IntegratedScheduling,
216 .SmallBucketScheduling,
218 .MaximumProducedItemCount
222 private LotSizingProblemClassMatchResult AssessCslp(
224 LotSizingProblemClassDefinition definition)
228 SmallBucketProductionMode.Continuous ||
231 return NotApplicable(
233 "CSLP:ContinuousAndAtMostOneItemPerBucket");
243 .IntegratedScheduling,
245 .SmallBucketScheduling,
247 .MaximumProducedItemCount
251 private LotSizingProblemClassMatchResult AssessPlsp(
252 LotSizingProblemDescriptor descriptor,
253 LotSizingProblemClassDefinition definition)
257 SmallBucketProductionMode.Continuous ||
260 return NotApplicable(
262 "PLSP:ContinuousAndAtMostTwoItemsPerBucket");
268 return new LotSizingProblemClassMatchResult(
274 "PLSP:MaximumSetupTransitionsPerBucket"
281 return NotApplicable(
283 "PLSP:AtMostOneSetupTransitionPerBucket");
293 .IntegratedScheduling,
295 .SmallBucketScheduling,
299 .MaximumProducedItemCount
303 private LotSizingProblemClassMatchResult Member(
304 LotSizingProblemDescriptor descriptor,
305 LotSizingProblemClassDefinition definition,
306 IEnumerable<LotSizingProblemClassExtensionKind>
310 new HashSet<LotSizingProblemClassExtensionKind>(
318 !core.Contains(extension))
321 return new LotSizingProblemClassMatchResult(
323 extensions.Length == 0
329 private static LotSizingProblemClassMatchResult NotApplicable(
330 LotSizingProblemClassDefinition definition,
331 string failedRequirement) =>
bool HasSharedProductionCapacity
bool HasProductionCapacity
Typed structured description of the factual lot-sizing problem characteristics currently represented ...
CapacityDescriptor Capacity
StructureDescriptor Structure
SchedulingDescriptor Scheduling
ProductionDescriptor Production
Factual integrated lot-sizing/scheduling characteristics.
int SchedulingResourceCount
bool HasSingleSchedulingResource
bool HasSmallBucketStructure
int MaximumSetupTransitionsPerBucket
bool HasMaximumProducedItemCountConstraint
int MaximumProducedItemCountPerBucket
SmallBucketProductionMode SmallBucketProductionMode
bool HasMaximumSetupCountConstraints
bool HasIntegratedScheduling
One canonical scientific problem-class definition.
CanonicalLotSizingProblemClassId Id
Identifies modeled extensions outside the six currently executable canonical lot-sizing core signatur...
Complete canonical problem-class membership assessment.
SmallBucketSchedulingProblemClassAnalyzer()
SmallBucketSchedulingProblemClassAnalyzer(LotSizingProblemClassExtensionAnalyzer extensionAnalyzer)
LotSizingProblemClassMatchResult Assess(LotSizingProblemDescriptor descriptor, LotSizingProblemClassDefinition definition)
LotSizingProblemClassMatchKind
Relationship between an instance descriptor and one canonical problem class.
LotSizingProblemClassExtensionKind
Modeled characteristics outside the canonical core signatures.
CanonicalLotSizingProblemClassId
Stable canonical LotSizingDataModel identifiers for problem classes.