CappedFlooredCoupon Class Reference

#include <ql/cashflows/capflooredcoupon.hpp>

Inheritance diagram for CappedFlooredCoupon:

Inheritance graph
[legend]
List of all members.

Detailed Description

Capped and/or floored floating-rate coupon.

The payoff $ P $ of a capped floating-rate coupon is:

\[ P = N \times T \times \min(a L + b, C). \]

The payoff of a floored floating-rate coupon is:

\[ P = N \times T \times \max(a L + b, F). \]

The payoff of a collared floating-rate coupon is:

\[ P = N \times T \times \min(\max(a L + b, F), C). \]

where $ N $ is the notional, $ T $ is the accrual time, $ L $ is the floating rate, $ a $ is its gearing, $ b $ is the spread, and $ C $ and $ F $ the strikes.

They can be decomposed in the following manner. Decomposition of a capped floating rate coupon:

\[ R = \min(a L + b, C) = (a L + b) + \min(C - b - \xi |a| L, 0) \]

where $ \xi = sgn(a) $. Then:

\[ R = (a L + b) + |a| \min(\frac{C - b}{|a|} - \xi L, 0) \]


Visitability

boost::shared_ptr< FloatingRateCouponunderlying_
bool isCapped_
bool isFloored_
Rate cap_
Rate floor_
virtual void accept (AcyclicVisitor &)
bool isCapped () const
bool isFloored () const
void setPricer (const boost::shared_ptr< FloatingRateCouponPricer > &pricer)

Public Member Functions

 CappedFlooredCoupon (const boost::shared_ptr< FloatingRateCoupon > &underlying, Rate cap=Null< Rate >(), Rate floor=Null< Rate >())
Rate cap () const
 cap
Rate floor () const
 floor
Rate effectiveCap () const
 effective cap of fixing
Rate effectiveFloor () const
 effective floor of fixing
Coupon interface
Rate rate () const
 accrued rate
Rate convexityAdjustment () const
 convexity adjustment
Observer interface
void update ()


Member Function Documentation

void update (  )  [virtual]

This method must be implemented in derived classes. An instance of Observer does not call this method directly: instead, it will be called by the observables the instance registered with when they need to notify any changes.

Reimplemented from FloatingRateCoupon.