Beruflich Dokumente
Kultur Dokumente
48/32-bit
48/32-
division algorithm
Vittorio GIOVARA
Alberto GRAND
Formulation of the problem
Example: 84 / 6 = (84 / 3) / (6 / 3)
= 28 / 2
= 12
Invariance property (II)
A A / 216
= =
B B / 216
Example:
184 / 21 = 8, R = 16
(184 / 10) / (21/10) ≅ 18 / 2 = 9
Approximation of the quotient
BUT
(-17) / 4 = -5, R = 3 = 4 – R*
17 / (-4) = -4, R = 1
(-17) / (-4) = 5, R = 3 = 4 – R*
Adjustment of the residual (II)
We can infer the rule from the previous
example:
◦ If the dividend is positive, the residual is the
computed one
◦ If the dividend is negative, the residual is the
complement to the divisor of the computed one.