Forums before death by AOL, social media and spammers... "We can't have nice things"
|    comp.lang.forth    |    Forth programmers eat a lot of Bratwurst    |    117,927 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 116,519 of 117,927    |
|    Krishna Myneni to Krishna Myneni    |
|    Re: F*/ (f-star-slash)    |
|    02 Jun 24 13:18:13    |
      From: krishna.myneni@ccreweb.org              On 6/2/24 07:11, Krishna Myneni wrote:       ...       > Using F*/ in Forth:       >       > 3.12e306 1.1e145 2.8e150 f*/ fs.       > 1.22571428571429e+301 ok       >              The alternative way to calculate this without overflow in Forth is to       add/subtract the logarithms, then take the antilog. However, let's check       the accuracy of this approach compared to the above:              3.12e306 flog 1.1e145 flog f+ 2.8e150 flog f- falog fs.       1.225714285714187e+301 ok              The base 10 significand of the result is              3.12e 1.1e f* 2.8e f/ fs.       1.225714285714286e+00 ok              The result from using F*/ to the same number of decimal digits is              3.12e306 1.1e145 2.8e150 f*/ fs. \ Anton's version of F*/       1.225714285714286e+301 ok              The relative error of the logarithm approach to using F*/ is              1.225714285714286e+301 1.225714285714187e+301 f- 1.225714285714286e+301       f/ f.       8.07495e-14 ok              We appear losing between about 3 decimal digits of accuracy with the       logarithm approach.              --       Krishna              --- SoupGate-Win32 v1.05        * Origin: you cannot sedate... all the things you hate (1:229/2)    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca