Question

In: Computer Science

I have the following decimal value 17.25. How can i convert this to IEEE 754 32...

I have the following decimal value 17.25. How can i convert this to IEEE 754 32 bit single precision floating point and double precision?. I need to use this as a matlab function block in Simulink, therefore i cannot use the conversion of hexadecimal to IEEE 754 32 bit single precision floating point matlab script.

Solutions

Expert Solution

To convert a decimal number to IEEE 754 format , first of all the number has to be converted to binary form. As shown in the figure, the two part of the number i.e, before the decimal point and after the decimal point has to be converted separately.

IEEE 754 floating point representation can be done in two ways: single precision and double precision. The two formats are shown below

A binary number can be represented in 32 bit single precision or 64 bit double precision.To convert in single precision we follow the steps described below.

1.After evaluating the binary equivalent, the decimal point has to moved to the left most side to reach the left most position of 1, to reach 1 the decimal point has to moved 4 steps as shown below, as it has taken 4 steps left the exponent has to raised to the power of 2 ( here 2 is considered as the number is binary), so 24 has become the exponent. Thus the exponent is calculated by adding 4 to 127 which is the bias exponent of single precision ( bias exponent of double precision is 1053). 4+127 is 131 , binary equivalent is found out i.e, 10000011

2. For mantissa, it is shown below, and the sign bit is 0 as the number is positive number.

For double precision format all the steps are similar , only the exponent bias is 1053 wich is added and the mantissa have 52 bits as shown above.

Hope it helped


Related Solutions

With a detailed step-by-step process, convert the following decimal number into binary, Hexadecimal and IEEE 754...
With a detailed step-by-step process, convert the following decimal number into binary, Hexadecimal and IEEE 754 formats : 72.nn ( where nn is 80)
Convert 1.67e14 to the 32-bit IEEE 754 Floating Point Standard, with the following layout: first bit...
Convert 1.67e14 to the 32-bit IEEE 754 Floating Point Standard, with the following layout: first bit is sign bit, next 8 bits is exponent field, and remaining 23 bits is mantissa field; result is to be in hexadecimal and not to be rounded up. answer choices 5717E27B 57172EB7 5717E2B7 C717E2B7 5771E2B7
The number –11.375 (decimal) represented as a 32-bit floating-point binary number according to the IEEE 754...
The number –11.375 (decimal) represented as a 32-bit floating-point binary number according to the IEEE 754 standard is
Convert 1101.11011101 x 223 to IEEE Standard 754 for single-precision floating-point binary format. Convert the IEEE...
Convert 1101.11011101 x 223 to IEEE Standard 754 for single-precision floating-point binary format. Convert the IEEE Standard 754 number 11001010100011010101000000000000 to its decimal equivalent.
Convert 1.8125 to IEEE-754 representation. Show all your work.
Convert 1.8125 to IEEE-754 representation. Show all your work.
Convert 1.8125 to IEEE-754 representation. Show all your work.
Convert 1.8125 to IEEE-754 representation. Show all your work.
Convert 3/7 to IEEE 754. Convert 171.375 to IEEE754 Convert the float number 0x4024 0080 0000...
Convert 3/7 to IEEE 754. Convert 171.375 to IEEE754 Convert the float number 0x4024 0080 0000 0000 to decimal. What is the true exponent? Circle the true exponent. 0x3FAF 9000 0000 is an IEEE float number. Convert it to base 10. While doing the conversion answer two questions: What is the true exponent? What is the mantissa? Make these two values obvious by circling them.
6 – Assuming single precision IEEE 754 format, what decimal number is represent by the following...
6 – Assuming single precision IEEE 754 format, what decimal number is represent by the following 32-bit binary word? 1 10001000 10010000000000000000000
Given the following 32-bit binary sequences representing single precision IEEE 754 floating point numbers: a =...
Given the following 32-bit binary sequences representing single precision IEEE 754 floating point numbers: a = 0100 0000 1101 1000 0000 0000 0000 0000 b = 1011 1110 1110 0000 0000 0000 0000 0000 Perform the following arithmetic and show the results in both normalized binary format and IEEE 754 single-precision format. Show your steps. a)     a + b b)     a × b
Represent the following decimal numbers using IEEE-754 floating point representation. A. -0.375 B. -Infinity C. 17...
Represent the following decimal numbers using IEEE-754 floating point representation. A. -0.375 B. -Infinity C. 17 D. 5.25
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT