Worked example 1
Represent the denary number 13.5 in normalised floating-point format using a 10-bit mantissa and a 6-bit exponent. Both should use two's complement.
Show solution outline
- Convert to Binary:
- Integer part:
- Fractional part:
- Combined:
- Normalise the Binary Number:
- To make the mantissa start with '0.1', we must shift the binary point 4 places to the left:
- The number is positive, so the mantissa starts '0.1...'. This format is correct: .
- Determine the Exponent:
- We shifted the point 4 places to the left, so the exponent is .
- Convert 4 to 6-bit two's complement: .
- Format the Mantissa:
- The normalised value is .
- In a 10-bit two's complement format, we pad with zeros: .
Final Answer:
- Mantissa: 0110110000
- Exponent: 000100