Computer Networks Answers for Assignment No. 1 Semester 2, 2010

Similar documents
Written examination in Computer Networks

2. What is the maximum value of each octet in an IP address? A. 128 B. 255 C. 256 D. None of the above

APPENDIX B. Routers route based on the network number. The router that delivers the data packet to the correct destination host uses the host ID.

Lecture 15. IP address space managed by Internet Assigned Numbers Authority (IANA)

Data Link Layer Overview

2. What is the maximum value of each octet in an IP address? A. 28 B. 255 C. 256 D. None of the above

Sheet 7 (Chapter 10)

BCS THE CHARTERED INSTITUTE FOR IT. BCS HIGHER EDUCATION QUALIFICATIONS BCS Level 5 Diploma in IT COMPUTER NETWORKS

Transport and Network Layer

Ethernet. Ethernet Frame Structure. Ethernet Frame Structure (more) Ethernet: uses CSMA/CD

IT 3202 Internet Working (New)

Candidates should attempt FOUR questions. All questions carry 25 marks.

Networking Test 4 Study Guide

ECE 358: Computer Networks. Homework #3. Chapter 5 and 6 Review Questions 1

Note! The problem set consists of two parts: Part I: The problem specifications pages Part II: The answer pages

Overview of Asynchronous Transfer Mode (ATM) and MPC860SAR. For More Information On This Product, Go to:

(Refer Slide Time: 02:17)

Chapter 3: Sample Questions, Problems and Solutions Bölüm 3: Örnek Sorular, Problemler ve Çözümleri

Number of bits needed to address hosts 8

2. IP Networks, IP Hosts and IP Ports

IP Subnetting. Subnetting

Useful Number Systems

Base Conversion written by Cathy Saxton

256 4 = 4,294,967,296 ten billion = 18,446,744,073,709,551,616 ten quintillion. IP Addressing. IPv4 Address Classes

Classless Subnetting Explained

Topics. Subnetting. The Basics of Subnetting Subnet Mask Computing subnets and hosts Subnet Routing Creating a Subnet Example of Subnetting 1/37

Introduction to IP v6

Lab#2: IP Addressing and Subnetting

Section 1.4 Place Value Systems of Numeration in Other Bases

CS335 Sample Questions for Exam #2

Internet Protocol Address

Data Link Layer(1) Principal service: Transferring data from the network layer of the source machine to the one of the destination machine

IT:101 Cisco Networking Academy I Subnetting

Internet Control Message Protocol (ICMP)

Internet Packets. Forwarding Datagrams

First Semester Examinations 2011/12 INTERNET PRINCIPLES

Pre-lab Preparation: 1. Read thoroughly and prepare the experiment sheet. 2. You must bring a printed copy of this experiment with you to the lab.

RARP: Reverse Address Resolution Protocol

The finite field with 2 elements The simplest finite field is

You can probably work with decimal. binary numbers needed by the. Working with binary numbers is time- consuming & error-prone.

Chapter 19 Network Layer: Logical Addressing 19.1

Module 5. Broadcast Communication Networks. Version 2 CSE IIT, Kharagpur

Variable length subnetting

Systems I: Computer Organization and Architecture

Asynchronous Transfer Mode: ATM. ATM architecture. ATM: network or link layer? ATM Adaptation Layer (AAL)

Internet Protocol version 4 Part I

Wide Area Networks. Learning Objectives. LAN and WAN. School of Business Eastern Illinois University. (Week 11, Thursday 3/22/2007)

Network Layer: Network Layer and IP Protocol

Chapter 5: Sample Questions, Problems and Solutions Bölüm 5: Örnek Sorular, Problemler ve Çözümleri Örnek Sorular (Sample Questions):

Positional Numbering System

CE363 Data Communications & Networking. Chapter 6 Network Layer: Logical Addressing

Exam 1 Review Questions

Transport Layer Protocols

CCNA Tutorial Series SUBNETTING

IP Addressing A Simplified Tutorial

Based on Computer Networking, 4 th Edition by Kurose and Ross

IP Multicasting. Applications with multiple receivers

Mobile IP Network Layer Lesson 02 TCP/IP Suite and IP Protocol

Computer Networks. Definition of LAN. Connection of Network. Key Points of LAN. Lecture 06 Connecting Networks

Multiprotocol Label Switching (MPLS)

IP Subnetting and Addressing

IP - The Internet Protocol

Network Simulation Traffic, Paths and Impairment

GATE CS Topic wise Questions Computer Network

WAN Data Link Protocols

- IPv4 Addressing and Subnetting -

Traffic Engineering Management Concepts

Technical Support Information Belkin internal use only

Chapter 3. TCP/IP Networks. 3.1 Internet Protocol version 4 (IPv4)

Note! The problem set consists of two parts: Part I: The problem specifications pages Part II: The answer pages

COMPSCI 210. Binary Fractions. Agenda & Reading

File Transfer Protocol (FTP) Throughput Testing by Rachel Weiss

Introduction to Metropolitan Area Networks and Wide Area Networks

8.2 The Internet Protocol

Communication Networks. MAP-TELE 2011/12 José Ruela

Oct: 50 8 = 6 (r = 2) 6 8 = 0 (r = 6) Writing the remainders in reverse order we get: (50) 10 = (62) 8

Decimal to Binary Conversion

Computer Networks. Main Functions

11/22/

EINDHOVEN UNIVERSITY OF TECHNOLOGY Department of Mathematics and Computer Science

Frame Relay and Frame-Based ATM: A Comparison of Technologies

Data Communication Networks and Converged Networks

RFC 2544 Testing of Ethernet Services in Telecom Networks

CYCLIC REDUNDANCY CHECKS IN USB. Introduction. Two-minute mathematical background

Computer Networks. Introduc)on to Naming, Addressing, and Rou)ng. Week 09. College of Information Science and Engineering Ritsumeikan University

TCP/IP Cheat Sheet. A Free Study Guide by Boson Software, LLC

DATA COMMUNICATION AND NETWORKS

Savera Tanwir. Internet Protocol

Asynchronous Transfer Mode

Math Workshop October 2010 Fractions and Repeating Decimals

Final for ECE374 05/06/13 Solution!!

DATA COMMUNICATIONS AND NETWORKING. Solved Examples

Route Discovery Protocols

Network Security 網 路 安 全. Lecture 1 February 20, 2012 洪 國 寶

101 Application Delivery Fundamentals

CSE 123: Computer Networks Fall Quarter, 2014 MIDTERM EXAM

ESSENTIALS. Understanding Ethernet Switches and Routers. April 2011 VOLUME 3 ISSUE 1 A TECHNICAL SUPPLEMENT TO CONTROL NETWORK

Transcription:

Computer Networks 159.334 Answers for Assignment No. 1 Semester 2, Problems Question 1 Professor Richard Harris 1.1 Suppose the length of a Base5 cable is 20 metres. If the speed of propagation in a thick coaxial cable is 0,000,000 m/s how long does it take for a bit to travel from the beginning to the end of the network? Assume that there is a s delay in the equipment. Base5 has a maximum length of 0 metres so repeaters should be inserted into the cable in order to ensure transmission is possible over the full length of the 20m cable. 4 repeaters are required as shown below: Recommended answer is 4 x s + 20/0,000,000 = 52.5s, but other answers will be accepted with suitable arguments. 1.2 The data rate of Base5 is Mbps. How long does it take to create the smallest frame? Show your calculations. The smallest frame is 64 bytes or 512 bits. With a data rate of Mbps, we have T fr = (512 bits) / ( Mbps) = 51.2 μs This means that the time required to send the smallest frame is the same at the maximum time required to detect the collision. Question 2 Asynchronous Transfer Mode Packets have an 8 bit CRC for the information contained in their headers. The header has the following 6 fields: First 4 bits: Generic Flow Control (GFC) field Next 8 bits: Virtual Path Identifier (VPI) field Next 16 bits: Virtual Circuit Identifier (VCI)field Next 3 bits: Type field Next 1 bit: CLP field Next 8 bits: CRC field Page 1 of 12

2.1 The CRC is calculated using the generator polynomial x 8 + x 2 + x + 1. Find the CRC bits if the GFC, VPI, Type and CLP fields are all zero and the VCI field is given by 00000000 00001111. Assume that the GFC bits correspond to the highest order bits in the polynomial. GFC VPI VCI TYPE CLP 000 00000000 00000000 00001111 000 0 Polynomial for this case is thus: x 7 +x 6 +x 5 +x 4 We multiply by x 8 to shift the polynomial for getting the new polynomial for division by the generator polynomial. This gives: x 15 +x 14 +x 13 +x 12 Dividing by the generator polynomial we obtain the CRC bits as: 1111 x 8 2 1 15 14 13 12 x x x 1 7 6 5 4 1 15 9 8 7 x x 14 13 12 9 8 7 14 8 7 6 13 12 9 6 13 7 6 5 12 9 7 5 12 6 5 4 9 7 6 4 9 3 2 1 x x 7 6 4 3 2 1 2.2 Read Forouzan (Fourth Edition) Chapter.4 on Cyclic codes and then explain whether the code described in question 2.1 above can detect single bit errors. Yes, the generator polynomial x 8 + x 2 + x + 1 can detect single bit errors since there is more than one term in this polynomial and the coefficient of x 0 is 1. See page 294 of the Forouzan textbook. Question 3 3.1 Given the dataword 0111 and the divisor 111 a) Show the generation of the codeword at the sender site using binary division b) Show the checking of the codeword at the receiver site assuming no error has occurred. c) What is the syndrome at the receiver end if the dataword has an error in the 5 th bit position counting from the right? Namely: dataword 0011 is received. Page 2 of 12

a) Binary division case 1 2 3 4 5 6 7 8 9 11 12 13 14 M= 1 0 1 0 0 1 1 1 1 0 G= 111 1 0 1 0 0 1 1 1 1 0 0 1 1 1 0 1 1 1 1 1 1 1 1 1 1 0 0 0 1 0 1 1 0 0 1 1 0 0 0 1 1 1 1 0 1 0 0 1 0 0 1 0 1 0 0 0 0 0 1 0 1 0 T= 1 0 1 0 0 1 1 1 1 0 1 0 1 0 Original Message CRC Checksum CRC Checksum was Codeword was 0111 b) Receiver using binary division: 1 2 3 4 5 6 7 8 9 11 12 13 14 M= 1 0 1 0 0 1 1 1 1 0 G= 111 1 0 1 0 0 1 1 1 1 0 1 0 1 0 0 0 1 1 1 0 1 1 1 1 1 1 1 1 1 1 0 0 0 1 0 1 1 0 0 1 1 0 0 1 1 1 1 0 0 0 0 0 0 0 0 0 0 Remainder was 0000 as required. c) Suppose that we received the corrupted dataword with the old CRC value as follows: 0011. We can determine the syndrome in this case as: Page 3 of 12

1 2 3 4 5 6 7 8 9 11 12 13 14 M= 1 0 1 0 0 1 1 1 1 0 G= 111 1 0 1 0 0 0 1 1 1 0 1 0 1 0 0 0 1 1 0 0 1 1 0 1 1 1 0 1 1 1 1 0 0 1 1 1 1 0 0 0 0 0 0 1 0 0 0 1 0 0 0 1 0 Non-zero CRC is obtained. CRC = 00 3.2 Repeat Question 3.1 by using polynomials instead of binary arithmetic. The polynomial for the divisor is: x 4 + x 2 + x + 1 The polynomial for the dataword is: x 9 + x 7 + x 4 + x 3 + x 2 + x 1 a) In order to perform the operations required when using the polynomial form we must first multiply the dataword by x 4 (equivalent to adding the 4 zeros in the binary division method. This yields the new polynomial as: x 13 + x 11 + x 8 + x 7 + x 6 + x 5 we now proceed to divide this by the divisor obtained above: x 4 + x 2 + x + 1 ) x 13 + x 11 + x 8 + x 7 + x 6 + x 5 Following the standard procedure, we obtain the remainder as x 3 + x 1, so that the bit pattern for this will be which agrees with our previous binary division result. Page 4 of 12

x x x x x 1 x x 9 6 5 3 2 1 4 2 1 13 11 8 7 6 5 13 11 9 x x 9 8 7 6 5 8 7 6 x x 9 5 9 7 6 5 x x 7 6 7 5 4 3 6 5 4 3 6 4 3 2 x x 5 2 5 3 2 1 x x 3 1 b) When we repeat the process for the complete message with CRC attached, the required polynomial will be x 13 + x 11 + x 8 + x 7 + x 6 + x 5 + x 3 + x 1 Thus we can then perform the required division once again and we find a zero remainder which verifies the required result. x x x x x 1 9 6 5 3 2 1 4 2 1 13 11 8 7 6 5 3 1 13 11 9 9 8 7 6 5 3 1 8 7 6 9 5 3 1 9 7 6 5 7 6 3 1 7 5 4 3 6 5 4 1 6 4 3 2 5 3 2 1 5 3 2 1 c) Taking the dataword that has an error in the appropriate 5 th position, we obtain the new polynomial to be considered as: x 13 + x 11 + x 7 + x 6 + x 5 + x 3 + x 1 0 Thus we can then perform the required division once again and we find a nonzero remainder of x 1 which verifies the required result and matches our conclusion from question 3.1 which found the bit pattern 00. Page 5 of 12

x x x x 1 x x x 9 6 5 4 3 4 2 1 13 11 7 6 5 3 1 13 11 9 x x x 9 7 6 5 3 1 8 7 6 x 9 8 5 3 1 9 7 6 5 x 8 7 6 3 1 8 6 5 4 x 7 5 4 3 1 7 5 4 3 1 0 0 x 0 Question 4 Consider the following segment of the Internet that consists of 7 nodes and 11 links and answer the questions below: 2 4 6 1 3 5 7 Figure 1: Sample Network from the Internet The figures on the links represent the delay (in milliseconds) for traffic using that link. 4.1 Determine the shortest route tree based on the home node 1, and connecting to all other nodes, using the Dijkstra algorithm. Carefully draw one copy of this network into your answer book. Show your working by placing appropriate labels on the nodes of this network. (Do not draw multiple copies of the network for your answer one will be sufficient.) A tree is required for this answer. Page 6 of 12

Node #2 Node #4 Node #6 Node #1 Node #7 Node #3 Node #5 Note that for the shortest path between nodes 1 and 7, the cost is ms. The tree shows the path as traversing the links 1 2, 2 5, 5 4, 4 6, and 6 7. 4.2 Draw another copy of the network into your answer book. How does the shortest route change between nodes 1 and 7 if the delays on links 4 6 and 6 7 are both increased from ms to ms? Two answers are possible here: 1) The path is actually still the same, it just has a higher cost: Cost = 70ms. Traffic Stream 1-7 Node #2 Node #4 Node #6 Node #1 Node #7 Node #3 Node #5 2) The path changes to using the 4 7 link instead of the 4 6 and 6 7 pair. The cost is 70ms. Page 7 of 12

Traffic Stream 1-7 Node #2 Node #4 Node #6 Node #1 Node #7 Node #3 Node #5 4.3 If all the delays into and out of node 3 are misreported as zero, what effect will this misinformation have on traffic using the network? (Do not compute the new shortest route on a new diagram only a descriptive answer is required.) Traffic Stream 1-7 Node #2 Node #4 Node #6 0 0 Node #1 0 Node #7 Node #3 Node #5 A totally new path is created if these links are misreported as having zero costs (delays). The new path would be via node #3 since it now acts as a sponge for traffic in the network. We can expect congestion to occur at this node as more traffic will divert towards it from elsewhere in the network. 4.4 Suppose that we need to determine a backup route between node 1 and node 7 in the network, and that it has been suggested that this route could be the second shortest route between these two nodes. a) Suggest a way that could be used to find this second shortest route and use your method to locate this route for the network given in Figure 1 above. b) What is the delay on this second shortest route? c) Are there any links that are common to the shortest and second shortest route from node 1 to node 7? (If so, which links?) d) How many links occur in both the shortest and second shortest routes? Page 8 of 12

Answers: a) Many different answers are possible. Two answers that are quite logical and feasible are: Remove all links from the original shortest path or set their costs to infinity. Recalculate the shortest path. This actually achieves the second shortest path that is link disjoint from the original path. Systematically remove one link at a time from the original shortest path leaving the others available. Compute the shortest path again and then restore the link and move onto the next one. After you have computed all of the shortest paths with just one link missing, compare them and take the shortest available path. This can approach the required ideal. More sophisticated approaches can be used to get the true second shortest path, eg. Chen s algorithm. b) Taking the first approach gives the link disjoint second shortest path as shown by the highlighted unbroken lines on the figure below: Traffic Stream 1-7 Node #2 Node #4 Node #6 Node #1 Node #7 Node #3 Node #5 Minimum cost of disjoint path: Node #1 to Node #7 is = 80ms. Path: Node #1 (Lk_Node #1_Node #3) Node #3 (Lk_Node #3_Node #4) Node #4 (Lk_Node #4_Node #7) Node #7 Taking the second approach produces the following set of possible paths: Link Node #1 to Node #2 absent, cost = ms Link Node #2 to Node #5 absent, cost = ms Link Node #5 to Node #4 absent, cost = ms Link Node #4 to Node #6 absent, cost = 70ms Link Node #6 to Node #7 absent, cost = 70ms Thus there are three candidate situations leading to a cost of ms that would qualify as being the second shortest path without considering disjointness. The path found for each of these three cases is: Node #1 (Lk_Node #1_Node #3) Node #3 (Lk_Node #3_Node #4) Node #4 (Lk_Node #4_Node #6) Node #6 (Lk_Node #6_Node #7) Node #7 Page 9 of 12

Thus, we would conclude that this is likely to be the second shortest path. Minimum cost of this second choice path: Node #1 to Node #7 is = ms. Traffic Stream 1-7 Node #2 Node #4 Node #6 Node #1 Node #7 Node #3 Node #5 c) Depending on the answer that you select, there are no links in common with the original shortest path if we choose the disjoint one (by definition!) If we choose the second approach, the common links are: 4 6 and 6 7. d) No links in the disjoint case and 2 links in the second case. 4.5 How does the version of the Dijkstra algorithm that you have used in part 4.1 of this question differ from the version of this algorithm used in the Internet routing protocol known as OSPF (Open Shortest Path First)? The original Dijkstra algorithm was designed and conceived as a centralised algorithm, OSPF has translated this into a distributed algorithm using the flooding algorithm. Page of 12

Question 5 5.1 (a) What is the purpose of a subnet mask? (b) Is the subnet mask 255.255.0.255 valid for a Class A address? Explain. Answers: (a) The subnet mask enables us to subdivide addresses to achieve more useful mixes of host and subnets for a given range of addresses. (b) The subnet mask given is represented in binary notation as: 11111111 11111111 00000000 11111111 A valid subnet mask must consist of contiguous 1 s and hence this proposed mask does not satisfy this requirement since the 1 s are not contiguous and contain a gap. 5.2 Consider the following internet address: 136.27.32.4 a) Convert this address into Binary format. b) Convert this address into Hex format. c) What class does this internet address represent? d) If we apply a subnet mask of FFFFFE00, obtain the relevant network, subnet and host addresses for the given internet address. Answers: a) In Binary format the address is 136.27.32.4 = 0000 000111 000000 0100 b) In Hex format the address is 136.27.32.4 = 88.1B..68 c) It is a B class address since the first two bits are d) The subnet mask is: FFFFFE00 = 11111111 11111111 111111 00000000 = /23 23 bit mask = 7 bits for subnet and 9 bits for host, so we have 128 subnets and 5 hosts per subnet. Network address only details Hex: 881b0000 Octal: 60000 Decimal: 2283470848 Binary: 0000 000111 00000000 00000000 IP Address: 136.27.0.0 Subnet address only details Hex: 00 Octal: 000 Decimal: 8192 Binary: 00000000 00000000 000000 00000000 IP Address: 0.0.32.0 Subnet #: (16) Page 11 of 12

Host address only details Hex: 68 Octal: 1 Decimal: 4 Binary: 00000000 00000000 00000000 0100 IP Address: 0.0.0.4 + + + + + + + + Page 12 of 12