two major approaches to store real numbers (i.e., numbers with fractional component
This representation has fixed number of bits for integer part and for fractional part
f given fixed-point representation is IIII.FFF
then you can store minimum value is 0000.0001 and maximum value is 9999.9999.
Assume number is using 32-bit format which reserve 1 bit for the sign, 15 bits for the integer part and 16 bits for the fractional part. Then, -43.625 is represented as following:
Where, 0 is used to represent + and 1 is used to represent. 000000000101011 is 15 bit binary value for decimal 43 and 1010000000000000 is 16 bit binary value for fractional 0.625.
The advantage of using a fixed-point representation is performance and disadvantage is relatively limited range of values that they can represent.
So, it is usually inadequate for numerical analysis as it does not allow enough numbers and accuracy
This representation does not reserve a specific number of bits for the integer part or the fractional part. Instead it reserves a certain number of bits for the number (called the mantissa or significand) and a certain number of bits to say where within that number the decimal place sits (called the exponent).
e first part represents a signed fixed point number called mantissa. The second part of designates the position of the decimal (or binary) point and is called the exponent.
Only the mantissa m and the exponent e are physically represented in the register
floating-point binary number is represented in a similar manner except that is uses base 2 for the exponent. A floating-point number is said to be normalized if the most significant digit of the mantissa is 1.
The floating point representation is more flexible
Glasp is a social web highlighter that people can highlight and organize quotes and thoughts from the web, and access other like-minded people’s learning.