Floating Point Representation

Learn about the conventions behind floating point representation.

How does it work?

Just like scientific notation is an extension of the decimal point notation, floating points can be said to extend fixed point notation.

Let’s look at a number in scientific notation:

ss m×10nm \times 10^{n}

We can divide this number into three distinct parts:

  • The coefficient mm, known as the significand or the mantissa, which can be any real number
  • The power of 1010, nn, which is called the exponent, and can be any integerinteger (positive or negative)
  • ss, which is the sign, and can be - or ++.

In the decimal representation, we leveraged extra symbols like ×\times, the sign, and exponent. In binary, we need to encode all of this in a string of ones and zeroes. For this we develop some conventions of how a floating point number will be represented.

Get hands-on with 1200+ tech skills courses.