QuantLib: a free/open-source library for quantitative finance
fully annotated source code - version 1.34
|
#include <optionletstripper1.hpp>
Public Member Functions | |
OptionletStripper1 (const ext::shared_ptr< CapFloorTermVolSurface > &, const ext::shared_ptr< IborIndex > &index, Rate switchStrikes=Null< Rate >(), Real accuracy=1.0e-6, Natural maxIter=100, const Handle< YieldTermStructure > &discount={}, VolatilityType type=ShiftedLognormal, Real displacement=0.0, bool dontThrow=false) | |
const Matrix & | capFloorPrices () const |
const Matrix & | capletVols () const |
const Matrix & | capFloorVolatilities () const |
const Matrix & | optionletPrices () const |
Rate | switchStrike () const |
Public Member Functions inherited from OptionletStripper | |
const std::vector< Rate > & | optionletStrikes (Size i) const override |
const std::vector< Volatility > & | optionletVolatilities (Size i) const override |
const std::vector< Date > & | optionletFixingDates () const override |
const std::vector< Time > & | optionletFixingTimes () const override |
Size | optionletMaturities () const override |
const std::vector< Rate > & | atmOptionletRates () const override |
DayCounter | dayCounter () const override |
Calendar | calendar () const override |
Natural | settlementDays () const override |
BusinessDayConvention | businessDayConvention () const override |
const std::vector< Period > & | optionletFixingTenors () const |
const std::vector< Date > & | optionletPaymentDates () const |
const std::vector< Time > & | optionletAccrualPeriods () const |
ext::shared_ptr< CapFloorTermVolSurface > | termVolSurface () const |
ext::shared_ptr< IborIndex > | iborIndex () const |
Real | displacement () const override |
VolatilityType | volatilityType () const override |
virtual const std::vector< Rate > & | optionletStrikes (Size i) const =0 |
virtual const std::vector< Volatility > & | optionletVolatilities (Size i) const =0 |
virtual const std::vector< Date > & | optionletFixingDates () const =0 |
virtual const std::vector< Time > & | optionletFixingTimes () const =0 |
virtual Size | optionletMaturities () const =0 |
virtual const std::vector< Rate > & | atmOptionletRates () const =0 |
virtual DayCounter | dayCounter () const =0 |
virtual Calendar | calendar () const =0 |
virtual Natural | settlementDays () const =0 |
virtual BusinessDayConvention | businessDayConvention () const =0 |
virtual VolatilityType | volatilityType () const =0 |
virtual Real | displacement () const =0 |
Public Member Functions inherited from LazyObject | |
LazyObject () | |
~LazyObject () override=default | |
void | update () override |
bool | isCalculated () const |
void | forwardFirstNotificationOnly () |
void | alwaysForwardNotifications () |
void | recalculate () |
void | freeze () |
void | unfreeze () |
Public Member Functions inherited from Observable | |
Observable () | |
Observable (const Observable &) | |
Observable & | operator= (const Observable &) |
Observable (Observable &&)=delete | |
Observable & | operator= (Observable &&)=delete |
virtual | ~Observable ()=default |
void | notifyObservers () |
Public Member Functions inherited from Observer | |
Observer ()=default | |
Observer (const Observer &) | |
Observer & | operator= (const Observer &) |
virtual | ~Observer () |
std::pair< iterator, bool > | registerWith (const ext::shared_ptr< Observable > &) |
void | registerWithObservables (const ext::shared_ptr< Observer > &) |
Size | unregisterWith (const ext::shared_ptr< Observable > &) |
void | unregisterWithAll () |
virtual void | update ()=0 |
virtual void | deepUpdate () |
LazyObject interface | |
Matrix | capFloorPrices_ |
Matrix | optionletPrices_ |
Matrix | capFloorVols_ |
Matrix | optionletStDevs_ |
Matrix | capletVols_ |
bool | floatingSwitchStrike_ |
Rate | switchStrike_ |
Real | accuracy_ |
Natural | maxIter_ |
bool | dontThrow_ |
void | performCalculations () const override |
Helper class to strip optionlet (i.e. caplet/floorlet) volatilities (a.k.a. forward-forward volatilities) from the (cap/floor) term volatilities of a CapFloorTermVolSurface.
Definition at line 44 of file optionletstripper1.hpp.
OptionletStripper1 | ( | const ext::shared_ptr< CapFloorTermVolSurface > & | termVolSurface, |
const ext::shared_ptr< IborIndex > & | index, | ||
Rate | switchStrikes = Null<Rate>() , |
||
Real | accuracy = 1.0e-6 , |
||
Natural | maxIter = 100 , |
||
const Handle< YieldTermStructure > & | discount = {} , |
||
VolatilityType | type = ShiftedLognormal , |
||
Real | displacement = 0.0 , |
||
bool | dontThrow = false |
||
) |
Definition at line 37 of file optionletstripper1.cpp.
const Matrix & capFloorPrices | ( | ) | const |
const Matrix & capletVols | ( | ) | const |
const Matrix & capFloorVolatilities | ( | ) | const |
const Matrix & optionletPrices | ( | ) | const |
Rate switchStrike | ( | ) | const |
|
overridevirtual |
This method must implement any calculations which must be (re)done in order to calculate the desired results.
Implements LazyObject.
Definition at line 60 of file optionletstripper1.cpp.
|
mutableprivate |
Definition at line 68 of file optionletstripper1.hpp.
|
private |
Definition at line 68 of file optionletstripper1.hpp.
|
mutableprivate |
Definition at line 69 of file optionletstripper1.hpp.
|
mutableprivate |
Definition at line 70 of file optionletstripper1.hpp.
|
private |
Definition at line 70 of file optionletstripper1.hpp.
|
private |
Definition at line 72 of file optionletstripper1.hpp.
|
mutableprivate |
Definition at line 74 of file optionletstripper1.hpp.
|
private |
Definition at line 75 of file optionletstripper1.hpp.
|
private |
Definition at line 76 of file optionletstripper1.hpp.
|
private |
Definition at line 77 of file optionletstripper1.hpp.