×

IEEE Standard 754 Floating Point Numbers

Floating Point Representation: IEEE- 754

There were many problems in the conventional representation of floating-point notation like we could not express 0(zero), infinity number. To solve this, scientists have given a standard representation and named it as IEEE  Floating point representation.

IEEE stands for “ The Institute of Electrical and Electronics Engineers." It's an association that develops, defines and reviews the standard of electrical and computer science engineering. IEEE in 1985 and augmented in 2008 provided a standard to represent floating-point numbers and process them. This standard is now used by all the manufacturers while designing the floating-point arithmetic units to be portable among computers.

History of IEEE Floating Point Standard 754 -1985 & innovation in 2008

In the mid-'50s, floating-point binary numbers were used in the beginning without a format. As there was no defined format to represent floating-point numbers in computers, creating problems in the portability of programs from one manufacturer's computer to another manufacturer's computer. With the innovation of personal computers in the mid-1980s, the number of bits used to store floating-point numbers was standardized as 32 bits. After that, a standing committee was formed by IEEE to standardize how floating-point binary numbers would be represented in computer and to resolve exception conditions such as an attempt to divide by 0, representation of infinity,0 and uniformity in rounding numbers.

Now, the system was able to use standard floating-point formats in 32 bits and 64 bits. With the innovation in computer technology, it became feasible to use many bits for floating-point numbers. IEEE 754 standard was updated in 2008 with a new standard for 16 bits and 128 bits numbers. The new version IEEE 754-2008 stated the standard for representing decimal floating-point numbers.

IEEE 754 standard has given the representation for floating-point number, i.e., it defines number representation and operation for floating-point arithmetic in two ways:-

  1. Single precision (32 bit)
  2. Double precision ( 64 bit )

 Single-Precision -

  1. Sign- In single precision, 1 bit is assigned for the sign (positive or negative).
  2. Exponent- 8 bit is assigned for the range named exponent.
  3. Mantissa- 23 bit is assigned for the precision ( it's for the fractional part)

Note:                                                                    

Floating Point Representation: IEEE- 754

Why do we add 127?

Suppose a floating-point number:

                                1.1011 * 2+5           E = 5 + 127 = 132               positive

                                1.1011 * 2-5           E = -5+ 127 = 122               number

To maintain the +ve exponent only, we have to add 127 & 1023 (due to this, exponent always remain positive). If we add number less than 127, then we attain – ve exponent.

Note:- (i) If a different sign for exponent is used while performing the floating-point arithmetic, the hardware only concentrates on the exponent sign to overcome certain hardware problems in the floating-point representation. The true component is added to 127 to manage the number in + ve form. End-user subtracts 127 when we give E' to end-user.

In double-precision (64- bit)

  1. Sign- In single precision, 1 bit is assigned for the sign(positive or negative).
  2. Exponent- 8 bit is assigned for the range named as an exponent.
  3. Mantissa- 23 bit is assigned for the precision ( it's for the fractional part)

                                                  Excess = 2n-1- 1

In single precision                                                     In double precision

N= E = 8                                                                    N= E = 11

So, Excess = 28-1- 1 = 127                                        So, Excess = 211-1- 1 = 1023

What is the range of E & e?

E = 8 bit (in single precision format)

So, maximum value of a 8 bit number = 28 – 1= 255

Minimum value of a 8 bit number = 0

     0? E ? 255 (because using 8 bits, total combination become = 28 =256[0-255]

But in actual the value for normal number    1? E ? 254

Therefore, 0 & 255 are  reserved for special number.

Example:- Represent the following number in single precision and double precision.

  • (-23.875)10
  • (.75)10

Solution:- (-23.875)10 =  -(10111.111)2 =  -1.0111111 * 2+4

                                                                         Mantissa

In single precision

S= 1 ( because number is –ve)

E= e + 127 = 4 +127 =131 =(10000011)2

M= 0111111

 S= 1E =10000011 M=0111111…..

     1 bit                                      8 bit                                     23 bit

In double precision

S= 1 ( because number is –ve)

E= e + 1023 = 4 +1023 =1027 =(10000000011)2

M= 0111111

 S= 1E =10000000011 M=0111111…..
  1. bit                                      11 bit                                     52 bit

Q) (.75)10

Solution:- (.75)10 =  -(.11)2 =  1.1 * 2-1

In single precision

S= 0 ( because number is +ve)

E= e + 127 = -1 +127 =126 =(01111110)2

M= 10000….

 S= 0E =011111110 M=10000…….

     1 bit                                      8 bit                                     23 bit

In double precision

S= 0 ( because number is +ve)

E= e + 1023 = -1 +1023 =1022 =(11100011110)2

M= 100000…..

 S= 1E =11100011110 M=100000…..

     1 bit                                      11 bit                                     52 bit

The maximum value in single precision

As we want maximum value so the number should be positive, i.e., S=0

      E max= 254 = (11111110)2

      M max = 11111…….111(23 bit)

      V= (-1)5 (1.11111…..)2  x 2e         where e = E-127

      V= (-1)0 (1.11111…..)2  x 2254-127

  V=  (1.11111…..23 times)2  x 2127    

   V= ( 20*1 + 1 * 2-1 + 1 * 2-2+………..1 * 2-23) x 2127

   V= ( 1+ ½ + ½2 +½3………..½23 ) x 2127   

               G.P series with r = ½, a =1, n =24[0-23]

Sum of G.P Series = a(1-rn) / 1-r = 2 x[1-2-24]

V= 2 x(1-2-24) x 2127

    = (2-2-23) x 2127 = 3.4 x 1038

Minimum value in single precision

As we want maximum value so the number should be negative i.e. S=1

      E min= 254 = (11111110)2

      M min = 11111…….23 times(23 bit)

      V= (-1)5 (1.11111…..)2  x 2e         where e = E-127

         Answer  = -3.4 x 1038

Maximum and Minimum value in Single and double precision

Floating Point Representation: IEEE- 754

IEEE -784 Floating-Point Standard –New Version (2008)

IEEE 754 standard was updated in 2008 with a new standard for 16 bits and 128 bits numbers. These are made to solve exact decimal computation required in financial transactions and for working in the graphic area, and using high-performance computers for intensive numeric computation.

16-bit Standard Representation  

            Sign          Exponent           Significant
              I bit            5 bits             10 bits

The maximum positive integer is

+ 1.111..1 × 2 15

 = 1 + (1 – 2– 11)×2 15

 = (2 – 2–11)×2 15

  ? 65504.

The minimum positive number is

+ 1.000 … 0 × 2 –14

= 2 –14

= 0.61 × 10-4 .

128-bit Standard Representation 

            Sign          Exponent           Significant
              I bit            14 bits             113 bits

The largest positive number which can be represented in this format is

(1 – 2–113)×216383

 ? 104932.

The smallest normalized positive number is:-

 = 2 1–16383

= 2 –16382

 ? 10 –4931 .


Related Topics

Instruction Pipelining and Pipeline Hazards

Instruction Pipelining and Pipeline Hazards To apply pipeline, the prerequisite is to perform the same processing over multiple inputs, then pipelining is important. So instruction execution is the best example for...

10 minutes read.

Machine Instructions

What is a Digital Computer? A computer that takes input in a binary form and produces output in binary form. The question arises of what kind of input the computer takes...

4 minutes read.

Micro-Operations

Micro-Operations If CPU wants to perform any operation, suppose execution of only one instruction or even break it down one particular execution phase (like fetch instruction, write back, decode, operand fetch...

9 minutes read.

Ethernet Frame Format

What is Ethernet? As we know in computer networking, LAN (Local Area Network) is used to connect devices in limited geographical areas like schools or a building.LAN uses different topologies (arrangement...

3 minutes read.

Data Path, ALU and Control Unit

Data Path, ALU(Arithmetic Logic Unit) and Control Unit What is the Data path? Suppose any data processing operation should be performed in the CPU like transferring the content of register from one...

5 minutes read.

Use Case Diagram for the online bank system

What is a Use Case Diagram? A tool is called a Use Case Diagram which is used to create, present, and comprehend the functional requirements for a system. The Use Case...

3 minutes read.

CPU Registers

CPU Registers Within the CPU, we have small- small storage units called registers. If we are executing a certain program within the CPU, there's a need to store that program content,...

11 minutes read.

Assembly Language Register

Assembly Language Register Assembly language was introduced during the late 1940s in the second generation. It is a low-level language that helps in communication between the user and the computer. It...

6 minutes read.

Computer Organization and Architecture Data Formats

Data Formats In the digital world, everything is based on digits. In every method, the calculation is processed on the digits, and most importantly, the computer only understands the binary language...

6 minutes read.

Basic Terminologies Related to COA

Some Basic Terminologies Related to COA Computer organization and architecture is the detailed study of the internal components of the computer with their functionality. It describes how components arranged together and...

7 minutes read.

Addressing Modes

Introduction: Addressing Modes An instruction consists of two parts opcode and operands. Opcode tells the operation going to perform, and operand information is the address of the operand. The CPU interprets...

8 minutes read.

BCD to 7 Segment Decoder

What is BCD? BCD is called Binary Coded Decimal. As you know there are a lot of forms in which we can represent the number like Binary, decimal, hexadecimal, and octal...

3 minutes read.

8085 instructions set

Introduction: In the computer, the user sends the data. The computer can use data and it also process the data. After the processing, send the result to the user. The specific...

10 minutes read.

8085 Pin Configuration

Introduction: Intel 8085 is consist 40 pin IC. The pin name of 8085 is A8 – A15; AD0 – AD7; ALE; IO/M; S0, S1; RD; WR; READY; HOLD; HLDA; INTR; INTA;...

6 minutes read.

Microprocessor classification

Introduction: Microprocessor is known as the computer processor. The IC or integrated Circuit makes the microprocessor. that is the brain of the computer machine. The microprocessor is known as the...

6 minutes read.

74138 IC DECODER

74138 DECODER Decoder A combinational circuit called a decoder can have up to 2n output lines and 'n' input lines. When a decoder is enabled, depending on the mix of inputs,...

4 minutes read.

Advantages and Disadvantages of Flash Memory

What is Flash Memory? Electrically Erasable Programmable Read-Only Memory (EEPROM) and Erasable Programmable Read-Only Memory (EPROM) are used for flash memory (EEPROM). Although technically the word flash is used in the industry...

3 minutes read.

Computer Organization and Architecture Tutorial

Introduction to Computer Organization and Architecture In this modern era, or we can say computer era, Technology from all around surrounds us. Human is conserved, connected and absorbed by Technology. From...

4 minutes read.

Local Broadcast Address and loopback address

In computer networking, if you send the data from one source to another source or group of sources in the form of packets, then this is called casting. We can categorize...

3 minutes read.

8085 Arithmetic Instructions

Arithmetic instructions are a type of instruction in a computer's instruction set that perform arithmetic operations on data. These operations can include addition, subtraction, multiplication, and division. Arithmetic instructions can...

4 minutes read.