/src/main/java/net/finmath/marketdata/products/Cap.java
if( !Double.isNaN( payoffUnit) && cacheStateModel.get( ) == model && cacheStateIsFirstPeriodIncluded == isFirstPeriodIncluded) {
if ( !Double.isNaN ( cachedATMForward ) && cacheStateModel.get ( ) == model && cacheStateIsFirstPeriodIncluded == isFirstPeriodIncluded ) {
value += AnalyticFormulas.bachelierOptionValue(forward, volatility, fixingDate, effektiveStrike, payoffUnit); } } return value / discountCurve.getDiscountFactor(model, evaluationTime); } public double getATMForward(final AnalyticModel model, final boolean isFirstPeriodIncluded) { <extra_id_0> return cachedATMForward; } Schedule remainderSchedule = schedule; if(!isFirstPeriodIncluded) { final ArrayList<Period> periods = new ArrayList<>(); periods.addAll(schedule.getPeriods());