Binary Operation
Binary operation that
only focus in addition, subtraction, multiplication and division. Binary number
operation is different with the normal mathematic operation. Binary number only
contains TWO number which are 0 or 1.
Binary Addition
In
the mathematic operation, if 1+1=2 but in binary operation 1+1=10. This is
because there are only 1 and 0 in this operation.
Example
1
Binary Rules
|
0+0=0
|
0+1=1
|
1+0=0
|
1+1=10
|
1+1+1=100
|
1+1+1+1=1000
|
Example
2
1
1<--------------------this is call carried bit
1
0 1
+ 1 1
1 0 0
0
|
Binary Subtraction
Example
1
In
the mathematic operation, if 12-9=3 that is because 2 borrow the left side
digit to minus 3. It is also same with binary subtraction operation 100-1=11
also borrow from left side number.
Binary Rules
|
0-0=0
|
1-0=1
|
0-1=1
(This must borrow
from next binary number)
|
1-1=0
|
10-1=1
|
100-1=11
|
1000-1=111
|
Example
2
1 1 1<-------it can minus 1 when borrow from left side number
1
0 1 0
- 1 1
1 1
1
|
Binary Multiplication
Binary
Multiplication is almost same with mathematic operation multiplication.
Example
1
Binary Rules
|
0x0=0
|
1x0=0
|
0x1=0
|
1x1=1
|
10x0=0
|
100x0=0
|
100x1=100
|
Example
2
1 1 1
x 1
1 0
0 }
1 1 1
0 } must use binary addition operation to solve
1
1 1 0
0 } this step
1
0 1 1
1 0 }
|
Binary Division
The
binary operation division only have a bit different with mathematic operation
division. The different step is only when minus the number.
1
1
1 1 / 1 0
1 1
- 1 1
1 0
1
-
1 1
1 0 This is remainder
|
No comments:
Post a Comment