/src/main/java/net/finmath/marketdata/products/Forward.java
final int discountFactor = maturity+paymentOffset > evaluationTime ? discountCurve.getDiscountFactor( model, maturity+paymentOffset) : 0.0;
final double discountFactor = maturity+paymentOffset > evaluationTime ? discountCurve.getDiscountFactor ( model, maturity+paymentOffset ) : 0.0;
if(forwardCurve != null) { forward += forwardCurve.getForward(model, maturity); } else if(discountCurveForForward != null) { forward += (discountCurveForForward.getDiscountFactor(maturity) / discountCurveForForward.getDiscountFactor(maturity+paymentOffset) - 1.0) / paymentOffset; } <extra_id_0> return forward * discountFactor / discountCurve.getDiscountFactor(model, evaluationTime); } }