Question bank › A-level › A-level Computer Science › Fundamentals of data representation

Fixed and floating point, errors, normalisation, underflow and overflow

10 questions54 marksabout 65 min

Answer on paper first, then reveal the mark scheme one mark at a time.

1Standard5 marks

A computer stores real numbers in floating point form using a mantissa of 8 bits and an exponent of 4 bits. Both are two's complement. The binary point of the mantissa is immediately after the sign bit.

(a) Calculate the denary value of the number with mantissa 01101000 and exponent 0011. [3]

(b) Calculate the denary value of the number with mantissa 01010000 and exponent 1110. [2]

2Hard5 marks

A computer stores real numbers in floating point form using an 8-bit mantissa followed by a 4-bit exponent. Both are in two's complement and the binary point of the mantissa is immediately after the sign bit.

(a) Represent −3.25 as a normalised floating point number in this format. Show your working. [4]

(b) Explain why floating point numbers are normalised. [1]

3Hard6 marks

A floating point system uses an 8-bit two's complement mantissa (point after the sign bit) and a 4-bit two's complement exponent. All numbers are stored normalised.

(a) Calculate the smallest positive normalised value that can be stored. Give your answer as a fraction or decimal. [3]

(b) Calculate the largest positive value that can be stored. [2]

(c) The designer changes the format to a 6-bit mantissa and a 6-bit exponent. State the effect on range and on precision. [1]

Stuck on Fixed and floating point, errors, normalisation, underflow and overflow?

Get it sorted in a free 30-minute session

We work through your weakest questions on this topic on Zoom. I reply the same day.

4Core5 marks

A microcontroller stores numbers with a fractional part using 8-bit fixed point binary in two's complement. There are 4 bits before the binary point and 4 bits after it.

(a) Convert the fixed point number 0101.1010 to denary. Show your working. [2]

(b) Show how the denary number −2.75 is represented in this format. [2]

(c) State the largest positive denary value that can be represented in this format. [1]

5Standard5 marks

A data logger stores readings using 8-bit unsigned fixed point binary with 2 bits before the binary point and 6 bits after it. Any bits that do not fit are discarded (truncated).

(a) Explain why the denary value 0.1 cannot be represented exactly in this format. [2]

(b) Give the binary value that would actually be stored for 0.1. [1]

(c) Calculate the absolute error and the relative error in storing 0.1. [2]

6Standard5 marks

A weather station stores two readings in a format that introduces small errors. The table shows the true value of each reading and the value actually stored.

ReadingTrue valueStored value
Cloud base height (m)1500.41500
Rainfall (mm)0.370.375

(a) Calculate the absolute error for each reading. [2]

(b) Calculate the relative error for each reading. Give each answer to 2 significant figures. [2]

(c) A student says the cloud base height reading is the less accurate one because its error is bigger. Using your answers, explain whether the student is correct. [1]

7Standard4 marks

A games company is choosing how to store numbers with a fractional part in its physics engine. The same number of bits will be used whichever method is chosen.

Compare the use of fixed point and floating point representation for this purpose. Your answer should refer to range, precision and speed of calculation. [4]

8Hard5 marks

A computer stores real numbers in floating point form using an 8-bit mantissa followed by a 4-bit exponent. Both are in two's complement and the binary point of the mantissa is immediately after the sign bit.

(a) The number below is not normalised:
Mantissa 00010110   Exponent 0101
Write the normalised form of this number. [2]

(b) The negative number below is also not normalised:
Mantissa 11100100   Exponent 0010
Write the normalised form of this number. [2]

(c) State how you can tell from the first two bits of the mantissa whether a number in this format is normalised. [1]

9Hard6 marks

A floating point system uses an 8-bit two's complement mantissa (binary point after the sign bit) and a 4-bit two's complement exponent. All results must be stored normalised.

(a) Explain what is meant by underflow. [1]

(b) A program multiplies these two numbers:
Mantissa 01100000 Exponent 0111   and   Mantissa 01000000 Exponent 0010
Calculate the denary result and explain why it cannot be stored in this format. [3]

(c) The program then divides Mantissa 01000000 Exponent 1000 by Mantissa 01000000 Exponent 0010. Explain what problem occurs. [2]

10Stretch8 marks

Figure 1 shows a 16-bit register holding a floating point number. It has a 10-bit mantissa followed by a 6-bit exponent. Both are in two's complement, the binary point is immediately after the sign bit of the mantissa, and numbers are stored normalised.

(a) Calculate the denary value of the number in Figure 1. Show your working. [2]

(b) The denary value 12.3 is to be stored in this format. Any bits that do not fit in the mantissa are discarded (truncated). Show the mantissa and exponent that would be stored, and calculate the absolute error. [4]

(c) The designer is told that 12.3 must be stored more accurately but the register must stay at 16 bits. Explain the change the designer could make and its disadvantage. [2]

Mantissa (10 bits)Exponent (6 bits)1011010000000101binary pointFigure 1

Stuck on this topic?

Book a free 30-minute session on WhatsApp and we'll find exactly which step is costing you the marks. Or build a timed paper on it.

Free 30-minute session