There is no performance advantage to this way of

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: right), we have ¼½½¼½¼¼½ representing the set ¼¿ , and ¼½¼½¼½¼½ representing the set ¼¾ . Under this interpretation, Boolean operations | and & correspond to set union and intersection, respectively, and ˜ corresponds to set complement. For example, the operation & yields bit vector ¼½¼¼¼¼¼½ , while ¼ . In fact, for any set Ë , the structure È ´Ë µ Ë forms a Boolean algebra, where È ´Ë µ denotes the set of all subsets of Ë , and denotes the set complement operator. That is, for any set , its complement is the set ¾ Ë ¾ . The ability to represent and manipulate finite sets using bit vector operations is a practical outcome of a deep mathematical principle. 2.1.8 Bit-Level Operations in C One useful feature of C is that it supports bit-wise Boolean operations. In fact, the symbols we have used for the Boolean operations are exactly those used by C: | for O R, & for A ND, ˜ for N OT, and ˆ for E XCLUSIVE O R. These can be applied to any “integral” dat...
View Full Document

This note was uploaded on 09/02/2010 for the course ELECTRICAL 360 taught by Professor Schultz during the Spring '10 term at BYU.

Ask a homework question - tutors are online