42 bool extrapolate)
const {
51 bool extrapolate)
const {
54 return std::sqrt(fwdVariance/
t);
59 bool extrapolate)
const {
68 bool extrapolate)
const {
72 QL_ENSURE(var1<var2,
"non-increasing variances");
81 QL_FAIL(
"not a EquityFXVolSurface term structure visitor");
degenerate base class for the Acyclic Visitor pattern
Real atmVariance(const Period &optionTenor, bool extrapolate=false) const
spot at-the-money variance
Black volatility (smile) surface.
Real atmForwardVariance(const Date &date1, const Date &date2, bool extrapolate=false) const
forward (at-the-money) variance
void accept(AcyclicVisitor &) override
EquityFXVolSurface(BusinessDayConvention bdc=Following, const DayCounter &dc=DayCounter())
default constructor
Volatility atmForwardVol(const Date &date1, const Date &date2, bool extrapolate=false) const
forward (at-the-money) volatility
Time timeFromReference(const Date &date) const
date/time conversion
Visitor for a specific class
virtual void visit(T &)=0
Equity/FX vol (smile) surface.
#define QL_ENSURE(condition, message)
throw an error if the given post-condition is not verified
#define QL_REQUIRE(condition, message)
throw an error if the given pre-condition is not verified
#define QL_FAIL(message)
throw an error (possibly with file and line information)
BusinessDayConvention
Business Day conventions.
Real Time
continuous quantity with 1-year units
unsigned QL_INTEGER Natural
positive integer
Real Volatility
volatility
ext::shared_ptr< BlackVolTermStructure > v