18 IEnumerable<double> minimumLotSizes,
19 IEnumerable<double> productionCapacities,
22 ArgumentNullException.ThrowIfNull(minimumLotSizes);
23 ArgumentNullException.ThrowIfNull(productionCapacities);
25 double[] lowerBounds =
26 minimumLotSizes.ToArray();
29 productionCapacities.ToArray();
32 lowerBounds.Length == 0 ||
33 lowerBounds.Length != capacities.Length)
35 throw new ArgumentException(
36 "Minimum-lot-size and capacity series must be non-empty " +
37 "and have the same length.");
40 ValidateNonNegativeFinite(
42 nameof(minimumLotSizes));
44 ValidateNonNegativeFinite(
46 nameof(productionCapacities));
59 double effectiveTolerance =
63 new double[lowerBounds.Length];
65 bool satisfied =
true;
67 for (
int index = 0; index < lowerBounds.Length; index++)
74 capacities[index] <= effectiveTolerance ||
75 Math.Abs(gaps[index]) > effectiveTolerance)