Examples of blackForwardVol()


Examples of org.jquantlib.termstructures.BlackVarianceTermStructure.blackForwardVol()

        volatility3 = varianceCurve.blackVol(date32.clone(), 40);
        System.out.println("Interpolated BlackVolatility on BlackVarianceCurve = "+volatility3);


        //Calculating blackForwardVolatility between 12 days after today and 16 days after today with strike as 20
        forwardVolatility1 = varianceCurve.blackForwardVol(date12.clone(), date16.clone(), 20, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceCurve = "+forwardVolatility1);

        //Calculating blackForwardVolatility between 22 days after today and 26 days after today with strike as 40
        forwardVolatility2 = varianceCurve.blackForwardVol(date22.clone(), date26.clone(), 40, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceCurve = "+forwardVolatility2);
View Full Code Here

Examples of org.jquantlib.termstructures.BlackVarianceTermStructure.blackForwardVol()

        //Calculating blackForwardVolatility between 12 days after today and 16 days after today with strike as 20
        forwardVolatility1 = varianceCurve.blackForwardVol(date12.clone(), date16.clone(), 20, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceCurve = "+forwardVolatility1);

        //Calculating blackForwardVolatility between 22 days after today and 26 days after today with strike as 40
        forwardVolatility2 = varianceCurve.blackForwardVol(date22.clone(), date26.clone(), 40, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceCurve = "+forwardVolatility2);

        //Calculating blackForwardVolatility between 27 days after today and 35 days after today with strike as 60
        forwardVolatility3 = varianceCurve.blackForwardVol(date27.clone(), date35.clone(), 60, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceCurve = "+forwardVolatility3);
View Full Code Here

Examples of org.jquantlib.termstructures.BlackVarianceTermStructure.blackForwardVol()

        //Calculating blackForwardVolatility between 22 days after today and 26 days after today with strike as 40
        forwardVolatility2 = varianceCurve.blackForwardVol(date22.clone(), date26.clone(), 40, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceCurve = "+forwardVolatility2);

        //Calculating blackForwardVolatility between 27 days after today and 35 days after today with strike as 60
        forwardVolatility3 = varianceCurve.blackForwardVol(date27.clone(), date35.clone(), 60, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceCurve = "+forwardVolatility3);


        //Calculating blackVariance using maturity as 12 days after today and strike as 20
        System.out.println("Interpolated BlackVariance on BlackVarianceCurve = "+varianceCurve.blackVariance(date12.clone(), 20));
View Full Code Here

Examples of org.jquantlib.termstructures.BlackVarianceTermStructure.blackForwardVol()

        volatility3 = varianceSurface.blackVol(date32.clone(), 45);
        System.out.println("Interpolated BlackVolatility on BlackVarianceSurface = "+volatility3);


        //Calculating blackForwardVolatility between 12 days after today and 16 days after today with strike as 20
        forwardVolatility1 = varianceSurface.blackForwardVol(date12.clone(), date16.clone(), 20, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceSurface = "+forwardVolatility1);

        //Calculating blackForwardVolatility between 22 days after today and 26 days after today with strike as 40
        forwardVolatility2 = varianceSurface.blackForwardVol(date22.clone(), date26.clone(), 40, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceSurface = "+forwardVolatility2);
View Full Code Here

Examples of org.jquantlib.termstructures.BlackVarianceTermStructure.blackForwardVol()

        //Calculating blackForwardVolatility between 12 days after today and 16 days after today with strike as 20
        forwardVolatility1 = varianceSurface.blackForwardVol(date12.clone(), date16.clone(), 20, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceSurface = "+forwardVolatility1);

        //Calculating blackForwardVolatility between 22 days after today and 26 days after today with strike as 40
        forwardVolatility2 = varianceSurface.blackForwardVol(date22.clone(), date26.clone(), 40, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceSurface = "+forwardVolatility2);

        //Calculating blackForwardVolatility between 27 days after today and 35 days after today with strike as 50
        forwardVolatility3 = varianceSurface.blackForwardVol(date27.clone(), date35.clone(), 50, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceSurface = "+forwardVolatility3);
View Full Code Here

Examples of org.jquantlib.termstructures.BlackVarianceTermStructure.blackForwardVol()

        //Calculating blackForwardVolatility between 22 days after today and 26 days after today with strike as 40
        forwardVolatility2 = varianceSurface.blackForwardVol(date22.clone(), date26.clone(), 40, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceSurface = "+forwardVolatility2);

        //Calculating blackForwardVolatility between 27 days after today and 35 days after today with strike as 50
        forwardVolatility3 = varianceSurface.blackForwardVol(date27.clone(), date35.clone(), 50, true);
        System.out.println("Interpolated BlackForwardVolatility on BlackVarianceSurface = "+forwardVolatility3);


        //Calculating blackVariance using maturity as 12 days after today and strike as 20
        System.out.println("Interpolated BlackVariance on BlackVarianceSurface = "+varianceSurface.blackVariance(date12.clone(), 20));
View Full Code Here

Examples of org.jquantlib.termstructures.BlackVarianceTermStructure.blackForwardVol()

        }


        //Calculating blackForwardVolatility between 12 days after today and 16 days after today with strike as 20
        forwardVolatility1 = varianceCurve.blackForwardVol(date12.clone(), date16.clone(), 20, true);
        final double impliedForwardVolatility1 = impliedVolTermStructure.blackForwardVol(date12.clone(), date16.clone(), 20, true);
        if(forwardVolatility1 == impliedForwardVolatility1){
            System.out.println("Interpolated BlackForwardVolatility on BlackVarianceCurve is same for varianceCurve and ImpliedVolTermStructure derived on it and = "+forwardVolatility1);
        }

        //Calculating blackForwardVolatility between 22 days after today and 26 days after today with strike as 40
View Full Code Here

Examples of org.jquantlib.termstructures.BlackVarianceTermStructure.blackForwardVol()

            System.out.println("Interpolated BlackForwardVolatility on BlackVarianceCurve is same for varianceCurve and ImpliedVolTermStructure derived on it and = "+forwardVolatility1);
        }

        //Calculating blackForwardVolatility between 22 days after today and 26 days after today with strike as 40
        forwardVolatility2 = varianceCurve.blackForwardVol(date22.clone(), date26.clone(), 40, true);
        final double impliedForwardVolatility2 = impliedVolTermStructure.blackForwardVol(date22.clone(), date26.clone(), 40, true);
        if(forwardVolatility2 == impliedForwardVolatility2){
            System.out.println("Interpolated BlackForwardVolatility on BlackVarianceCurve is same for varianceCurve and ImpliedVolTermStructure derived on it and = "+forwardVolatility2);
        }

        //Calculating blackForwardVolatility between 27 days after today and 35 days after today with strike as 60
View Full Code Here

Examples of org.jquantlib.termstructures.BlackVarianceTermStructure.blackForwardVol()

            System.out.println("Interpolated BlackForwardVolatility on BlackVarianceCurve is same for varianceCurve and ImpliedVolTermStructure derived on it and = "+forwardVolatility2);
        }

        //Calculating blackForwardVolatility between 27 days after today and 35 days after today with strike as 60
        forwardVolatility3 = varianceCurve.blackForwardVol(date27.clone(), date35.clone(), 60, true);
        final double impliedForwardVolatility3 = impliedVolTermStructure.blackForwardVol(date27.clone(), date35.clone(), 60, true);
        if(forwardVolatility3 == impliedForwardVolatility3){
            System.out.println("Interpolated BlackForwardVolatility on BlackVarianceCurve is same for varianceCurve and ImpliedVolTermStructure derived on it and = "+forwardVolatility3);
        }

View Full Code Here

Examples of org.jquantlib.termstructures.BlackVolatilityTermStructure.blackForwardVol()

        if(volatility1.equals(volatility2) && volatility2.equals(volatility3)){
            System.out.println("All the volatilities calculated above are same and = "+volatility1);
        }

        //Calculating blackForwardVolatility between 10 days after today and 15 days after today with strike as 20
        Double forwardVolatility1 = constantVolatility.blackForwardVol(date10.clone(), date15.clone(), 20, true);
        System.out.println("BlackForwardVolatility = "+forwardVolatility1);

        //Calculating blackForwardVolatility between 20 days after today and 25 days after today with strike as 40
        Double forwardVolatility2 = constantVolatility.blackForwardVol(date10.clone(), date15.clone(), 20, true);
        System.out.println("BlackForwardVolatility = "+forwardVolatility2);
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.