Class CapletVolatilitiesParametricFourParameterPicewiseConstant

  • All Implemented Interfaces:
    Cloneable, ParameterObject, VolatilitySurface

    public class CapletVolatilitiesParametricFourParameterPicewiseConstant
    extends AbstractVolatilitySurfaceParametric
    A parametric caplet volatility surface created form the picewise constant (numerical integration) of the four parameter model for the instantaneous forward rate volatility given by \( \sigma(t) = (a + b t) \exp(- c t) + d \). In other words, the Black volatility for maturity T is given by \[ \sqrt{ \frac{1}{t_{n}} \sum_{i=0}^{n-1} ((a + b t_{i}) \exp(- c t_{i}) + d)^2 (t_{i+1}-t_{i}) } \], where \( t_{i} \) is given time discretization.
    Version:
    1.0
    Author:
    Christian Fries
    • Constructor Detail

      • CapletVolatilitiesParametricFourParameterPicewiseConstant

        public CapletVolatilitiesParametricFourParameterPicewiseConstant​(String name,
                                                                         LocalDate referenceDate,
                                                                         double a,
                                                                         double b,
                                                                         double c,
                                                                         double d,
                                                                         TimeDiscretization timeDiscretization)
        Create a model with parameters a,b,c,d.
        Parameters:
        name - The name of this volatility surface.
        referenceDate - The reference date for this volatility surface, i.e., the date which defined t=0.
        a - The parameter a
        b - The parameter b
        c - The parameter c
        d - The parameter d
        timeDiscretization - The timeDiscretizationFromArray used in numerical integration.
    • Method Detail

      • getValue

        public double getValue​(double maturity,
                               double strike,
                               VolatilitySurface.QuotingConvention quotingConvention)
        Description copied from interface: VolatilitySurface
        Returns the price or implied volatility for the corresponding maturity and strike.
        Parameters:
        maturity - The option maturity for which the price or implied volatility is requested.
        strike - The option strike for which the price or implied volatility is requested.
        quotingConvention - The quoting convention to be used for the return value.
        Returns:
        The price or implied volatility depending on the quoting convention.
      • getValue

        public double getValue​(AnalyticModel model,
                               double maturity,
                               double strike,
                               VolatilitySurface.QuotingConvention quotingConvention)
        Description copied from interface: VolatilitySurface
        Returns the price or implied volatility for the corresponding maturity and strike.
        Parameters:
        model - An analytic model providing a context. Some curves do not need this (may be null).
        maturity - The option maturity for which the price or implied volatility is requested.
        strike - The option strike for which the price or implied volatility is requested.
        quotingConvention - The quoting convention to be used for the return value.
        Returns:
        The price or implied volatility depending on the quoting convention.
      • getParameter

        public double[] getParameter()
        Description copied from interface: ParameterObject
        Get the current parameter associated with the state of the objects.
        Returns:
        The parameter.
      • setParameter

        public void setParameter​(double[] parameter)
        Description copied from interface: ParameterObject
        Set the current parameter and change the state of the objects.
        Parameters:
        parameter - The parameter associated with the new state of the objects.