I know how to calculate them for bonds. But it came to my mind this.

In bonds, Macaulay duration technically is a weighted average of coupon payments. But can it be somehow calculated for swaps? Or when dealing with swaps, you always need to proxy duration as the "contractual duration"?


3 Answers 3


If you know how to calculate them for bonds, you know how to calculate them for swaps.

Assuming you refer to fixed-income swaps where a party receives a fixed rate and pays a floating rate or vice versa, the duration of a swap is the duration of the long position and the duration of your short position, which in this case will be a negative duration. Let's say a swap is entered where party 'A' will receive a floating rate and will pay a fixed rate. This is the same as issuing a fixed-rate bond and using the proceeds of such issuance to buy a floating-rate bond. Thus, the duration of the swap can be summarized as:

$\text{duration of swap} = \text{duration of long position} - \text{duration of short position}$

In our example, as party 'A' is borrowing at a fixed-rate it would be benefited with rising rates and a lower market value. In the same way, he will see the benefit of being long the floating-rate because future payments will reflect the rise in rates.

To finish, let's express the idea with numbers. Let's say the duration of the floater for party 'A' is 0.125 and the duration on the short side is 0.75. In this case the duration of the swap would be

$0.125 - 0.75 = -0.625$,

a negative duration. Effectively, when rates rise, his short position would be worth less. As a note of reference $\text{change in price} = -\,\text{duration} \cdot \text{change in yield}$. So when rates rise, the market yield will rise and the market value of the short position decreases. Entering the same swap again, would require party 'A' to pay a higher fixed rate. The opposite logic will apply to his long position.

  • $\begingroup$ Hi, thanks for the response. If I wanted to support this professionally, is there any academic literature to back this methodology up? $\endgroup$ Commented Mar 26, 2020 at 22:41
  • 1
    $\begingroup$ I’m sure there are as I’ve studied it. After running a quick search on Google you may find something here oreilly.com/library/view/bond-math-the/9781576603062/… I must say I don’t know what Oreilly is. $\endgroup$
    – teoeme139
    Commented Mar 27, 2020 at 12:29
  • 2
    $\begingroup$ The Oreilly web site is based on the book BOND MATH: The Theory Behind the Formulas by Donald J. Smith (2011,2014) , Bloomberg Press, ISBN: 9781576603062 so that is your academic reference for you. $\endgroup$
    – nbbo2
    Commented Mar 27, 2020 at 13:43
  • $\begingroup$ This answer does not address the question, which referred to the Macaulay duration. The latter can be defined - approximately - as -(1/P)(dP/dy), where P is the NPV of the instrument and y its yield. Your answer addresses the "dollar duration", which is defined as -dP/dy, but this is not what has been asked for. $\endgroup$
    – Yannis
    Commented Nov 20, 2020 at 10:03

The Macauley duration is defined for fixed rate bonds as

Macauley duration formula

The sum is over all bond cash flows, including the coupons and the principal at maturity.

Each cash flow occurs at tᵢ and has a present value denoted by PVᵢ.

V is the sum of all PVᵢ and equals of course the present value of the bond.

Although this formula could be in principle applied on any type of financial instrument as long as its present value V is not 0, nobody does so in practice. The reason is that this formula returns a value in time units - for example 8.5 years for a 10-year bond - that turns out to be very close to the sensitivity of the bond price wrt interest rates, but only if the instrument is a fixed rate bond.

It is easy to prove that for a fixed rate bond and a continuously compounded discounting rate y, the Macaulay duration equals the Modified duration defined by

Modified Duration Formula

This equality reduces to an approximation when the rate y is not continuously compounded or when the cash flows are not those of a fixed rate bond.


It makes no sense to use the Macaulay duration for swaps!

Possible resolution:

Most people today use the Modified duration to represent in annual units the interest rate risk of certain financial instruments because this definition of duration can also apply to instruments that pay floating rate coupons.

A par floater for example would have a Modified duration exactly equal to zero, if the first coupon rate has not yet been fixed. Otherwise its duration would equal that for the first coupon.

Some people have the impression they can calculate the Modified duration of a swap by considering the swap as a portfolio of two bonds: A long fixed rate bond and a short floater.

Then the argument goes, the swap duration could be defined as the sum of the two durations.

There is no basis to this argument for the simple reason that the Modified duration is not additive!

You can see this by considering a portfolio of two equal zero bonds, each maturing in 10 years. If the Modified duration were additive, the portfolio's duration would equal 10 + 10 = 20 years, which is absurd!

The correct definition of the Modified duration D of a portfolio is: D = w₁D₁ + w₂D₂ + ... + wₙDₙ where Dᵢ is the Modified duration of the iᵗʰ bond and wᵢ is the iᵗʰ bond's weight defined as: wᵢ = market value of iᵗʰ bond / market value of portfolio

This definition makes sense only for portfolios of long bonds. It makes no sense for portfolios of mixed long and short positions.

As a proof, consider a receiver swap seen as an equivalent portfolio consisting of a long bond with a 10 year duration and a short floater with zero duration. Assume also that both bonds have an equal absolute market value.

Then the total market value becomes zero and the weights w₁ and w₂ jump to infinity!

In fact, the final result for the Modified duration also jumps to infinity, as it should because the concept of Modified duration is a "relative" concept: It expresses the interest rate risk of an instrument relative to its current market value.

This is also the intuition behind why the Modified duration cannot be applied to a swap.

Because a swap's relative interest rate risk is - at least at inception - infinite!

What does make sense for single swaps or portfolio of swaps is the concept of "dollar duration", which is defined as the usual swap's flat DV01.

A portfolio manager should thus calculate the "dollar duration" of the whole portfolio by adding the DV01s of the booked trades. If the portfolio is funded externally, i.e. if the funding instruments are not part of the portfolio as is, for example, the case with pure bond portfolios, it would then make sense to divide the thus computed "dollar duration" with the market value of the portfolio to arrive to a "relative" duration metrics that may be interpreted as Modified duration of the whole portfolio.


The problem of modified duration (MD) can easily be solved if one realizes that fixed vs floating IRS is simply a fixed coupon bond. Here is the derivation:

$FixCpnLeg=C* \sum (T_i*Df_i)$

$FltCpnLeg=\sum{F_i*T_i*Df_i}$ where $F_i = [1-Df_{i-1}/Df_i]/T_i$

Receiver IRS is simply $IRSwp=FixCpnLeg - FltCpnLeg$. If you carefully work out the $FltCpnLeg$ summation, you will end up with $FltCpnLeg = 1 - Df_n$.

Putting it together with $FixCpnLeg$, $IRSwp = C*\sum(T_i*Df_i)-(1 - Df_n) = C*\sum(T_i*Df_i)+ Df_n - 1$

One will notice the first 2 terms define fixed coupon bond, where $C*\sum(T_i*Df_i)+Df_n = FixCpnBondPrice$

Thus Swap price formula simply re-expresses the price of a fixed coupon bond in terms of discount factor at each cashflow date. The '1' is simply the price of the bond at inception.

To answer your question calculating the Modified Duration of a IRS is simply calculating the MD of a fixed coupon bond itself.

I hope this helps.

  • 1
    $\begingroup$ The formulas in your answer is difficult to understand. You really need to learn a bit of LaTeX. $\endgroup$
    – Alper
    Commented Aug 5, 2022 at 9:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.