In Fast Formulas #3: Pool Average Life with CPR Prepayments, I presented Formula 3.1, a shortcut calculation for the average life of a loan pool under a constant prepayment assumption. I mentioned that Formula 3.1 was derived by using “a couple of tricks.” Cameron asked in a comment if I could explain the tricks. In this post, I will explain one of the tricks, which is the foundation for many financial calculations. I will give the full derivation of Formula 3.1 in a later post.

The trick also relates to a recent post about Matt Henderson’s mathematical animations. Matt gave me permission to reproduce one of his animations. I selected not his most dazzling work, but an example I could use for this discussion. It is a clever demonstration that

1/4 + 1/16 + 1/64 + 1/256 + . . . = 1/3

Each new term always equals its predecessor multiplied by 1/4. When a constant factor generates new terms in this way, we have a geometric series (in mathspeak, a *series* is a list that is added together, and a *sequence* is just a list). Since the addition never stops in this case, it is an *infinite* geometric series. We could write it as:

* Q* =

*+*

**q**

**q**^{2}+

**q**^{3}+ . . . (4.1)

If * q* is between -1 and +1, then the terms will continue to get smaller and the series converges to some value

*. But what is*

**Q***? And how could we ever find the result of an endless addition?*

**Q**It is actually very easy. Consider * qQ*. Multiplying every term of

*by*

**Q***, we have*

**q*** qQ* =

**q**^{2}+

**q**^{3}+

**q**^{4}+. . .

Notice that the terms * Q* and

*are all the same, except that***qQ**

*has the initial term*

**Q***. You could make*

**q***from*

**Q***by inserting a q at the front and shoving all the other terms one place to the right. This is similar to Hilbert’s infinite hotel that could always accommodate a new guest even if it had no vacancies: just move the old guest in Room 1 to Room 2, the one in Room 2 to Room 3, and so on.***qQ**

Now subtract * qQ* from

*:*

**Q*** Q* –

*=***qQ**

*+ (*

**q**

**q**^{2}–

**q**^{2}) + (

**q**^{3}–

**q**^{3}) + . . . =

**q**We’re almost done. Since * Q* –

*is (1 –***qQ**

**q**)

**Q**, we have

(1 – **q**) **Q** = **q**

* Q* =

*/ (1 –*

**q****q**) (4.2)

With q = ¼ in Matt’s animation, we see that

**Q** = ¼ / ¾ = 1/3, as he showed.

Now suppose our series is merely finite, with ** n** terms:

* Q* =

*+*

**q**

**q**^{2}+

**q**^{3}+ . . . +

**q**^{n-1}+

**q**^{n}(4.3)

As before, consider **qQ**

* qQ* =

**q**^{2}+

**q**^{3}+ . . . +

**q**^{n}+

**q**^{n+1}

and subtract * qQ* from

*:*

**Q*** Q* –

*=***qQ**

*+ (*

**q**

**q**^{2}–

**q**^{2}) + (

**q**^{3}–

**q**^{3}) + . . . + (

**q**^{n}–

**q**^{n}) –

**q**^{n+1}=

*–*

**q**

**q**^{n+1 }

Since the **q**^{n+1} term appears in * qQ* but no in

*, it does not get cancelled out (this is like a finite hotel where not everyone can be accommodated). So*

**Q**(1 – * q*)

*=*

**Q***–*

**q**

**q**^{n+1}

* Q* = (

*–*

**q**

**q**^{n+1})/(1 –

*) (4.4)*

**q**Formula 4.4, the shortcut for a finite geometric series, is one of the tricks I used to derive Formula 3.1.

**See Also**: Fast Formulas #3: The Derivation.

Pingback: Fast Formulas #3: Pool Average Life with CPR Prepayments | The Well-Tempered Spreadsheet

Pingback: Fast Formulas #1: Average Life of Mortgage (as Scheduled) | The Well-Tempered Spreadsheet

Pingback: Fast Formulas #5: Quasi-Geometric Series (The Other Trick) | The Well-Tempered Spreadsheet

Pingback: Fast Formulas #3: The Derivation | The Well-Tempered Spreadsheet

Pingback: Fast Formulas #1: New Insight into an Old Formula | The Well-Tempered Spreadsheet