Hi Alexander,
yes, for ZCIIS you are correct - thanks for
catching it. The tests are ATM so this didn't show up.
For inflation indexed bonds then you do need an
IndexedCashFlow that does not have the -1, so both versions are
required in general. Both IndexedCashFlow and ZeroCouponInflationSwap now updated in the SVN for the 0.99 branch.
The interface to IndexedCashFlow has changed from:
IndexedCashFlow(Real notional,
const boost::shared_ptr<Index> &index,
const Date&
baseDate,
const Date& fixingDate,
const Date& paymentDate)
to:
IndexedCashFlow(Real notional,
const boost::shared_ptr<Index> &index,
const Date&
baseDate,
const Date& fixingDate,
const Date& paymentDate,
bool growthOnly = false)
The bond-focused version (without the -1) is the default, and ZCIIS uses it with growthOnly = true so the desired effect of I(T)/I(0) - 1
happens for the swap.
Best,
Chris
From: "[hidden email]" <[hidden email]>
To: [hidden email]
Sent: Tue, December 15, 2009 7:35:33 PM
Subject: Question about ZeroCouponInflationSwap
Hello Chris,
I priced a zero coupon inflation swap and can't explain the both legs.
I've noticed that the inflation leg is priced using the formula of the IndexedCashFlow
notional * I(T1) / I(T0)
But in papers and books I found the following formula
Inflation Leg = Notional * I(T1)/I(T0) - 1
So I am missing this -1. Am I wrong?
Best
Alexander
------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev _______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users