FA-65289 / Epidemic compartment models / Member archive
Household secondary attack rate: stratum key · case 04
Size strata mix households of different sizes that share an at-risk count.
Case contract
Each household is [size, index_cases, secondary]; skip households without an index case, without members at risk, or with more secondaries than at-risk members; pooled SAR = sum secondary / sum (size-index); per-size table sorted by size ascending; return [pooled rounded 6 or None, table].
Why this case matters
Compartmental epidemic calculations drive outbreak forecasts, vaccine targets and hospital planning; a single wrong flow, rate conversion or boundary silently changes every downstream number.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| regression: mixed households | [0.444444, [[1, 1.0], [2, 0.0], [3, 0.5]]] | [0.444444, [[2, 1.0], [3, 0.0], [4, 0.666667], [5, 0.333333]]] | Failed |
MEMBER ARCHIVE
The complete case is available to members.
This record includes three runnable implementations, regression fixtures, execution results, and source hashes.
Member access is invitation-based. Sign in with your invited account to inspect the sources.
Sign in to the archive ↗