September 01, 2003

IRR Details

It took me a lot of googling to find what I needed, so I'm summarizing here in case it helps someone later.

IRR guesses the interest rates by applying them to a series of time-based contributions and withdrawals, and hoping they sum up to zero.

To figure the interest generated by yearly rates:

Compounded n times per year:

(1 + R/n)n - 1
Compounded continually:

eR - 1
You can figure the rates if you know the full value, the starting value, and the length of time of an investment (e.g. 1.75 years):
FV = P(1 + R/n)Yn FV = PeYr

What this program is doing is figuring the rate for continual compounding. (It also figures yearly compound, but not daily.) For each value, it figures:

PeYr
by plugging in everything except r, which it interpolates. The time periods are in terms of years, so the rate it is figuring is therefore the continual rate per year.

It then has to convert this continuous rate to a discrete rate. Since you can arrive at the same full value using either a discrete rate compounded periodically, or the continual rate compounded continually, set them to be equal. We'll say d is the periodic rate, and u is the continual rate.

P(1 + d/n)Y*n = PeY*u

This leads to two conversion formulas.

u = n ln(1 + d/n)
d = n(eu/n - 1)

So, plugging in numbers:

Yearly compound: d = eu - 1
Daily compound: d = 365 * (eu/365 - 1)
Posted by Curt at September 1, 2003 04:15 PM