Post Reply 
Torture tests: what do they mean?
05-18-2014, 10:00 PM
Post: #60
RE: Torture tests: what do they mean?
(05-18-2014 03:09 PM)Dieter Wrote:  If (!) the user was able to provide a 39-digit representation of 355/226 (for instance with a dedicated TAN_Y/X function) the 34s might get 31 digits right. Otherwise just 26 correct digits can be expected here. That's why I wonder why the 34s returns 31-32 correct digits. ;-)

With the old code, the 34S is attempting to calculate the tangent of a thirty four digit number:

Code:
TAN(1.570796460176991150442477876106195) =
    -7497258.18532558711290507181448136970156

    -7497258.185325587112905071814481418482796577296176634279

Which is 31 digits as you mentioned. Eight digits are being lost which is what I thought was expected.

With the new code, it would get all 39 digits for the same input. I added some extra digits for the computation of the TAN function. The sledgehammer approach to numerical analysis. For an input of PI/2 (rounded to 34 digits), TAN isn't anything like as good, it gets seventeen digits correct. I could fix this by adding more digits to the intermediate computations but I'm not sure of the memory ramifications -- I know we're pretty close to the stack limit for the path that goes through the incomplete beta function, to lngamma, to sincos.


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


Messages In This Thread
Torture tests: what do they mean? - jebem - 05-13-2014, 10:58 PM
RE: Torture tests: what do they mean? - Paul Dale - 05-18-2014 10:00 PM



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