I am a former maths teacher and owner of Doingmaths. I love writing about maths, its applications and fun mathematical facts.
Decimal and Binary Numbers
Decimal numbers are all around us. Every time we count something or look at a clock or adjust the temperature on the oven, we're dealing with decimal numbers. What a lot of people don't realise, however, is how important a role binary numbers also play in our lives. When you switch on your computer, glance at your phone or digital watch, or set the Ti-Vo box to record, these devices are using a digital data system based upon binary numbers.
So what are these binary numbers and why are they so important? In this article, we will take a look at the answers to these questions and more.
The Construction of Decimal Numbers
Before delving into how binary numbers are constructed, it helps to have a full understanding of the composition of the decimal numbers we use on a daily basis. The decimal system takes its name from the root dec- meaning ten in Latin. It's so called as it comprises of ten digits: 0, 1, 2, 3, 4, 5, 6, 7, 8 and 9.
When we count upwards from 0, we start counting through these numbers. As we don't have a single digit to denote the number ten, we write this by moving into a second column on the left and starting our right hand count at 0 again i.e. 10, 11, 12, 13, etc. Once we reach twenty we increase our left hand column to 2 to denote that we have counted through 2 tens and then continue as before.
The same thing happens when we reach 99 and want to continue. We have run out of digits to show how many tens we have and so move over a column to the left and start our count again, but this time with a 1 in the left-most column i.e. 100, 101, 102, 103, etc.
This keeps repeating forever. Once all of our columns have reached 9, we start a new column on the left with a 1 and reset our previous columns back to 0.
Because we shift one column to the left each time we reach ten, we have that each column is worth ten times as much as the one to its right. In a seven-digit number, the first column is worth millions, the second column 100 thousands, then 10 thousands, thousands, hundreds, tens and finally the units in the right-hand column.
You can see this demonstrated in the picture below.
Composition of a Decimal Number
So How Do Binary Numbers Work?
Binary numbers are constructed in a similar way to decimal but with one major difference. Instead of ten digits, we only use two: 0 and 1.
This means that we now have to move over to the left by one column each time we want to count to 2.
Let's build the first few binary numbers in order to demonstrate this:
- Decimal 0 = Binary 0
- Decimal 1 = Binary 1
- Decimal 2 = Binary 10 (we don't have an individual digit above 1, so in order to count higher, we start a new column and reset our right-hand column to 0).
- Decimal 3 = Binary 11 (we have just increased our right-hand column by 1 as we would in decimal).
- Decimal 4 = Binary 100 (we can't increase either of the 1s in 11, so we move over one column and reset the right-hand columns)
- Decimal 5 = Binary 101 (we now continue with the right-hand columns as before)
- Decimal 6 = Binary 110
- Decimal 7 = Binary 111
- Decimal 8 = Binary 1000 (again, as soon as our columns fill with 1s, we create a new column and reset the existing right-hand columns).
Just as with decimal numbers, this continues forever. Remember that in the decimal system each column is worth ten times the one to the right of it. In the binary system, however, as we have been moving over each time we get to 2, each column is now worth twice the column to its right.
This means that the first column from the right is counting how many ones there are; the second column is counting twos; the third column is counting fours; then eights and so on in increasing powers of 2.
The Composition of a Binary Number
Take a look at the image above. It shows the binary number 1 011 001.
To convert this back into decimal, we remember that each column is worth twice the column to its right, hence they are going up in powers of two starting with 20 = 1 for the first column and going up until we have 26 = 64 in the 7th column.
Our number is therefore 1 × 64 + 0 × 32 + 1 × 16 + 1 × 8 + 0 × 4 + 0 × 2 + 1 × 1 = 89.
Just like any decimal number can be calculated by counting up consecutive powers of 10, our binary numbers can be calculated by counting consecutive powers of 2.
Why Is the Binary System So Important?
The binary system is incredibly important in computing. Our devices work through electricity which comes in two states; on or off. As the binary system only has two values: 0 and 1, it is therefore very easy and quick to duplicate using this system of ons and offs.
For example, each time you press a key on your keyboard, that action is represented within your computer as a binary number with the on and off of switches representing the 0s and 1s of the binary system.
© 2020 David
David (author) from West Midlands, England on August 09, 2020:
You're welcome. Thank you for the positive comment!
OJ on July 29, 2020:
Thanks a lot!!! This helped me understand binary numbers very well!!!