I could just explain how to read a binary number, but in order to fully grasp the concept of the binary number system, we need to do a bit more work. Trust me, though, as it will provide context, and will allow you to understand other number base systems as well!
Base 10
In our number system, we have ten digits: 0, 1, 2, 3, 4, 5, 6, 7, 8, and 9. Note that 10 is not included. Our system is called “Base 10”, and it works because each digit in a number can be any of those 10 digits.
Remember that you can break up a number into parts, such as:
As we add more digits to our number, the number place increases by 10. We know this intuitively.
This is actually a quirk of the Base 10 number system; each digit represents 1s, 10s, 100s, 1000s, and so on. We can actually re-write our example equation to show this:
Can you see a pattern?
Remember powers? Like…
Well, number systems are actually kinda built around powers! Look at these:
And this pattern continues… You can see that our Base 10 system is actually made up of 10s to the power of counting numbers!
Look at our earlier example:
Let’s extend this idea to Base 2….
Base 2 (Binary)
In a Base 2 number system, we only have the two digits 0 and 1. Note that 2 is not included; there are two digits. Similarly, we can represent numbers by putting these digits together.
Let’s use the same idea as before. Instead of 10, we can use 2.
Can you see a pattern? Our number doubles each time.
Now, instead of each digit representing 1s, 10s, 100s, etc, they represent 1s, 2s, 4s, 8s, 16s, etc.
Let’s look at an example. This is a binary number:
We know, like before, that it can be broken up into parts, which represent each digit:
Which is the same as:
I actually chose this binary number arbitrarily before doing the calculation, so my apologies for the unfortunate result.
Now we know how to read binary numbers; if there is a 1, then add its value to the total. A 0 means do nothing.
Any number can be written as a binary number. Let’s try writing one… 37!
First of all, it’s an odd number. The only way we can have an odd number is if the first digit is a 1. This is because the first digit is the only one that represents an odd number. The others are all 2, 4, 8, 16, 32, etc. They are all divisible by 2. Hence, the first digit will be a 1.
So now we just need to figure out how to make “36” with our other options…
The next number in the sequence after 16 is 32, which is close to 36, so let’s use that. So far, we have:
It looks like we are missing a 4, so let’s add that!
We’ll simply change the “4” position from a 0 to a 1:
Ta-da!
Other Uses
Counting
Binary numbers are useful for counting in electronics!
We can count in binary by starting with 0, which represents 0.
We’ll change it to a 1, which represents 1.
Since 1 is the ‘highest’ number, it will turn the next number into a 1, and itself into a 0. So, we get 10, which represents 2.
We’ll keep changing the first digit to a 1. We get 11, which represents 3.
Since 1 is the ‘highest’ number, we’ll overflow it to the next digit, which also happens to be a 1. We’ll overflow it to the next digit as well. Now we get 100, which represents 4.
This process continues forever. Here is a gif to show it more visually:
This is useful for computers, since we can keep applying a “pulse” to the first digit to change it from 0 to 1. If a 1 receives a pulse, it will turn to 0, and pass a pulse to the next digit.
This functionality has actually been added to Minecraft via the new copper bulbs! Check out Mumbo Jumbo’s video (time stamped). Note: I believe that in this video, a “on” copper bulb represents a binary 0, and an “off” copper bulb represents a binary 1, counter-intuitively…
Operations
Binary numbers allow us to do helpful operations revolving around the number 2.
In Base-10, we can easily multiply by 10 by adding a 0 to the end of our number, thus making it 10 times bigger.
In Binary, we can easily multiply by 2 by adding a 0 to the end of our number. This effectively doubles each part of the number, since they are being moved to the left by one position.
For example, 10101 (16 + 4 + 1 = 21) multiplied by two is 101010 (32 + 8 + 2 = 42).
The same is true for division; in Base-10, we can easily divide by 10 by shifting the numbers to the right by one position. In Base-2, we can easily divide by 2 by shifting the numbers to the right by one position. However, because of a lack of decimal points (at least in our basic understanding at the moment), some rounding will occur on odd numbers.
Conclusion
All in all, binary numbers are helpful for computers because of the simple fact that electricity can either be flowing (1) (on) or not flowing (0) (off).
I hope you were able to learn something!
If you would like to have a go at writing a number in binary, go for it! An extension task can be to write a number in another Base system, such as Base-5…
i often think in binary when i think about food... either i'm eating, or i'm not! 🤣