What are the Conversion Of Number System?
Conversion of Number System:
There are several number systems that are generally utilized including Decimal (base 10), Binary (base 2), Octal (base 8), and Hexadecimal (base 16).
Conversion between these number systems involves understanding the positional values of each digit within the number and using basic arithmetic operations.
Here are a few examples of how to convert between these number systems:
1. Converting from decimal to binary:-
To convert a decimal number to binary, you can use the following steps
Divide the decimal number by 2 and record the remainder and the remaining portion.
Divide the remainder by 2 and record the new remainder and leftover portion.
Repeat this cycle until the remainder is 0.
Write the remainder in reverse order(bottom to top) to get the binary equivalent.
For example, to convert the decimal number 43 to binary:
4310 = 101011243 divided by 2 is 21 with a remainder of 1
21 divided by 2 is 10 with a remainder of 1
10 divided by 2 is 5 with a remainder of 0
5 divided by 2 is 2 with a remainder of 1
2 divided by 2 is 1 with a remainder of 0
1 divided by 2 is 0 with a remainder of 1
So the binary equivalent of 43 is 101011.
2. Converting from decimal to Octal:-
To convert a decimal number to an octal, you can use the following steps:
Divide the decimal number by 8 and record the remainder and the remaining portion.
Divide the remainder by 8 and record the new remainder and leftover portion.
Repeat this cycle until the remainder is 0.
Write the remainder in reverse order to get the octal equivalent.
For example, to convert the decimal number 473 to octal:
473 divided by 8 is 59 with a remainder of 1
59 divided by 8 is 7 with a remainder of 3
7 divided by 8 is 0 with a remainder of 7
LSB TO MSB:
1 MSB
3
7 LSB
47310 = 7318
So the octal equivalent of 473 is 731.
3. Converting from decimal to Hexadecimal:-
To convert a decimal number to hexadecimal, you can use the following steps:
Divide the decimal number by 16 and record the remainder and the remaining portion.
Divide the remainder by 16 and record the new remainder and leftover portion.
Repeat this cycle until the remainder is 0.
Write the remainder in reverse order to get the hexadecimal equivalent.
For example, to convert the decimal number 423 to hexadecimal:
26 divided by 16 is 1 with a remainder of A
1 divided by 16 is 0 with a remainder of 1
LSB TO MSB:
7 MSB
A
1 LSB
42310 = 1A716
So the hexadecimal equivalent of 423 is 1A7.
4. Converting from binary to decimal:-
To convert a binary number to decimal. you can use the following steps:-
Write down the binary number and assign positional values to each digit. starting with 1 for the rightmost digit and doubling the value for each subsequent digit.
Multiply each digit by its positional value.
Add up the products to get the decimal equivalent.
For example, to convert the binary number 11011 to decimal:
The rightmost digit has a positional value of 1 so its value is 1 * 1 = 1
The next digit has a positional value of 2 so its value is 1 * 2 = 2
The third digit has a positional value of 4 so its value is 0 * 4 = 0
The fourth digit has a positional value of 8 so its value is 1 * 8 = 8
The leftmost digit has a positional value of 16 so its value is 1 * 16 = 16
Adding up the products gives us 1 + 2 + 0 + 8 + 16 = 27 so the decimal equivalent of 11011 is 27.
5. Converting from binary to Octal and vice versa:-
Octal Digit |
0 |
1 |
2 |
3 |
4 |
5 |
6 |
7 |
Binary Equivalent |
000 |
001 |
010 |
011 |
100 |
101 |
110 |
111 |
6. Binary to Hexadecimal:-
To convert a binary number to a hexadecimal number, these steps are followed −
Starting from the least significant bit, make groups of four bits.
If there are one or two bits less in making the groups, 0s can be added after the most significant bit.
Convert each group into its equivalent hexadecimal number.
Let’s take an example to understand this.
101101101012 = DB516
To convert an octal number to binary, each octal digit is converted to its 3-bit binary equivalent.
Post a Comment