flat assembler
Message board for the users of flat assembler.
Index
> Main > Floating point representation |
Author |
|
zhak 27 Dec 2006, 12:31
you have the fp number: 0 10010011 10100010000000000000000
it is 00 00 D1 49 in memory... here we have a single-precision value. as you figured out, the exponent is: 10010011b = 147-(biasing constant which is 127) = 20. 10100010000000000000000 - is a real part of the number, so to convert it to decimal you do: 1*(2^-1)+0+1*2(^-3)+0+0+0+1*2(^-7) = 0.5+0.125+0.0078125 = 0.6328125. so, you've got your number: 1.6328125 * 2^20 = 1712128 |
|||
27 Dec 2006, 12:31 |
|
playworld 27 Dec 2006, 13:33
thanks zhak.
|
|||
27 Dec 2006, 13:33 |
|
m 28 Dec 2006, 08:59
Hey read Intel Docs and you'll have to never ask such trivial questions.
|
|||
28 Dec 2006, 08:59 |
|
zhak 28 Dec 2006, 09:45
m, even well organized documentation is not always clear, especially for newbies.
|
|||
28 Dec 2006, 09:45 |
|
Jack 29 Dec 2006, 00:41
this may also help http://babbage.cs.qc.edu/IEEE-754/
|
|||
29 Dec 2006, 00:41 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.