Examples of visitCouponIborSpread()


Examples of com.opengamma.analytics.financial.interestrate.ParRateCalculator.visitCouponIborSpread()

        final int nbCpn = getNumberOfPayments();
        final double[] cpnRate = new double[nbCpn];
        for (int loopcpn = 0; loopcpn < nbCpn; loopcpn++) {
          if (getNthPayment(loopcpn) instanceof CouponIborRatchet) {
            final CouponIborRatchet cpn = (CouponIborRatchet) getNthPayment(loopcpn);
            final double ibor = prc.visitCouponIborSpread(cpn, curves);
            final double cpnMain = cpn.getMainCoefficients()[0] * cpnRate[loopcpn - 1] + cpn.getMainCoefficients()[1] * ibor + cpn.getMainCoefficients()[2];
            final double cpnFloor = cpn.getFloorCoefficients()[0] * cpnRate[loopcpn - 1] + cpn.getFloorCoefficients()[1] * ibor + cpn.getFloorCoefficients()[2];
            final double cpnCap = cpn.getCapCoefficients()[0] * cpnRate[loopcpn - 1] + cpn.getCapCoefficients()[1] * ibor + cpn.getCapCoefficients()[2];
            cpnRate[loopcpn] = Math.min(Math.max(cpnFloor, cpnMain), cpnCap);
            calibration.add(new CapFloorIbor(cpn.getCurrency(), cpn.getPaymentTime(), cpn.getFundingCurveName(), cpn.getPaymentYearFraction(), cpn.getNotional(), cpn.getFixingTime(), cpn.getIndex(),
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.