Class BlackVolSurface
- Namespace
- NanoQL.Experimental
- Assembly
- NanoQL.dll
The base of Black volatility (smile) surfaces: a smile section at each time, the at-the-money volatility and variance read off it. Volatilities are on an annual basis.
[Experimental("NQL0001")]
public abstract class BlackVolSurface : BlackAtmVolCurve
- Inheritance
-
BlackVolSurface
- Derived
- Inherited Members
- Extension Methods
Remarks
An extension point, as in QuantLib. QuantLib's acyclic visitor isn't ported.
Constructors
BlackVolSurface(Date, Calendar?, BusinessDayConvention, DayCounter, int?)
Initializes a new instance of the BlackVolSurface class at a reference date.
protected BlackVolSurface(Date referenceDate, Calendar? calendar, BusinessDayConvention bdc, DayCounter dayCounter, int? settlementDays = null)
Parameters
referenceDateDateThe reference date.
calendarCalendarThe calendar, or null for QuantLib's empty one.
bdcBusinessDayConventionThe business-day convention of the option dates; QuantLib's default is
Following.dayCounterDayCounterThe day counter.
settlementDaysint?The settlement days the reference date was moved by, or null.
Exceptions
- ArgumentNullException
dayCounteris null.- ArgumentException
The reference date is
default(Date).- ArgumentOutOfRangeException
bdcisn't a member of its type.
Methods
AtmVarianceImpl(double)
The at-the-money variance at a time already range-checked.
protected override double AtmVarianceImpl(double t)
Parameters
tdoubleThe time.
Returns
- double
The variance.
Exceptions
- NanoQLException
The smile section has no at-the-money level.
AtmVolImpl(double)
The at-the-money volatility at a time already range-checked.
protected override double AtmVolImpl(double t)
Parameters
tdoubleThe time.
Returns
- double
The volatility.
Exceptions
- NanoQLException
The smile section has no at-the-money level.
SmileSection(Date, bool)
The smile section at a date.
public SmileSection SmileSection(Date date, bool extrapolate)
Parameters
Returns
- SmileSection
The smile section.
Exceptions
- ArgumentException
dateisdefault(Date).- NanoQLException
The date is out of range.
SmileSection(Period, bool)
The smile section at an option tenor.
public SmileSection SmileSection(Period optionTenor, bool extrapolate)
Parameters
Returns
- SmileSection
The smile section.
Exceptions
- NanoQLException
The option date is out of range, or can't be computed.
SmileSection(double, bool)
The smile section at a time.
public SmileSection SmileSection(double t, bool extrapolate)
Parameters
Returns
- SmileSection
The smile section.
Exceptions
- NanoQLException
The time is out of range.
SmileSectionImpl(double)
The smile section at a time already range-checked.
protected abstract SmileSection SmileSectionImpl(double t)
Parameters
tdoubleThe time.
Returns
- SmileSection
The smile section.