Post Reply 
Request TVM formula guidance
12-25-2014, 12:42 PM (This post was last modified: 12-26-2014 06:44 PM by Dieter.)
Post: #14
RE: Request TVM formula guidance
(12-24-2014 05:17 AM)iMatt04bit Wrote:  Dieter I have to ask: how did you determine that formula? Its awesome.

It's trivial. ;-)

That's simply the next approximation you get with Newton's method if you start with r=0, using the TVM formula as stated in the documentation for the WP34s TVM solver. So it's nothing but

r   ≈   0 – TVM(0) / TVM'(0)

You can also do this with the TVM formula as it is given in the 12C manual. In this case the result is

r   ≈   –2 * (pv + n*pmt + fv) / (n * (pmt*(n+2*k-1) + 2*pv))

In other words: you could just as well start with r=0 and you'd get these approximations after the first iteration step. ;-)

However, this would require special handling of the (removable) singularity at r=0 where the TVM function and its derivative are not defined (both approach a limit as r→0, and these limits are used for the first guess). If the mentioned approximation is used as the first guess and the next iteration step still yields r=0, the solution is r=0. Else we can expect the following iterations to lead away from r=0, thus avoiding problems with the singularity at that point.

In many cases these two approximations bracket the true interest rate, or their mean is an even better estimate that comes quite close. Using your original example (n=10, PV=50, PMT=–30, FV=400, k=0) the two approximations are 9,836% and 17,647% (mean = 13,74%) while the exact rate is 14,436%.

However, this (one approximation a bit low, the other one a bit high) is not the case under all circumstances. ;-)

Addendum (Dec 26): Obviously we ain't seen nothing yet. I just read HP Journal 10/1977 on the new HP92 financial calculator. The article mentioned the "new" TVM formula (with signed parameters) and the problems when solving for the interest rate. Most of these problems look quite familar, and the author stresses the importance of a decent initial guess. Quote: "...a strategy was developed that produces inital guesses accurate to five decimal places". Well, that's awesome. :-)

BTW there also is an interesting read on the way the good old HP80 tries to solve for the interest rate (at least in a standard case like FV=0) which is described in HP Journal 5/1973 (cf. Appendix A following the article). Here the author even describes how the formula for the first guess was developed. Please note that at that time all variables were entered unsigned, i.e. usually positive.

We now can see whether we can develop a strategy that produces decent guesses for various scenarios. We can tell quite easily whether a solution exists and if there are multiple or no solutions at all. Upper limits for the interest rate can be given for some standard cases, e.g. FV=0 or PV=0, where the interest rate approaches a limit as n approaches infinity (which helps solve these ciritcal cases for large n where convergence may become extremely slow – which is also mentioned in the HP Journal article). Designing an algorithm that estimates the interest rate for different scenarios will be a tricky task, but I think it can be done. However, compared to HP's, I assume my skills are too limited to get a result with five valid digits in the initial guess. On the other hand, for large n and FV=0 or PV=0 this can be accomplished quite easily.

Your turn now. :-)

Dieter
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
Request TVM formula guidance - iMatt04bit - 12-02-2014, 05:33 AM
RE: Request TVM formula guidance - Dieter - 12-03-2014, 09:17 PM
RE: Request TVM formula guidance - Dieter - 12-11-2014, 06:36 PM
RE: Request TVM formula guidance - Dieter - 12-14-2014, 04:24 PM
RE: Request TVM formula guidance - Dieter - 12-17-2014, 01:21 PM
RE: Request TVM formula guidance - Dieter - 12-21-2014, 06:14 PM
RE: Request TVM formula guidance - Dieter - 12-25-2014 12:42 PM
RE: Request TVM formula guidance - Dieter - 12-29-2014, 07:47 PM



User(s) browsing this thread: 1 Guest(s)