Discounting swap engine providing analytical deltas and gammas. More...
#include <qle/pricingengines/discountingswapenginedeltagamma.hpp>
Public Member Functions | |
DiscountingSwapEngineDeltaGamma (const Handle< YieldTermStructure > &discountCurve=Handle< YieldTermStructure >(), const std::vector< Time > &bucketTimes=std::vector< Time >(), const bool computeDelta=false, const bool computeGamma=false, const bool computeBPS=false, const bool linearInZero=true) | |
void | calculate () const override |
Handle< YieldTermStructure > | discountCurve () const |
Private Attributes | |
Handle< YieldTermStructure > | discountCurve_ |
const std::vector< Real > | bucketTimes_ |
const bool | computeDelta_ |
const bool | computeGamma_ |
const bool | computeBPS_ |
const bool | linearInZero_ |
Discounting swap engine providing analytical deltas and gammas.
The provided deltas and gammas are (continuously compounded) zero yield deltas assuming linear in zero or loglinear in discount factor interpolation on the discounting and forwarding curves with flat extrapolation of the zero rate before the first and last bucket time. The deltas are provided as additional results
deltaDiscount (vector<Real> ): Delta on discount curve, rebucketed on time grid deltaForward (vector<Real> ): Delta on forward curve, rebucketed on time grid deltaBPS (vector<vector<Real>> ): Delta of BPS (on discount curve, per leg)
The gammas, likewise,
gamma (Matrix ): Gamma matrix with blocks | dsc-dsc dsc-fwd | | dsc-fwd fwd-fwd | gammaBps (vector<Matrix> ): Gamma of BPS (on dsc, per leg)
bucketTimes (vector<Real> ): Bucketing grid for deltas and gammas
Derivatives are not w.r.t. basispoints, but w.r.t. the usual unit
BPS is the value of one unit (not one basispoint actually), it has to be divided by 10000.0 to get QL's BPS
Definition at line 70 of file discountingswapenginedeltagamma.hpp.
DiscountingSwapEngineDeltaGamma | ( | const Handle< YieldTermStructure > & | discountCurve = Handle<YieldTermStructure>() , |
const std::vector< Time > & | bucketTimes = std::vector<Time>() , |
||
const bool | computeDelta = false , |
||
const bool | computeGamma = false , |
||
const bool | computeBPS = false , |
||
const bool | linearInZero = true |
||
) |
Definition at line 375 of file discountingswapenginedeltagamma.cpp.
|
override |
Definition at line 386 of file discountingswapenginedeltagamma.cpp.
Handle< YieldTermStructure > discountCurve | ( | ) | const |
Definition at line 77 of file discountingswapenginedeltagamma.hpp.
|
private |
Definition at line 80 of file discountingswapenginedeltagamma.hpp.
|
private |
Definition at line 81 of file discountingswapenginedeltagamma.hpp.
|
private |
Definition at line 82 of file discountingswapenginedeltagamma.hpp.
|
private |
Definition at line 82 of file discountingswapenginedeltagamma.hpp.
|
private |
Definition at line 82 of file discountingswapenginedeltagamma.hpp.
|
private |
Definition at line 82 of file discountingswapenginedeltagamma.hpp.