QuantLib: a free/open-source library for quantitative finance
fully annotated source code - version 1.34
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
CapPseudoDerivative Class Reference

#include <swaptionpseudojacobian.hpp>

+ Collaboration diagram for CapPseudoDerivative:

Public Member Functions

 CapPseudoDerivative (const ext::shared_ptr< MarketModel > &inputModel, Real strike, Size startIndex, Size endIndex, Real firstDF)
 
const MatrixvolatilityDerivative (Size i) const
 
const MatrixpriceDerivative (Size i) const
 
Real impliedVolatility () const
 

Private Attributes

ext::shared_ptr< MarketModelinputModel_
 
std::vector< MatrixvolatilityDerivatives_
 
std::vector< MatrixpriceDerivatives_
 
Real impliedVolatility_
 
Real vega_
 
Real firstDF_
 

Detailed Description

In order to compute market vegas, we need a class that gives the derivative of a cap implied vol against changes in pseudo-root elements. This is that class.

The operation is non-trivial because the cap implied vol has a complicated relationship with the caplet implied vols.

This is tested in the pathwise vegas routine in MarketModels.cpp

Definition at line 78 of file swaptionpseudojacobian.hpp.

Constructor & Destructor Documentation

◆ CapPseudoDerivative()

CapPseudoDerivative ( const ext::shared_ptr< MarketModel > &  inputModel,
Real  strike,
Size  startIndex,
Size  endIndex,
Real  firstDF 
)

Definition at line 232 of file swaptionpseudojacobian.cpp.

+ Here is the call graph for this function:

Member Function Documentation

◆ volatilityDerivative()

const Matrix & volatilityDerivative ( Size  i) const

Definition at line 367 of file swaptionpseudojacobian.cpp.

+ Here is the caller graph for this function:

◆ priceDerivative()

const Matrix & priceDerivative ( Size  i) const

Definition at line 362 of file swaptionpseudojacobian.cpp.

◆ impliedVolatility()

Real impliedVolatility ( ) const

Definition at line 374 of file swaptionpseudojacobian.cpp.

Member Data Documentation

◆ inputModel_

ext::shared_ptr<MarketModel> inputModel_
private

Definition at line 96 of file swaptionpseudojacobian.hpp.

◆ volatilityDerivatives_

std::vector<Matrix> volatilityDerivatives_
private

Definition at line 98 of file swaptionpseudojacobian.hpp.

◆ priceDerivatives_

std::vector<Matrix> priceDerivatives_
private

Definition at line 100 of file swaptionpseudojacobian.hpp.

◆ impliedVolatility_

Real impliedVolatility_
private

Definition at line 102 of file swaptionpseudojacobian.hpp.

◆ vega_

Real vega_
private

Definition at line 103 of file swaptionpseudojacobian.hpp.

◆ firstDF_

Real firstDF_
private

Definition at line 104 of file swaptionpseudojacobian.hpp.