Class implements an plain vanilla (flo/fix) interest rate swap contract. More...
#include <IRS.hpp>
Public Member Functions | |
IRS () | |
Default constructor. More... | |
IRS (Date trade_date, Date start_date, Date maturity_date, CashFlowVector fixed_leg, CashFlowVector floating_leg, InterestRate fixed_leg_rate, InterestRate floating_leg_rate, double notional, double quoting, Frequency fixed_leg_freq, Frequency floating_leg_freq) | |
Constructor. More... | |
virtual IRS * | clone () const |
Virtual copy constructor. More... | |
Linear instrument interface | |
virtual double | price (const SmartPointer< ir::Curve > &) |
calculates price of IRS by summing the discounted CFs More... | |
virtual double | price (const SmartPointer< ir::Curve > &discounting, const SmartPointer< ir::Curve > &projecting, const SmartPointer< ir::Curve > &, const SmartPointer< ir::Curve > &) |
calculates price of IRS by summing the discounted CFs More... | |
virtual void | valuation (const SmartPointer< ir::Curve > &) |
prints price and CFs of IRS More... | |
virtual void | valuation (const SmartPointer< ir::Curve > &discounting, const SmartPointer< ir::Curve > &projecting, const SmartPointer< ir::Curve > &, const SmartPointer< ir::Curve > &) |
prints price and CFs of IRS More... | |
Building Block interface | |
virtual Date | getDate () const override |
returns maturity of IRS More... | |
virtual std::pair< CashFlowVector, CashFlowVector > | getCFs () const override |
Returns the sets of cashflows associated with IRS. More... | |
virtual double | calibrate (const SmartPointer< ir::Curve > &calibrated) override |
Method calibrate is used by root finding estimator. More... | |
virtual double | calibrate (const SmartPointer< ir::Curve > &discounting, const SmartPointer< ir::Curve > &projection, const SmartPointer< ir::Curve > &calibrated) override |
Method calibrate is used by root finding estimator. More... | |
virtual double | getParRate (const SmartPointer< ir::Curve > &discounting, const SmartPointer< ir::Curve > &projection, const SmartPointer< ir::Curve > &projection2) override |
Implies quoting of benchmark instrument from interest rate curves provided. More... | |
virtual double | getQuoting () override |
Returns quoting. More... | |
virtual void | changeQuoting (double) override |
changes quoting of the IRS More... | |
virtual InterestRate | getInterestRate () const override |
Returns interest rates convention of fixed leg. More... | |
std::string | info () const override |
Returns a name of instrument: FRA. More... | |
Public Member Functions inherited from julian::LinearInstrument | |
LinearInstrument () | |
constructor More... | |
virtual | ~LinearInstrument () |
destructor More... | |
Public Member Functions inherited from julian::ir::BuildingBlock | |
virtual | ~BuildingBlock () |
destructor More... | |
Private Attributes | |
Date | trade_date_ |
The date on which IRS is dealt. More... | |
Date | start_date_ |
The date initial date of first accrual period. More... | |
Date | maturity_date_ |
The date on which the IRS expires. More... | |
CashFlowVector | fixed_leg_ |
Fixed leg cash flows. More... | |
CashFlowVector | floating_leg_ |
Floating leg cash flows. More... | |
InterestRate | fixed_leg_rate_ |
Convention of fixed leg interest rate. More... | |
InterestRate | floating_leg_rate_ |
Convention of floating leg interest rate. More... | |
double | notional_ |
The amount for which IRS is traded. More... | |
double | quoting_ |
Interest rate at which IRS is paying fixed leg. More... | |
Frequency | fixed_leg_freq_ |
Frequency of payment of fixed leg. More... | |
Frequency | floating_leg_freq_ |
Frequency of payment of floating leg. More... | |
Friends | |
std::ostream & | operator<< (std::ostream &, IRS &) |
Overloads stream operator. More... | |
Detailed Description
Class implements an plain vanilla (flo/fix) interest rate swap contract.
IRS is an agreement between two counter-parties to make periodic interest payments to one another during the life of the swap, on a predetermined set of dates, based on a notional principal amount. One party is the fixed-rate payer (rate is agreed at the time of trade of the swap); other party is the floating-rate payer (rate is determined during the life of the swap)
For more details see [3] and [31].
- Examples:
- bootstrapperComparison.cpp.
Constructor & Destructor Documentation
|
inline |
Default constructor.
|
inline |
Constructor.
Member Function Documentation
|
overridevirtual |
Method calibrate is used by root finding estimator.
The estimator calibrates curve by finding the root of this method.
Calibrated curve is used to price the fixed leg.
Implements julian::ir::BuildingBlock.
|
overridevirtual |
Method calibrate is used by root finding estimator.
The estimator calibrates curve by finding the root of this method.
Calibrated curve is used as projection curve for floating leg. Discounting curve is used to prize fixed and floating leg.
Implements julian::ir::BuildingBlock.
|
overridevirtual |
changes quoting of the IRS
Implements julian::ir::BuildingBlock.
|
virtual |
Virtual copy constructor.
Implements julian::LinearInstrument.
|
overridevirtual |
Returns the sets of cashflows associated with IRS.
Implements julian::ir::BuildingBlock.
|
overridevirtual |
returns maturity of IRS
Implements julian::ir::BuildingBlock.
|
overridevirtual |
Returns interest rates convention of fixed leg.
Implements julian::ir::BuildingBlock.
|
overridevirtual |
Implies quoting of benchmark instrument from interest rate curves provided.
Implements julian::ir::BuildingBlock.
|
overridevirtual |
Returns quoting.
Implements julian::ir::BuildingBlock.
|
overridevirtual |
Returns a name of instrument: FRA.
Implements julian::ir::BuildingBlock.
|
virtual |
calculates price of IRS by summing the discounted CFs
- Parameters
-
c discounting curve
Implements julian::LinearInstrument.
|
virtual |
calculates price of IRS by summing the discounted CFs
Projecting curve is used to estimate CFs generated by floating leg. Discounting curve is used to discount CFs of both leg.
- Parameters
-
discounting discounting curve projecting projecting curve
Implements julian::LinearInstrument.
|
virtual |
prints price and CFs of IRS
Implements julian::LinearInstrument.
|
virtual |
prints price and CFs of IRS
Implements julian::LinearInstrument.
Friends And Related Function Documentation
|
friend |
Overloads stream operator.
This overloaded operator enables to print the curve on the console.
Member Data Documentation
|
private |
Fixed leg cash flows.
|
private |
Frequency of payment of fixed leg.
|
private |
Convention of fixed leg interest rate.
|
private |
Floating leg cash flows.
|
private |
Frequency of payment of floating leg.
|
private |
Convention of floating leg interest rate.
|
private |
The amount for which IRS is traded.
|
private |
Interest rate at which IRS is paying fixed leg.
|
private |
The date initial date of first accrual period.
The documentation for this class was generated from the following files:
- C:/Unix/home/OEM/jULIAN/src/instruments/linear/IRS.hpp
- C:/Unix/home/OEM/jULIAN/src/instruments/linear/IRS.cpp