Re: [WP34s] RUN instead of STOP ? Message #3 Posted by fhub on 10 May 2012, 5:38 a.m., in response to message #2 by Paul Dale
Quote:
We await the new version.....
Well, it was not really a serious problem, i.e. it didn't return any wrong results. It was just so that the solver SLV didn't get the correct (intended) 2 initial guesses but some other meaningless values, so it may fail in some cases when solving for I.
But it seems that bug-fixing isn't always a goos idea. :-(
Now that I use the 2 correct initial guesses, _sometimes_ the solver fails because of a different problem: it produces values <= -1 for the internal interest rate during the SLV process, and so the financial equation stops with an error (because ln(1+x) is of course not defined for x<=-1.
Now my question: should I implement a test for i<=-1 and return NaN in this subroutine for SLV?
Can SLV handle such NaN 'results' and what would SLV do in this situation?
Franz
|