[Numpy-discussion] Log Arrays
Nadav Horesh
nadavh@visionsense....
Thu May 8 12:06:57 CDT 2008
Is the 80 bits float (float96 on IA32, float128 on AMD64) isn't enough? It has a 64 bits mantissa and can represent numbers up to nearly 1E(+-)5000.
Nadav.
-----הודעה מקורית-----
מאת: numpy-discussion-bounces@scipy.org בשם Charles R Harris
נשלח: ה 08-מאי-08 19:25
אל: Discussion of Numerical Python
נושא: Re: [Numpy-discussion] Log Arrays
On Thu, May 8, 2008 at 10:11 AM, Anne Archibald <peridot.faceted@gmail.com>
wrote:
> 2008/5/8 Charles R Harris <charlesr.harris@gmail.com>:
> >
> > What realistic probability is in the range exp(-1000) ?
>
> Well, I ran into it while doing a maximum-likelihood fit - my early
> guesses had exceedingly low probabilities, but I needed to know which
> way the probabilities were increasing.
>
The number of bosons in the universe is only on the order of 1e-42.
Exp(-1000) may be convenient, but as a probability it is a delusion. The
hypothesis "none of the above" would have a much larger prior.
But to expand on David's computation... If the numbers are stored without
using logs, i.e., as the exponentials, then the sum is of the form:
x_1*2**y_1 + ... + x_i*2**y_i
Where 1<= x_j < 2 and both x_i and y_i are available. When the numbers are
all of the same general magnitude you get essentially the same result as
David's formula by simply by dividing out the first value.
Chuck
Chuck
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/ms-tnef
Size: 3794 bytes
Desc: not available
Url : http://projects.scipy.org/pipermail/numpy-discussion/attachments/20080508/752df5bb/attachment.bin
More information about the Numpy-discussion
mailing list