Number System
A number system is a system for representing numbers. Different number systems use different bases (or radices) to represent numbers.
Common Number Systems:
- Decimal Number System (Base-10):
- Uses 10 digits (0-9) to represent numbers.
- Each digit's position represents a power of 10.
- Example: 123 = 1 * 10^2 + 2 * 10^1 + 3 * 10^0
- Binary Number System (Base-2):
- Uses 2 digits (0 and 1) to represent numbers.
- Each digit's position represents a power of 2.
- Example: 101 = 1 * 2^2 + 0 * 2^1 + 1 * 2^0 = 5
- Octal Number System (Base-8):
- Uses 8 digits (0-7) to represent numbers.
- Each digit's position represents a power of 8.
- Example: 25 = 2 * 8^1 + 5 * 8^0 = 21
- Hexadecimal Number System (Base-16):
- Uses 16 digits (0-9 and A-F) to represent numbers.
- Each digit's position represents a power of 16.
- Example: 2F = 2 * 16^1 + 15 * 16^0 = 47
Number System Conversion
Converting between number systems
involves changing the base of the number. Here are some common conversion
methods:
- Decimal to Binary:
Repeated division by 2, remainders form the binary number.
- Binary to Decimal:
Sum of each digit multiplied by its corresponding power of 2.
- Decimal to Octal:
Repeated division by 8, remainders form the octal number.
- Octal to Decimal:
Sum of each digit multiplied by its corresponding power of 8.
- Decimal to Hexadecimal: Repeated division by 16, remainders form the
hexadecimal number.
Hexadecimal to Decimal: Sum of each digit multiplied by its corresponding power of 16.
No comments:
Post a Comment