Fixed and Floating Point Representation
Fixed and Floating Point Representation
Representation
• In General sign bit equal to 0 for positive
and 1 for negative.
• The representation of the binary point in a
register is complicated by the fact that it is
characterized by a position in the register.
There are two ways
• fixed position
• floating-point representation.
Fixed point Representation
• The fixed-point method assumes that the
binary point is always fixed in one position.
The two positions most widely used
– a binary point in the extreme left of the
register to make the stored number a fraction
– a binary point in the extreme right of the
register to make the stored number an integer.
Integer Representation
• When an integer binary number is positive, the
sign is represented by 0 and the magnitude by a
positive binary number.
• When the number is negative, the sign is
represented by 1 but the rest of the number may
be represented in one of three possible ways:
1. Signed-magnitude representation
2. Signed-1' s complement representation
3. Signed 2' s complement representation
Ex: + 14 – 0 0001110
• Three different ways to represent - 14 with eight bits.
In signed-magnitude representation 1 0001110
In signed-1's complement representation 1 11 10001
In signed-2's complement representation 1 11 10010
Overflow
• When two numbers of n digits each are added and the sum
occupies n + 1 digits, we say that an overflow occurred.