Package org.jquantlib.pricingengines.swap

Examples of org.jquantlib.pricingengines.swap.DiscountingSwapEngine


        //floatFirstDate_ = Date.maxDate();
        //floatNextToLastDate_ = Date.maxDate();
        floatSpread_ = (0.0);
        fixedDayCount_ = (new Thirty360());
        floatDayCount_ = (index.dayCounter());
        engine_ = new DiscountingSwapEngine(index.termStructure());
    }
View Full Code Here


                    floatDayCount_,
                    BusinessDayConvention.Following
                    /* , fixingDays */);

            // ATM on the forecasting curve
            temp.setPricingEngine(new DiscountingSwapEngine(iborIndex_.termStructure()));
            usedFixedRate = temp.fairRate();
        }

        //FIXME: remove parameter "fixingDays"
        final VanillaSwap swap = new VanillaSwap (
View Full Code Here

        floatRule_ = r;
        return this;
    }

    public MakeVanillaSwap withDiscountingTermStructure(final Handle<YieldTermStructure> discountingTermStructure) {
        engine_ = (new DiscountingSwapEngine(discountingTermStructure));
        return this;
    }
View Full Code Here

        this.floatFirstDate        = new Date();
        this.floatNextToLastDate   = new Date();
        this.floatSpread       = 0.0;
        this.fixedDayCount     = new Thirty360();
        this.floatDayCount     = index.dayCounter();
        this.engine         = new DiscountingSwapEngine(index.termStructure());
    }
View Full Code Here

                    floatSpread,
                    floatDayCount,
                    BusinessDayConvention.Following);

            // ATM on the forecasting curve
            temp.setPricingEngine(new DiscountingSwapEngine(iborIndex.termStructure()));
            usedFixedRate = temp.fairRate();
        }

        final VanillaSwap swap = new VanillaSwap (
                type,
View Full Code Here

      this.floatRule = r;
        return this;
    }

    public MakeVanillaSwap withDiscountingTermStructure(final Handle<YieldTermStructure> discountingTermStructure) {
      this.engine = (new DiscountingSwapEngine(discountingTermStructure));
        return this;
    }
View Full Code Here

            final BMASwap swap = new BMASwap(BMASwap.Type.Payer, 100.0,
                               liborSchedule, 0.75, 0.0,
                               libor3m, libor3m.dayCounter(),
                               bmaSchedule, bma, vars.bmaDayCounter);
            swap.setPricingEngine(new DiscountingSwapEngine(libor3m.termStructure()));

            /*@Real*/ final double expectedFraction = bmaData[i].rate/100;
            /*@Real*/ final double estimatedFraction = swap.fairLiborFraction();
            /*@Real*/ final double error = Math.abs(expectedFraction-estimatedFraction);
            if (error > tolerance) {
View Full Code Here

                  iborIndex.dayCounter(),
                  bmaSchedule,
                  clonedIndex,
                  bmaDayCount);
     
      this.swap.setPricingEngine(new DiscountingSwapEngine(iborIndex.termStructure()));
     
      Date d = calendar.adjust(swap.maturityDate(), BusinessDayConvention.Following);
      Weekday w = d.weekday();
      Date nextWednesday = w.value() >=4 ? d.add(11 - w.value()) :  d.add(4 - w.value());
     
View Full Code Here

TOP

Related Classes of org.jquantlib.pricingengines.swap.DiscountingSwapEngine

Copyright © 2018 www.massapicom. 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.