Description
Include both window endpoints, wrapping across cycle end when start>end; return nonnegative modular days to start.
Policy-related period and quantity calculations need explicit expiry boundaries, claim-season anchors and moisture conventions. Half-open periods differ from inclusive day counts, and moisture-standardized mass differs from observed wet mass. Supplied rules and reference values do not establish current policy.
Include both window endpoints, wrapping across cycle end when start>end; return nonnegative modular days to start.
When to use this tool
Use Agricultural Tariff Season Window Gap when checking the stated caller-defined policy time, proration or material-basis convention.
How to use the tool and how it works
- Enter day, startDay, endDay, calendarDays. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read withinWindow, daysToStart. Inspect withinWindow before interpreting the associated values.
Require whole calendarDays 1..366 and day/start/end within 1..calendarDays. Include both window endpoints, wrapping across cycle end when start>end; return nonnegative modular days to start.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| day | Day | Required. Safe integer; minimum 1. |
| startDay | Start Day | Required. Safe integer; minimum 1. |
| endDay | End Day | Required. Safe integer; minimum 1. |
| calendarDays | Supplied whole cycle length 1..366; no civil calendar is selected. | Required. Safe integer; minimum 1; maximum 366. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| withinWindow | Within Window | Required. Boolean. |
| daysToStart | Nonnegative forward modular distance, zero at start even if the season is currently active. | Required. Safe integer. |
{
"input": {
"day": 10,
"startDay": 350,
"endDay": 20,
"calendarDays": 365
},
"output": {
"withinWindow": true,
"daysToStart": 340
}
} Limitations and assumptions
- A cycle-day index is not a civil date; equal start/end selects one day rather than the entire calendar cycle.
- Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
- Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.
Alternative or Complementary methods
Use verified dates, quantities and authoritative current program or contract documents for real administrative and financial decisions.
References
Similar or alternative tools
- Quota Carryover Expiry Gap
Return remaining units, expiryDay-checkDay and boundary usability using <= or < according to expiryIncluded.
- Agricultural Tariff Season Label
Qualify an explicit agricultural tariff record by season and rule version without applying tariffs.