You are on page 1of 6

1

Homework 3
Communication Networks (EE 706), Spring’23

1) The following problems from Kurose and Ross, 6th edition, Chapter 5 (pp. 504-507): P8,
P9, P10, P11, P13, P17, P18, P19, P20.
2) The following problems from Kurose and Ross, 6th edition, Chapter 6 (pp. 580-582): P6,
P7, P8.
3) Consider a network of N nodes connected to each other via a shared medium of rate R bps.
Each node always has a packet to send. Time is divided into slots of duration ts each, and
the slot boundaries at all the nodes are aligned. Also, there are alternating contention and
data transmission periods. At the beginning of each contention period, node i ∈ {1, . . . , N }
selects a random backoff of Ki ∈ {0, 1, . . . , M −1} slots (independently of the other nodes)
using the following Probability Mass Function (PMF):

P (Ki = k) = pk , k ∈ {0, 1, . . . , M − 1}. (1)

Node i continuously senses the medium, and if it does not detect a transmission from another
node until the beginning of the Ki ’th slot, then it starts sending its packet at the beginning
of the Ki ’th slot. Otherwise, it defers its packet transmission. If there is a collision, then it
lasts for one slot and all N nodes select new random backoff values using the PMF in (1)
and repeat the above procedure starting from the slot following the collision. This continues
until one of the nodes successfully gains access to the medium and transmits a data packet.
Assume that each data packet takes l slots to transmit. Find the efficiency of the above
protocol.
4) Throughout this question, assume that the same attempt probability is used for the first
attempt as well as subsequent attempts if any of each packet.
(a) Consider N nodes, each of which always has a packet to send, using a protocol similar
to Slotted ALOHA, the difference being that in each slot, K of the nodes transmit with
2

probability p1 and the remaining N − K nodes transmit with probability p2 . Find the
efficiency of this protocol.
(b) Consider N nodes using Slotted ALOHA. In every slot, each of the nodes has a packet
to send with probability q and no packet to send with probability 1 − q independently
of the other slots and the other nodes. (This is a simple model for traffic with strict
delay constraints– in each slot, a traffic source at the node generates a new packet
with probability q, and it is dropped if it is not successfully transmitted in that slot.)
A node that has a packet to send transmits it with probability p in the slot. Find the
efficiency and the value of p that maximizes the efficiency for given N and q. Compare
the optimal value of p you found with that for the case where all nodes always have
packets to send and interpret the result.
(c) Consider N nodes, each of which always has a packet to send, using Slotted ALOHA.
Each node uses an attempt probability of p in each slot, where p is the value that
maximizes the efficiency for the given value of N . Let f (N ) be the efficiency achieved.
Show that f (N ) is a decreasing function of N and interpret the result.
5) A wireless network consists of N transmitters, all in the range of each other and of a
common receiver. Time is divided into slots 0, 1, 2, . . . of equal length synchronously to all
the transmitters. At the beginning of slot 0, each of the N transmitters has a packet that it
wants to send to the receiver. Consider the following two distributed schemes for selecting
a transmitter that will send its packet to the receiver:
Scheme A: At the beginning of slot 0, each transmitter independently selects an integer
uniformly at random from the set {0, 1, 2, . . . , W − 1}, where W ≥ 2 is a parameter known
to all the transmitters. Suppose transmitter i selects the integer bi . It then senses the wireless
medium for bi time slots. If it finds the wireless medium to be idle in this duration, then it
transmits its packet to the receiver at the beginning of slot bi .
Scheme B: In each slot starting from slot 0, each transmitter independently transmits with
probability p, where p ∈ (0, 1) is a parameter known to all the transmitters, and senses
the medium with probability 1 − p. This continues until one of the transmitters transmits a
packet.
For each of the above two schemes, a successful transmission occurs if exactly one trans-
3

mitter transmits. If two or more transmitters transmit, then a collision occurs.


(a) Are the two schemes A and B equivalent? Justify your answer.
(b) What is the probability of a collision for scheme A? For scheme B?
(c) Given that a successful transmission occurs under scheme A, find the expected slot
number at which it occurs. Do the same for scheme B.
(d) Now, suppose packets belong to one of two classes: a high-priority class and a low-
priority class. The packets with some of the transmitters belong to the high-priority class
and those with the rest of the transmitters belong to the low-priority class. Suggest ways
to modify scheme A for each of the following cases:
i) The priorities are required to be enforced strictly, i.e., a low-priority packet must
not be sent if one or more of the transmitters have a high-priority packet.
ii) The priorities are required to be enforced softly, i.e., a high-priority packet must be
sent with a higher probability than a low-priority packet.
(e) Do part (d) with scheme B instead of A.
6) Throughout this question, assume that the same attempt probability is used for the first
attempt as well as subsequent attempts if any of each packet.
(a) Consider a wireless network that consists of 6 nodes on a straight line as shown in
Fig. 1, with the distance between each pair of adjacent nodes being 1 unit. Suppose
the transmission range (radius) of each node is 1.5 units. For i ∈ {1, 2, 3}, node 2i − 1
always has a packet to send to node 2i. The even-numbered nodes never have any
packets to send. Suppose each odd-numbered node uses Slotted ALOHA with attempt
probability p to send its packets. Find the expected total number of packets successfully
transmitted per slot and find the value of p, which maximizes this quantity.

Fig. 1. The figure for Question 6.

(b) Generalize part (a) to the case where there are 2n nodes instead of 6 nodes, where
4

n ≥ 3 is an arbitrary integer.
(c) Consider part (a) with the change that nodes 1, 3 and 5 use attempt probabilities p1 , p3
and p5 respectively instead of p. Find the expected total number of packets successfully
transmitted per slot and find the values of p1 , p3 and p5 , which maximize this quantity.
7) Consider a wireless network that consists of N transmitters sending data to a common
receiver. All N + 1 nodes are in the range of each other. Time is divided into slots of equal
duration, and the slot boundaries at all the nodes are aligned. At the beginning of slot 0, each
of the N transmitters has a packet to send to the receiver. The N transmitters are divided
into two groups, G1 (high-priority transmitters) and G2 (low-priority transmitters), with m1
transmitters in G1 and m2 transmitters in G2, where m1 +m2 = N . The transmitters use the
following medium access protocols. Each transmitter in G1 (respectively, G2) selects an inte-
ger uniformly at random from the set {0, 1, . . . , W1 } (respectively, {W2 , W2 + 1, . . . , W3 })
independently of the other N − 1 transmitters. Here, W1 , W2 , W3 are integers satisfying
0 < W2 < W1 < W3 . Let ni be the integer selected by transmitter i. Transmitter i
continuously senses the wireless medium until the beginning of slot ni . If it does not
detect a transmission from another node in this duration, it starts sending its packet to the
receiver at the beginning of slot ni . Otherwise, it does not transmit its packet. If exactly
one node transmits, then a successful transmission occurs, else a collision occurs.
(a) Find the probability that a given (fixed) node in G1 successfully transmits a packet.
(b) Redo part (a) with G2 in place of G1.
(c) Find the probability of a collision.
8) (a) Nodes A and B are connected by a Wi-Fi link with rate R bps. An application at A
generates a burst of N data packets, each of length LD bits, for an application at B.
The transport and network layers at A and B are bypassed and these N packets are sent
from A to B using Wi-Fi’s CSMA/CA protocol. Find the expected total time required
for the N packets to be transferred.
Assume that other than the above transfer, no traffic is sent on the medium by any
node and the wireless link between A and B is free from errors and interference. The
RTS/CTS mechanism is not used. Also, the CSMA/CA parameters used are as follows:
CWmin = 16, CWmax = 1024, SIF S = s, DIF S = d, the duration of a slot is ts
5

and an ACK packet is LA bits in length. Ignore propagation delays, packet headers,
processing times at nodes and the amounts of time required to sense the channel.
(b) Do part (a) with the change that instead of a Wi-Fi link, there is an Ethernet cable of
rate R bps connecting A and B and the CSMA/CD protocol with slot duration ts is
used for the transfer.
9) Consider N nodes, each of which always has a packet to send, using a protocol similar to
Pure ALOHA, the difference being that each of nodes 1, . . . , K uses attempt probability p1
and each of nodes K + 1, . . . , N uses attempt probability p2 . Assume that each node uses
the same attempt probability for the first attempt as well as subsequent attempts, if any, of
each packet. Also, assume that 1 unit of time is required to transmit each packet.
(a) Find the efficiency of this protocol.
(b) Find the average amount of time required for successful transmission (i.e., the time from
the instant that the packet is taken up for transmission until the packet is successfully
transmitted) of a given packet of node 1, and of node K + 1.
(c) Find the values of p1 and p2 that minimize the average amount of time required for
successful transmission of a given packet of node 1. State the disadvantage, if any, of
using these values.
10) Throughout this question, assume that the same attempt probability is used for the first
attempt as well as subsequent attempts if any of each packet.
(a) Consider a wireless network that consists of 9 nodes on a uniform grid as shown in
Fig. 2, with the distance between each pair of adjacent nodes being 1 unit. Suppose the
transmission range of each node is a disc of radius 1.1 units. As shown by the arrows,
node 1 always has a packet for node 2, node 5 for node 4, node 7 for node 8 and
nodes 3 and 9 for node 6. The even-numbered nodes never have any packets to send.
Suppose each odd-numbered node uses Slotted ALOHA with attempt probability p to
send its packets. Find the expected total number of packets successfully transmitted per
slot and the value of p that maximizes this quantity.
(b) Now suppose each of the 9 nodes always has a packet for each of its neighbors. Node i
selects a receiver (fixed for all slots) and uses Slotted ALOHA with attempt probability
pi ∈ [0, 1] in each slot to transmit to the selected receiver. Find p1 , . . . , p9 and the
6

Fig. 2. The figure for Question 10.

choice of receiver for each transmitting node such that the expected total number of
successfully transmitted packets per slot is maximized. Justify your answer. (Assume
that a given node can either act as a transmitter or receiver at a time, i.e., it is able to
receive a packet in a slot only if it has not transmitted a packet in the slot.)
11) Suppose N transmitters send packets to a common receiver using Slotted ALOHA. Each
transmitter always has a packet to send. Assume that each transmitter uses the same attempt
probability, p, in the first attempt and subsequent attempts, if any, of each packet. Let K1 and
K2 be the number of slots, out of k slots, in which collisions and successful transmissions
take place respectively.
(a) Find the probability mass function (PMF) of K1 , i.e., P (K1 = i) for i ∈ {0, 1, 2, 3, . . .}.
(b) Find the joint PMF of K1 and K2 , i.e., P (K1 = i, K2 = j) for i, j ∈ {0, 1, 2, 3, . . .}.

You might also like