1. Rates of Return
Basic finance includes assessment of a project or an investment that produces a cash flow both positive or negative. One question is whether a project is worth doing. The simplest case is one which involves no risk (or risk is ignored) and the cash flows are certain. A time-honored way to assess such an investment is to compute its internal rate of return (IRR).

Let $v_t$ be the payoff of the investment or activity in period $t$, for $t=0,1,\dots,T$ Let $v$ be the vector of these cashflows. Negative values are periods in which the costs are greater than the returns of the activity. Positive values occur when returns exceed costs.

There is a fixed interest rate $r$ at which money can be borrowed or save. The decision is whether putting money into the stream $v$ is better than ordinary interest. If the amount $a$ and the subsequent interest were saved at $t=0$ then its value at time $t$ would equal $$y_t(a) = a*(1+r)(1+r)\cdots(1+r) = a(1+r)^t.\nonumber$$ Here $y_t(a)$ is cash available $t$ periods in the future. Its present value would still be $a = y_t/(1+r)^t$. That is, if I foresee having $y_t$ at time $t$ it is equivalent to having $a$ right now. The term $1/(1+r)$ is a discount factor. When $r$ is the market rate it is the market's discount factor. But it also could be an agent's private rate of time preference reflecting impatience.

Now consider an investment with time-varying cash flow $v_t.$ The simple case above is $v_0=a$ and $v_t=0$ for other t's. A project may incur costs (negative $v$) and then profits which depend on time. The total present value of the income stream is: $$PV_r(v) = {\sum}_{t=0}^T \left({1\over 1+r}\right)^t v_t.\label{PV}\tag{PV}$$ If we let $T\to\infty$ this may become an infinite present value. In particular, if $v_t$ grows faster than $1/(1+r)^t$ shrinks to 0 then PV would be the sum of an infinite number of strictly positive terms. One way to ensure that PV is well-defined, even if the horizon is infinite, is to require $v_t\to 0$ as $t\to\infty$. In this case the infinite series will have a finite value.

If $PV_r(v)\gt 0$ then more wealth is created by making the investment than doing nothing at all, which has present value of $0$. If PV is negative then it is better to do nothing. This comparison depends on the interest rate $r$. An internal rate of return (IRR) is an interest rate, that when applied to the income stream, results in a present value is 0. That is, the IRR calculation finds an interest rate $\rho_v$ at which the investment is equal in value as doing nothing: $$\rho_v\ :\ {\sum}_{t=0}^T \left({1\over 1+\rho_v}\right)^t v_t = 0.\tag{IRR}\label{IRR}$$ Notice that the IRR is a solution (or root) of a non-linear equation that is specific to the investment.

We can also redefine the IRR in terms of the discount factor instead of an interest rate. Let $\delta = 1/(1+r)$. Then $\delta_v$ solves $$\delta_v\ :\ {\sum}_{t=0}^T\ v_t\delta^t_v = 0.\tag{DFIRR}\label{DFIRR}$$ If the horizon of the investment $T$ is finite then this is the root of a polynomial in $\delta$. For example, if $T=5 then we want $\delta_v$ such that $$v_0 + v_1\delta_v + v_2\delta_v^2+ v_3\delta_v^3+ v_4\delta_v^4+ v_4\delta_v^4 = 0.$ The v's are the coefficients on the powers of $\delta,$ hence the IRR is a root of the polynomial. Methods to find (all) the real roots of a polynomial can be employed to compute $\beta_v$. An IRR is then simply the rate of time preference associated with the root: $$\rho_v = 1/\beta_v-1.\label{IRR2}\tag{IRR2}$$

Sometimes the IRR is simple to interpret and straightforward to compute. In particular, suppose $v_t$ starts with negative values and then is followed by positive values. The signs in $v$ follow the pattern $$(-,-,\dots,-,+,+,\dots,+).$$ If $r=0$ then $PV_0(v) = \sum\ v_t$, the simple sum of cash flows. And if $PV_0(v)\gt 0$ it means the positive returns outweigh the negative upfront costs. For $r>0$ the present value must fall because the weight on the positive values falls quicker than the earlier negative values. Thus, if the investor faces a market rate $r\lt\rho_v$ they are better off making the investment than doing nothing. And if $r\gt\rho_v$ it is better to do nothing than make the investment. Further, as long as the negative values first pattern holds we know the IRR is positive and unique, and it can be computed with a simple bracket and bisect approach.

When the cash flows include more than one change in signs then the IRR may not be unique. And at the market rate $PV(v)$ might be negative but $r\lt \rho_v$. So the simple decision rule for whether a project is worth doing no longer applies.