Вы находитесь на странице: 1из 3

# ECE/CS 372Introduction to Computer Networks SolutionAssignment # 1

## Bechir Hamdaoui, School of EECS, Oregon State University

P6, Page 72 (or P5, Page 73 version 5) a) dprop = m/s seconds b) dtrans = L/R seconds c) dend to end = (m/s + L/R) seconds d) The bit is just leaving Host A e) The rst bit is in the link and has not reached Host B f) The rst bit has reached Host B L 8 s = 56120 g) Want m = R 103 (2.5 10 ) 536 km. P7, Page 72 (or P6, Page 74 version 5) Consider the rst bit in a packet. Before this bit can be transmitted, all of the bits in the packet must be generated. This requires 56 8/(64 103 ) seconds = 7 milliseconds. The time required to transmit the packet is 56 8/(2 106 ) seconds = 224 microseconds. Propagation delay = 10 milliseconds. The delay until decoding is 7 milliseconds + 224 microseconds + 10 milliseconds = 17.224 milliseconds P8, Page 72 (or P7, Page 74 version 5) a) 3 1000kbps/150kbps = 20 users can be supported because each user requires one tenth of the bandwidth b) p = 0.1 n 120n c) (120 n )p (1 p) 20 120 n d) 1 n=0 (n )p (1 p)120n 0.003. P10, Page 73 (or P9, Page 74 version 5) The rst end system requires L/R1 to transmit the packet onto the rst link; the packet propagates over the rst link in d1/s1; the rst packet switch adds a processing delay of dproc ; after receiving the entire packet, the rst packet switch requires L/R2 to transmit the packet onto the second link; the packet propagates over the second link in d2/s2; the second packet switch adds a processing delay of dproc ; after receiving the entire packet, the second packet switch requires L/R3 to transmit the packet onto the third link; the packet propagates over the third link in d3/s3. Adding all these delays gives dendend = L/R1 + L/R2 + L/R3 + d1/s1 + d2/s2 + d3/s3 + 2 dproc To answer the second question, we simply plug the values into the equation to get 6 + 6 + 6 + 20 + 16 + 4 + 3 + 3 = 64 msec

P11, Page 73 (or P10, Page 75 version 5) Because bits are immediately transmitted, the packet switch does not introduce any delay; in particular, it does not introduce a transmission delay. Thus, dendend = L/R + d1/s1 + d2/s2 + d3/s3 For the values in the previous problem (P10), we get 6 + 20 + 16 + 4 = 46 msec. P12, Page 73 (or P11, Page 75 version 5) Given that one packet is already been transmitted, and n packets are in the queue waiting their turns, the queuing delay of the (n+1)th packet is [nL + (L x)]/R

P13, Page 73 (or P12 and P13, Page 75 version 5) a) (or P12 version 5) The queuing delay is 0 for the rst transmitted packet, L/R for the second transmitted packet, and generally, (N-1)L/R for the Nth transmitted packet. Thus, the average delay for the N packets is (L/R + 2L/R + ....... + (N 1)L/R)/N which is equal to L/(RN ) (1 + 2 + ..... + (N 1)) = L/(RN ) N (N 1)/2 = LN (N 1)/(2RN ) = (N 1)L/(2R) Note that here we used the well-known fact that 1 + 2 + ....... + N = N (N + 1)/2 b) (or P13 version 5) It takes LN/R seconds to transmit the N packets. Thus, the buffer is empty when a batch of N packets arrive. The rst of the N packets has no queuing delay. The 2nd packet has a queuing delay of L/R seconds. The N th packet has a delay of (N 1)L/R seconds. Note that the N th packet has already been transmitted when the second batch of N packets arrives. Hence, the next N packets arrive at an empty queue; that is, the (N + 1)th packet has no queueing delay; the (N + 2)th packet has a queueing delay of L/R, etc. Therefore, it sufces to average over a batch of N packets to determine the average over all packets. The average queueing delay is then 1 N
N

n=1

(n 1)L/R =

L 1 RN

N 1

n=
n=0

L 1 (N 1)N L (N 1) = RN 2 R 2

P14, Page 74 (or P14, Page 75 version 5) a) The transmission delay is L/R. Hence, the total (queueing + transmission) delay is IL L/R + L/R = R(1 I ) 1I b) Let x = L/R. Thus, the total delay is
x 1ax .

a = 10

0.092

0.098

0.1

Fig. 1.

## Total delay as a function of L/R for a=10

P15, Page 74 (or P15, Page 75 version 5) First, note that = R/L packets per second. From previous problem (P14), we derived the total (queueing + transmission) delay as L/R 1I

Replacing I by aL/R and R/L by implies that the total delay is L/R 1/ 1 = = 1 aL/R 1 a/ a