Number Systems - SSS 1 Digital Technologies note
NUMBER SYSTEMS
Subject: Digital Technologies
Term: First Term
Week: 3
Topic: Number Systems
Duration: 80 Minutes (Double Period)
INTRODUCTION
Computers and other digital devices process information using numbers. However, the number system normally used in everyday life is not the only number system used in computing. Digital devices commonly represent and process information using the binary number system, while other number systems such as decimal, octal and hexadecimal are also important in computing.
Understanding number systems enables students to understand how numerical information is represented inside a computer and how values can be converted from one number system to another.
MEANING OF NUMBER SYSTEM
For example, the decimal number system has ten digits, from 0 to 9, so it has a base of 10. The binary number system has only two digits, 0 and 1, so it has a base of 2.
UNDERSTANDING BASE OR RADIX
The base, also called the radix, tells us the number of different digits or symbols available in a number system.
| Number System | Base | Digits/Symbols Used |
|---|---|---|
| Decimal | 10 | 0 – 9 |
| Binary | 2 | 0 and 1 |
| Octal | 8 | 0 – 7 |
| Hexadecimal | 16 | 0 – 9 and A – F |
1. DECIMAL NUMBER SYSTEM (BASE 10)
The decimal number system, also called the denary number system, is the number system commonly used in everyday life.
It has a base of 10 and uses ten digits:
0, 1, 2, 3, 4, 5, 6, 7, 8 and 9
Place Values in Decimal
The value of a digit depends on its position. Each position represents a power of 10.
| Thousands | Hundreds | Tens | Units |
|---|---|---|---|
| 103 | 102 | 101 | 100 |
| 1000 | 100 | 10 | 1 |
For example:
= 300 + 40 + 5
= 345
2. BINARY NUMBER SYSTEM (BASE 2)
The binary number system is a number system with base 2. It uses only two digits:
0 and 1
Binary is fundamental to digital computing because electronic digital circuits can represent two basic states, commonly represented as 0 and 1.
Binary Place Values
Binary place values are powers of 2, beginning with 20 at the right-hand side.
| Position | 27 | 26 | 25 | 24 | 23 | 22 | 21 | 20 |
|---|---|---|---|---|---|---|---|---|
| Value | 128 | 64 | 32 | 16 | 8 | 4 | 2 | 1 |
3. OCTAL NUMBER SYSTEM (BASE 8)
The octal number system is a base-8 number system. It uses eight digits:
0, 1, 2, 3, 4, 5, 6 and 7
The digits 8 and 9 are not used in the octal number system.
Octal Place Values
The place values in octal are powers of 8.
| Position | 83 | 82 | 81 | 80 |
|---|---|---|---|---|
| Value | 512 | 64 | 8 | 1 |
4. HEXADECIMAL NUMBER SYSTEM (BASE 16)
The hexadecimal number system is a base-16 number system. It uses sixteen symbols. The first ten are the decimal digits 0–9, while the remaining six values are represented by the letters A–F.
| Decimal | Hexadecimal |
|---|---|
| 0 | 0 |
| 1 | 1 |
| 2 | 2 |
| 3 | 3 |
| 4 | 4 |
| 5 | 5 |
| 6 | 6 |
| 7 | 7 |
| 8 | 8 |
| 9 | 9 |
| 10 | A |
| 11 | B |
| 12 | C |
| 13 | D |
| 14 | E |
| 15 | F |
COMPARISON OF THE FOUR NUMBER SYSTEMS
| Number System | Base | Symbols Used | Example |
|---|---|---|---|
| Decimal | 10 | 0 – 9 | 34510 |
| Binary | 2 | 0, 1 | 10112 |
| Octal | 8 | 0 – 7 | 3458 |
| Hexadecimal | 16 | 0 – 9, A – F | A2DE16 |
CONVERSION BETWEEN NUMBER SYSTEMS
Converting between number systems means changing a numerical value from one base to another without changing the actual value represented.
BINARY TO DECIMAL
To convert a binary number to decimal, multiply each binary digit by its corresponding power of 2 and add the results.
= (1 × 23) + (0 × 22) + (1 × 21) + (1 × 20)
= (1 × 8) + (0 × 4) + (1 × 2) + (1 × 1)
= 8 + 0 + 2 + 1
= 11
Therefore, 10112 = 1110
DECIMAL TO BINARY
To convert a whole decimal number to binary, repeatedly divide the number by 2 and record the remainder at each step. Continue until the quotient becomes zero. Read the remainders from bottom to top.
| Division | Quotient | Remainder |
|---|---|---|
| 25 ÷ 2 | 12 | 1 |
| 12 ÷ 2 | 6 | 0 |
| 6 ÷ 2 | 3 | 0 |
| 3 ÷ 2 | 1 | 1 |
| 1 ÷ 2 | 0 | 1 |
Reading the remainders from bottom to top:
Therefore:
BINARY TO OCTAL
Binary can be converted directly to octal by grouping the binary digits into sets of three, starting from the right. If necessary, leading zeros are added to complete the first group.
Binary-to-Octal Conversion Table
| Binary | Octal |
|---|---|
| 000 | 0 |
| 001 | 1 |
| 010 | 2 |
| 011 | 3 |
| 100 | 4 |
| 101 | 5 |
| 110 | 6 |
| 111 | 7 |
= 011 100 101
011 = 3
100 = 4
101 = 5
Therefore:
111001012 = 3458
This is one of the useful direct conversion methods from the original number system material.
OCTAL TO BINARY
To convert octal to binary, replace each octal digit with its equivalent three-bit binary group.
4 = 100
5 = 101
3458 = 0111001012
= 111001012
Leading zeros may be removed from the complete number when they do not affect the value.
BINARY TO HEXADECIMAL
To convert binary to hexadecimal, group the binary digits into sets of four, starting from the right. Add leading zeros where necessary.
| Binary | Hexadecimal |
|---|---|
| 0000 | 0 |
| 0001 | 1 |
| 0010 | 2 |
| 0011 | 3 |
| 0100 | 4 |
| 0101 | 5 |
| 0110 | 6 |
| 0111 | 7 |
| 1000 | 8 |
| 1001 | 9 |
| 1010 | A |
| 1011 | B |
| 1100 | C |
| 1101 | D |
| 1110 | E |
| 1111 | F |
= 1110 0101
1110 = E
0101 = 5
Therefore:
111001012 = E516
The four-bit conversion relationship between binary and hexadecimal is also useful for reverse conversion.
HEXADECIMAL TO BINARY
To convert hexadecimal to binary, replace each hexadecimal digit with its four-bit binary equivalent.
2 = 0010
D = 1101
E = 1110
Therefore:
A2DE16 = 10100010110111102
This direct conversion method is based on the four-bit relationship between hexadecimal and binary digits.
DECIMAL TO OCTAL
To convert a whole decimal number to octal, repeatedly divide the number by 8 and record the remainders. Read the remainders from bottom to top.
| Division | Quotient | Remainder |
|---|---|---|
| 1792 ÷ 8 | 224 | 0 |
| 224 ÷ 8 | 28 | 0 |
| 28 ÷ 8 | 3 | 4 |
| 3 ÷ 8 | 0 | 3 |
Reading the remainders from bottom to top gives:
Therefore:
The repeated-division method is also demonstrated in the original material.
DECIMAL TO HEXADECIMAL
To convert a whole decimal number to hexadecimal, repeatedly divide the number by 16. If a remainder is 10 or greater, replace it with the corresponding hexadecimal letter A–F.
| Division | Quotient | Remainder | Hexadecimal |
|---|---|---|---|
| 1792 ÷ 16 | 112 | 0 | 0 |
| 112 ÷ 16 | 7 | 0 | 0 |
| 7 ÷ 16 | 0 | 7 | 7 |
Reading the hexadecimal remainders from bottom to top:
Therefore:
OCTAL TO DECIMAL
To convert an octal number to decimal, multiply each digit by its corresponding power of 8 and add the results.
= (3 × 82) + (4 × 81) + (5 × 80)
= (3 × 64) + (4 × 8) + (5 × 1)
= 192 + 32 + 5
= 229
Therefore:
3458 = 22910
This place-value method is demonstrated in the original material.
HEXADECIMAL TO DECIMAL
To convert hexadecimal to decimal, replace A–F with their decimal values, multiply each digit by its corresponding power of 16, and add the results.
= (A × 163) + (2 × 162) + (D × 161) + (E × 160)
= (10 × 4096) + (2 × 256) + (13 × 16) + (14 × 1)
= 40960 + 512 + 208 + 14
= 41694
Therefore:
A2DE16 = 4169410
The original material uses this same place-value method for hexadecimal to decimal conversion.
OCTAL AND HEXADECIMAL THROUGH BINARY
When converting between octal and hexadecimal, an effective method is to use binary as an intermediate number system.
Example: Octal to Hexadecimal
Convert 3458 to hexadecimal.
3 = 011
4 = 100
5 = 101
3458 = 0111001012
Step 2: Group the binary digits into sets of four from the right.
011100101 = 0000 1110 0101
0000 = 0
1110 = E
0101 = 5
Therefore:
3458 = E516
IMPORTANCE OF NUMBER SYSTEMS IN COMPUTING
Number systems are important in Digital Technologies for several reasons:
- They help computers represent and process numerical information.
- Binary provides the basic numerical representation used by digital electronic systems.
- Hexadecimal provides a shorter and more convenient way of writing long binary values.
- Octal can also provide a compact representation of binary values.
- Number-system conversion helps programmers, computer technicians and students interpret data represented in different bases.
- Understanding number systems provides a foundation for studying computer architecture, digital electronics and programming.
COMMON ERRORS TO AVOID
- Do not use digits that are not allowed in a number system.
- Remember that binary uses only 0 and 1.
- Remember that octal uses 0 to 7 only.
- Remember that hexadecimal uses 0–9 and A–F.
- When using repeated division, read the remainders from bottom to top.
- When converting binary to octal, group the digits in threes.
- When converting binary to hexadecimal, group the digits in fours.
- Always identify the base of a number when necessary.
CLASS ACTIVITY
Activity 1: Identify the Number System
State the number system represented by each of the following:
- 1011012
- 7258
- 34810
- AF216
Activity 2: Convert the Following
- 10102 to decimal
- 2510 to binary
- 111001012 to octal
- 111001012 to hexadecimal
- 3458 to decimal
SUMMARY
A number system is a method of representing numerical values using a defined set of symbols and rules. The most common number systems studied in computing are decimal, binary, octal and hexadecimal.
Decimal has base 10 and uses 0–9. Binary has base 2 and uses 0 and 1. Octal has base 8 and uses 0–7, while hexadecimal has base 16 and uses 0–9 and A–F.
Numbers can be converted from one system to another using place-value calculations, repeated division, and direct binary grouping methods.
EVALUATION QUESTIONS
- What is a number system?
- What is meant by the base or radix of a number system?
- State the base of the decimal number system.
- List the digits used in the binary number system.
- State the digits used in the octal number system.
- What are the hexadecimal symbols A–F used to represent?
- Convert 10112 to decimal.
- Convert 2510 to binary.
- Convert 111001012 to octal.
- Convert 3458 to decimal.
ASSIGNMENT
- Define number system and explain the meaning of base.
- Write the base and symbols used by the decimal, binary, octal and hexadecimal number systems.
- Convert 1101012 to decimal.
- Convert 4510 to binary.
- Convert 101011112 to hexadecimal.
- Convert 5728 to decimal.
- Convert 25510 to hexadecimal.
Comments
Post a Comment