/src/main/java/net/finmath/marketdata/products/SwapLeg.java
forward += forwardCurve.getForward( model, fixingDate, periodLength-fixingDate) ;
forward += forwardCurve.getForward ( model, fixingDate, paymentDate-fixingDate ) ;
final double periodStart = productToModelTimeOffset + legSchedule.getPeriodStart(periodIndex); final double periodEnd = productToModelTimeOffset + legSchedule.getPeriodEnd(periodIndex); final double paymentDate = productToModelTimeOffset + legSchedule.getPayment(periodIndex); final double periodLength = legSchedule.getPeriodLength(periodIndex); double forward = spreads[periodIndex]; if(forwardCurve != null) { <extra_id_0> } double notional = notionals != null ? notionals[periodIndex] : 1.0; if(discountCurveForNotionalReset != null && discountCurveForNotionalReset != discountCurve) { notional *= discountCurveForNotionalReset.getDiscountFactor(model,periodStart) / discountCurve.getDiscountFactor(model,periodStart); } final double discountFactor = paymentDate > cashFlowEffectiveTime ? discountCurve.getDiscountFactor(model, paymentDate) : 0.0;