Hacker News new | ask | show | jobs
by mkl 665 days ago
Not in floating point, which is the whole point here. Floats can only represent a finite subset of the real numbers (there are only 2^32 or 2^64 possible bit patterns, after all). They can represent lots of small numbers close together around 0, and lots of big numbers with increasingly large gaps between them, and there's an infinitely large gap between ~10^308 and inf. They are designed so that the possible floating point numbers are among the most useful numbers for most human calculations.

Even ignoring the realities of floating point, your argument depends on sampling uniformly from an infinite interval, which is not possible: https://math.stackexchange.com/questions/14777/why-isnt-ther...