Presentation is loading. Please wait.

Presentation is loading. Please wait.

Convert Decimal to Floating point number [IEEE 754]

Similar presentations


Presentation on theme: "Convert Decimal to Floating point number [IEEE 754]"— Presentation transcript:

1 Convert Decimal to Floating point number [IEEE 754]

2 Try to do the conversion in 3 steps, lets continue with an example:
F Try to do the conversion in 3 steps, lets continue with an example: Step 1 : Convert 13 to binary (13)decimal (1101)binary Step 2:  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 Top-Down = 0011 1 1

3 We should reach to this condition : (+/-) 1.F X 𝟐 (𝐄−𝟏𝟐𝟕)
we move the decimal point to the left to make it like 1.F so the result will be: = 1.F so F = We moved the decimal point 3 to the left so 𝟐 𝟑 = 𝟐 (𝐄−𝟏𝟐𝟕)  E-127=3 SO E= (130)decimal E=( )binary 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


Download ppt "Convert Decimal to Floating point number [IEEE 754]"

Similar presentations


Ads by Google