Friday 25 March 2011

Boolean Operations

In computer science a Boolean is a primitive data type. This data type consists of whether something is True or False. In this blog 1 or 0.
//section (11.1) personal note

Definitions:
                                                                                                        
The Boolean compliment: 
                                                                 __   __
The negation of  a Boolean. Denoted as  1 or 0.  Spoken as 1(bar) and 0(bar).

 0(bar) = 1
1(bar) = 0

Boolean Addition:

This works exactly like the logical operator OR.

0+0 = 0
0+1= 1
1+0= 1
1+1 =1

Boolean Multiplication:

This works exactly like the logical operator AND.

0*0 = 0
0*1 = 0
1*0 = 0
1*1 = 1

As you can see zeros dominate in any multiplication

Example:
__
 1  *(0+1) = 0 * 1 = 0
(1+1)+(1+0) = 1 + 1 = 1

11 comments:

  1. Very informative and useful in computer science applications! I had to learn this last year for my IB computer science exam. Awesome stuff!

    ReplyDelete
  2. Are you in the Games Design business? Are you in any business?

    ReplyDelete
  3. This stuff seems pretty easy but it probably gets crazy when the numbers get huge!

    ReplyDelete
  4. This stuff just goes completely over my head

    ReplyDelete
  5. Very informative! just being supportive!

    ReplyDelete
  6. in c you can do this wonderful thing
    #define TRUE FALSE
    which will pretty mindfuck every other guy working on the same project :3

    ReplyDelete
  7. Dude, you seem to really know your stuff :D
    I'm going to be taking a course in computing soon so I need to get used to things like this. Please check out my blog!

    ReplyDelete
  8. It is amazing computers can do all they do with 100% toggle switches (on off). It is mind blowing

    ReplyDelete