Question

In: Computer Science

Consider the following 32-bit floating point representation based on the IEEE floating point standard: There is...

  1. Consider the following 32-bit floating point representation based on the IEEE floating point standard:
    1. There is a sign bit in the most significant bit.
    2. The next eight bits are the exponent, and the exponent bias is 28-1-1 = 127.
    3. The last 23 bits are the fraction bits.
    4. The representation encodes number of the form V = (-1)S x M x 2E, where S is the sign, M is the significand, and E is the biased exponent.
    5. The rules for the IEEE standard for normalized, denormalized, representation of zero, infinity, and NaN still apply.

  1. What is the valid range of values for the biased exponent E? -126 to ______

  1. What is the biased exponent E for denormalized values? ______
  1. Match the following values in decimal (base 10 form) or descriptions with the corresponding 32-bit binary representation (fill in with a-h):

  1. Negative infinity             _____ 1. 01000000111000000000000000000000
  2. Positive zero          _____ 2. 11000000011000000000000000000000
  3. 3.5                           _____ 3. 01000000011000000000000000000000
  4. 7.0                            _____ 4. 11000000111000000000000000000000
  5. -3.5                          _____ 5. 00000000000000000000000000000000
  6. -7.0                           _____ 6. 01111111100000000000000000000111
  7. Not-a-Number (NaN)            _____ 7. 01111111100000000000000000000000
  8. Positive infinity              _____ 8. 11111111100000000000000000000000

Solutions

Expert Solution

Solution:

a) What is the valid range of values for the biased exponent E? -126 to ______

The valid range of values for the biased exponent E is from -126 to +127. These values are for single-precision floating-point representation i.e. for 32-bit number.

b) What is the biased exponent E for denormalized values?

A denormal number is represented with a biased exponent of all 0 bits, this represents a value -126. The smallest biased exponent representing a normal number is 1

c)

  1. Negative infinity             ___b__ 1. 01000000111000000000000000000000
  2. Positive zero          ___e__ 2. 11000000011000000000000000000000
  3. 3.5                           ____c_ 3. 01000000011000000000000000000000
  4. 7.0                            ___f__ 4. 11000000111000000000000000000000
  5. -3.5                          __b___ 5. 00000000000000000000000000000000
  6. -7.0                           ___g__ 6. 01111111100000000000000000000111
  7. Not-a-Number (NaN)            __h___ 7. 01111111100000000000000000000000
  8. Positive infinity              ___a__ 8. 11111111100000000000000000000000

Infinity is represented with all 1's in the exponent and all 0's in the fraction part. For negative infinity, the sign bit is 1 and for positive infinity, the sign bit is 0.

Zero is indicated with all 0's in the exponent and fraction. For positive 0, the sign bit is 0.

Floating-point exception results if the computation is not a number. For representing these kinds of results we use the Not-a-Number format. It is represented either 0/1 in sign bit, all 1's in the exponent field, and anything other than all 0's in the fraction field.

Representation of 3.5:

(representation of floating-point numbers: 1 sign bit, 8 bits of exponent field, 23 bits of mantissa field.)

3 in binary is 011, 0.5 in binary is 1. Concatenating the result: 11.1 is the binary representation of 3.5

as this is +ve number, the sign bit is 0. 11.1 is represented as 1.11 * 2^1. This indicates, the exponent is 1 i.e 127+1 which is 128. 11 is the mantissa field.

Representation of 128 in binary is 10000000

The mantissa is 11, and its representation is 11000000000000000000000.

So the result is 01000000011000000000000000000000

So for 3.5 the result is 01000000011000000000000000000000

Representation of -3.5:

The result is exactly the same as 3.5 except that the sign bit indicates the value as -ve. So the sign bit is 1 in this case.

So the result is 11000000011000000000000000000000

Representation of 7.0:

(representation of floating-point numbers: 1 sign bit, 8 bits of exponent field, 23 bits of mantissa field.)

7 in binary is 111, 0.0 in binary is 0. Concatenating the result: 111.0 is the binary representation of 7.0

as this is +ve number, the sign bit is 0. 111.0 is represented as 1.11 * 2^2. This indicates, the exponent is 1 i.e 127+2 which is 129. 11 is the mantissa field.

Representation of 129 in binary is 10000001

The mantissa is 11, and its representation is 11000000000000000000000.

So the result is 01000000111000000000000000000000

So for 7.0 the result is 01000000111000000000000000000000

Representation of -7.0:

The result is exactly the same as 7.0 except that the sign bit indicates the value as -ve. So the sign bit is 1 in this case.

So the result is 11000000111000000000000000000000


Related Solutions

3. IEEE Floating Point Representation What decimal number does the 32-bit IEEE floating point number 0xC27F0000...
3. IEEE Floating Point Representation What decimal number does the 32-bit IEEE floating point number 0xC27F0000 represent? Fill in the requested information in the blanks below. What is the sign of the number (say positive or negative): What is the exponent in decimal format: What is the significand in binary: What is the value of the stored decimal number in decimal (final answer): Credit will be given for your final answer in the blanks and the work shown below.
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
Convert the following decimal numbers into their 32-bit floating point representation (IEEE single precision). You may...
Convert the following decimal numbers into their 32-bit floating point representation (IEEE single precision). You may use a calculator to do the required multiplications, but you must show your work, not just the solution. 1. -59.75 (ANSW: 11000010011011110000000000000000) 2. 0.3 (ANSW: 00111110100110011001100110011010 (rounded) 00111110100110011001100110011001 (truncated; either answer is fine)) Please show all work
Concert the following 32-bit floating point number (IEEE single precision) into their decimal representation. 1100 0101...
Concert the following 32-bit floating point number (IEEE single precision) into their decimal representation. 1100 0101 0001 1111 1000 0000 0000 0000 (ANSW: -2552.0) Please show all work
Convert the following decimal numbers to 32-bit IEEE floating point: 86.59375 -1.59729 Convert the following 32-bit...
Convert the following decimal numbers to 32-bit IEEE floating point: 86.59375 -1.59729 Convert the following 32-bit IEEE floating point numbers to decimal: 0100 1100 1110 0110 1111 1000 0000 0000 1011 0101 1110 0110 1010 0110 0000 0000
verilog code to implement 32 bit Floating Point Adder in Verilog using IEEE 754 floating point...
verilog code to implement 32 bit Floating Point Adder in Verilog using IEEE 754 floating point representation.
Convert the following binary floating point  to decimal IEEE 32-bit floating point format.   0 1000 0101 000...
Convert the following binary floating point  to decimal IEEE 32-bit floating point format.   0 1000 0101 000 0100 1101 0000 0000 0000
Show the IEEE 32-bit representation for 2.09375 and 17.1875
Show the IEEE 32-bit representation for 2.09375 and 17.1875
The biggest mysteries of the IEEE 754 Floating-Point Representation are “hidden bit” and “Bias. Can someone...
The biggest mysteries of the IEEE 754 Floating-Point Representation are “hidden bit” and “Bias. Can someone explain to me why the "hidden bits" and "bias" are considered to be mysteries for the IEEE 754 floating point representation
Q1.Convert C46C000016 into a 32-bit single-precision IEEE floating-point binary number.
Q1.Convert C46C000016 into a 32-bit single-precision IEEE floating-point binary number.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT