Question 11
AQA Computer Science June 2017 Paper 2A level9 marks
On the specification
- 11.1
- 4.5 Fundamentals of data representation
- 11.2
- 4.5 Fundamentals of data representation
- 11.3
- 4.5 Fundamentals of data representation3.5 Fundamentals of data representation
- 11.4
- 4.5 Fundamentals of data representation3.5 Fundamentals of data representation
- 11.5
- 4.5 Fundamentals of data representation
- 11.6
- 4.5 Fundamentals of data representation
Question text
11 A particular computer uses a normalised floating point representation with an 8-bit mantissa and a 4-bit exponent, both stored using two’s complement. Four bit patterns that are stored in this computer’s memory are listed in Figure 8 and are labelled A, B, C and D. Some of the bit patterns are valid normalised floating point numbers. Figure 8 A 0 0 0 0 0 0 0 1 0 0 0 0 Mantissa Exponent B 0 1 0 0 0 0 0 0 1 0 0 0 Mantissa Exponent C 1 0 0 0 0 0 0 0 0 0 1 0 Mantissa Exponent D 1 1 0 0 1 1 1 0 1 0 0 0 Mantissa Exponent 11.1 Shade one lozenge to indicate which bit pattern (A–D) in Figure 8 represents a negative normalised value. [1 mark] A B C D 11.2 Shade one lozenge to indicate which bit pattern (A–D) in Figure 8 represents the smallest positive normalised value. [1 mark] A B C D 11.3 The following is a floating point representation of a number: 10 1 1 0 0 0 0 0 0 1 1 Mantissa Exponent Calculate the decimal equivalent of the number. You must show your working. [2 marks] 11.4 Write the normalised floating point representation of the decimal value 58.5 in the boxes below. You must show your working. [3 marks] Mantissa Exponent There can be a loss of precision when a decimal number is stored when using a floating point system. The closest possible representation of the decimal number 13.8 is shown below. 1 1 0 1 1 1 0 0 1 0 0 Mantissa Exponent By converting this bit pattern back into denary it can be seen that the actual number stored is 13.75, not 13.8. 11.5 Calculate the absolute error that has occurred. [1 mark] 11.6 Calculate the relative error that has occurred. Express your answer as a percentage to two decimal places. [1 mark]