Operations Involving Binary Numbers
Mainly, there are 4 operations involving Binary Numbers, That is
1.Addition
2.Subtraction
3. Multiplication
4.Division
But i will cover ONLY on subtraction because other operation are as simple as normal
operation in decimal numbers.
For other operation involving Binary Numbers u can refer it on the video above
So I will explain to all of you currently reading this on subtraction between binary numbers.
This will require us to convert the binary numbers in to TWO's Complement.
What is a Two's Complement? Its a step to find a negative number for binary to use for subtraction
operation for binary numbers. The MSB (Most Significant Bit) of a negative binary must be 1.
"Keep in mind that even positive number has a Two's complement but it will turn to be the same binary number due to the MSB (Most Significant Bit) must be a 0!!"
Steps to convert to a Two's Complement
1.Make sure change it to a nearest 4 times bits type either 4 bits , 8 bits or 16 bits.
2. Reverse all the Number of the binary means from 1 to 0 and 0 to 1
eg:
From -->
0111
To --->
1000
3.Add 1 to the LSB (Least Significant Bit)
eg:
1000
+ 1
1001
Therefore the 2's Complement of 0111 is 1001 .
Looks like we are done with the binary numbers. Lets jump to Hexadecimal and Decimal Numbers.
By: Lai Chai Teng
what a nice entry dear.. keep it up yeah! :D
ReplyDelete