Solving the TVM equation for the interest rate
|
04-15-2018, 09:38 PM
(This post was last modified: 04-15-2018 09:41 PM by Dieter.)
Post: #8
|
|||
|
|||
RE: Solving the TVM equation for the interest rate
(04-15-2018 08:48 PM)Carsen Wrote: Problem #1: n=32 PV=-6,000 FV=10,000 PMT=0 i=??? First of all: thank you for the time and effort you spent on this. However, the quality of the estimate cannot be judged from the final result: this depends on the numerical accuracy during the iteration and its implementation. Since the 12C calculates with 13 digits internally and because it also has means for exact evaluation of e^x–1 and ln(1+x) the results from this calculator are inherently more accurate. The relevant figure for the quality of the initial estimate here is the number of required iterations. I have included a loop counter in my 15C version and it looks like the results are quite good: Problem 1: n=3 iterations, estimate was 1,57%, result is 1,61%. Problem 2: the guess is very good (0,171% vs. 0,169% exact) and already after the second loop the absolute error is less than 2E–8. So once again one should expect the error to drop below the given threshold after 3 iterations. But in this case the Newton algorithm finally has problems to get the desired number of significant digits, so it takes 11 iterations. This nicely shows the numeric pitfalls mentioned above. But this is not related to the initial guess. Problem 3: n=3 iterations, estimate was 0,58%, result is 0,56%. Problem 4: n=4 iterations, estimate was 0,58%, result is 0,46%. (04-15-2018 08:48 PM)Carsen Wrote: I wonder if there is a even better way to produce a estimate. Compare it with the number of required loops based on other initial guesses. ;-) Dieter |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)