Exercises v3

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 7

Data Communication Networks

Exercises
D.S. Kim (dskim@iupui.edu)

1. 25 meters is how many kilometers?


2. 0.90 mA is how many nA?
3. 1.15 × 10−2 second is how many microseconds?
4. An hour is how many milliseconds?
5. Usain Bolt sprinted men’s 100 meters for 9.58 sec as the world record in 2009. What is his speed in
mph?
6. The speed of the light is 300,000 km per second, and a microwave signal travels at two thirds of the
light speed. What is the speed of microwave in meter per nanosecond?
7. An Ethernet cable is 100 meter long at maximum. How long does a signal propagate the Ethernet
cable in millisecond?
8. An 100 Mbps (mega-bit-per-second) is the most popular Ethernet standard. How many bits are in
transit during 1 millisecond propagation delay?
9. A fair die is rolled and then another fair die is rolled. The number on the top face is noted.
(a) What is the probability that the sum of the two numbers showing is 5?
(b) What is the probability that the second number rolled is greater than the first number?
10. Suppose a deck of 52 cards is shuffled and the top two cards are dealt.
(a) How many ordered pairs of cards could possibly results as outcomes?
(b) Assuming each of theses pairs has the same chances, calculate the chance that the first card is an
ace.
(c) Under the same assumption, calculate the chance that the second card is an ace.
(d) Under the same assumption, calculate the chance that both cards are aces.
(e) Under the same assumption, calculate the chance of at least one ace among the two cards.
11. Use your preferred software (C/C++, Matlab, Mathematica, or gnuplot) to draw histograms of the
binomial (100, p) distribution for p = 0.1 to 0.9 by the step of 0.1.
12. Use your preferred software to draw histograms of the binomial (n, 0.5) distribution for n = 20 to 200
by the step of 20.
13. Suppose 5 dice are rolled. Assume they are fair and the rolls are independent. Calculate the probability
of the following event:
(a) Exactly two sixes
(b) At least two sixes
(c) At most two sixes
(d) Exactly three dice show 4 or greater
(e) At least 3 dice show 4 or greater
14. Suppose a fair coin is tossed n times. Find simple fomulae in terms of n and k for
(a) P (k − 1 heads | k − 1 or k heads)

1
(b) P (k heads | k − 1 or k heads)

15. A fair coin is tossed 10,000 times. Find a number m such that the chance of the number of heads being
between 5000 − m and 5000 + m is approximately 2/3.
16. Find Poisson approximation to the probabilities of the following events in 500 independent trials with
probability 0.02 of success on each trial:

(a) 1 success
(b) 2 or fewer successes
(c) more than 3 successes
17. (Urn distribution) A population of 100,000 people consists of 40% men and 60% women. A random
sample of size 100 is drawn from this population without replacement. Derive expression for the
probability that there are at least 45 men in the sample. Approximately, what is the value of the
probability?
18. A computer communication channel transmits words of n bits using an error-correcting code which is
capable of correcting errors in up to k bits. Here each bit is either a 0 or a 1. Assume each bit is
transmitted correctly with probability p and incorrectly with probability q independently of all other
bits.
(a) Find a formula for the probability that a word is correctly transmitted.
(b) Calculate the probability of correct transmission for n = 8, k = 2, and p = 0.01.
19. Each box of a particular brand of cereal contains one out of a set of n different plastic animals. Suppose
that the animal in each box is equally likely to be any on of the set of n, independently of what animals
are in other boxes. What is the expected number of cereal boxes a collector must buy in order to obtain
the complete set of animals?
20. Suppose component lifetime are exponentially distributed with mean 10 hours. Find:

(a) the probability that a component survives 20 hours


(b) the median component lifetime
(c) the SD of component lifetime
(d) the probability that the average lifetime of 100 independent component exceeds 11 hours
(e) the probability that the average lifetime of 2 independent component exceeds 2 hours

21. Suppose calls arrive at a telephone exchange at an average rate of one per second according to a Possion
arrival process. Find:
(a) the probability that the fourth call after time t = 0 arrives within 2 seconds of the third calls
(b) the probability that the fourth call arrives by time t = 5 seconds
(c) the expected time at which the fourth call arrives
22. A company X has an ambition to build a dual-line DSL router to support double Internet access
bandwidth, in which each DSL line supports 1 Mbps bandwidth. The router takes packets from its
LAN and forwards them to one of DLS lines. The mean of the flow is 1.2 Mbps and the average packet
size is 512 bytes.

(a) What is the average arrival rate λ? What is the average service rate µ? for each DLS line?
(b) The router has a single queue of size n packets for both DSL lines. Draw the Markov chain of
this dual-line system in terms of λ and µ?.
(c) Derive the probabilities pk for k = 1, · · · , j, · · · n in terms of p0 and ρ (λ/µ) from the Markov chain,
where pk is the probability of having k waiting packets including the packets on the service.

2
(d) Find an approximate probability pk for 0 ≤ k ≤ n. (Assume that the size of buffer n is fairly
large and the load ρ is less than 2.)
(e) Find the mean length of the queue E(N ) and the mean of service time E(T ).
23. An ATM/SONET OC-3 is operating at 155.52 Mbps. Note that an ATM cell contains 53 octets.
(a) At the maximum speed, what is the cell inter-arrival time and what is the cell arrival rate?
(b) A real ATM is not operating at that maximum speed. Let us assume that the ATM switch is
operating at 30% of the maximum rate and the ATM switch fabric is fast enough to block no
incoming cell. What are the effective arrival rate and the effective departure rate?
(c) The SONET layer provides 4-cell buffer plus an ATM cell processed by the ATM processor. Draw
a Markov chain for this queuing system.
(d) Derive the probabilities of each state from the above Markov chain. What is the loss probability
of the system?
24. A burst noise channel can be modeled using a Markov chain with two states, which will be called G
(for good) and B (for bad or for burst). In state G, the channel has no noise at all. In state B, each
bit a bit will be garbled with noise at the probability z. The transition probabilities are defined as
p = Pr(G → B) and q = Pr(B → G).
(a) Draw the Markov chain describing the system.
(b) Find the stationary probabilities P (G) and P (B) as functions of p and q.
(c) Find the error probability of each bit, P (E), as a function of p, q, and z.
(d) Use any programming language (Matlab, C, or even Excel) to generate a couple of sample error
vectors in this model. Using any chart program, illustrate the burstness of the error generation
depending on the independent variables p, q, and z. (Use your creativity for the illustration).
25. Use a telnet program to send a request to retrieve a web page from a news site and list all url’s (css,
image, link, etc) in the retrieved page.
Note 1: An HTTP server listens to port 80.
Note 2: Do not print the HTML text file itself.
26. Suppose the following sequence of bits arrives over a link, and draw time-signal diagrams for unipolar
NRZ, polar NRZ, bipolar, Manchester encoding, and differential Manchester encoding:

1101011111010101

27. Do web search for DSLAM equipment available from telecommunication equipment vendors (at least
five). What specification do you see in terms of the number of ports, bit rate, and additional features?
28. Investigate the Internet to answer the following questions. It will be considered as a plagiarism if
you copy the web contents to answer the questions. Instead, you must paraphrase them write after
searching and reading.
(a) What are the relations between Internet2 and Abilene Networks?
(b) What universities in the State of Indiana are participating to the Internet2 consortium?
(c) What is the Internet2 Network Connectors? List all of them along with city name.
(d) What is a Sponsored Education Group Participant?
(e) Who are the users of the Internet2? What kind of applications will need the Internet2?
(f) What is the role of NOC for the Internet2?
(g) What is the average of aggregate usage of the Internet2 for the last month? What is its maximum?
29. What are two reasons for using layered protocols?

3
30. List two ways in which the OSI reference model and the TCP/IP reference model are the same. Now
list two ways in which they differ.
31. What is the main difference between TCP and UDP?
32. A noiseless 4 kHz channel is sampled every 1 msec. What is the maximum data rate?
33. If a binary signal is sent over a 3 kHz channel whose signal-to-noise ratio of 20 dB, what is the maximum
achievable data rate?
34. If the bit string 011101111101111110 is bit stuffed, what is the output string?
35. To provide more reliability than a single parity bit can give, an error-detecting code scheme uses one
parity bit for checking all the odd numbered bits and a second parity bit for all the even numbered
bits. What is the Hamming distance of this code?
36. What is the remainder obtained by dividing x7 + x5 + 1 by the generator polynomial x3 + 1?
37. Data link protocols almost always put the CRC in a trailer, rather than in a header. Why?
38. A channel has a bit rate of 4 kbps and a propagation delay of 20 msec. For what range of frame sizes
does stop-and-wait give an efficiency of at least 50%?
39. A group of N stations share a 56 kbps pure ALOHA channel. Each station outpus a 1000 bit frame
on an average of once every 100 sec, even if the previous one has not yet been sent (e.g., the station
are buffered). What is the maximum value of N ?
40. Ten thousand airline reservation stations are competing for the use of a single slotted ALOHA channel.
The average station makes 18 request/hour. A slot is 125 µsec. What is the approximate total channel
load?
41. Under what conditions would the wireless LAN be possible to use CSMA/CD?
42. A CDMA receiver gets the chips as (-1 +1 -3 +1 -1 -3 +1 +1). Assuming the chip sequence defines as
follows:
A: (-1 -1 -1 +1 +1 -1 +1 +1),
B: (-1 -1 +1 -1 +1 +1 +1 -1),
C: (-1 +1 -1 +1 +1 +1 -1 -1),
D: (-1 +1 -1 -1 -1 -1 +1 -1).
which station transmitted, and which bits did each one send?

43. Two CSMA/CD stations are each trying to transmit long (multiframe) files. After each frame is sent,
they contend for the channel using the binary exponential backoff algorithm. What is the probability
that the contention ends on round k, and what is the mean number of round per contention period?
44. Consider an ARQ protocol that uses only negative acknowledgements (NAKs), but no positive acknowl-
edgements (ACKs). Describe what timeouts would need to be scheduled. Explain why an ACK-based
protocol is usually preferred to a NAK-based protocol.
45. What kind of problem can arise when two hosts on the same Ethernet share the same hardware address?
Describe what happens and why that behavior is a problem.
46. Suppose that N Ethernet stations, all trying to send at the same time, require N/2 slot times to
sort out who transmits next. Assuming the average packet size is 5 slot times, express the available
bandwidth as a function of N .

4
47. Prove that any two rows in Walsh-Hadamard matrix are orthogonal.

48. Show that two-dimensional parity checks can correct and detect a single bit error. Show a double-bit
error can be detected but not corrected.
49. Suppose four nodess A, B, C, and D, are all connected to a hub via 10 Mbps Ethernet cables. The
distance between the hub and these four nodes are 300m, 400m, 500m, and 700m, respectively. Recall
that the CSMA/CD protocol is used for this Ethernet. Assume that the signal propagation speed is
2 × 108 m/sec.
(a) What is the minimum required frame length? What is the maximum required frame length?
(b) If all frames are 1500 bits long, find the efficiency of this Ethernet.
50. Suppose that the ALOHA protocol is used to share a 56 kbps satellite channel. Suppose that frames
are 1000 bits long. Find the maximum throughput of the System in frames/second.
51. M terminals are attached by a dedicated pair of lines to a hub in a star topology. The distance from
each terminal to the hub is d meters, the speed of the transmission lines is R bits/second, all frames are
of length 12,500 bytes, and the signal propagates on the line at a speed of 2.5 × 108 meters/second. For
the four combinations of the following parameters (d = 25 meters or d = 2500 meters; R = 10 Mbps or
R = 10 Gbps), compare the maximum network throughput achievable when the hub is implementing
slotted ALOHA and CSMA-CD.
52. A wireless LAN uses polling to provide communications between M workstations and a central base
station. The system uses a channel operating at 25 Mb-p s. Assume that all stations are 100 meters
from the base station and that polling messages are 64 bytes long. Assume that frames are of constant
length of 1250 bytes. Assume that stations indicate that they have no frames to transmit with a
64-byte message.
(a) What is the maximum possible arrival rate that can be supported if stations are allowed to
transmit an unlimited number of frames/poll?
(b) What is the maximum possible arrival rate that can be supported if stations are allowed to
transmit N frarnes/poll?
(c) Repeat parts (a) and (b) if the transmission speed is 2.5 Gbps.
53. A token-ring LAN interconnects M stations using a star topology in the following way. All the input
and output lines of the token-ring station interfaces are connected to a cabinet where the actual ring
is placed. Suppose that the distance from each station to the cabinet is 100 meters and that the ring
latency per station is eight bits. Assume that frames are 1250 bytes and that the ring speed is 25
Mbps.
(a) What is the maximum possible arrival rate that can be supported if stations are allowed to
transmit an unlimited number of frames/token?
(b) What is the maximum possible arrival rate that can be supported if stations are allowed to
transmit 1 frame/token using single-frame operation? using multitoken operation?
(c) Repeat parts (a) and (b) if the transmission speed is 2.5 Gbps.
54. Suppose that a group of 10 stations is serviced by an Ethernet LAN. How much bandwidth is available
to each station if (a) the 10 stations are connected to a 10 Mbps Ethernet hub; (b) the 10 stations
are connected to a 100 Mbps Ethernet hub; (c) the 10 stations are connected to a 10 Mbps Ethernet
switch.
55. Calculate the parameter a and the maximum throughput for a Gigabit Ethernet switch with stations
at a 100-meter distance and average frame size of 512 bytes; 1500 bytes; and 64,000 bytes.
56. Use IEEE 802.3 and IEEE 802.11 to discuss three differences between wired and wireless LANs.

5
57. Consider the distributed coordination function in IEEE 802.11. Suppose that all frame transmissions
are preceded by an RTS-CTS handshake. Find the capacity of this protocol following the analysis used
for CSMA-CD.
58. Why is error control (ARQ and retransmission) included in the MAC layer in IEEE 802.11 and not in
IEEE 802.3?
59. Consider the exchange of CSMA-CA frames. Assume the IEEE 802.11 LAN operates at 2 Mbps using
a frequency-hopping physical layer. Sketch a time diagram showing the frames transmitted including
the final ACK frame. Show the appropriate interframe spacings and NAV values. Use the textbook to
obtain the appropriate time parameters. Assume that the data frame is 2000 bytes long.
60. A 64-kilobyte message is to be transmitted over two hops in a network. The network limits packets to
a maximum size of 2 kilobytes, and each packet has a 32-byte header. The transmission lines in the
network are error free and have a speed of 50 Mbps. Each hop is 1000 km long. How long does it take
to get the message from the source to the destination?
61. Suppose that a site has two communication lines connecting it to a central site. One line has speed
of 64 kbps, and the other line has a speed of 384 kbps. Suppose each line is modeled an M/M/1
queueing system with average packet delay given by E[D] = E[X]/(1 − ρ) where E[X] is the average
time required to transmit a packet, λ is the arrival rate in packets/second, and ρ = λE[X] is the load.
Assume packets have an average length of 8000 bits. Suppose that a fraction a of the packets are
routed to the first line and the remaining 1 − α are routed to the second line.
62. Suppose that a datagram packet-switching network has a routing algorithm that generates routing
tables so that there are two disjoint paths between every source and destination that is attached to the
network. Identify the benefits of this arrangement. What problems are introduced with this approach?
63. Suppose that a block of user information that is L bytes long is segmented into multiple cells. Assume
that each data unit can hold up to P bytes of user information, that each cell has a header that is H
bytes long, and that the cells are fixed in length and padded if necessary. Define the efficiency as the
ratio of the L user bytes to the total number of bytes produced by the segmentation process.

(a) Find an expression for the efficiency as a function of L, H, and P . Use the ceiling function c(x),
which is defined as the smallest integer larger or equal to x.
(b) Plot the efficiency for the following ATM parameters: H = 5, P = 48, and L = 24k for k =
0, 1, 2, 3, 4, 5, and 6.

64. Assuming that the earth is a perfect sphere with radius 6400 km, how many bits of addressing are
required to have a distinct address for every 1 cm × 1 cm square on the surface of the earth?
65. Suppose that 64 kbps PCM coded speech is packetized into a constant bit rate ATM cell stream.
Assume that each cell holds 48 bytes of speech and has a 5 byte header.
(a) What is the interval between production of full cells?
(b) How long does it take to transmit the cell at 155 Mbps?
(c) How many cells could be transmitted in this system between consecutive voice cells?
66. An IP packet consists of 20 bytes of header and 1500 bytes of payload. Now suppose that the packet
is mapped into ATM cells that have 5 bytes of header and 48 bytes of payload. How much of the
resulting cell stream is header overhead?

67. Consider a packet-by-packet fair-queueing system with three logical buffers and with a service rate of
one unit/second. Show the sequence of transmissions for this system for the following packet arrival
pattern. Buffer 1: arrival at time t = 0, length 2; arrival at t = 4, length 1. Buffer 2: arrival at time
t = 1, length 3; arrival at t = 2, length 1. Buffer 3: arrival at time t = 3, length 5.

6
68. Queue management with random early detection (RED):
(a) Explain why RED helps prevent TCP senders from detecting congestion and slowing down their
transmission rates at the same time.
(b) Discuss the effect of RED on network throughput.
(c) Discuss the implementation complexity of the RED algorithm.
(d) Discuss what would happen if instantaneous queue length were used instead of average queue
length.
(e) Explore ways to find reasonable values for the RED parameters (i.e., minth , maxth , and the
packet drop probability when the average queue length reaches maxth ).
69. Modify the leaky bucket algorithm in the textbook if packet length is variable.
70. Explain the difference between the leaky bucket traffic shaper and the token bucket traffic shaper.
71. For the following VC switches, find all virtual paths in the form of data-transit-identifier, which is a
list of alternating node and VCI. For example, NA → 1 → N1 → 2 → N3 → 7 → N6 → 8 → NB .

72. For the VC switches above, show the change of those switch configurations for adding a new bidirec-
tional DTI as NB ↔ 13 ↔ N6 ↔ 14 ↔ N5 ↔ 15 ↔ N4 ↔ 16 ↔ N2 ↔ 17 ↔ NC .
73. Consider the above virtual-circuit packet network. Suppose that link between node 3 and 4 in the
network fails. Reroute the affected calls and show the new set of routing table.
74. Consider the above virtual-circuit packet network. Suppose that node 3 in the network fails. Reroute
the affected calls and show the new set of routing table.
75. Use a system command traceroute to find the average number of intermediate routers for 30 random
Internet sites.
76. Design a method to measure an effective network bandwidth and an end-to-end delay between your
computer and a remote site.
77. The behavior of data communication network renders different characteristics on time. Most of persons
check their emails and retrieve recent hot news for certain period of time, which produces rush hours
in the communication network. You are asked to draw a trace of network delay to a specific host (a
remote well-known site) for 48 hours. When is the busiest time of the day?

You might also like