Quote:
No. It has an exponent. And the mantissa is an integral.
I had to read that a couple of times before I realized you meant integer. The mantissa of IEEE-754 numbers is not an integer. It is the fractional part of a number with an implied "1." prefix. In other words, it is a fixed point real number.
Quote:
That's two steps when you could have just taken one: convert mantissa and exponent to decimal, attach sign, and you have your decimal representation in scientific notation.
I know what you are saying, but you are grossly oversimplifying what you are claiming. If nothing else, you'd have to remember the bias and scientific notation calls for a decimal base.
[Edit]
Come to think of it, that doesn't account for subnormal numbers either, but I will not go there if you don't. I hate dealing with them.
[/Edit]
Quote:
And here I was doing an effort to demonstrate why it isn't useful as a teaching mechanism...
I find it useful as a teaching tool. Using that representation along with an explanation of dyadic rationals make explaining why mechanisms like IEEE-754 can't accurately represent categories of simple decimal fractions.
Quote:
I'll omit the exact formula, but as an example, if you had a coin that came up heads 25% of the time and tails 75% of the time, you could actually encode the state of the coin using only 0.881 bits.
For a lot of examples, grab a copy of "Data Compression: The Complete Reference".
Information theory is fun.
Soma