Skip to content

v0.3.0 — cross-flow census and bound

Choose a tag to compare

@clarkbw clarkbw released this 16 Aug 02:53
· 6 commits to main since this release
6b218d3

Measures and bounds the 1-D major-axis approximation this package emits.

What this adds

The bundle models each station as one signed speed along a fixed flood axis. NOAA also publishes minorMeanSpeed — the DC component of flow perpendicular to that axis, running at all times including slack — which the extractor fetched and discarded.

Bundles now carry a crossFlow census at the root (~200 bytes) recording how much the major-axis model drops:

cross-flow (856 harmonic records): 62 >= 0.25 kn, 12 >= 0.50 kn
  worst ratio    0.241 at BOS1130 (0.178 kn across a 0.74 kn axis)
  worst absolute 0.803 kn at PUG1619

validateBundle fails above a cross-flow/along-axis ratio of 0.5. Because the census is stored on the bundle rather than printed, that check runs offline against any bundle with no re-extraction. extract and validate both print it.

alongAxisPeak is Σ|majorAmplitude| + |Z₀| — a theoretical maximum where every constituent aligns, not a realized peak. The ratio only means anything given that denominator, so it is documented in the schema and the types.

What this deliberately does not add

No per-station minor-axis data. Bundling the full minor axis was measured and rejected: it is worth a median 4% of peak speed, and a 2-D magnitude series never crosses zero — so slack detection silently returns nothing at 836 of 850 stations. The census provides the diagnostic without the payload.

Compatibility

Additive and backward compatible. A bundle without a crossFlow block still validates — absent means "not measured", never "failed". No breaking changes to any existing field.

index.d.ts gains CrossFlowCensus, Bundle.crossFlow, and a previously missing NoaaConstituent.minorMeanSpeed.

Bundle asset

The attached currents.json is the minified US bundle: 856 harmonic + 1,705 subordinate stations, 0 unresolvable references. No NOAA station data changed since the previous bundle — the diff is the census block alone.