23 integer arithmetic 59 twos complement addition 4

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: s, however, we might wish to determine whether overflow has occurred. For example, suppose we compute × Ü +u Ý , and we wish to Û determine whether × equals Ü · Ý . We claim that overflow has occurred if and only if × Ü (or equivalently × Ý.) To see this, observe that Ü · Ý Ü, and hence if × did not overflow, we will surely have × Ü. On the other hand, if × did overflow, we have × Ü · Ý ¾Û . Given that Ý ¾Û , we have Ý ¾Û ¼, and hence × Ü · Ý ¾Û Ü. In our earlier example, we saw that +u ½¾ . We can see that overflow occurred, since . Modular addition forms a mathematical structure known as an Abelian group, named after the Danish mathematician Niels Henrik Abel (1802–1829). That is, it is commutative (that’s where the “Abelian” part comes in) and associative. It has an identity element 0, and every element has an additive inverse. Let us consider the set of Û-bit unsigned numbers with addition operation +u . For every value Ü, there must Û be some value -u Ü such that -u Ü +u Ü ¼....
View Full Document

Ask a homework question - tutors are online