QuantLib_Swaption man page

Swaption — Swaption class

Synopsis

#include <ql/instruments/swaption.hpp>

Inherits Option.

Classes

class arguments
Arguments for swaption calculation
class engine
base class for swaption engines

Public Member Functions

Swaption (const boost::shared_ptr< VanillaSwap > &swap, const boost::shared_ptr< Exercise > &exercise, Settlement::Type delivery=Settlement::Physical)

Volatility impliedVolatility (Real price, const Handle< YieldTermStructure > &discountCurve, Volatility guess, Real accuracy=1.0e-4, Natural maxEvaluations=100, Volatility minVol=1.0e-7, Volatility maxVol=4.0, Real displacement=0.0, VolatilityType type=ShiftedLognormal) const
implied volatility

Instrument interface

bool isExpired () const
returns whether the instrument might have value greater than zero.
void setupArguments (PricingEngine::arguments *) const

Inspectors

Settlement::Type settlementType () const

VanillaSwap::Type type () const

const boost::shared_ptr< VanillaSwap > & underlyingSwap () const

Additional Inherited Members

Detailed Description

Swaption class

Tests

·
the correctness of the returned value is tested by checking that the price of a payer (resp. receiver) swaption decreases (resp. increases) with the strike.
·
the correctness of the returned value is tested by checking that the price of a payer (resp. receiver) swaption increases (resp. decreases) with the spread.
·
the correctness of the returned value is tested by checking it against that of a swaption on a swap with no spread and a correspondingly adjusted fixed rate.
·
the correctness of the returned value is tested by checking it against a known good value.
·
the correctness of the returned value of cash settled swaptions is tested by checking the modified annuity against a value calculated without using the Swaption class.

Examples: BermudanSwaption.cpp.

Member Function Documentation

void setupArguments (PricingEngine::arguments *) const [virtual]

When a derived argument structure is defined for an instrument, this method should be overridden to fill it. This is mandatory in case a pricing engine is used.

Reimplemented from Instrument.

Author

Generated automatically by Doxygen for QuantLib from the source code.

Referenced By

Swaption(3) is an alias of QuantLib_Swaption(3).

Fri Sep 23 2016 Version 1.8.1 QuantLib