@mark1russell7/stack-endurance 0.8.15 → 0.8.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -334,6 +334,8 @@ function bestShare(input) {
334
334
  };
335
335
  }
336
336
  // src/endurance.ts
337
+ /** The default horizon of a layer with a converter with a season: 730 days, thus two seasons of each year. */
338
+ const SEASON_HORIZON_DAYS = 730;
337
339
  /**
338
340
  * This function gives the `id` of each part that does not work in a case: the cut parts and the parts of `down`.
339
341
  * With a stack, it also gives each part that stops.
@@ -393,7 +395,7 @@ function makersOf(layer, stoppedParts) {
393
395
  const out = /* @__PURE__ */ new Map();
394
396
  for (const converter of layer.converters ?? []) {
395
397
  const resource = giftResource(converter);
396
- if (resource === void 0 || !canRun(converter, stoppedParts)) continue;
398
+ if (resource === void 0 || converter.season !== void 0 || !canRun(converter, stoppedParts)) continue;
397
399
  out.set(resource, [...out.get(resource) ?? [], converter]);
398
400
  }
399
401
  return out;
@@ -512,6 +514,125 @@ function inputClosure(ways) {
512
514
  }
513
515
  /** The relative tolerance of a used-up resource. */
514
516
  const USED_UP = 1e-9;
517
+ /** This function gives the day number of a day `MM-DD` of a year. A day that the year does not have gives undefined. */
518
+ function yearDay(year, monthDay) {
519
+ return dayNumber(`${String(year).padStart(4, "0")}-${monthDay}`);
520
+ }
521
+ /**
522
+ * This function gives the sow days of a season, in days from the start of the event, before the horizon, in increasing
523
+ * order (M2-grow). The sow day of a year is the first day of its window on the start or after it. A window with `from`
524
+ * after `to` goes across the end of the year. A year that does not have a day of the window (`02-29`) has no sowing.
525
+ *
526
+ * @throws RangeError when the start is not `YYYY-MM-DD`, or the horizon is not more than 0.
527
+ */
528
+ function sowDays(season, start, horizon) {
529
+ if (!(horizon > 0)) throw new RangeError(`The horizon ${String(horizon)} is not a number of days more than 0.`);
530
+ const first = dayOf(start);
531
+ const out = [];
532
+ for (let year = Number(start.slice(0, 4)) - 1;; year += 1) {
533
+ const from = yearDay(year, season.from);
534
+ const sameYear = yearDay(year, season.to);
535
+ const to = from !== void 0 && sameYear !== void 0 && sameYear < from ? yearDay(year + 1, season.to) : sameYear;
536
+ if ((from ?? yearDay(year, "01-01")) - first >= horizon) break;
537
+ if (from === void 0 || to === void 0 || to < first) continue;
538
+ const day = Math.max(from, first) - first;
539
+ if (day < horizon) out.push(day);
540
+ }
541
+ return out;
542
+ }
543
+ /** This function gives a lot of a store: it is ready before the event, and it does not spoil. */
544
+ function storeLot(resource, amount) {
545
+ return {
546
+ resource,
547
+ day: -1e400,
548
+ spoils: 1e400,
549
+ left: amount,
550
+ lost: 0
551
+ };
552
+ }
553
+ /** This function compares two numbers for a sort, also two that are Infinity. */
554
+ function compare(a, b) {
555
+ return a < b ? -1 : a > b ? 1 : 0;
556
+ }
557
+ /**
558
+ * This function takes the use of each resource from `from` to `to` from the lots, first expiring first out. It takes
559
+ * the lot that spoils first, then the lot of the earliest day. A store comes after each lot with a spoil day, and before each
560
+ * harvest with no spoil day. With no spoil day, the order is thus the stores, then each harvest in the order of its day.
561
+ */
562
+ function useLots(lots, from, to) {
563
+ for (const [resource, had] of from) {
564
+ let rest = had - (to.get(resource) ?? 0);
565
+ if (!(rest > 0)) continue;
566
+ const order = lots.filter((lot) => lot.resource === resource && lot.left > 0).sort((a, b) => compare(a.spoils, b.spoils) || compare(a.day, b.day));
567
+ for (const lot of order) {
568
+ if (!(rest > 0)) break;
569
+ const taken = Math.min(lot.left, rest);
570
+ lot.left -= taken;
571
+ rest -= taken;
572
+ }
573
+ }
574
+ }
575
+ /**
576
+ * This function gives the sowings of the converters with a season that can operate in a case, up to the horizon. It
577
+ * also gives the lot of each harvest. The order is the order of their sow days, then of the layer. Each sowing takes its inputs
578
+ * from `stock`, and from each harvest that is ready and not spoiled on its sow day (M2-grow-seed). It changes `stock`,
579
+ * and the `left` of each lot is the rest of its harvest after the later sowings.
580
+ */
581
+ function sowings(layer, stoppedParts, stock, makers, start, horizon) {
582
+ const plan = [];
583
+ (layer.converters ?? []).forEach((converter, order) => {
584
+ const season = converter.season;
585
+ if (season === void 0 || !(season.runs > 0) || !canRun(converter, stoppedParts)) return;
586
+ for (const sow of sowDays(season, start, horizon)) plan.push({
587
+ converter,
588
+ season,
589
+ sow,
590
+ order
591
+ });
592
+ });
593
+ plan.sort((a, b) => a.sow - b.sow || a.order - b.order);
594
+ const stores = [...stock].map(([resource, amount]) => storeLot(resource, amount));
595
+ const lots = [];
596
+ const out = [];
597
+ for (const { converter, season, sow } of plan) {
598
+ const ready = [...stores, ...lots.filter((lot) => lot.day <= sow && lot.spoils > sow)];
599
+ const pool = /* @__PURE__ */ new Map();
600
+ for (const lot of ready) pool.set(lot.resource, (pool.get(lot.resource) ?? 0) + lot.left);
601
+ const had = new Map(pool);
602
+ const runs = run(pool, makers, converter, season.runs, NO_PATH);
603
+ useLots(ready, had, pool);
604
+ const resource = giftResource(converter);
605
+ if (resource === void 0) continue;
606
+ const day = sow + season.delayDays;
607
+ const amount = runs * converter.gives.amount;
608
+ const spoils = season.shelfDays === void 0 ? 1e400 : day + season.shelfDays;
609
+ out.push({
610
+ converter: converter.id,
611
+ sow,
612
+ day,
613
+ runs,
614
+ resource,
615
+ amount,
616
+ ...season.shelfDays === void 0 ? {} : { spoils }
617
+ });
618
+ lots.push({
619
+ resource,
620
+ day,
621
+ spoils,
622
+ left: amount,
623
+ lost: 0
624
+ });
625
+ }
626
+ for (const store of stores) stock.set(store.resource, store.left);
627
+ return {
628
+ harvests: out,
629
+ lots
630
+ };
631
+ }
632
+ /** This function tells if a layer has a converter with a season that can run in a case. */
633
+ function hasSeason(layer, stoppedParts) {
634
+ return (layer.converters ?? []).some((converter) => converter.season !== void 0 && canRun(converter, stoppedParts));
635
+ }
515
636
  /**
516
637
  * This function gives the days that each draw holds when a case stops its supply, and the resources that are used up then.
517
638
  *
@@ -531,6 +652,14 @@ const USED_UP = 1e-9;
531
652
  * Thus a draw whose ways reach two converters of one device, each with a limit `perDay` more than 0, does not use the take order.
532
653
  * A linear program with exact rationals gives its days: the largest `T` with the best share of its stocks and of the device-days.
533
654
  * At this `T`, the draw takes the smallest sum of its takes of the stocks, each over its stock, then the fewest device-days.
655
+
656
+ * - A converter with a season (M2-grow) is not a maker of a take. Its sowings take their inputs from the stores before
657
+ * the first draw, and each harvest adds to the stocks on its day. Refer to `Season`. The query reads the sowings
658
+ * and the harvests up to the horizon (`horizon`, default `SEASON_HORIZON_DAYS`), and a draw holds the horizon at most.
659
+ * - With a season, each draw takes its stocks over spans from harvest to harvest. `days` is the first stop of the
660
+ * draw. A later harvest can feed the draw again: `again` gives these spans, and `takes` is the sum to the horizon.
661
+ * A lower draw gets the stocks that the higher draws leave, the earliest stocks first taken. This is the safe side.
662
+ * - A draw with a shared device and a season gets a `RangeError` (M2-grow-share).
534
663
  *
535
664
  * The function is pure, but for an internal count of the tries of its fits for the tests. It throws a `RangeError` for a date that is not `YYYY-MM-DD`. The gate `checkEndurance` examines the layer before.
536
665
  *
@@ -548,6 +677,19 @@ function enduranceOf(layer, caseCuts, options) {
548
677
  const devices = new Map(limited.map((converter) => [deviceKey(converter), converter.devices ?? 1]));
549
678
  const used = /* @__PURE__ */ new Map();
550
679
  let before = new Map(start);
680
+ const seasonal = hasSeason(layer, stoppedParts);
681
+ const horizon = seasonal ? seasonHorizon(options.horizon) : 1e400;
682
+ const sown = seasonal ? sowings(layer, stoppedParts, before, makers, options.start ?? options.at, horizon) : {
683
+ harvests: [],
684
+ lots: []
685
+ };
686
+ const harvests = sown.harvests;
687
+ const later = sown.lots.filter((lot) => lot.day < horizon && lot.left > 0).sort((a, b) => a.day - b.day).map((lot) => ({
688
+ day: lot.day,
689
+ spoils: lot.spoils,
690
+ resource: lot.resource,
691
+ amount: lot.left
692
+ }));
551
693
  const needs = {};
552
694
  for (const draw of caseDraws(layer, caseCuts, stoppedParts)) {
553
695
  const ways = waysOf(layer, draw.need, stoppedParts, makers);
@@ -555,7 +697,31 @@ function enduranceOf(layer, caseCuts, options) {
555
697
  const room = new Map([...devices].map(([key, count]) => [key, Math.max(0, count - (used.get(key) ?? 0))]));
556
698
  const closure = inputClosure(ways);
557
699
  const reach = /* @__PURE__ */ new Set([...ways.converters, ...[...closure].flatMap((resource) => makers.get(resource) ?? [])]);
558
- const share = sharesDevice(reach) ? bestShare({
700
+ const after = (stock, days) => {
701
+ const tried = new Map(stock);
702
+ for (const [key, free] of room) tried.set(RUNS + key, free * days);
703
+ return {
704
+ left: tried,
705
+ short: take(tried, ways, days * demand)
706
+ };
707
+ };
708
+ const span = (stock, limit, bound) => {
709
+ const fit = largestFit(Math.min(limit, bound / demand), (days) => {
710
+ const tried = after(stock, days);
711
+ return {
712
+ short: tried.short,
713
+ need: days * demand,
714
+ value: tried.left
715
+ };
716
+ });
717
+ return {
718
+ days: fit.x,
719
+ left: fit.value ?? after(stock, fit.x).left
720
+ };
721
+ };
722
+ const shares = sharesDevice(reach);
723
+ if (shares && seasonal) throw new RangeError(`The draw "${draw.need}" reaches two limited converters of one device, and the layer has a converter with a season. The query does not give their share (M2-grow-share).`);
724
+ const share = shares ? bestShare({
559
725
  draw,
560
726
  stock: before,
561
727
  room,
@@ -566,60 +732,149 @@ function enduranceOf(layer, caseCuts, options) {
566
732
  }) : void 0;
567
733
  let low;
568
734
  let left;
735
+ let final;
736
+ const came = new Map(before);
737
+ const lost = /* @__PURE__ */ new Map();
738
+ const pool = [...before].map(([resource, amount]) => storeLot(resource, amount));
739
+ const arrived = [];
740
+ const again = [];
741
+ let atHorizon = false;
742
+ const perDay = /* @__PURE__ */ new Map();
743
+ const count = (spanLeft, days) => {
744
+ if (days > 0) for (const [key, free] of room) {
745
+ const each = (free * days - (spanLeft.get(RUNS + key) ?? 0)) / days;
746
+ perDay.set(key, perDay.has(key) ? Math.max(perDay.get(key), each) : each);
747
+ }
748
+ };
749
+ let spanDays;
569
750
  if (share !== void 0) {
570
751
  low = share.days;
752
+ spanDays = low;
571
753
  left = new Map(before);
572
754
  for (const [resource, amount] of share.taken) left.set(resource, Math.max(0, (left.get(resource) ?? 0) - amount));
573
755
  for (const [key, free] of room) left.set(RUNS + key, Math.max(0, free * low - (share.used.get(key) ?? 0)));
756
+ final = left;
757
+ count(left, low);
758
+ } else if (later.length === 0 && !seasonal) {
759
+ ({days: low, left} = span(before, 1e400, capacity(start, ways)));
760
+ spanDays = low;
761
+ final = left;
762
+ count(left, low);
574
763
  } else {
575
- const after = (days) => {
576
- const tried = new Map(before);
577
- for (const [key, free] of room) tried.set(RUNS + key, free * days);
578
- return {
579
- left: tried,
580
- short: take(tried, ways, days * demand)
581
- };
764
+ let stock = new Map(before);
765
+ let next = 0;
766
+ let at = 0;
767
+ let first;
768
+ let resumed = 0;
769
+ const advance = () => {
770
+ while (next < later.length && later[next].day <= at) {
771
+ const harvest = later[next];
772
+ const lot = {
773
+ resource: harvest.resource,
774
+ day: harvest.day,
775
+ spoils: harvest.spoils,
776
+ left: harvest.amount,
777
+ lost: 0
778
+ };
779
+ pool.push(lot);
780
+ arrived.push({
781
+ lot,
782
+ harvest
783
+ });
784
+ stock.set(lot.resource, (stock.get(lot.resource) ?? 0) + lot.left);
785
+ came.set(lot.resource, (came.get(lot.resource) ?? 0) + lot.left);
786
+ next += 1;
787
+ }
788
+ for (const lot of pool) {
789
+ if (!(lot.left > 0) || lot.spoils > at) continue;
790
+ stock.set(lot.resource, Math.max(0, (stock.get(lot.resource) ?? 0) - lot.left));
791
+ lost.set(lot.resource, (lost.get(lot.resource) ?? 0) + lot.left);
792
+ lot.lost += lot.left;
793
+ lot.left = 0;
794
+ }
582
795
  };
583
- const fit = largestFit(capacity(start, ways) / demand, (days) => {
584
- const tried = after(days);
585
- return {
586
- short: tried.short,
587
- need: days * demand,
588
- value: tried.left
589
- };
590
- });
591
- low = fit.x;
592
- left = fit.value ?? after(low).left;
796
+ advance();
797
+ for (;;) {
798
+ const spoil = Math.min(...pool.filter((lot) => lot.left > 0).map((lot) => lot.spoils));
799
+ const end = Math.min(next < later.length ? later[next].day : 1e400, spoil, horizon);
800
+ const part = span(stock, end - at, capacity(stock, ways));
801
+ count(part.left, part.days);
802
+ const rest = resourcesOnly(part.left);
803
+ useLots(pool, stock, rest);
804
+ stock = rest;
805
+ const stop = at + part.days;
806
+ if (part.days < end - at) {
807
+ if (first === void 0) first = {
808
+ days: stop,
809
+ left: part.left,
810
+ spanDays: part.days
811
+ };
812
+ else if (stop > resumed) again.push({
813
+ from: resumed,
814
+ to: stop
815
+ });
816
+ if (next >= later.length) break;
817
+ at = later[next].day;
818
+ resumed = at;
819
+ } else {
820
+ at = end;
821
+ if (at >= horizon) {
822
+ if (first === void 0) atHorizon = true;
823
+ else again.push({
824
+ from: resumed,
825
+ to: horizon
826
+ });
827
+ break;
828
+ }
829
+ }
830
+ advance();
831
+ }
832
+ low = first?.days ?? horizon;
833
+ left = first?.left ?? stock;
834
+ spanDays = first?.spanDays ?? horizon;
835
+ final = stock;
593
836
  }
594
837
  const stores = resourcesOnly(left);
595
- const binding = [...closure].filter((resource) => !makers.has(resource) || stocked.has(resource)).filter((resource) => mostResource(stores, makers, resource, NO_PATH) <= USED_UP * Math.max(1, start.get(resource) ?? 0)).sort();
838
+ const binding = atHorizon ? [] : [...closure].filter((resource) => !makers.has(resource) || stocked.has(resource)).filter((resource) => mostResource(stores, makers, resource, NO_PATH) <= USED_UP * Math.max(1, start.get(resource) ?? 0)).sort();
596
839
  const takes = {};
597
- for (const [resource, amount] of before) {
598
- const taken = amount - (left.get(resource) ?? 0);
840
+ for (const [resource, amount] of came) {
841
+ const taken = amount - (final.get(resource) ?? 0) - (lost.get(resource) ?? 0);
599
842
  if (taken > 0) takes[resource] = taken;
600
843
  }
844
+ const spoiled = Object.fromEntries([...lost].filter(([, amount]) => amount > 0));
601
845
  const runsLeft = (converter) => (daysLeft(left, converter) ?? 0) * (converter.perDay ?? 0);
602
- const runsGiven = (converter) => (devices.get(deviceKey(converter)) ?? 1) * (converter.perDay ?? 0) * low;
603
- const capped = limited.filter((converter) => reach.has(converter)).filter((converter) => runsLeft(converter) <= USED_UP * Math.max(1, runsGiven(converter))).filter((converter) => mostRuns(stores, makers, converter, NO_PATH) > USED_UP).map((converter) => converter.id).sort();
604
- needs[draw.need] = capped.length === 0 ? {
605
- days: low,
606
- binding,
607
- takes
608
- } : {
846
+ const runsGiven = (converter) => (devices.get(deviceKey(converter)) ?? 1) * (converter.perDay ?? 0) * spanDays;
847
+ const capped = atHorizon ? [] : limited.filter((converter) => reach.has(converter)).filter((converter) => runsLeft(converter) <= USED_UP * Math.max(1, runsGiven(converter))).filter((converter) => mostRuns(stores, makers, converter, NO_PATH) > USED_UP).map((converter) => converter.id).sort();
848
+ needs[draw.need] = {
609
849
  days: low,
610
850
  binding,
611
851
  takes,
612
- capped
852
+ ...capped.length === 0 ? {} : { capped },
853
+ ...atHorizon ? { atHorizon: true } : {},
854
+ ...again.length === 0 ? {} : { again },
855
+ ...Object.keys(spoiled).length === 0 ? {} : { spoiled }
613
856
  };
614
- if (low > 0) for (const [key, free] of room) used.set(key, (used.get(key) ?? 0) + (free * low - (left.get(RUNS + key) ?? 0)) / low);
615
- before = stores;
857
+ for (const [key, each] of perDay) used.set(key, (used.get(key) ?? 0) + each);
858
+ if (later.length === 0 && !seasonal) {
859
+ before = resourcesOnly(final);
860
+ continue;
861
+ }
862
+ for (const lot of pool) if (lot.day === -1e400) before.set(lot.resource, lot.left);
863
+ for (const { lot, harvest } of arrived) harvest.amount = lot.left + lot.lost;
616
864
  }
617
865
  return {
618
866
  case: caseCuts.case,
619
867
  at: options.at,
620
- needs
868
+ needs,
869
+ ...harvests.length === 0 ? {} : { harvests }
621
870
  };
622
871
  }
872
+ /** This function gives the horizon of a layer with a season, or throws a `RangeError` for a horizon that is not more than 0. */
873
+ function seasonHorizon(horizon) {
874
+ const value = horizon ?? 730;
875
+ if (!(value > 0) || !Number.isFinite(value)) throw new RangeError(`The horizon ${String(horizon)} is not a number of days more than 0.`);
876
+ return value;
877
+ }
623
878
  /** This function tells if two converters of `reach` with a limit `perDay` more than 0 share one device. */
624
879
  function sharesDevice(reach) {
625
880
  const seen = /* @__PURE__ */ new Set();
@@ -663,6 +918,9 @@ function capacity(start, ways) {
663
918
  * converter with no limit uses no device-days, so its runs do not reduce the runs of the limited converter.
664
919
  * - `endurance-no-way` (warning): a draw has no direct use and no converter, so it holds 0 days when its supply stops.
665
920
  * - `endurance-cut-no-curve` (warning): a cut has no curve of its duration. The draws whose stop it can be part of are no read in the shortfall.
921
+ * - `endurance-season`: the season of a converter has a day that is not `MM-DD`. Or its delay or its shelf life is not more than 0.
922
+ * Or its count of sowings is not a finite number of 0 or more. Or the converter with a season gives a need, or it has
923
+ * `perDay` or `devices`. Since 0.8.16 (M2-grow).
666
924
  */
667
925
  const ENDURANCE_CODES = [
668
926
  "endurance-twice",
@@ -679,7 +937,8 @@ const ENDURANCE_CODES = [
679
937
  "endurance-devices",
680
938
  "endurance-device-mix",
681
939
  "endurance-no-way",
682
- "endurance-cut-no-curve"
940
+ "endurance-cut-no-curve",
941
+ "endurance-season"
683
942
  ];
684
943
  /**
685
944
  * This function gives each fault of an endurance layer. With a base stack, it also examines the `id` of each part. A list with no error tells that the gate passes.
@@ -764,6 +1023,7 @@ function checkEndurance(layer, stack) {
764
1023
  part(converter.id, "device", converter.device);
765
1024
  if (converter.perDay !== void 0) range(converter.id, "rate perDay", converter.perDay);
766
1025
  if (converter.devices !== void 0 && !(Number.isSafeInteger(converter.devices) && converter.devices >= 1)) add("error", "endurance-range", converter.id, `The count of devices of "${converter.id}" is ${String(converter.devices)}. It must be a whole number of 1 or more.`);
1026
+ if (converter.season !== void 0) for (const message of seasonFaults(converter)) add("error", "endurance-season", converter.id, message);
767
1027
  }
768
1028
  const counts = /* @__PURE__ */ new Map();
769
1029
  for (const converter of converters) {
@@ -818,12 +1078,32 @@ function checkEndurance(layer, stack) {
818
1078
  }
819
1079
  return faults;
820
1080
  }
821
- /** This function gives each cycle of resources: a resource is made from a resource that a converter makes from it. Each cycle is a list of codes. */
1081
+ /** This function tells if a text is a day `MM-DD` of a leap year. */
1082
+ function isMonthDay(value) {
1083
+ return /^\d{2}-\d{2}$/.test(value) && dayNumber(`2000-${value}`) !== void 0;
1084
+ }
1085
+ /** This function gives the messages of the faults of the season of a converter. */
1086
+ function seasonFaults(converter) {
1087
+ const season = converter.season;
1088
+ if (season === void 0) return [];
1089
+ const out = [];
1090
+ for (const day of [season.from, season.to]) if (!isMonthDay(day)) out.push(`The season of "${converter.id}" has the day "${day}". It is not a day MM-DD.`);
1091
+ if (!(Number.isFinite(season.delayDays) && season.delayDays > 0)) out.push(`The delay of the season of "${converter.id}" is ${String(season.delayDays)}. It must be a finite number of days more than 0.`);
1092
+ if (season.shelfDays !== void 0 && !(Number.isFinite(season.shelfDays) && season.shelfDays > 0)) out.push(`The shelf life of the season of "${converter.id}" is ${String(season.shelfDays)}. It must be a finite number of days more than 0.`);
1093
+ if (!(Number.isFinite(season.runs) && season.runs >= 0)) out.push(`The runs of the season of "${converter.id}" are ${String(season.runs)}. They must be a finite number of 0 or more.`);
1094
+ if (giftResource(converter) === void 0) out.push(`The converter "${converter.id}" has a season and gives a need. A converter with a season gives a resource.`);
1095
+ if (converter.perDay !== void 0 || converter.devices !== void 0) out.push(`The converter "${converter.id}" has a season and a limit perDay or devices. A converter with a season has no such limit.`);
1096
+ return out;
1097
+ }
1098
+ /**
1099
+ * This function gives each cycle of resources: a resource is made from a resource that a converter makes from it. Each cycle is a list of codes.
1100
+ * A converter with a season is not part of a cycle: its harvest comes after its sowing, thus a chain of it ends.
1101
+ */
822
1102
  function resourceCycles(converters) {
823
1103
  const from = /* @__PURE__ */ new Map();
824
1104
  for (const converter of converters) {
825
1105
  const made = giftResource(converter);
826
- if (made === void 0) continue;
1106
+ if (made === void 0 || converter.season !== void 0) continue;
827
1107
  const inputs = from.get(made) ?? /* @__PURE__ */ new Set();
828
1108
  for (const input of converter.takes) if (input.amount > 0) inputs.add(input.resource);
829
1109
  from.set(made, inputs);
@@ -897,6 +1177,6 @@ function joinEndurance(pieces) {
897
1177
  }
898
1178
  };
899
1179
  }
900
- export { exact as S, fewestRow as _, hasEnduranceError as a, addTo as b, drawDemand as c, giftResource as d, storeAmounts as f, drawBlock as g, deviceUse as h, curveFault as i, enduranceOf as l, caseParts as m, ENDURANCE_CODES as n, caseDraws as o, Program as p, checkEndurance as r, caseStopped as s, joinEndurance as t, giftNeed as u, reachOf as v, dense as x, valueAt as y };
1180
+ export { addTo as C, valueAt as S, exact as T, caseParts as _, hasEnduranceError as a, fewestRow as b, caseStopped as c, giftNeed as d, giftResource as f, Program as g, storeAmounts as h, curveFault as i, drawDemand as l, sowDays as m, ENDURANCE_CODES as n, SEASON_HORIZON_DAYS as o, hasSeason as p, checkEndurance as r, caseDraws as s, joinEndurance as t, enduranceOf as u, deviceUse as v, dense as w, reachOf as x, drawBlock as y };
901
1181
 
902
- //# sourceMappingURL=join-C9nJDe7B.js.map
1182
+ //# sourceMappingURL=join-B7THRfQS.js.map