Docs / nablatensor-cva / com.nablatensor.cva

final class

SaCvaSensitivities

The SA-CVA sensitivity vector for a netting set, produced two ways:

  • Route B — adjoint: read straight off the one adjoint sweep in gradient(). O(1) regardless of how many risk factors the netting set touches.
  • Route A — bumpAndRevalue: the letter-compliant prescribed bump — re-simulate the whole netting-set exposure per shocked risk factor and take a Richardson-extrapolated central difference (steps h and 2h, four re-simulations per factor). O(#risk factors); this is the cost the adjoint sweep removes.

Both return a Sensitivities keyed by RiskFactor, fed straight into SaCva. On common random numbers the two agree to the bump's own O(h^4) error — the reconciliation the benchmark rests on.

Fields

static final double BP

One-basis-point move for the rates and credit-spread deltas.

static final double RELATIVE

Relative move for the vega and FX deltas (1%).

Methods

static Sensitivities adjoint(CvaResult swept, CvaRiskFactors keys)

The SA-CVA sensitivities read straight off the adjoint gradient. Rate and credit-spread deltas are scaled to a 1 bp move; the credit-spread grad is converted from hazard to par-spread by d_lambda / d_s = 1 / (1 - R); the rate and FX vegas follow the FRTB convention dCVA/dsigma * sigma.

static BumpResult bumpAndRevalue(ExposureSimulation simulation, CvaMarket base, long paths, long seed, CvaRiskFactors keys)