Uploaded by caleb.debuyn

Patrick Liu SYSC 4602 Assignment 1

advertisement
Name: Patrick Liu
Student Number: 101142730
SYSC 4602 Fall 2023 Assignment 1
1.
The total distance the signal needs to travel is 40000 km * 4, this is because the client needs to
first make a request to the satellite, then the satellite will make a request to the server, the
server will then respond to the satellite, and finally the satellite responds to the client.
Speed of light = 299792.458 km/s
Response time = Distance / Speed = 160000 km / (299792.458 km/s) = 0.534 seconds
The best-case delay in receiving the response to a request sent by a client is 0.543 seconds.
2.
p = probability of a frame’s being damaged
This means that 1 - p = probability of a frame NOT being damaged
In order for the transmission to be successful, the frame must not be damaged.
Mean number of transmissions required to send a frame = 1 / probability of a frame NOT being
damaged = 1 / (1 - p)
3.
a.
- Each package takes Length(L)/Transmission Rate(R) to complete
- First packet has no delay because no packets are currently being transmitted or queued\
- Second packet has to wait for the first packet to finish transmitting which means it has a delay
of L/R
- Third packet has 2*L/R delay and so on, which means last packet has (Number of total
packet(N) - 1)*L/R
Average delay = total transmission time / total number of packet(N)
[0 + L/R + 2 * L/R + ... + (N-1) * L/R] / N
= L/R * [0 + 1 + 2 + ... + (N-1)] / N
= (L/R)/N * {[0 + (N - 1)] * N / 2}
= (L/R)/N * (N - 1) * N / 2
= L/R * (N - 1) / 2
= L/2R * (N - 1)
= (LN - L)/2R
b.
Total length of the packets = Length(L) * total number of packet(N)
Total time to transmit all packets = Total length of the packets / Transmission Rate(R) = LN/R
If N such packets arrive at the link every LN/R seconds, it means that the packet arrives at the
exact same time when all of the previous packets have just finished transmitting, thus the queue
is empty. the average delay remains exactly the same with the newly arrived packets:
(LN - L)/2R
4.
a.
Bandwidth delay product is a measurement of how many bits can fill up a network link.
Time it takes to travel between the link = Distance / propagation speed = 20000000m /
(2.5*10^8 m/s) = 0.08 seconds
bandwidth-delay product = R * Time it takes to travel between the link = 2Mbps * 0.08 = 0.16 mb
b.
800,000 bits = 0.8 mb
Since the size of the file is larger than the bandwidth-delay product, the maximum number of
bits that will be in the link at any given time is 0.16 mb
c.
Bandwidth delay product is a measurement of how many bits can fill up a network link. It gives
the maximum amount of data that can be transmitted by the sender at a given time before
waiting for acknowledgment.
d.
Width of a bit = Distance / Bandwidth delay product = 20000000m / 0.16 mb = 125 m
Football field has a length of 100 yards (91.44 m), the width of 1 bit between host A and B is
indeed longer than a football field.
e.
Width of a bit = Distance / Bandwidth delay product = m / (R*(m/s)) = s/r
5.
Number of links = 3
Number of switches = 2
File size = F bit size of each segment = S bits
Number of segments = F/S
Header size = 80 bits
Packet size(L) = 80+S bits
Transmission rate ® = R bps
Transmission delay = Tdelay = L/R = (80+S)/R seconds
Time(T) required for the first packet to be transmitted to destination:
T = Tdelay * Number of links = (80 + S)/R * 3
The total (Ttotal ) delay:
Ttotal = delay for the first packet + (number of packets x delay for one packet)
=(
80+𝑆
𝑅
) · 3 + ( 𝑆 − 1)(
=(
80+𝑆
𝑅
)(3 + ( 𝑆 − 1))
Ttotal = (
𝐹
80+𝑆
𝑅
)
𝐹
80+𝑆
𝑅
𝐹
)( 𝑆 + 2)
Minimum value of S:
𝑑(𝑢𝑣)
𝑑𝑥
𝑑𝑢
𝑑𝑥
=𝑣
𝑑𝑐
𝑑𝑥
=0
𝑑𝑥
𝑑𝑥
=1
𝑑
𝑑𝑥
(𝑥) =
1
𝑑𝑇
𝑡𝑜𝑡𝑎𝑙
𝑑𝑆
𝑑
𝑑𝑆
[(
+𝑢
−1
2
𝑥
= 0
80+𝑆
𝑅
𝐹
)( 𝑆 + 2)] = 0
𝐹
𝑑
𝑑𝑆
𝐹
𝑑
( 𝑆 + 2)
(
80+𝑆
𝑅
( 𝑆 + 2)( 𝑑𝑆 (
𝐹
𝑑𝑣
𝑑𝑥
( 𝑆 + 2)(0 +
)+(
80
𝑅
)+
𝑑
𝑑𝑆
1
𝑅
)+(
80+𝑆
𝑅
)
𝑑
𝑑𝑆
𝑆
𝐹
( 𝑆 + 2) = 0
( 𝑅 )) + (
80+𝑆
𝑅
)(
−𝐹
𝑆
2
80+𝑆
𝑅
𝑑
𝐹
)( 𝑑𝑆 ( 𝑆 ) +
+ 0) = 0
𝑑
𝑑𝑆
(2)) = 0
𝐹
1
( 𝑆 + 2)( 𝑅 ) + (
(
𝐹+2𝑆
𝑆𝑅
)−(
80+𝑆
𝑅
80+𝑆
𝑅
)(
𝐹
2
𝑆
)(
−𝐹
𝑆
2
) = 0
) = 0
2
𝑆𝐹 + 2𝑆 −80𝐹−𝑆𝐹
2
2𝑆
2
2𝑆
𝑆
2
= 0
2
𝑅𝑆
− 80𝐹 = 0
= 80𝐹
= 40𝐹
𝑆=
40𝐹
The value of S that minimizes the delay of moving the file from Host A to Host B = 40𝐹
6.
a.
Number of users = Link Bandwidth / Bandwidth required by each user = 3 mbps / 150kbps = 20
users
b.
Since each user transmits only 10 percent of the time, the probability that a given user is
transmitting is 10%
c.
𝑃(𝑛) =
𝑃(𝑛) =
𝑁
𝐶
𝑛
120
𝐶
(𝑃)
1
(
𝑛 10
𝑛
(1 − 𝑝)
)
𝑛
9
( 10 )
𝑁−𝑛
120 − 𝑛
d.
120
𝑃(21 𝑜𝑟 𝑚𝑜𝑟𝑒 𝑢𝑠𝑒𝑟𝑠) = 1 − 𝑃( ∑ 𝑋
𝑗=1
𝑗
≤ 10)
120
120
𝑃( ∑ 𝑋
𝑗=1
≤ 10) = 𝑃(
𝑗
∑ 𝑋 𝑗−4
𝑗=1
≤
120·0.1·0.9
= 𝑃(𝑍 ≤
6
10.8
6
120·0.1·0.9
)
)
= 𝑃(𝑧 ≤ 1. 83)
= 0. 999
P (21 or more users) = 1 - 0.999 = 0.001
7.
Operations at layers k-1 and k+1 are not impacted. This is because each layer implements a
contract with how it behaves, and the layer above and below it just uses that contract to do their
jobs.
Download