24#ifndef quantlib_btp_hpp
25#define quantlib_btp_hpp
88 Real accuracy = 1.0e-8,
89 Size maxEvaluations = 100)
const;
101 const std::vector<ext::shared_ptr<BTP> >&
btps()
const;
112 std::vector<ext::shared_ptr<BTP> >
btps_;
123 ext::shared_ptr<Euribor> euriborIndex,
130 const std::vector<Rate>&
yields()
const;
131 const std::vector<Time>&
durations()
const;
134 const std::vector<Rate>&
swapRates()
const;
163 mutable std::vector<ext::shared_ptr<VanillaSwap> >
swaps_;
177 ext::shared_ptr<RendistatoCalculator>
r_;
188 ext::shared_ptr<RendistatoCalculator>
r_;
203 inline const std::vector<ext::shared_ptr<BTP> >&
208 inline const std::vector<Handle<Quote> >&
214 return std::inner_product(
basket_->weights().begin(),
253 inline ext::shared_ptr<VanillaSwap>
284 return r_->equivalentSwapLength();
288 return r_->equivalentSwapSpread();
Italian BTP (Buono Poliennali del Tesoro) fixed rate bond.
Rate yield(Real cleanPrice, Date settlementDate=Date(), Real accuracy=1.0e-8, Size maxEvaluations=100) const
BTP yield given a (clean) price and settlement date.
Real accruedAmount(Date d=Date()) const override
accrued amount at a given date
Real cleanPrice() const
theoretical clean price
virtual Real accruedAmount(Date d=Date()) const
accrued amount at a given date
const ext::shared_ptr< CashFlow > & redemption() const
Date maturityDate() const
Date settlementDate(Date d=Date()) const
Real accruedAmount(Date d=Date()) const override
accrued amount at a given date
floating-rate bond (possibly capped and/or floored)
Shared handle to an observable.
T result(const std::string &tag) const
returns any additional result returned by the pricing engine.
Framework for calculation on demand and result caching.
virtual void calculate() const
Object that notifies its changes to a set of observers.
Object that gets notified when a given observable changes.
purely virtual base class for market observables
const std::vector< ext::shared_ptr< BTP > > & btps() const
const std::vector< Real > & outstandings() const
std::vector< ext::shared_ptr< BTP > > btps_
const std::vector< Handle< Quote > > & cleanPriceQuotes() const
const std::vector< Real > & weights() const
std::vector< Real > weights_
std::vector< Real > outstandings_
std::vector< Handle< Quote > > quotes_
Size equivalentSwapIndex_
void performCalculations() const override
Rate equivalentSwapYield() const
Handle< YieldTermStructure > discountCurve_
const std::vector< Time > & swapLengths() const
const std::vector< Rate > & swapYields() const
std::vector< Time > swapBondDurations_
ext::shared_ptr< Euribor > euriborIndex_
std::vector< Time > swapLengths_
const std::vector< Rate > & yields() const
std::vector< Rate > swapBondYields_
Time equivalentSwapLength() const
ext::shared_ptr< VanillaSwap > equivalentSwap() const
const std::vector< Time > & durations() const
std::vector< ext::shared_ptr< VanillaSwap > > swaps_
std::vector< Time > durations_
std::vector< Rate > yields_
std::vector< Rate > swapRates_
const std::vector< Time > & swapDurations() const
Spread equivalentSwapSpread() const
const std::vector< Rate > & swapRates() const
Rate equivalentSwapRate() const
ext::shared_ptr< RendistatoBasket > basket_
Time equivalentSwapDuration() const
RendistatoCalculator equivalent swap lenth Quote adapter.
ext::shared_ptr< RendistatoCalculator > r_
Real value() const override
returns the current value
bool isValid() const override
returns true if the Quote holds a valid value
RendistatoCalculator equivalent swap spread Quote adapter.
ext::shared_ptr< RendistatoCalculator > r_
Real value() const override
returns the current value
bool isValid() const override
returns true if the Quote holds a valid value
Real Time
continuous quantity with 1-year units
Real Spread
spreads on interest rates
std::size_t Size
size of a container
ext::shared_ptr< YieldTermStructure > r
Simple fixed-rate vs Libor swap.