Skip to main content

averaged_sum

Function averaged_sum 

fn averaged_sum<R: Scalar>(
    coupon: &OvernightCoupon,
    fwd: Option<&dyn YieldCurve<R>>,
    fixings: &FixingsView<'_, R>,
    as_of: NaiveDate,
) -> Result<R, CashflowError>
Expand description

Σ rᵢ·τᵢ over the coupon’s observation strip — the numerator of an averaged overnight rate.

This cannot telescope. The compounded form collapses a run of projected days into one discount-factor ratio, because a product of DF(dᵢ)/DF(dᵢ₊₁) cancels at every interior boundary. A sum does not: rᵢ·τᵢ is DF(dᵢ)/DF(dᵢ₊₁) − 1, and summing those leaves every boundary standing. What the boundaries do share is the factor itself — one day’s DF(end) is the next day’s DF(start) — so carrying it across the boundary leaves an averaged coupon paying one curve query per projected day plus one per run, where a compounded one pays two per run.

That is a real cost the convention carries, not an oversight — and it is why this is written out rather than expressed as a variation on the growth walk.