Docs / nablatensor-quant / com.nablatensor.quant.analytic
record
CdsParSpread
The par spread of a single-name credit default swap from a survival curve and a discount curve on a common time grid — the closed-form reference for the bootstrapped-hazard CDS pricing in nablatensor-cva.
The grid times[i] (ascending, all > 0) carries the survival probability survival[i] = Q(0, times[i]) and the risk-free discount factor discount[i] = P(0, times[i]); time zero has Q = 1, P = 1 implicitly. Over segment i = (times[i-1], times[i]] of length dt_i:
protection leg = (1 - R) * sum_i Dmid_i * (Q_{i-1} - Q_i)
premium annuity = sum_i dt_i * D_i * (Q_{i-1} + Q_i) / 2 (accrual on default, half period)
par spread = protection leg / premium annuity
where Dmid_i = (D_{i-1} + D_i) / 2 approximates discounting to the mid-point of the segment in which default occurs. A monthly (or finer) grid keeps the piecewise-flat approximation tight.
Record components
Methods
Mark-to-market of a bought-protection position paying contractSpread on unit notional.