Hw1 solution PDF

Title Hw1 solution
Author Saster He
Course Internet Svcs & Protocol
Institution University of North Carolina at Chapel Hill
Pages 7
File Size 297.5 KB
File Type PDF
Total Downloads 14
Total Views 120

Summary

solution to written hw 1...


Description

Message Switching (Store and Forward)

Packet Switching (Store and Forward)

1. a)

1. b) Datagram Network R bps R bits/sec

Time

bits

1 2 3

1 2

M

M M



“Message switching” on N links » N * 8(F+h)/R s total time to send file from A to B



N*8(P+h)/R

...

...

M Packets, P+h Bytes M

8(F+h)

1 2 3 4

...

8(F+h)/R sec

...

8(F+h)/R sec

...

F Bytes

8(F+h)/R sec

1 2 3 4

N*8(P+h)/R + (M-1)*8(P+h)/R

Packet-switching: » Total time to send file = (M+N-1)*8(P+h)/R

1

2

Packet Switching (Store and Forward)

Circuit Switching

1. c) Virtual-Circuit Network

1. d)

R bps R bits/sec

Time

1 2

...

M

TS + 8(F+h/2)/R sec 8(F+h/2) bits

M M



N*8(P+h/2)/R

...

1 2 3

...

...

M Packets, P+h/2 Bytes M

1 2 3 4

...

F Bytes

1 2 3 4

N*8(P+h/2)/R + (M-1)*8(P+h/2)/R



Total time to send file from A to B: » TS + 8(F+h/2)/R

Packet-switching: » Total time to send file = (M+N-1)*8(P+h/2)/R + TS 3

4

Packet Switching vs. Circuit Switching

Bandwidth-Delay Product

1. e)

2. a), 2. b), 2. c) R = 1.5 Mbps

R bits/sec

d = 5,000 km



Tpropagation = 5,000 km / 2.5 x 108 m/s = 0.02 s



One-way Bandwidth-delay Product = 1.5 Mbps * 0.02 s

F Bytes



Circuit Switching Time > Packet Switching Time

= 30,000 bits TS + 8(F+h/2)/R > (M+N-1)*8(P+h)/R … TS > 8/R * ((N-1)(P+h) + Mh – h/2) 5



Max # of bits on the link at any one time = 30,000



BDP represents the storage capacity of the network 6

Total Delay: Message Switching

Total Delay: One UnACKed Packet Only

2. d)

2. e) R = 1.5 Mbps

d = 5,000 km



1 2 3 4

1

50

2

R = 1.5 Mbps

d = 5,000 km

Total delay for 450,000 bits = processing + queueing + transmission + propagation delays

3

= 0 + 0 + 450,000/(1.5 Mbps) + 0.02 = 0.32 s ◆

Total delay for 50 packets, 9,000 bits each = 50*(end-to-end frame delay + end-to-end ACK delay) – (end- to-end ACK delay for 50th ACK) = 50 * ( (9,000 b)/(1.5 Mbps) + 0.02 + 0.02 ) – 0.02 = 2.28 s

7

8

Total Delay: Upto m UnACKed Packets

Total Delay: m Outstanding Packets

2. f)

2. f)

1 2 3 4

1 2 3

50

4 5 6

R = 1.5 Mbps

R = 1.5 Mbps

d = 5,000 km

d = 5,000 km



50 pkts, 9,000 bits each, m pkts pipelined Time for 1st ACK to return



To keep pipeline full: m*0.006 > 0.046



Sender is in middle of transmitting 8th packet when 1st ACK arrives



= (9,000 b)/(1.5 Mbps) + 0.02 + 0.02 = 0.006 + 0.02 + 0.02 = 0.046

7



=> m = 8 packets

Up to m packets can be sent before waiting for an ACK e.g., m = 3

»

9th packet will be transmitted, starting at 8*0.006 = 0.048 s

Frame 2m will be sent starting at: (2m-1)*0.006 = 0.09 s ◆ Total end-to-end delay = 50*0.006 + 0.02 = 0.32 s

◆ 9

10

Total Delay: m Outstanding Packets

Geostationary Satellite

3.

4. R = 600 Mbps

d = 5,000 km



d = 3.6 * 107 m



R = 10 Mbps Image size = 37*106

◆ ◆

a) 12 Mb



b) 450 Kbits d) 20.75 ms

One un-acknowledged image at a time a) Images transmitted per minute: Total time per image = transmissionDelay + 2*propagationDelay = 37 * 106/107 + 2* (3.6 * 107)/(2.4 * 108) = 4 seconds Images / minute = 60/4 = 15

e) 1.98075 s f) m = 2,668 packets



b) Desired throughput = one image / second Total time per image = X/107 + 2*propagationDelay...


Similar Free PDFs