Skip to main content

sigma_from_price

Function sigma_from_price 

pub fn sigma_from_price(
    model: &HullWhite,
    passive_curve: &dyn YieldCurve<f64>,
    expiry: NaiveDate,
    bond_maturity: NaiveDate,
    strike: f64,
    kind: OptionKind,
    target_price: f64,
) -> Option<SolvedParameter>
Expand description

The Hull-White sigma implying target_price for a zero-bond option.

A passive kernel, reattached analytically. The solve runs on plain f64 through a derivative-free view of the curve, so nothing is recorded for the iteration — a bisection over two hundred steps would otherwise put two hundred repricings on the tape to recover one number.

What comes back is the fitted volatility together with ∂sigma/∂P, the implicit-function derivative of the calibration condition. A caller reattaches with reattach: the sensitivity a calibrated parameter carries is the one the calibration condition implies, and expressing it as arithmetic in the pricing mode is what replaces splicing a solved value onto a tape.

Returns None when the target is outside the range the formula can produce.