|
From: Luigi B. <lui...@gm...> - 2023-03-23 10:48:41
|
Hello everybody,
a question on the calculation of the year-on-year inflation fixings
used in the payoff of, say, year-on-year inflation swaps; specifically, the
interpolated case.
Let's say we have a coupon that needs the interpolated year-on-year
inflation for October 20th 2022.
The current implementation (see <
https://github.com/lballabio/QuantLib/blob/master/ql/indexes/inflationindex.cpp#L330-L356>)
does as follows:
- read the four relevant inflation fixings: October 2021, November 2021,
October 2022, November 2022;
- calculate an interpolated fixing F1 by interpolating October 2021 and
November 2021;
- calculate an interpolated fixing F2 by interpolating October 2022 and
November 2022;
- calculate the interpolated year-on-year performance as F2/F1 - 1.
Another possibility would be:
- read the four relevant inflation fixings: October 2021, November 2021,
October 2022, November 2022;
- calculate the October year-on-year performance as P1 = October
2022/October 2021 - 1;
- calculate the November year-on-year performance as P2 =
November 2022/November 2021 - 1;
- calculate the interpolated year-on-year performance by interpolating P1
and P2.
The two yield similar results but not identical.
To further confuse things, the equivalent of the second one is used (see <
https://github.com/lballabio/QuantLib/blob/master/ql/indexes/inflationindex.cpp#L376-L387>)
is the year-on-year performance is published, rather than calculated as a
ratio; in that case, we interpolate between the October-on-October and
November-on-November performances.
Can anybody confirm whether the current implementation correctly models the
payoff calculations in the real world, or the other one does instead?
Thanks a lot!
Luigi
|