Page 95 - Engineering Digital Design
P. 95

66              CHAPTER 2 / NUMBER SYSTEMS, BINARY ARITHMETIC, AND CODES


                    Here, the exponents are subtracted (added) in radix 2 (binary) by using the same algo-
                    rithms as for addition, namely Algorithms 2.8 and 2.9. The division of the mantissas, on
                    the other hand, is best accomplished by using the quadratic convergence iterative divide
                    method discussed in Subsection 2.9.5, since the mantissas are usually represented in nor-
                    malized FPN form. The following examples illustrate the multiplication and division of
                    FPNs.
                    EXAMPLE 2.36 — FPN signed-magnitude multiplication



                                 ->     1    10000010          11101000---00
                       -7.25 10
                       x4.50ip   ->  +0    +10000010          x 10010000-•-00
                      -32.625io        1     10000101          00000000 •• • 00
                                                              000000000•••00
                                                             0000000000•••00
                                                            00000000000•••00
                                                           111010000000-•• 00
                                                          0000000000000•••00
                                                         00000000000000•• • 00
                                                        111010000000000••-00
                                                       1000001010000000-•-00
                                                            23-bit representation
                    The result, given in normalized signed-magnitude 32-bit FPN form, is

                                   1 10000101 000001010000000 • • • Q FPN = -32.625,o,

                    where the MSB 1 bit of the mantissa is omitted. Note that the mantissa has a magnitude
                                        6
                    . 10000010100-•• 00 x 2  = 100000.101.

                    EXAMPLE 2.37 — FPN signed-magnitude division
                                                               3
                                             4.5      0.1001 x 2  _ X
                                           -0.625 ^      0.1010 ~ 7

                    In FPN notation the operands are

                                           X = 0 10000010 100100 • • • 00
                                            7=1 01111111 101000-•• 00.

                    Division of the mantissas MX/'My = Dp/Ds by Algorithm 2.13:

                                  a = l-D s = l - . 101000- • • 00= .011000-•-00
                                 k 0 = l+a = 1.011000 ••-00

                                     D sk 0 = .11011100---00
   90   91   92   93   94   95   96   97   98   99   100