A number system is a system for expressing numbers that are the mathematical notation used for manipulating other countable things. The numbers are represented in different based systems in different situations. The decimal number system is used for human counting but not role in machines. Binary numbers are used in modern digital devices. Octal and Hexadecimal number systems are just packages of 4 binary bits. In computer science, we have to study four number systems. They are
The following table shows the number system equivalent to one another.
Binary Number System: Any number having a base or radix 2 and the number consists of 0 and 1 only are called binary number systems. E.g: 11102, 10012, 1110012
Decimal Number System: Any number having a base or radix 8 and the number consists of 0, 1, 2, 3, 4, 5, 6, and 7 are called octal number systems. E.g: 5638, 12358, 57368
Decimal Number System: Any number having a base or radix 10 and the numbers consists 0, 1, 2, ........ 9 are called decimal number system. E.g : 19610, 25810, 123610
Hexadecimal Number System: Any number having a base or radix 16 and the number consists 0, 1, 2, 3, ...... 9 and character consist A, B, C, D, E and F are called hexadecimal number system. Where A=10, B=11, C=13, D=14, E=15 and F=15. E.g : 25A16, 156B16, 9D16
The modern digital computer system performs every calculation in the form of binary format. They present 0 or 1, on or off, present and absent. It represents the status.
1) Binary Addition:
Binary addition is performed in a similar way to decimal addition.
|1||1||10 (With a carry of 1)|
Example: a) Add 110102 + 10012 b) 111102 + 111012
2) Binary Subtraction
Binary subtraction, a similar method is adopted as in the decimal system
|0||1||1 (with a borrow of 1)|
Example : a) 10010 - 1011 b) 1101101 - 111101
3) Binary Multiplication
Binary multiplication is easier since there is no number as a "carry" value. The following rule is adopted in binary multiplication. The values are added column-wise as in binary addition.
Example: a) 11101 x 111 b) 100011 x 110
4) Binary Division
Binary Division is similar to decimal division. If a number cannot be divided, put 0 to the quotient. If a division is possible put 1 to the quotient. Multiplication and subtraction are discussed in binary multiplication and binary subtraction.
Example: a) Divide 1011 by 11 b) 111 by 11