Download presentation
Presentation is loading. Please wait.
1
Dr J Frost (jfrost@tiffin.kingston.sch.uk)
KS3: Bases Dr J Frost Objectives: To appreciate how we can have different number systems using different ‘bases’. Count in different bases. To convert numbers from decimal to another base. To convert numbers from any base to decimal. Last modified: 22nd June 2015
2
Starter ? ? ? ? ? ? ? ? What 3 numbers comes next in each sequence?
Base 10 5 6 7 8 9 10 11 12 Base 2 1 10 11 100 Base 3 2 10 11 12 Base 5 344 400 401 402 Base 2 111 1000 1001 1010 Base 16 99 9A 9B 9C ? ? ? ? ? ? Follow up questions: What do you think it means for our ‘normal’ number system to be base 10? Each digit has 10 possible values. What is the rule for counting (if say in ‘base 6’) Once the digit goes past 5, we jump back to 0 (and the digit to the left goes up by 1) ? ?
3
! Base Values for each digit Base Name of number system 0 to 9 10
The base of a number system is the number of possible values for each digit. Values for each digit Base Name of number system 0 to 9 10 Decimal 0 to 1 2 Binary 0 to F (A=10, B=11, ... F=15) 16 Hexadecimal ? ? ? ? ? ?
4
Counting Game! Everyone stand up. Take it in turns to count in ternary (base 3), starting at 0. If you get it wrong, you sit down. 1 2 10 11 12 20 21 22 100 101 102 110 111 112 120 121 122 200 201 202 210 211 212 220 221 222 1000 1001 1002 1010 1011 1012 1020 1021 1022 1100 1101 1102 1110 1111 1112 1120 1121 1122 1200 1201 1202 1210 1211 1212 1220 1221 1222 2000 2001 2002 2010 2011 2012 2020
5
Exercise 1 1 Write out the first ten numbers in each of these bases, starting at 1. Base 2: 1, 10, 11, 100, 101, 110, 111, 1000, 1001, 1010 Base 5: 1, 2, 3, 4, 10, 11, 12, 13, 14, 20 Base 4: 1, 2, 3, 10, 11, 12, 13, 20, 21, 22 What number comes after 555 in: Base 6? 1000 Base 7? 556 How many times does the digit 0 occur if you write out the numbers 1 to in binary? (Hint: consider all two-digit numbers, then three, and so on) 2 digit numbers: 1 occurrence 3 digit numbers: 4 occurrences 4 digit numbers: 12 occurrences 5 digit numbers: 36 occurrences 6 digit number: 108 occurrences Total = 161 ? a ? b ? c 2 a ? b ? 3 ?
6
Any Base → Decimal If we were to write out the digits of the decimal number “2493”, what is the value of each digit? (Hint: Think primary school!) ? This means number is in base 10. We don’t include it if the base is obvious from the context. multiply ? = 2493 ?
7
Any Base → Decimal Now suppose we had a number in base 5 instead. How do we convert it to decimal? ? multiply ? = 576 ?
8
1 0 1 12 3 3 0 24 1 2 2 03 Test Your Understanding
Copy and complete in your book. ? ? = 11 = 242 ? ? ? = 51 ?
9
I’m a Mayan, Get Me Out Of Here!
The Maya numeral system is base 20 (“vigesimal”). Use the approach you used for converting other bases to decimal to vote for the correct number.
10
Example = 0 3 30 60 300
11
Q1 = 6 66 126 105 156
12
Q2 123 243 53 223
13
Q3 123 243 53 223
14
Q4 239 144 129 1
15
Q5 = 411 121 211 111 411
16
Q6 490 1180 1980 1380
17
Q7 = 157784 582984 396884 196884
18
Exercise 2 In computing, a byte consists of 8 bits, where each bit is a binary digit. What is the largest possible number in decimal that a byte can represent? 𝟐𝟓𝟓 In general, what is the largest number in decimal that can be represented by 𝑛 binary digits? Give your answer in terms of 𝑛. 𝟐 𝒏 −𝟏 A three-digit number is 100 in decimal. What’s the smallest the base can be? In base 4 the biggest number in decimal is 𝟒 𝟑 −𝟏=𝟔𝟑, whereas in base 5 it’s 𝟓 𝟑 −𝟏=𝟏𝟐𝟒. So 5 is the smallest base. The number with digits "𝑎1𝑏", where 𝑎 and 𝑏 are unknown digits, is 107 in decimal if the number was originally in base 5, and 205 in decimal if it was originally in base 7. Determine 𝑎 and 𝑏. 𝟐𝟓𝒂+𝟓+𝒃=𝟏𝟎𝟕 𝟒𝟗𝒂+𝟕+𝒃=𝟐𝟎𝟒 Solving, 𝒂=𝟒, 𝒃=𝟐. 432 is in an unknown base, but when converted to decimal, gives 164. Determine the base. Let the base be 𝒃. Then 𝟒 𝒃 𝟐 +𝟑𝒃+𝟐=𝟏𝟔𝟒. Solving this quadratic equation gives 𝒃=𝟔. 4 Convert the following numbers from the indicated base to decimal. 1 ? 11012 1112 10223 7348 2335 5306 13 7 51 35 476 68 198 ? ? 5 ? ? ? ? 6 ? ? ? What is the following Mayan number in decimal? 2 N ? ? 3 When the number “a036” in base 7 is converted to decimal, the value is Determine the value of the digit 𝑎. 𝟑𝟒𝟑𝒂+𝟎+𝟐𝟏+𝟔=𝟏𝟕𝟒𝟐 𝒂=𝟓 N ? ?
19
Summary So Far We have learnt that the numbers we use in everyday life are in “base 10”. But numbers can be in any ‘base’ such as base 2 (binary). The base of a number system is the number of possible values for each digit. To convert a number to decimal, we just consider the value of each digit, just like in decimal each digit represents “units”, “tens”, “hundreds” and so on. =𝟏𝟐𝟓+𝟏𝟎𝟎+𝟑=𝟐𝟐𝟖 ? ? ? ?
20
1 0 0 1 0 2 16 + 0 + 0 + 2 + 0 = 18 16 8 4 2 1 Decimal → Any Base
Do the opposite! Convert 18 from decimal to binary. ? ? ? ? ? ? = 18 Bro Tip: Start with the highest multiple possible of the highest power (in this case 16). Then see what’s left and continue to get the digits.
21
2 0 4 2 5 250+ 0 + 20+ 2= 272 Convert 272 for decimal to base 5.
Another Example Convert 272 for decimal to base 5. ? ? ? ? ? = 272
22
1 2 1 0 4 64 +32 + 4 + 0 = 100 Convert 100 from decimal to base 4.
Test Your Understanding Convert 100 from decimal to base 4. ? ? ? ? ? = 100
23
Decimal → Any Base It can help to write out multiples of your various powers. Below is base 6. Multiples of 6 Multiples of 62 Multiples of 63 c. We can only have 1 lot of 6. x 1 6 12 18 24 30 36 72 108 144 180 216 432 648 864 1080 x 2 a. We can have 3 lots of 63. x 3 b. We can have 4 lots of 62. x 4 x 5 Therefore what is 800 is base 6? 3412 ?
24
Exercise 3 Copy and complete the following table. 3 The decimal number “7a2” is in base 5. Determine the digit 𝑎. 𝒂=𝟏 1000 is a four-digit decimal number whose first digit one. In what other bases can this can be converted to such that we still have a four-digit number which starts with 1? If the base is 𝒃, 𝒃 𝟑 has to be between 500 and 1000 (if it were less, the first digit wouldn’t be 1). Only 8 and 9 satisfy this. Prove that there is no base 𝑏 such that 123 in decimal can be converted to: 45 in that base. 𝟒𝒃+𝟓=𝟏𝟐𝟑 𝒃= 𝟓𝟗 𝟐 ii in that base. 𝟒 𝒃 𝟐 +𝟓𝒃+𝟔=𝟏𝟐𝟑 Solving gives 𝒃=𝟒.𝟖𝟐, −𝟔.𝟎𝟕, neither or which are integers. 1 ? Decimal Binary (Base 2) Base 6 3 11 8 1000 12 10 1010 14 77 205 102 250 105 253 1365 10153 N ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? N 2 Convert 123 in decimal to Mayan numerals (recall that Mayan is base 20, and that a horizontal line means 5, a dot 1 and a shell 0). ? ? ?
25
Decimal → Hexadecimal The most well-known usage of hexadecimal is to represent colours. Each colour can be composed of red, green and blue light, each of intensity varying between 0 and 255. Note to teacher: For this example, ask volunteers to explain how we can convert between the two. ...which can be represented using just 6 digits in hexadecimal, 2 for each of the three colour components. A means 10, B means 11, ... F means 15
26
FF, FF, FF 00, 00, 00 00, FF, 00 FF, FF, 00 4B, AC, C6 FF, 80, 00 RED
Multiples of 16: RED GREEN BLUE HEXADECIMAL 255 255 255 FF, FF, FF 0: 0 1: 2: 3: 4: 5: 6: 7: 8: 9: A: B: C: D: E: F: ? ? ? ? 00, 00, 00 ? ? 255 ? ? 00, FF, 00 ? 255 255 ? ? FF, FF, 00 ? ? 75 ? 172 198 ? 4B, AC, C6 ? 255 ? 128 ? ? FF, 80, 00 ?
27
Adding in decimal 3+9=12 We’d use the 2 then carry the 1.
28
Adding in other bases ? ? ? ? ? 1
29
Another Example ?
30
Test Your Understanding
? ?
31
Exercise 4 Convert the following to hexadecimal.
32
QQQ Time 1a The number of possible values each digit can have. ? 4 3900 ? 5 11011 ? 1b Because each digit must be between 0 and one less than the base/the digits must be less than the base. ? 6 2400 ? 100100 7 ? 2a 2 ? 8 a = 2, b = 4 ? 2b 178 ? 3 551 ?
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.