Background: Base 10 (Decimal Number) is a number system we use everyday life. An
ID: 3901834 • Letter: B
Question
Background:
Base 10 (Decimal Number) is a number system we use everyday life. An electronic computer uses base 2 (binary number). Unlike we use ten digits to calculate with (0, 1, 2, 3, 4, 5, 6, 7, 8, 9), the computer has only two digits (0 and 1) with which it must do everything.
Objectives:
This exercise will focus on your ability to accomplish the following tasks:
Work with base 10 exponents (powers of 10) and understand how position defines value
Work with base 2 exponents (powers of 2) and understand how position defines value
Manually convert simple binary numbers and decimal numbers
Manually convert 32-bit binary IP addresses and dotted decimal IP addresses
Describe the differences between binary and decimal numbering systems
Step 1 - Decimal Numbers
Decimal Number Conversion Example
The following chart shows how the decimal number system represents the number 352,481. This will help in understanding the binary numbering system.
Exponent
106
105
104
103
102
101
100
Position
7
6
5
4
3
2
1
Value
1000000
100000
10000
1000
100
10
1
Number
0
3
5
2
4
8
1
0 x 1,000,000
3 x 100,000
5 x 10,000
2 x 1,000
4 x 100
8 x 10
1 x 1
The number 352,481 if read from right to left would be (1 x 1) + (8 x 10) + (4 x 100) + (2 x 1,000) + (5 x 10,000) + (3 x 100,000) for a total of 352,481 (a six-digit number).
Here is another way to look at it that makes it easier to add up the decimal number values:
Position of digit (from right)
Value of bit position (10^X or ten to the power of)
Number value from 0 to 9
Calculation
Decimal Value
1st Decimal Digit
10^ 0 or 1
1
1 x 1
1
2nd Decimal Digit
10^ 1 or 10
8
8 x 10
80
3rd Decimal Digit
10^ 2 or 100
4
4 x 100
400
4th Decimal Digit
10^ 3 or 1000
2
2 x 1,000
2,000
5th Decimal Digit
10^ 4 or 10000
5
5 x 10,000
52,000
6th Decimal Digit
10^ 5 or 100000
3
3 x 100,000
300,000
Decimal Value (Total of 6 digits)
352,481
Step 2 - Binary Numbers
Binary Number Conversion Example
The following table shows the detail calculations (starting from the right side) to convert the binary number 10011100 into a decimal number.
Position of digit (from right)
Value of bit position (two to the power of)
Is bit a One (on) or a Zero (Off)
Calculation
Decimal Value
1st Decimal Digit
2^ 0 or 1
0
0 x 1
0
2nd Decimal Digit
2^ 1 or 2
0
0 x 2
0
3rd Decimal Digit
2^ 2 or 4
1
1 x 4
4
4th Decimal Digit
2^ 3 or 8
1
1 x 8
8
5th Decimal Digit
2^ 4 or 16
1
1 x 16
16
6th Decimal Digit
2^ 5 or 32
0
0 x 32
0
7th Decimal Digit
2^ 6 or 64
0
0 x 64
0
8th Decimal Digit
2^ 7 or 128
1
1 x 128
128
Decimal Value (Total of 8 digits)
156
Step 3 - Binary to Decimal Practice Exercises
Task: Practice converting the 4 binary octets of an IP address to the dotted decimal equivalent.
Explanation: Look at the Binary number bit status. If there is a ONE in a position add the value shown. If there is a ZERO in a position then do not add it. Note that 8 bits cannot represent a decimal number greater than 255 (If all 8 positions are ones then 128 + 64 + 32 + 16 + 8 + 4 + 2 + 1 = 255).
10011100 . 11100011 . 01110000 . 11011010
Now, Solve for the 1st, 2nd, 3rd and 4th octet Decimal value and Enter the value in the Underlined
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
1
0
0
1
1
1
0
0
1st Octet Decimal Value:____________________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
1
1
1
0
0
0
1
1
2nd Octet Decimal Value:____________________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
0
1
1
1
0
0
0
0
3rd Octet Decimal Value:____________________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
1
1
0
1
1
0
1
0
4th Octet Decimal Value:____________________
Step 4 - Decimal to Binary Practice Exercises.
Task: Practice converting the following decimal values 90, 99, 200, 254 to the binary octet equivalent.
Explanation: Look at the Decimal value and then subtract binary values starting from 128 (the highest value binary bit). If the number is larger than 128 then put a one in the first position binary number bit status. Subtract 128 from the number and then see if there is a 64 left. If there is put a one there otherwise put a zero and see if there is a 32. Continue until all 8 bits are defined as either a zero or a one.
Now, Solve the 1st, 2nd, 3rd and 4th octet Decimal value to binary bit number and Enter the binary values in the Underlines.
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
90 -à 1st Octet Binary Value:____________________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
99-à 2nd Octet Binary Value:____________________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
200 à 3rd Octet Binary Value:____________________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
254-à 4th Octet Binary Value:____________________
Exponent
106
105
104
103
102
101
100
Position
7
6
5
4
3
2
1
Value
1000000
100000
10000
1000
100
10
1
Number
0
3
5
2
4
8
1
0 x 1,000,000
3 x 100,000
5 x 10,000
2 x 1,000
4 x 100
8 x 10
1 x 1
Explanation / Answer
PART 1
======
10011100 . 11100011 . 01110000 . 11011010
Now, Solve for the 1st, 2nd, 3rd and 4th octet Decimal value and Enter the value in the Underlined
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
1
0
0
1
1
1
0
0
1st Octet Decimal Value:_________= 128 + 16 + 8 + 4 = 156___________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
1
1
1
0
0
0
1
1
2nd Octet Decimal Value:______= 128 + 64 + 32 + 2 + 1 = 227______________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
0
1
1
1
0
0
0
0
3rd Octet Decimal Value:___= 64 + 32 + 16 = 112_________________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
1
1
0
1
1
0
1
0
4th Octet Decimal Value:_____= 128 + 64 + 16 + 8 + 2 = 218_______________
==============*************==========================
PART 2
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
90 -à 1st Octet Binary Value:_01011010___________________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
99-à 2nd Octet Binary Value:__01100011__________________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
200 à 3rd Octet Binary Value:_11001000___________________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
254-à 4th Octet Binary Value:_11111110___________________
Exponent
27
26
25
24
23
22
21
20
Bit Position
8
7
6
5
4
3
2
1
Value
128
64
32
16
8
4
2
1
Binary Number Bit Status
1
0
0
1
1
1
0
0
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.