Loading...
Hello.
My name is Mrs. Holborow, and welcome to Computing.
I'm so pleased that you can join me for the lesson today.
In today's lesson, we're going to be exploring number bases and how we can convert binary numbers to and from decimal numbers.
Welcome to today's lesson from the unit Representation of numbers.
This lesson is called Number basis, and by the end of today's lesson, you'll know the difference between a base-2 and base-10 number and you'll be able to convert between these bases.
Shall we make a start? We will be exploring these key words during today's lesson.
Place value.
Place value.
A digit's value based on its position in a number Base-10.
Base-10.
A number system using the digits 0 to 9 where each place value is a power of 10.
Base-2.
Base-2.
A number system using only the digits 0 and 1 where each place value is the power of 2.
Decimal.
Decimal.
A base-10 number system.
There are three parts to today's lesson.
We'll start by explaining the differences between base-2 and base-10.
We'll then convert binary numbers to decimal numbers and we'll finish by converting decimal numbers to binary numbers.
Let's make a start by explaining the differences between base-2 and base-10.
All computer systems run on electricity.
Transistors allow electricity to be on or off in a circuit.
In transistors, on represents 1 and off represents 0.
These combinations of 1s and 0s are called binary.
We combine lots of transistors to represent data and instructions in binary.
Here's an example of some switches and they represent the binary value 10101110.
But Aisha's got a really good question.
"What does 10101110 actually mean?" Let's find out.
What is the value of this number? 9 019.
The value of this number is 9,019.
Aisha says, "Why does the first 9 hold more value than the last 9?" Ah, Jun's got a brilliant answer.
"Each number has a place value." Place value is a digit's value based on its position in a number.
For example, the number 9 in the number 9123 has the value of 9000 and the number 2 has the value of 20.
What are the place values in this number? Perhaps pause your video here and have a think.
How did you get on? Can you see here I've added the headings, 1,000 for the 9 'cause that represents 9,000, then 100, and then 10, and then 1.
You work out the next place value by multiplying by 10.
Time to check your understanding.
What would the next place value be if there was another column on the left? Is it a, 1,000, b, 10,000, or c, 100,000? Pause the video here whilst you have a think.
That's right! The correct answer is b, 10,000.
We have 10 digits in our decimal number counting system, 0 through to 9.
Our number system is called a base-10 number system because it has 10 digits.
Binary is a base-2 number system.
This is because it only uses two digits, 0 and 1.
Aisha's got a really good question.
"What would be the place values for a binary number?" Maybe pause the video whilst you have a think.
To work out the next place value in binary, we multiply by 2 as we move from right to left.
So, in the base-10 number system we multiplied by 10.
In binary, which is base-2, we multiply by 2.
So, in the rightmost column, we have 1 for the place value, we multiply that by 2, which becomes 2, and then if we multiply that again by 2, it's 4, and then if we multiply again by 2, it's 8, and so on.
Time to check your understanding.
How many digits does base-10 use? Is it a, 2, b, 9, or c, 10? Pause the video here whilst you have a think.
How did you get on? Did you select c? Great work.
The base-10 number system uses 10 digits, 0 through to 9.
For binary values, what would the next place value be if there was another column on the left? Is it a, 8, b, 10, or c, 16? Pause your video here whilst you have a think.
That's right! The correct answer is c, 16.
And that's because remember this is a base-2 number system, so we multiply the place value by 2, so 8 multiplied by 2 is 16.
You're doing a fantastic job so far, so well done.
We're now moving on to our first task of today's lesson, Task A.
I'd like you to fill the table in with a list of differences between base-2 and base-10 to compare the two different number systems. Pause the video here whilst you complete the activity.
How did you get on? Did you manage to think of some differences between base-2 and base-10? Great work.
Let's have a look at some sample answers together.
So, for base-10, I've said it uses the digits 0 to 9, 10 digits in total, but for base-2, it uses the digits 0 and 1 only.
I've said that base-10 is also known as decimal and base-2 is also known as binary.
From right to left, place values in base-10 go up in multiples of 10 each time.
So, for example, 1, 10, 100, 1,000, and so on.
Whereas in base-2, the place values go up in multiples of 2 each time, so 1, 2, 4, 8, and so on.
And then lastly, I've said that base-10 is used in standard counting, whereas base-2 is used by computers.
Did you have any other differences? Remember, if you need to add any more detail to your answer or fill in any gaps, you can pause your video now.
Now, I'd like you to fill in the place values and digits in the empty tables for the following decimal and binary numbers.
So, the decimal number is 20,367 and the binary number is 10110.
Pause the video here whilst you complete the activity.
How did you get on? Let's go through the answer together.
So, for the decimal number, the place values along the top from right to left should be 1, 10, 100, 1,000, and then 10,000.
And then if we put the number in, we'd have 2, 10,000s, so 20,000, 0 in the 1,000s column, 3 in the 100s column, 6 in the 10s column, and 7 in the 1s column.
For the binary number, the place values from right to left are 1, 2, 4, 8, and 16.
And then I filled the binary number underneath, so 10110.
We're now moving on to the second part of today's lesson where we're going to convert binary numbers to decimal numbers.
To work out the value of a decimal number, you need to know the place value of each digit.
So, here, I've got the number 9019.
We multiply each digit by its place value to get that individual digits value.
For example, the first digit, 9, 9 multiplied by 1,000 means that that 9 has the value of 9,000.
We then add all of those numbers together.
So, we have the number 9019.
Alex says, "That's easy, but does that also work for binary?" To work out the value of a binary number, you need to know the place value of each digit.
So, here, I have the binary number 1001.
Again, exactly as we did with the decimal number, we multiply each digit by its place value.
So, in the first column on the left, we know that the place value is 8 and we had a 1 in that column, so 1 times 8 is 8.
We then have two 0s, so we don't have to do any multiplication there because 0 times 4 is 0, and 0 times 2 is 0.
But then in the last column, we have 1 times 1, which is equal to 1.
So, we then add all of those numbers together, so 8 plus 1 is equal to 9.
So, the binary number 1001 is equal to 9 in decimal.
Jun's got a really good tip, "For binary, an easier rule is just to add the place values of those columns that have a 1 to get your final answer." You can ignore the 0s.
Time to check your understanding.
Calculate the decimal number represented by 1100 in binary.
Is it a, 10, b, 11, c, 12, or d, 13? Pause the video here whilst you have a think.
Did you select c, 12? Well done.
Let's try another one.
Calculate the decimal number represented by 1010 in binary.
Is it a, 10, b, 11, c, 12, or d, 13? Pause the video here whilst you have a think.
Great work.
The correct answer is 10 because we're adding together 8 plus 2.
Ah, Laura's got a really good question, "How can you tell the base of a number that you're given? For example, 101 could be a base-2 or a base-10 number." That's a really good point.
Aisha says, "You can use a subscript at the end of the number to state the number base." Let's have a look what these look like.
101 with a subscript of 2 means that the number is a binary number.
101 with a subscript of 10 means that the number is a decimal number.
In order to convert from binary to decimal, you need to know the place value of each digit in the number.
When you're just starting to learn how to do this, it's a really good idea to always use the table like the one I've drawn on here.
In any exam-style question, you're unlikely to be asked to work with binary numbers greater than 8 digits, so this table should be okay for most questions.
Aisha says, "Remember that the place values increase by a multiple of each time, so don't forget to start from the right." So, 1, 2, 4, 8, 16, 32, 64, and 128.
If you have a binary number, such as 100101, place the digits in the table using the lowest place value columns first.
If you don't need to use all of the columns, you can just leave them blank.
It's a good idea to write the binary number from right to left rather than from left to right.
The next step is to add up the values of the place value columns that have a 1 in them.
So, in this example, 32, 4, and 1.
So, 32 plus 4 plus 1 is equal to 37.
Therefore, the binary number 100101 represents the decimal value 37.
Time to check your understanding, Calculate the decimal number represented by 111010 in binary.
Is it a, 48, b, 56, c, 58, or d, 64? Pause the video here whilst you do your calculation.
The correct answer is c, 58.
That's because 32 plus 16 plus 8 plus 2 is equal to 58.
Let's try another one.
Calculate the decimal number represented by 1001011 in binary.
Is it a, 55, b, 65, c, 74, or d, 75? Pause the video here whilst you have a think.
That's right! The correct answer is 75.
You're doing a fantastic job so far, so well done.
We're now going to move on to the second task of today's lesson, Task B.
Using the binary place value table, convert the following binary values into decimal.
Pause the video here whilst you complete the activity.
How did you get on? Great work.
Let's have a look at some answers together.
So, the first binary value was 1011.
The decimal value for this binary number is 11.
The next one was 11011, which, in decimal, is 27.
The third was 100100, which is 36 in decimal.
Next one was 1100110, which is the decimal 102.
And then 111011, which is decimal 123.
And then 10101010, which is 170 in decimal.
And finally, 11111110, which is decimal 254.
Remember, if you need to go back and make any corrections, you can pause your video here.
Next, I'd like you to write down the steps needed to convert a binary number to its decimal value.
Imagine that you're teaching somebody else to do this.
What steps would they need to follow? Pause the video here whilst you complete the activity.
Great work.
Let's have a look at a sample answer together.
So, the steps needed to convert a binary number to a decimal value are, start with the place value table.
Two, write the binary number in the table, starting by putting the binary numbers farthest-right digit in the farthest-right column, and then work across to the left, putting the other digits in the table.
So, moving from right to left.
Third, write down the place value for the columns that contain a 1.
And then lastly, add up these place values to get the decimal value.
We're now moving on to the final part of today's lesson, and you're doing a great job so far, so well done.
We're now going to look at converting decimal numbers to binary numbers, so the opposite way 'round of what we've done already.
When converting from decimal to binary, the process is slightly different.
This time, we work from left to right and we subtract values rather than adding them.
Let's take the example if we wanted to convert the decimal number 5 into binary.
We still have our place value table.
We start by working from left to right and we look for the first value that is less than or equal to the number 5.
So, the first value we're gonna come across is going to be 4, because 8 is not less than 5, so we can't use that value.
We place a 1 at that position.
We then subtract that place value from the original number, which was 5, so 5 minus 4 is equal to 1.
We then use the result, which in this case is 1, and continue looking left to right to find the next value that is less than or equal to this number.
So, in this case, that would be the last place value in the table, which is 1, so 1 minus 1 is 0.
We then put 0s in the columns of the place values that are larger than the remainder.
When you've reached the end of the table, the conversion is complete.
So, 1 minus 1 is 0.
And as Laura has said correctly, "5 in decimal is 101 in binary." Alex said, "It's a good idea to double check your calculation by doing a quick conversion back into decimal to make sure that it's correct." So, I've placed the 101 into the table and I can do 4 plus 1 is equal to 5.
Aisha says, "This becomes more important with higher numbers, especially if you're in an exam." Let's check your understanding.
Alex wants to convert the number 7 into binary using this table.
What should his first step be? Is it 1, working from left to right, look for the highest value that is less than or equal to the number 7? Is it b, working from right to left, look for a number that is higher than the number 7? Or c, working from left to right, look for the lowest value that is less than the number 7? Pause the video here whilst you have a think.
Did you put a? Well done, that's correct.
Remember, the first step is to work from left to right and look for the highest value that is less than or equal to the number 7.
So, in this case, it's going to be the number 4.
Let's have a look at another example.
Now, we're going to convert the decimal number 60 into binary, so a bit of a larger than we've done before.
Same process, working from left to right, look for the first value that is less than or equal to the number 60.
Can you spot what that number is? That's right, the number 32.
So, we place a 1 in that position and we subtract 32 from the original value, which was 60, which gives us 28.
We then use that result, which is 28, and continue looking left to right to find the next value that is less than or equal to this number.
So, what's the next value that is gonna be less than or equal to 28? That's right, it's 16.
So, 28 minus 16 is 12.
And we continue this process, working from left to right.
So, the next value less than or equal to 12 is 8, so we place a 1 in that column and we do 12 minus 8, which gives us 4.
We repeat the process again.
So, what is the next value in the table which is less than or equal to 4? It's 4, so we do 4, subtract 4, which gives us 0.
If the result of the subtraction is 0, then we have to fill any remaining columns to the right with 0s, and that's a really important step.
And when we've completed the end of the table, we've completed the conversion.
So, the decimal number 60 is 111100 in binary.
And Jun's reminding us, remember we can double check this by doing 32 plus 16 plus 8 plus 4 is equal to 60 so we know the conversion is correct.
We're now moving on to our final set of tasks for today's lesson, and you've done a fantastic job, so well done.
I'd like you to use the binary place value table to convert the following decimal numbers into binary.
And as a quick hint, you may find it useful to double-check your answers by converting them back again.
Pause the video here whilst you complete the activity.
How did you get on? Great work, well done.
Let's have a look at the answers together.
So, decimal value 13.
If we go across the table, we would place a 1 because 8 is less than or equal to 13.
13, subtract 8 is 5.
So, 4 is less than or equal to 5, so we'd place a 1 in that value.
5 minus 4 is 1.
Okay, so we then get to the 2.
We're gonna place a 0 in there because 2 is greater than 1.
And then we have our 1 remaining, so we put the 1 in that column.
and 1 minus 1 is 0.
So, decimal value 13 is 1101 in binary.
32 is 100000 in binary.
That's a nice easy one.
47 is 101111 in binary.
63 is 111111 in binary.
132 is 10000100 in binary.
161 is 10100001 in binary.
201 is 11001001 in binary.
And lastly, 255 is 11111111 in binary, which, incidentally, is the largest number that can be represented with an 8-bit binary value.
Next, I'd like you to write down the steps needed to convert a decimal number to its binary value.
Remember, consider teaching somebody else how to do this and think about all the steps that they would need to follow.
Pause the video here whilst you complete the activity.
How did you get on? Great work.
So, the first step is to start with our place value table.
Working from left to right, look for the first place value that is less than or equal to the decimal number.
And then we write a 1 in that column.
We then subtract the place value from the original decimal number.
If you haven't filled the farthest-right column of the table already, repeat the steps above using the result of the subtraction.
Put a 1 in the first column with a place value less than or equal to the subtraction result and a 0 in any column before this column with a place value higher than the subtraction result.
In the column where you have just put a 1, subtract the place value number from the result of your first subtraction.
You'll now have a new subtraction result.
And with this new subtraction result, repeat step 5.
When you fill in the farthest-right column of the table, you will have completed the conversion.
If you have a subtraction result that is 0 and there are still columns to the right, you need to remember to fill these with 0s.
Don't forget to double-check your result by converting the binary number back to decimal.
We've come to the end of today's lesson and you've done a fantastic job, so well done.
Let's summarize what we have learned.
Number systems use place value to represent the value of each digit in a number.
The base of a number system refers to the range of values the digit can use.
Decimal is a base-10 number system and binary is a base-2 number system.
You can convert between binary and decimal numbers as long as you know the steps that you need to follow.
I hope you join me again soon.
Bye!.