Module 5: Number Systems: Introduction To Networks v7.0 (ITN)
Module 5: Number Systems: Introduction To Networks v7.0 (ITN)
Module 5: Number Systems: Introduction To Networks v7.0 (ITN)
Module Objective: Calculate numbers between decimal, binary, and hexadecimal systems.
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 2
5.1 Binary Number System
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 3
Binary Number System
Binary and IPv4 Addresses
• Binary numbering system consists of 1s and 0s, called bits
• Decimal numbering system consists of digits 0 through 9
• Hosts, servers, and network equipment using binary addressing to identify each other.
• Each address is made up of a string of 32 bits, divided into four sections called octets.
• Each octet contains 8 bits (or 1 byte) separated by a dot.
• For ease of use by people, this dotted notation is converted to dotted decimal.
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 4
Binary Number System
Binary Positional Notation
• Positional notation means that a digit represents different values depending on the
“position” the digit occupies in the sequence of numbers.
• The decimal positional notation system operates as shown in the tables below.
Result 1,234
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 5
Binary Number System
Binary Positional Notation (Cont.)
The binary positional notation system operates as shown in the tables below.
Radix 2 2 2 2 2 2 2 2
Position in Number 7 6 5 4 3 2 1 0
Result 192
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 6
Binary Number System
Convert Binary to Decimal
Convert 11000000.10101000.00001011.00001010 to decimal.
Positional Value 128 64 32 16 8 4 2 1
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 8
Binary Number System
IPv4 Addresses
• Routers and computers only understand binary, while humans work in
decimal. It is important for you to gain a thorough understanding of these
two numbering systems and how they are used in networking.
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 9
5.2 Hexadecimal Number
System
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 10
Hexadecimal Number System
Hexadecimal and IPv6 Addresses
• To understand IPv6 addresses,
you must be able to convert
hexadecimal to decimal and
vice versa.
• Hexadecimal is a base sixteen
numbering system, using the
digits 0 through 9 and letters A
to F.
• It is easier to express a value
as a single hexadecimal digit
than as four binary bit.
• Hexadecimal is used to
represent IPv6 addresses and
MAC addresses.
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 11
Hexadecimal Number System
Hexadecimal and IPv6 Addresses (Cont.)
• IPv6 addresses are 128 bits in
length. Every 4 bits is
represented by a single
hexadecimal digit. That makes
the IPv6 address a total of 32
hexadecimal values.
• The figure shows the preferred
method of writing out an IPv6
address, with each X
representing four hexadecimal
values.
• Each four hexadecimal
character group is referred to
as a hextet.
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 12
Hexadecimal Number System
Video – Converting Between Hexadecimal and Decimal
Numbering Systems
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 13
Hexadecimal Number System
Decimal to Hexadecimal Conversions
Follow the steps listed to convert decimal numbers to hexadecimal values:
• Convert the decimal number to 8-bit binary strings.
• Divide the binary strings in groups of four starting from the rightmost position.
• Convert each four binary numbers into their equivalent hexadecimal digit.
For example, 168 converted into hex using the three-step process.
• 168 in binary is 10101000.
• 10101000 in two groups of four binary digits is 1010 and 1000.
• 1010 is hex A and 1000 is hex 8, so 168 is A8 in hexadecimal.
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 14
Hexadecimal Number System
Hexadecimal to Decimal Conversions
Follow the steps listed to convert hexadecimal numbers to decimal values:
• Convert the hexadecimal number to 4-bit binary strings.
• Create 8-bit binary grouping starting from the rightmost position.
• Convert each 8-bit binary grouping into their equivalent decimal digit.
© 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 15