From: Joel VanderWerf Date: 2006-11-15T06:13:31+09:00 Subject: Re: Is 2.0 Integer or Float? Sander Land wrote: > On 11/14/06, Joel VanderWerf wrote: >> How does that work? Is there an 11-bit pattern that signifies "use the >> remaining 53 bits as a integer"? Do math library functions respect this? > > 53 bits is just the mantissa size. > imagine using scientific notation a * 10^b with a<1 and 3 decimal > digits, this gives you accurate integers up to 1000. > 999 => 0.999 * 10^3 exact > 1001=> 0.100 * 10^4 overflowed Ok, so they aren't doing anything exceptional with the format. There's no special switching going on, just normal floating point math with integer values. -- vjoel : Joel VanderWerf : path berkeley edu : 510 665 3407