21 Oct 2012

ARITHMETIC FOR COMPUTERS ( addition and subtraction)

Binary Addition:

There is four rules we should follow in binary addition as shown below:

actually,adding binary number is almost similar to adding decimal number. The different is,we use binary rule in this operation. Here i show you the steps how to solve addition of binary number.

Step 1:

Align the numbers you wish to add as you would if you were adding decimal numbers

Step 2:

Start with the two numbers from the right column

Step 3:

Add the numbers following the rules of decimal addition

Step 4:

Add 1+1 as "10". (actually it is not "ten" but "one zero"). Write "0" below and carry a "1" to the next column.


 Step 5 :Start on the next column to the left

Step 6 :

Repeat the steps 5, but add any carry. just to remind that 1+1 = 10 and 1+1+1 = 11. dont forget to carry the "1".

Ok,there is some tips that you must take note. First, don't ever forget the carry. The most important in binary addition, you just only use the digit '1' and '0'. If you find yourself using any other digit, you did something wrong!

Binary subtraction :

same as additon,subtraction of binary also must follow some rule. the rule is shown below:

We can subtract one binary number from another by using the standard techniques adapted for decimal numbers (subtraction of each bit pair, right to left, "borrowing" as needed from bits to the left).

Minuend           10110
Subtrahand  -  10010 
Difference       00100

And when a borrow is needed. Let me make you more clear. you just note that the borrow gives
us 2 in the current bit position. See this example:

Other example:

hexadecimal addition

In hexadecimal addition,if the sum number is greater than 1510, the amount of sum that exceeds
1610 will carry a 1 to the next column. Example are shown below:

hexadecimal subtraction:

There is several steps you must remember to solved hexadecimal subtraction.

step 1: convert hexadecimal to binary.

step 2: take the 2's complement of the binary number

step 3: change it back to hexadecimal number.


Alright! thats all some notes from me. Hopefully you can absorb a few knowledge by this entry and don't forget to come again ya! Thanks for reading...

~posted by Nabila Huda Mohamad (B031210008)

No comments:

Post a Comment