Converting a decimal number to binary involves dividing the decimal number by 2 repeatedly and keeping track of the remainders at each step. Here’s a step-by-step mathematical method to convert a decimal number to binary:
Let’s say you have a decimal number “N” that you want to convert to binary.
Let’s say we have decimal number N = 13.
Now, we take the remainders in reverse order: 1101.
So, the binary representation of decimal number 13 is 1101.
Example 1 – Convert 1310 to binary
Division by 2 | Quotient | Remainder | Bit |
13/2 | 6 | 1 | 0 |
6/2 | 3 | 0 | 1 |
3/2 | 1 | 1 | 2 |
1/2 | 0 | 1 | 3 |
Ans. So, 1310 = 11012
Example 2- Convert 17410 to binary
Division by 2 | Quotient | Remainder | Bit |
174/2 | 87 | 0 | 0 |
87/2 | 43 | 1 | 1 |
43/2 | 21 | 1 | 2 |
21/2 | 10 | 1 | 3 |
10/2 | 5 | 0 | 4 |
5/2 | 2 | 1 | 5 |
2/2 | 1 | 0 | 6 |
1/2 | 0 | 1 | 7 |
Ans. So, 17410 = 101011102
0.75 * 2 = 1.5 → Write down 1. 0.5 * 2 = 1.0 → Write down 1. 0.0 * 2 = 0.0 → Stop. So, the binary representation of 0.75 is 0.11.
To convert binary digits to decimals, follow these steps: Start from the leftmost binary digit. Multiply each binary digit by 2 raised to the power of its position (counting from 0 for the rightmost digit). Sum up all the products obtained in step 2.
Decimal 128 is equivalent to binary 10000000.
To write decimal 1024 in binary: Divide 1024 by 2 repeatedly until the quotient becomes 0. Write down the remainders in reverse order. o, decimal 1024 is equivalent to binary 10000000000.
Binary number 11110000 in decimal is equivalent to 240.