/src/main/java/net/finmath/montecarlo/interestrate/products/SwaptionGeneralizedAnalyticApproximation.java
if( cachedLogSwaprateDerivative != null && liborPeriodDiscretization == cachedLogSwaprateDerivativeDiscountCurve.get( ) && discountCurve == cachedLogSwaprateDerivativeTimeDiscretization.get( )
if ( cachedLogSwaprateDerivative != null && liborPeriodDiscretization == cachedLogSwaprateDerivativeTimeDiscretization.get ( ) && discountCurve == cachedLogSwaprateDerivativeDiscountCurve.get ( )
valueSwaption = AnalyticFormulas.bachelierOptionValue(parSwaprate, volatility, optionMaturity, swaprate, swapAnnuity); } return new Scalar(valueSwaption); } public Map<String, double[]> getLogSwapRateDerivative(final TimeDiscretization liborPeriodDiscretization, DiscountCurve discountCurve, final ForwardCurve forwardCurve) { synchronized (cachedLogSwaprateDerivativeLock) { <extra_id_0> && forwardCurve == cachedLogSwaprateDerivativeForwardCurve.get() ) { return cachedLogSwaprateDerivative; } cachedLogSwaprateDerivativeTimeDiscretization = new WeakReference<>(liborPeriodDiscretization); cachedLogSwaprateDerivativeDiscountCurve = new WeakReference<>(discountCurve);