26#include <ql/math/interpolation.hpp>
27#include <ql/math/interpolations/interpolation2d.hpp>
28#include <ql/patterns/lazyobject.hpp>
29#include <ql/quote.hpp>
30#include <ql/termstructures/volatility/equityfx/blackvoltermstructure.hpp>
31#include <ql/termstructures/yieldtermstructure.hpp>
32#include <ql/time/daycounters/actual365fixed.hpp>
44 const Handle<Quote>& movingSpot,
const std::vector<Time>& times,
46 const std::vector<std::vector<Handle<Quote>>>& volSpreads,
47 const Handle<Quote>& stickySpot,
48 const Handle<YieldTermStructure>& stickyDividendTs,
49 const Handle<YieldTermStructure>& stickyRiskFreeTs,
50 const Handle<YieldTermStructure>& movingDividendTs,
51 const Handle<YieldTermStructure>& movingRiskFreeTs,
bool stickyStrike);
61 const std::vector<QuantLib::Real>&
moneyness()
const;
Black volatility surface based on forward log moneyness.
Real strikeFromMoneyness(Time t, Real moneyness, const bool stickyReference) const override
Real moneynessFromStrike(Time t, Real strike, const bool stickyReference) const override
Spreaded Black volatility surface based on spot log moneyness.
Real strikeFromMoneyness(Time t, Real moneyness, const bool stickyReference) const override
Real moneynessFromStrike(Time t, Real strike, const bool stickyReference) const override
Spreaded Black volatility surface based on absolute forward moneyness.
Real strikeFromMoneyness(Time t, Real moneyness, const bool stickyReference) const override
Real moneynessFromStrike(Time t, Real strike, const bool stickyReference) const override
Black volatility surface based on forward moneyness.
Real strikeFromMoneyness(Time t, Real moneyness, const bool stickyReference) const override
Real moneynessFromStrike(Time t, Real strike, const bool stickyReference) const override
Abstract Spreaded Black volatility surface based on moneyness (moneyness defined in subclasses)
void performCalculations() const override
Handle< Quote > movingSpot_
Handle< BlackVolTermStructure > referenceVol_
Calendar calendar() const override
virtual Real strikeFromMoneyness(Time t, Real moneyness, const bool stickyReference) const =0
virtual Real moneynessFromStrike(Time t, Real strike, const bool stickyReference) const =0
Handle< Quote > stickySpot_
const std::vector< QuantLib::Real > & moneyness() const
const Date & referenceDate() const override
Real minStrike() const override
std::vector< Time > times_
Handle< YieldTermStructure > movingRiskFreeTs_
SpreadedBlackVolatilitySurfaceMoneyness(const Handle< BlackVolTermStructure > &referenceVol, const Handle< Quote > &movingSpot, const std::vector< Time > ×, const std::vector< Real > &moneyness, const std::vector< std::vector< Handle< Quote > > > &volSpreads, const Handle< Quote > &stickySpot, const Handle< YieldTermStructure > &stickyDividendTs, const Handle< YieldTermStructure > &stickyRiskFreeTs, const Handle< YieldTermStructure > &movingDividendTs, const Handle< YieldTermStructure > &movingRiskFreeTs, bool stickyStrike)
Natural settlementDays() const override
Handle< YieldTermStructure > movingDividendTs_
Date maxDate() const override
Handle< YieldTermStructure > stickyRiskFreeTs_
std::vector< std::vector< Handle< Quote > > > volSpreads_
Real blackVolImpl(Time t, Real strike) const override
Interpolation2D volSpreadSurface_
Handle< YieldTermStructure > stickyDividendTs_
Real maxStrike() const override
std::vector< Real > moneyness_
Spreaded Black volatility surface based on absolute spot moneyness.
Real strikeFromMoneyness(Time t, Real moneyness, const bool stickyReference) const override
Real moneynessFromStrike(Time t, Real strike, const bool stickyReference) const override
Spreaded Black volatility surface based on spot moneyness.
Real strikeFromMoneyness(Time t, Real moneyness, const bool stickyReference) const override
Real moneynessFromStrike(Time t, Real strike, const bool stickyReference) const override
Black volatility surface based on std devs (standardised log moneyness)
Real strikeFromMoneyness(Time t, Real moneyness, const bool stickyReference) const override
Real moneynessFromStrike(Time t, Real strike, const bool stickyReference) const override