0% found this document useful (0 votes)
10 views15 pages

Data Representation & Arithmetic Algorithms

The document discusses Booth’s Multiplication Algorithm for multiplying signed binary integers and outlines the processes of restoring and non-restoring division. It also covers the IEEE 754 floating-point number representation standard, detailing its components, sizes, and the significance of biased exponents and normalized mantissas. Additionally, it includes examples of finding the IEEE 754 representation for specific decimal numbers.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views15 pages

Data Representation & Arithmetic Algorithms

The document discusses Booth’s Multiplication Algorithm for multiplying signed binary integers and outlines the processes of restoring and non-restoring division. It also covers the IEEE 754 floating-point number representation standard, detailing its components, sizes, and the significance of biased exponents and normalized mantissas. Additionally, it includes examples of finding the IEEE 754 representation for specific decimal numbers.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Module 4: Data Representation and Arithmetic Algorithms

Booth’s Multiplication Algorithm


• Booth algorithm gives a procedure for multiplying binary integers in
signed 2’s complement representation.
• It operates on the fact that strings of 0’s in the multiplier require no
addition but just shifting and a string of 1’s in the multiplier from bit
weight 2k to weight 2m can be treated as 2(k+1) to 2m.
Example -9 X -13 = + 117
Division of integers: Restoring and non-restoring division
Restoring Division:
Non-restoring division
Signed Division
IEEE 754 floating point number representation
Floating Point Standard
• Defined by IEEE Std 754-1985
• Developed in response to divergence of representations
• Portability issues for scientific code
• It defines 4 main sizes of floating-point numbers
• 16, 32, 64 and 128 bit
• Sometimes referred to as Half, Single, Double and Quadruple
precision
• Two commonly used representations
• Single precision (32-bit)
• Double precision (64-bit)
IEEE 754 has 3 basic components:
• The Sign of Mantissa
• 0 represents a positive number
• 1 represents a negative number.
• The Biased exponent
• The exponent field needs to represent both positive and negative
exponents.
• A bias is added to the actual exponent in order to get the stored
exponent.
• excess representation = actual exponent + Bias (Ensures exponent
is unsigned)
• The Normalized Mantissa
• The mantissa is part of a number in scientific notation or a floating-
point number, consisting of its significant digits.
• Here we have only 2 digits, i.e. 0 and 1. So a normalized mantissa
is one with only one 1 to the left of the decimal.
find the IEEE 754 32-bit floating-point representation for −7.7510

find the IEEE 754 32-bit floating-point representation for −0.12510


IEEE reserved values

Common questions

Powered by AI

To convert -7.75 into IEEE 754 32-bit floating-point format, first convert the decimal to its binary equivalent, resulting in -111.11. Normalize this binary number to -1.1111 x 2^2. The sign bit is 1 since it is negative. The exponent is adjusted with a bias of 127, resulting in an exponent of 129 (10000001 in binary). The mantissa is derived from the significant digits to the right of the binary point, resulting in 1111000... The complete IEEE 754 representation is: sign = 1, exponent = 10000001, mantissa = 1111000... .

Booth’s multiplication algorithm manages strings of 0's in the multiplier by simply requiring shifting without any addition, thus streamlining the calculation process. Conversely, it treats a string of 1's in the multiplier differently by translating the segment from bit weight 2^k to weight 2^m into an operation involving 2^(k+1) to 2^m. This approach enables the efficient handling of signed 2’s complement representation for binary integers .

IEEE 754 specifies floating-point precision levels as 16-bit (half), 32-bit (single), 64-bit (double), and 128-bit (quadruple). Half precision is used in applications where memory savings are critical and precision demands are low, such as graphics programming. Single precision is standard for many scientific calculations where moderate precision is sufficient. Double precision is prevalent in high-precision scientific computations and simulations. Quadruple precision is reserved for highly sensitive calculations in fields such as astrophysics, where maximum accuracy is necessary .

In IEEE 754, the mantissa is represented in a normalized form where there is only one non-zero digit (1) to the left of the decimal point. This representation is necessary to maximize the precision and efficiency of stored numbers by keeping significant digits consistent, avoiding ambiguity and redundancy, and ensuring that computations are carried out with high accuracy across different systems .

IEEE reserved values include representations like positive and negative infinity, NaN (Not a Number), and zero. These special values serve distinct purposes: infinities result from operations like division by zero, providing an indication of overflow. NaN is used to represent undefined or unrepresentable results, maintaining computational robustness by allowing continued processing even when encountering mathematically invalid operations. Zero enables differentiation between positive zero and negative zero, which can be significant in certain mathematical contexts .

The IEEE 754 standard was developed in response to the divergence in floating-point number representations across different computing systems, which led to significant portability issues for scientific computation codes. By defining a standardized approach, particularly with specified bit representations like single and double precision, it ensures consistent behavior and accuracy across platforms, aiding in reliable software development and data sharing .

A 32-bit IEEE 754 floating-point number comprises three main components: the sign bit, the biased exponent, and the normalized mantissa. The sign bit signifies whether the number is positive or negative. The biased exponent enables representation of a wide range of powers by storing the exponent with an added bias, making it unsigned. The normalized mantissa ensures precision in the representation by maintaining significant digits within a standardized form, ensuring accuracy in computations .

Restoring division involves calculating an intermediate result and then potentially restoring the previous quotient value if a correction is required, whereas non-restoring division attempts to avoid this restoration step by accounting for errors as they occur, leading to a streamlined process. Both methods seek to achieve the division of binary integers effectively, but they do so with differing procedural approaches .

IEEE 754 employs the biased exponent and normalized mantissa to adequately represent both small and large numbers. By adjusting the exponent with a bias, the standard can express a vast range of values due to the non-negative nature of stored exponents. The normalized mantissa allows for precision within this range, ensuring significant digits are represented accurately without redundant zeros, making efficient use of available bits .

In IEEE 754 floating point representation, the biased exponent allows for the representation of both positive and negative exponents by adding a bias value to the actual exponent. This bias ensures that the exponent is always stored as an unsigned value, which simplifies computation and representation. The mechanism effectively balances the need to accommodate a wide range of exponent values without utilizing a signed integer format .

You might also like