05.03.2015 Views

Representation of Floating Point Numbers in Single Precision ...

Representation of Floating Point Numbers in Single Precision ...

Representation of Floating Point Numbers in Single Precision ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>Float<strong>in</strong>g</strong> <strong>Po<strong>in</strong>t</strong> Conversion Example<br />

• The decimal number -2345.125 10 is to be represented <strong>in</strong> the<br />

IEEE 754 32-bit s<strong>in</strong>gle precision format:<br />

-2345.125 10 = -100100101001.001 2 (converted to b<strong>in</strong>ary)<br />

Hidden<br />

= -1.00100101001001 x 2 11 (normalized b<strong>in</strong>ary)<br />

• The mantissa is negative so the sign S is given by:<br />

S = 1<br />

• The biased exponent E is given by E = e + 127<br />

E = 11 + 127 = 138 10<br />

= 10001010 2<br />

• Fractional part <strong>of</strong> mantissa M:<br />

M = .00100101001001000000000 (<strong>in</strong> 23 bits)<br />

The IEEE 754 s<strong>in</strong>gle precision representation is given by:<br />

1 10001010 00100101001001000000000<br />

S E M<br />

1 bit 8 bits 23 bits<br />

EECC250 - Shaaban<br />

#6 lec #17 W<strong>in</strong>ter99 1-27-2000

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!