Dan wrote: >> The total range for the mantissa of a double-precision float is >> 52-bits, with 1 >> bit for sign. This means that the range between your most significant >> and least >> significant digit of the final summed answer cannot be greater than >> 2^51, or >> you'll loose precision. >> >> The total range for the exponent of a double-precision float is >> 2^1023, so you >> cannot express any numbers larger than 2^51 + 2^1023. >> > > > I'm not that experienced with math/compsci, but Excel describes > > 2^51 as having 15 digits (2,251,799,813,685,250) > > 2^1023 comes in with 307 digits (won't display above 255) > > > So you're saying 307 integers and 15 decimals?:
No, I'm saying 15 digits. That's *total* combined between integer and decimal places. However, because the floating point is stored in a scientific notation, you can add a bunch of extra zeros to push those 15 digits around. So you can have: (15 digits) + (307 zeros).0 or 0.(307 zeros) +(15 digits) (note: I've simplified the math a lot here, because none of this is really stored in terms of decimal places. It's really stored as powers-of-two, binary format. It's really 2^51 +/- 2^e , where e can be up to anywhere up to 1023)