4.1.14

Floating Points in Binary

Test yourself on Floating Points in Binary

Test your knowledge with free interactive questions on Seneca — used by over 10 million students.

Floating Point Representation

Floating point is a method of representing numbers in binary, which makes use of a binary point placed after the ‘most significant bit’ (MSB).

Floating point

Floating point

  • A floating point binary number is made up of two parts:
    • The mantissa is the main number, containing a binary point after the MSB.
    • The exponent determines where the binary point is positioned before the number is read.
  • If the exponent is negative (i.e. it begins with a ‘1’), the binary point is moved left instead of right.
Converting to denary

Converting to denary

  • After the binary point has been moved, we can read the value of the mantissa.
  • The denary value of the binary digit to the right of the binary point corresponds to:
    • 21=122^{-1}=\frac{1}{2}.
  • Each subsequent binary digit corresponds to 22,23,242^{-2},\,2^{-3},\,2^{-4}.. and so on.
Example

Example

  • The example below is a 12-bit floating point number, with an 8-bit mantissa and a 4-bit exponent:
    • 0 . 1 0 1 1 0 0 0 0 0 1 1
  • The exponent 0011 (which is equal to 3) identifies where the binary point should move in order to read the number.
Example cont.

Example cont.

  • In this example, the binary point is moved 3 places to the right, which in turn subtracts 3 from the exponent:
    • 0 1 0 1 . 1 0 0 0 0 0 0 0
  • This represents the decimal number 5.5.
Jump to other topics
1

Components of a Computer

2

Software & Software Development

3

Exchanging Data

4

Data Types, Data Structures & Algorithms

5

Legal, Moral, Cultural & Ethical Issues

6

Elements of Computational Thinking

6.1

Thinking Abstractly

6.2

Thinking Ahead

6.3

Thinking Procedurally

6.4

Thinking Logically

6.5

Thinking Concurrently

7

Problem Solving & Programming

8

Algorithms

Unlock your full potential with Seneca Premium

  • Unlimited access to 10,000+ open-ended exam questions

  • Mini-mock exams based on your study history

  • Unlock 800+ premium courses & e-books

Get started with Seneca Premium