1 / 3

Convert Decimal to Floating point number [IEEE 754]

Convert Decimal to Floating point number [IEEE 754]. E. F. Try to do the conversion in 3 steps , lets continue with an example: 13.1875 1101 . 0011 Step 1 : Convert 13 to binary (13) decimal  ( 1101 ) binary Step 2: 13 .1875  0.1875 X 2 = 0.375 0.375 X 2 = 0.75

neil
Télécharger la présentation

Convert Decimal to Floating point number [IEEE 754]

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Convert Decimal to Floating point number [IEEE 754]

  2. E F Try to do the conversion in 3 steps, lets continue with an example: 13.1875 1101.0011 Step 1 : Convert 13 to binary (13)decimal (1101)binary Step 2:13.1875  0.1875 X 2 = 0.375 0.375 X 2 = 0.75 0.75 X 2 = 1.5 0.5 X 2 = 1.0 We reached 0, so we stopped 0 0 Top-Down = 0011 1 1

  3. Step 3: We should reach to this condition : (+/-) 1.F X 1101.0011 we move the decimal point to the left to make it like 1.F so the result will be: 1.1010011 = 1.F so F = 1010011 We moved the decimal point 3 to the left so =  E-127=3 SO E= (130)decimal E=(10000010)binary 0 10000010 10100110000000000000000 We add these 0s to right to make it 23 bits 0 for positive number 1 for negative number Fortunately it is 8 bits, but if it is less, you have to add 0s to the left

More Related