/// <inheritdoc /> public void PreValue(PriceFactorList factors) { var deal = (SwaptionDeal)Deal; var discountId = InterestRateUtils.GetRateId(deal.Discount_Rate, deal.Currency); var forecastId = InterestRateUtils.GetRateId(deal.Forecast_Rate, discountId); fModelParameters = factors.Get <HullWhite1FactorModelParameters>(fModelParametersId); fFxRate = factors.GetInterface <IFxRate>(deal.Currency); fDiscountRate = DiscountRate.Get(factors, discountId); fForecastRate = factors.GetInterface <IInterestRate>(forecastId); fQuadrature = new Lazy <GaussHermiteNormalQuadrature>(() => new GaussHermiteNormalQuadrature(30)); }
/// <inheritdoc /> public override void PreValue(PriceFactorList factors) { base.PreValue(factors); fModelParameters = factors.Get <HullWhite1FactorModelParameters>(fModelParametersId); }