Documente Academic
Documente Profesional
Documente Cultură
104700978
Computer Networks
thankih@uwindsor.ca
Homework-4
1. Flow control is to monitor the proper transmission of data from sender to receiver. On the
other hand, Error Control monitors the error-free delivery of data from sender to receiver.
2. Flow control can be achieved by the Feedback-based flow control and rate-based flow control
approach whereas, to detect the error the approaches used are Parity checking, Cyclic
Redundancy Code (CRC) and checksum and to correct the error the approaches used are
Hamming code, Binary Convolution codes, Reed-Solomon code, Low-Density Parity Check
codes.
3. Flow control prevents the receivers buffer from overrunning and also prevents the loss of
data. On the other hand, Error control detects and corrects error occurred in the data.
c. Explain the reason for moving from the Stop-and-Wait ARQ protocol to the Go-
Back-N ARQ protocol.
Go back-N ARQ protocol is used to improve the efficiency of transmission of stop-and-wait ARQ
protocol by sending multi frame while waiting for acknowledgement in order to utilize the bandwidth
channel. The way Stop-and-Wait ARQ Protocol work is not fully utilize the bandwidth channel.
Piggybacking is used to improve the efficiency of bidirectional transmission. When a frame is carrying
data from A to B, it can also carry control information about frames from B; when a frame is carrying data
from B to A, it can also carry control information about frames from A.
e. Which of the protocols described in lecture notes utilize pipelining?
1 2 3 4 5 6 7 8 9 10 11 12 13 14
M= 1 0 1 0 0 1 1 1 1 0
G=
10111 1 0 1 0 0 1 1 1 1 0 0 0 0 0
1 0 1 1 1
0 0 1 1 1
0 0 0 0 0
0 1 1 1 1
0 0 0 0 0
1 1 1 1 1
1 0 1 1 1
1 0 0 0 1
1 0 1 1 1
0 1 1 0 0
0 0 0 0 0
1 1 0 0 0
1 0 1 1 1
1 1 1 1 0
1 0 1 1 1
1 0 0 1 0
1 0 1 1 1
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
1 2 3 4 5 6 7 8 9 10 11 12 13 14
M= 1 0 1 0 0 1 1 1 1 0
G=
10111 1 0 1 0 0 1 1 1 1 0 1 0 1 0
1 0 1 1 1
0 0 1 1 1
0 0 0 0 0
0 1 1 1 1
0 0 0 0 0
1 1 1 1 1
1 0 1 1 1
1 0 0 0 1
1 0 1 1 1
0 1 1 0 0
0 0 0 0 0
1 1 0 0 1
1 0 1 1 1
1 1 1 0 0
1 0 1 1 1
1 0 1 1 1
1 0 1 1 1
0 0 0 0 0
0 0 0 0
0 0 0 0
a) In order to perform the operations required when using the polynomial form we must
first multiply the dataword by x4 (equivalent to adding the 4 zeros in the binary division
method. This yields the new polynomial as: x13 + x11 + x8 + x7 + x6 + x5 we now
proceed to divide this by the divisor obtained above:
x4 + x2 + x + 1 ) x13 + x11 + x8 + x7 + x6 + x5
Following the standard procedure, we obtain the remainder as x3 + x1, so that the bit
pattern for this will be 1010 which agrees with our previous binary division result
x 10 +x 9 +x 8 +x 7+x 6+x5
x 9+x5
x 9 +x 7 +x 6 + x5
x 7 +x6
x 5+x2
x 3 +x1
b) When we repeat the process for the complete message with CRC attached, the required polynomial
will be x13 + x11 + x8 + x7 + x6 + x5 + x3 + x1
Thus we can then perform the required division once again and we find a zero remainder which
verifies the required result.
0
Q.3 A sender needs to send the four data items 0x3456, 0xABCC, Ox02BC,
and 0xEEEE. Answer the following:
1 2 2 2 Carries
3 4 5 6
A B C C
0 2 B C
E E E E
0 0 0 0 Checksum(Initial)
D 1 C C Sum(Partial)
1
D 1 C D Sum
2 E 3 2 Checksum (to send)
1 2 2 2
3 4 5 6
A B C E
0 2 B A
E E E E
2 E 3 2 Checksum(Initial)
F F F E Sum(Partial)
1
F F F F Sum
0 0 0 0 Checksum (to send)
ES ES ES FLA ES ES ES ES ES ES FLA
C C C G C C C C C C G
Q.7 Using a 5-bit sequence numbers, what is the maximum size of the send
and receive windows for each of the following protocols?
i. Stop and Wait
Send Window=1
Receive Window = 1
ii. Go-Back-N ARQ
Send Window = 25-1=31
Receive Window = 1
iii. Selective Repeat ARQ
Send Window = 25-1=16
Q.8 A system uses the Stop-and-Wait ARQ protocol. If each packet carries
1000 bits of data, how long does it take to send 1 million bits of data if
the distance between the sender and receiver is 5000 Km and the
propagation speed is 2*108 metres? Ignore transition, waiting, and
processing delays. We assume no data or control frame is lost or
damaged.
Frames = (1,000,000 bits of data) / (1,000 bits of data per frame) = 1,000 frames
Data frame trip time = (5,000 Km) / (200,000 Km/s) = 25 ms
ACK trip time = (5,000 Km) / (200,000 Km/s) = 25 ms
Delay for 1 frame = 25 ms + 25 ms = 50 ms per frame
Total delay = (1000 frames) x (50 ms per frame) = 50 s