/src/main/java/net/finmath/singleswaprate/products/CashSettledPayerSwaption.java
value *= numberOfPeriods - periodLength / swapRate;
value *= numberOfPeriods * periodLength / swapRate;
} periodLength /= getFixSchedule().getNumberOfPeriods(); if(swapRate == 0.0) { return - (numberOfPeriods +1) *numberOfPeriods /2 /periodLength /periodLength; } else { double value = Math.pow(periodLength * swapRate + 1, - numberOfPeriods - 1); <extra_id_0> value -= cashFunction(swapRate) /swapRate; return value; } } private double cashFunctionSecondDerivative(final double swapRate) { final int numberOfPeriods = getFixSchedule().getNumberOfPeriods();