# Deadline Aware Retransmission Threshold Setting Protocol in Cyber-Physical Systems

Authors: Ran Bi; Jianzhong Li; Hong Gao; Quan Chen
Journal: International Journal of Distributed Sensor Networks
 (2015)

---

## Abstract

Many time-sensitive applications impose high requirement on real-time response. There exist many algorithms and routing protocols for efficient data packet delivery. However, previous works set the same retransmission threshold for all the relay nodes along a delivery path. The method decreases the probability of a packet being transmitted through the delivery path within given deadline. In this paper, we focus on finding the optimal retransmission thresholds for the relay nodes, such that the summation of the probability of a packet being transmitted to the next relay node or destination node within the specified deadline is maximized. A distributed greedy algorithm that can be run on sensor node is proposed, which enables the sensor node to adaptively set the optimal retransmission threshold. To avoid dropping the packet forwarded to the destination within given deadline with high probability, we develop a packet dropped protocol based on probabilistic delay bound. Experimental results show that the proposed protocols have better performance.


---

## Body

## 1. Introduction

Cyber-physical systems (CPS) integrate the computation and physical processes to monitor and control the continuous dynamics of physical world and engineered systems, which revolutionize the approaches for observing the physical world and the process of information access. As extremely critical component in CPS, wireless sensor networks (WSNs) have been envisioned to observe and cognize the complicated physical world at low cost [1, 2]. Deployments of large-scale WSNs have potential to shed light on a variety of monitoring purposes, such as environment monitoring, pollution levels monitoring, and progress of climate change. The discovery of useful knowledge from the massive sensed data is helpful for deeper scientific understanding of human-physical world interaction, which motivates researchers to explore complex and evolving relationships among the data. Plentiful research works have begun focusing on extracting useful knowledge from the Big Data perspective by using the large-scale sensed data.Large-scale WSNs have been considered as one of the promising, high-value applications for CPS, whose enormous societal impact and economic benefit will be created by the discovery of useful knowledge from the sensed data. Many time-sensitive applications, such as intruder tracking, environment control, and structural health diagnosis impose high requirement on real-time response for decision making and future actions [3–6]. In these applications, deadline misses in data communication may bring about irreparable financial and environmental impacts. Therefore, achieving fast data delivery and response for the massive data generated in WSNs poses new research challenges.Data delivery delay has been extensively studied in forwarding quality measurement [7–9], sensor network routing, and scheduling [10–13]. Most of the works focus on investigating the metrics to characterize the forwarding quality or minimizing average path delay. Moreover, existing works set the same retransmission threshold for all the sensor nodes along a delivery path. The method is short of taking the link quality and delay requirement into account, which decreases the probability of a packet being successfully transmitted through its delivery path within given deadline. In many cases, the retransmission threshold imposes a significant effect on the probability. To understand the impact of retransmission threshold on the probability of packet delivery before its deadline, we give an example, which is illustrated in Figure 1.Figure 1
The impact of retransmission threshold on success probability of packet delivery.The number at each link is the probability of a packet being successfully delivered to the next node through the link, denoted byp
s
u
c, which means that on average it takes 1
/
p
s
u
c transmission trials to successfully deliver a packet. We assume that one transmission takes 1 second and the deadline of delivering a packet from node S to node D is 9 s. To deliver the packet to node D before the deadline, the summation of transmission trials along the path must be no more than 9, which is the result of dividing deadline 9 s by one transmission time 1 s. If the retransmission threshold for each link is 2, then it is easily known that the probability of a packet passing the first link is 1 − 0.9 × 0.9 × 0.9 = 0.271. Therefore, the probability of a packet being successfully received by destination node D within its deadline is 0.271 × 1 × 1 = 0.271. However, if the retransmission thresholds for the first link is 6 and the others are 0, then the probability is (1 − 0.97) × 1 × 1 ≈ 0.522, which is almost twice as that of the method of setting the same retransmission threshold in advance. The approach of setting the same retransmission threshold did not take the link quality and deadline into account, which decreases the probability of a packet being successfully transmitted through its delivery path within given deadline.To improve the reliability of packets delivery, the method of packets being transmitted along multiple paths is widely applied. Therefore, in this paper we focus on computing the optimal retransmission thresholds for the relay nodes along a delivery path, such that the summation of the probability of a packet being successfully delivered to the next relay node or destination node within the specified deadline is maximized. To find the optimal retransmission threshold, a distributed greedy algorithm that can be run on sensor node is proposed, which enables the sensor node to adaptively set the optimal retransmission threshold based on the link quality and the remaining time to deadline. Stringent retransmission threshold may make the packet forwarded to the destination within deadline with high probability be dropped. To overcome the shortcoming, we develop an(
α
,
β
)-probabilistic delay bound based packet dropped protocol. The main contributions of the paper are as follows.(i)
The problem of finding optimal retransmission thresholds for the relay nodes along a delivery path is proposed. A formal description of the problem is given, and it can be formalized as an integer optimization problem.
(ii)
A distributed greedy algorithm for computing optimal retransmission threshold is proposed and the correctness of this algorithm is proved. The time complexity of the algorithm isO
(
Δ
n
), and the memory complexity is O
(
n
), where Δ is the given upper bound of the delivery delay and n is the length of the delivery path.
(iii)
To avoid dropping the packet forwarded to the destination within the given deadline with high probability, an(
α
,
β
)-probabilistic delay bound based packet dropped protocol is developed.
(iv)
Simulation experiments are conducted to evaluate the proposed algorithm and protocol. Experimental results show that our algorithms have better performance in terms of deadline success ratio and real-time ratio.The rest of this paper is organized as follows. The related works on real-time data delivery are surveyed in Section2. In Section 3, the optimization problem is described first, and a greedy algorithm for computing optimal retransmission threshold is provided. Based on Chebyshev inequality, an (
α
,
β
)-probabilistic delay bound based packet dropped protocol is proposed in Section 4. Experimental results are illustrated in Section 5, and Section 6 concludes this paper.


## 2. Related Works

Data delivery delay is extensively considered in routing metric. The metric of expected transmission count (ETX) was proposed in [14]. ETX measures the expected number of transmissions for successfully delivering a packet over the link, which works well in a homogeneous sigle-radio environment. Effective number of transmissions (ENT) [15] was proposed to enhance ETX by taking the variable link reliability into account. Expected transmission time (ETT) [16] and the path metric of weighted cumulative ETT were proposed for multichannel mesh networks. ETT can be considered as enhanced ETX by counting the hererogeneous channel rate and intraflow interference.Data delivery delay has also attracted much attention in designing efficient routing protocol. There are three categories of routing protocols that favor the end-to-end delay performance guarantee in WSNs [17]: (I) tree-based routing; (II) optimal routing based on the knowledge of network topology; (III) geographic routing by the information of node position. To shorten the worst-case delay, [18] proposed tree-based routing protocol, which looks up the neighbor table for routing decisions. Tree-based protocol may lead to high energy consumption of the nodes near root of the tree. Generally, geographic routing protocols are not optimal, because they are merely based on one-hop decision [17]. SPEED protocol was proposed in [12], which estimates the forwarding delay. In SPEED protocol, the node of higher relay velocity is selected with higher probability. However, for high efficient energy utilization it is significant to integrate the information effectively.Motivated by the tradeoff between the energy consumption and real-time routing performance, [19–21] investigated the optimal construction of virtual backbone and node placement. Aiming at enabling routing with probabilistic delay bounds in wireless sensing and control networks, multitimescale adaptation routing protocol was proposed in [22], which addresses the challenges of dynamic, uncertain link/path delays in real-time routing. To minimize the cost of packet delivery, [23, 24] developed approximation algorithms for the capacitated multicast routing problem.There are plentiful research works that focus on the analysis of the end-to-end delay in wireless networks. In literature [25], the open queueing network theory was applied to model the WSNs and the analysis for the paths delay based on the model was provided. By mapping the scheduling of real-time periodic data flows in a wirelessHART network to real-time multiprocessor scheduling, the analysis of end-to-end delay was given in [26].However, all the previous works set the same retransmission threshold for the sensor nodes in advance. The method of setting the same retransmission threshold for the sensor nodes along a delivery path is short of taking the link quality and delay requirement into account, which decreases the probability of a packet being successfully transmitted through its delivery path within given deadline. To the best of our knowledge, this paper first investigates the problem of finding optimal retransmission thresholds.


## 3. Greedy Algorithm for Computing Optimal Retransmission Threshold

The method of setting the same retransmission threshold for all sensor nodes has poor performance in real-time data delivery. In this section, we develop a greedy algorithm for computing the optimal retransmission thresholds for the relay nodes along a delivery path, such that the summation of the probability of a packet being successfully transmitted to the next relay node or destination node within the specified deadline is maximized.


### 3.1. Problem Description

Suppose that the end-to-end path isP
=
j
1
,
j
2
,
…
,
j
n
+
1, where j
1 and j
n
+
1 are source and destination nodes. Let p
i denote the probability of a transmission failure over the link from j
i to j
i
+
1. Then p
i is the probability that a MAC-layer transmission fails due to either collisions or bad channel quality when node j
i forwards a data packet to node j
i
+
1. If K
i is the retransmission threshold of node j
i, then 1
-
p
i
K
i
+
1 is the probability of a packet being successfully transmitted to node j
i
+
1 by node j
i. To improve the reliability of packet delivery, packets are transmitted along multiple paths. Therefore, we focus on maximizing the summation of the probability of a packet being successfully transmitted to the next relay node or destination node along the delivery path within the given deadline. Let Δ denote the end-to-end delay requirement. L
i and U
i are used to denote the given lower and upper bounds of retransmission threshold of node i. The problem of finding optimal retransmission thresholds for relay nodes can be formulated as the following integer optimization problem:(1)
m
a
x
∑
i
=
1
n
‍
1
-
p
i
K
i
+
1
s
.
t
.
∑
i
=
1
n
‍
K
i
+
1
≤
Δ
L
i
≤
K
i
≤
U
i
,
K
i
∈
Z
,
i
∈
1,2
,
…
,
n
,
p
i
∈
0,1
,
L
i
,
U
i
∈
0
,
+
∞
,
i
∈
1,2
,
…
,
n
.Obviously, the value of objective function∑
i
=
1
n
‍
(
1
-
p
i
K
i
+
1
) is maximized if and only if the value of ∑
i
=
1
n
‍
p
i
K
i
+
1 achieves the minimum. For any i
∈
{
1,2
,
…
,
n
}, let k
i
=
K
i
+
1
,
l
i
=
L
i
+
1 and u
i
=
U
i
+
1. Then the aforementioned optimization problem is equivalent to the following integer optimization problem:(2)
m
i
n
∑
i
=
1
n
‍
p
i
k
i
s
.
t
.
∑
i
=
1
n
‍
k
i
≤
Δ
l
i
≤
k
i
≤
u
i
,
k
i
∈
Z
,
i
∈
1,2
,
…
,
n
,
p
i
∈
0,1
,
l
i
,
u
i
∈
0
,
+
∞
,
i
∈
1,2
,
…
,
n
.Then the problem of finding the optimal retransmission thresholds for each relay node along a delivery path can be defined as follows.Input. (
1
) The set of the transmission failure probabilities of the nodes along a delivery path, {
p
1
,
…
,
p
n
}.  (
2
) The end-to-end delivery delay requirement Δ.Output. Optimal retransmission thresholds k
1
′
,
k
2
′
,
…
,
k
n
′, which are optimal solutions for integer optimization problem (2).Based on the above analysis, the key point is to design an efficient algorithm for finding the optimal solutions to integer optimization problem (2). In the following section, we prove that the optimization problem can be solved by a greedy algorithm. And the correctness of the algorithm is proved.


### 3.2.  Correctness of Greedy Algorithm

Lemma 1.
For anyi
∈
{
1,2
,
…
,
n
}, the following inequalities hold; if 0
<
p
i
<
1 and l
i
<
u
i,(3)
p
i
l
i
+
j
-
p
i
l
i
+
j
-
1
<
p
i
l
i
+
j
+
1
-
p
i
l
i
+
j
<
0
,where j
∈
{
1,2
,
…
,
u
i
-
l
i
}.Proof.
Letf
i
(
x
)
=
p
i
x; it is easily known that f
i
′
′
(
x
)
>
0.
Thusf
i
′
(
x
) is an increasing function with respect to x. According to the differential mean value theorem, the following equalities can be derived:(4)
f
i
(
l
i
+
j
+
1
)
-
f
i
(
l
i
+
j
)
=
f
i
′
(
ξ
)
·
1
f
i
(
l
i
+
j
)
-
f
i
(
l
i
+
j
-
1
)
=
f
i
′
(
η
)
·
1
,where ξ
∈
l
i
+
j
,
l
i
+
j
+
1 and η
∈
l
i
+
j
-
1
,
l
i
+
j. Since f
i
′
(
x
) is an increasing function, then f
i
′
(
η
)
<
f
i
′
(
ξ
). Then we can derive that p
i
l
i
+
j
-
p
i
l
i
+
j
-
1
<
p
i
l
i
+
j
+
1
-
p
i
l
i
+
j. Due to the decreasing of f
i
(
x
), we have p
i
l
i
+
j
+
1
-
p
i
l
i
+
j
<
0. In conclusion, we know that p
i
l
i
+
j
-
p
i
l
i
+
j
-
1
<
p
i
l
i
+
j
+
1
-
p
i
l
i
+
j
<
0.For anyi
∈
{
1,2
,
…
,
n
}
,
j
∈
Z
+, λ
i
(
j
) is defined as follows:(5)
λ
i
j
=
p
i
j
-
p
i
j
-
1
j
≤
u
i
∞
j
>
u
i
,where l
i
<
u
i.According to Lemma1, for any j
∈
[
l
i
,
u
i
-
1
], we have λ
i
(
j
+
1
)
>
λ
i
(
j
). And it can be known that p
i
l
i
+
j
=
p
i
l
i
+
∑
k
=
l
i
+
1
l
i
+
j
‍
λ
i
(
k
). For ∀
i
∈
{
1,2
,
…
,
n
}, we introduce the following sign function:(6)
χ
i
x
=
1
x
=
i
0
x
≠
i
.Lemma 2.
Leth
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}; then l
1
+
χ
1
(
h
)
,
l
2
+
χ
2
(
h
)
,
…
,
l
n
+
χ
n
(
h
) are the optimal solution to the following integer optimization problem:(7)
m
i
n
∑
i
=
1
n
‍
p
i
k
i
s
.
t
.
∑
i
=
1
n
‍
k
i
≤
1
+
∑
i
=
1
n
‍
l
i
l
i
≤
k
i
≤
u
i
,
k
i
∈
Z
,
i
∈
1,2
,
…
,
n
,
p
i
∈
0,1
,
l
i
,
u
i
∈
0
,
+
∞
,
i
∈
1,2
,
…
,
n
.Proof.
Based on the definition ofχ
i
(
x
), it is easily verified that the solution l
1
+
χ
1
(
h
)
,
l
2
+
χ
2
(
h
)
,
…
,
l
n
+
χ
n
(
h
) satisfies all the constraints of optimization problem (7). For any i
∈
{
1,2
,
…
,
n
}, the objective function is decreasing with respect to k
i. Then it is easily derived that the necessary condition of the objective function value achieving the minimal is that ∑
i
=
1
n
‍
k
i
=
1
+
∑
i
=
1
n
‍
l
i. Suppose that k
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to problem (7). According to the constraints, for any i
∈
{
1,2
,
…
,
n
}, we know that k
i
∗
≥
l
i. Thus we can derive that there must exist j
∈
{
1,2
,
…
,
n
}, such that k
i
∗ satisfies the following formula:(8)
k
i
∗
=
l
i
i
≠
j
l
i
+
1
i
=
j
.
It can be easily known that∑
i
=
1
n
‍
p
i
l
i
+
χ
i
(
h
)
-
∑
i
=
1
n
‍
p
i
k
i
∗
=
p
h
l
h
+
1
+
p
j
l
j
-
p
h
l
h
-
p
j
l
j
+
1  =
(
p
h
l
h
+
1
-
p
h
l
h
)
-
(
p
j
l
j
+
1
-
p
j
l
j
)
=
λ
h
(
l
h
+
1
)
-
λ
j
(
l
j
+
1
). Since λ
h
(
l
h
+
1
)
=
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}, then ∑
i
=
1
n
‍
p
i
l
i
+
χ
i
(
h
)
-
∑
i
=
1
n
‍
p
i
k
i
∗
≤
0. In conclusion, l
1
+
χ
1
(
h
)
,
l
2
+
χ
2
(
h
)
,
…
,
l
n
+
χ
n
(
h
) is the optimal solution to problem (7).Lemma 3.
Leth
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}; if k
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to the following integer optimization problem, then k
h
∗
≥
l
h
+
1, where Λ is a given positive integer:(9)
m
i
n
∑
i
=
1
n
‍
p
i
k
i
s
.
t
.
∑
i
=
1
n
‍
k
i
≤
Λ
+
∑
i
=
1
n
‍
l
i
l
i
≤
k
i
≤
u
i
,
k
i
∈
Z
,
i
∈
1,2
,
…
,
n
,
p
i
∈
0,1
,
l
i
,
u
i
∈
0
,
+
∞
,
i
∈
1,2
,
…
,
n
.Proof.
The proof is by induction onΛ. According to Lemma 2, k
h
∗
≥
l
h
+
1 holds, when Λ
=
1. Suppose that the proposition is true, when Λ
≤
m
-
1. In the following, we prove that when Λ
=
m, k
h
∗
≥
l
h
+
1 holds. And the proof is by contradiction.
Suppose thatk
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to problem (9), and k
h
∗
<
l
h
+
1. According to the constraints, we know that k
h
∗
=
l
h. For any i
∈
{
1,2
,
…
,
n
}, the objective function is decreasing with respect to k
i. Thus we can derive that ∑
i
=
1
n
‍
k
i
∗
=
Λ
+
∑
i
=
1
n
‍
l
i. Then there must exist r
∈
{
1,2
,
…
,
n
}, such that k
r
∗
≥
l
r
+
1. We define k
1
′
,
k
2
′
,
…
,
k
n
′ as follows:(10)
k
i
′
=
k
i
∗
i
≠
h
,
i
≠
r
k
i
∗
+
1
i
=
h
k
i
∗
-
1
i
=
r
.
It is easily verified that the solutionk
1
′
,
k
2
′
,
…
,
k
n
′ satisfies all the constraints; then it is a feasible solution to optimization problem (9). We can derive that ∑
i
=
1
n
‍
p
i
k
i
′
-
∑
i
=
1
n
‍
p
i
k
i
∗
=
p
h
l
h
+
1
+
p
r
k
r
∗
-
1
-
p
h
l
h
-
p
r
k
r
∗  =
(
p
h
l
h
+
1
-
p
h
l
h
)
-
(
p
j
k
r
∗
-
p
j
k
r
∗
-
1
)
=
λ
h
(
l
h
+
1
)
-
λ
r
(
k
r
∗
). Since λ
r
(
j
) is an increasing function with respect to j, then λ
r
(
k
r
∗
)
≥
λ
r
(
l
r
+
1
). Since λ
h
(
l
h
+
1
)
=
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}, then λ
r
(
l
r
+
1
)
>
λ
h
(
l
h
+
1
). Therefore, we have that ∑
i
=
1
n
‍
p
i
k
i
′
-
∑
i
=
1
n
‍
p
i
k
i
∗
<
0, which contradicts the fact that k
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution. In conclusion, it is proved that k
h
∗
≥
l
h
+
1.Theorem 4.
Ifk
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to integer optimization problem (9), then k
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to the following integer optimization problem, where h
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}:(11)
m
i
n
∑
i
=
1
n
‍
p
i
k
i
s
.
t
.
∑
i
=
1
n
‍
k
i
≤
Λ
-
1
+
(
l
h
+
1
)
+
∑
i
=
1
,
i
≠
h
n
‍
l
i
l
i
≤
k
i
≤
u
i
,
i
∈
1,2
,
…
,
n
-
h
l
h
+
1
≤
k
h
≤
u
h
,
k
i
∈
Z
,
i
∈
1,2
,
…
,
n
,
p
i
∈
0,1
,
l
i
,
u
i
∈
0
,
+
∞
,
i
∈
1,2
,
…
,
n
.Proof.
Based on Lemma3, it can be verified that the solution k
1
∗
,
…
,
k
n
∗ satisfies all the constraints of problem (11) and then it is a feasible solution to the problem. In the following, we prove that k
1
∗
,
…
,
k
n
∗ is the optimal solution for problem (11) by contradiction.
Suppose thatk
1
′
,
k
2
′
,
…
,
k
n
′ is the optimal solution to problem (11), and ∑
i
=
1
n
‍
p
i
k
i
′
<
∑
i
=
1
n
‍
p
i
k
i
∗. Due to l
h
+
1
≤
k
h
′
≤
u
h, we have l
h
≤
k
h
′
≤
u
h. Then k
1
′
,
k
2
′
,
…
,
k
n
′ is a feasible solution to integer optimization problem (9). It can be known that k
1
′
,
k
2
′
,
…
,
k
n
′ is a better solution to problem (9), which contradicts the fact that k
1
∗
,
…
,
k
n
∗ is the optimal solution. In conclusion, k
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to problem (11).Theorem 5.
Leth
1
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}, for any r
∈
{
2
,
…
,
Λ
}, h
r is defined as follows:(12)
h
r
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}

λ
i
j

-

⋃
z
=
1
r
-
1
λ
h
z
l
h
z

+

∑
m
=
1
z
‍
χ
h
z
h
m
,where i
∈
{
1,2
,
…
,
n
}
,
j
∈
{
l
i
+
1
,
…
,
u
i
}. Then l
1
+
∑
r
=
1
Λ
‍
χ
1
(
h
r
)
,
l
2
+
∑
r
=
1
Λ
‍
χ
2
(
h
r
)
,
…
,
l
n
+
∑
r
=
1
Λ
‍
χ
n
(
h
r
) is the optimal solution to integer optimization problem (9).Proof.
The proof is by induction onΛ. According to Lemma 2, l
1
+
∑
r
=
1
Λ
‍
χ
1
(
h
r
)
,
l
2
+
∑
r
=
1
Λ
‍
χ
2
(
h
r
)
,
…
,
l
n
+
∑
r
=
1
Λ
‍
χ
n
(
h
r
) is the optimal solution to problem (9), when Λ
=
1. Suppose that when Λ
≤
m
-
1, the proposition holds. In the following, we prove that, when Λ
=
m, the proposition is true.
Suppose thatk
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to problem (9), when Λ
=
m. Let h
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}. Based on Theorem 4, we know that k
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to the following integer optimization problem:(13)
m
i
n
∑
i
=
1
n
‍
p
i
k
i
s
.
t
.
∑
i
=
1
n
‍
k
i
≤
m
-
1
+
l
h
+
1
+
∑
i
=
1
,
i
≠
h
n
‍
l
i
l
i
≤
k
i
≤
u
i
,
i
∈
1,2
,
…
,
n
-
h
l
h
+
1
≤
k
h
≤
u
h
,
k
i
∈
Z
,
i
∈
1,2
,
…
,
n
,
p
i
∈
0,1
,
l
i
,
u
i
∈
0
,
+
∞
,
i
∈
1,2
,
…
,
n
.
Leth
1
′
=
a
r
g
m
i
n
i
∈
{
1
,
…
,
n
}
λ
i
j
-
λ
h
l
h
+
1. For any r
∈
2
,
…
,
m
-
1, h
r
′ is defined as follows:(14)
h
r
′
=
a
r
g
m
i
n
⋃
z
=
1
r
-
1
λ
h
z
′
l
h
z
′
+
∑
m
=
1
z
‍
χ
h
z
′
(
h
m
′
)

λ
i
j
-
λ
h
l
h
+
1
-
⋃
z
=
1
r
-
1
λ
h
z
′
l
h
z
′
+
∑
m
=
1
z
‍
χ
h
z
′
(
h
m
′
)
. By the induction hypothesis, l
1
+
∑
r
=
1
m
-
1
‍
χ
1
(
h
r
′
)
,
…,  l
h
-
1
+
∑
r
=
1
m
-
1
‍
χ
h
-
1
(
h
r
′
),  l
h
+
1
+
∑
r
=
1
m
-
1
‍
χ
h
(
h
r
′
)
,  l
h
+
1
+
∑
r
=
1
m
-
1
‍
χ
h
+
1
(
h
r
′
)
,
…
,  l
n
+
∑
r
=
1
m
-
1
‍
χ
n
(
h
r
′
) is the optimal solution to problem (13), and the value of the objective function achieves ∑
i
=
1
n
‍
p
i
k
i
∗. Thus we can know that l
1
+
∑
r
=
1
m
-
1
‍
χ
1
(
h
r
′
)
+
χ
1
(
h
),  l
2
+
∑
r
=
1
m
-
1
‍
χ
2
(
h
r
′
)
+
χ
2
(
h
)
,
…,  l
h
+
∑
r
=
1
m
-
1
‍
χ
h
(
h
r
′
)
+
χ
h
(
h
)
,
…,  l
n
+
∑
r
=
1
m
-
1
‍
χ
n
(
h
r
′
)
+
χ
n
(
h
) is the optimal solution to problem (9), when Λ
=
m.
Leth
1
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}, and, for any r
∈
{
2
,
…
,
m
}, h
r is defined based on formula (12). It is easily known that for any i
∈
{
1,2
,
…
,
n
}, l
i
+
∑
r
=
1
m
-
1
‍
χ
i
(
h
r
′
)
+
χ
i
(
h
)
=
l
i
+
∑
r
=
1
m
‍
χ
i
(
h
r
). In conclusion, for a given positive integer Λ, l
1
+
∑
r
=
1
Λ
‍
χ
1
(
h
r
)
,
…
,
l
n
+
∑
r
=
1
Λ
‍
χ
n
(
h
r
) is the optimal solution to problem (9).


### 3.3.  Greedy Algorithm for Computing Optimal Retransmission Threshold

From Theorems4 and 5, we know that integer optimization problem (9) exhibits the optimal substructure and greedy-choice properties, which are two key ingredients of the greedy approach. In this section, a greedy algorithm for computing the optimal retransmission threshold is proposed.Suppose that the end-to-end path isP
=
j
1
,
j
2
,
…
,
j
n
+
1, where j
1 and j
n
+
1 are source and destination nodes, respectively. Let p
i denote the transmission failure probability over the link from j
i to j
i
+
1. Suppose that rely node j
i receives a data packet with delay requirement Δ
′. The greedy algorithm for computing optimal retransmission threshold runs at sensor node j
i as follows. The retransmission thresholds for nodes j
i
,
j
i
+
1
,
…
,
j
n are initialized as L
i
,
L
i
+
1
,
…
,
L
n, respectively, where L
h is the given lower bound of retransmission threshold of node j
h. First, for each h
∈
{
i
,
i
+
1
,
…
,
n
}, compute p
h
L
h
+
2
-
p
h
L
h
+
1. Then, the L
h with the minimum value p
h
L
h
+
2
-
p
h
L
h
+
1 is incremented by one. The above procedures are repeated Δ
′
-
∑
h
=
i
n
‍
L
h
+
1 times. The detail of the algorithm is described in Algorithm 1.Algorithm 1:Greedy algorithm for computing optimal retransmission threshold.
Input:Δ
′, {
p
i
,
p
i
+
1
,
…
,
p
n
}
,
{
L
i
,
L
i
+
1
,
…
,
L
n
}
,
{
U
i
,
U
i
+
1
,
…
,
U
n
}
Output: optimal retransmission threshold of nodei
(1)Δ
′
=
Δ
′
-
∑
h
=
i
n
L
h
+
1,
(2)for  k
=
1 to Δ
′  do
(3)
t
e
r
m
=
0;
(4)
for  h
=
i to n  do
(5)
if  L
h
+
1
≤
U
h  then
(6)λ
h
=
p
h
L
h
+
2
-
p
h
L
h
+
1;
(7)
else
(8)λ
h
=
∞;
(9)
if  λ
h
<
t
e
r
m  then
(10)
t
e
r
m
=
λ
h;
(11)
κ
=
arg
⁡
{
t
e
r
m
};
(12)
L
κ
=
L
κ
+
1;
(13)return  L
iFor a given delay requirementΔ and a delivery path consisting of n sensor nodes, the cost for computing the optimal retransmission threshold is O
(
n
Δ
), and the memory complexity is O
(
n
).


## 3.1. Problem Description

Suppose that the end-to-end path isP
=
j
1
,
j
2
,
…
,
j
n
+
1, where j
1 and j
n
+
1 are source and destination nodes. Let p
i denote the probability of a transmission failure over the link from j
i to j
i
+
1. Then p
i is the probability that a MAC-layer transmission fails due to either collisions or bad channel quality when node j
i forwards a data packet to node j
i
+
1. If K
i is the retransmission threshold of node j
i, then 1
-
p
i
K
i
+
1 is the probability of a packet being successfully transmitted to node j
i
+
1 by node j
i. To improve the reliability of packet delivery, packets are transmitted along multiple paths. Therefore, we focus on maximizing the summation of the probability of a packet being successfully transmitted to the next relay node or destination node along the delivery path within the given deadline. Let Δ denote the end-to-end delay requirement. L
i and U
i are used to denote the given lower and upper bounds of retransmission threshold of node i. The problem of finding optimal retransmission thresholds for relay nodes can be formulated as the following integer optimization problem:(1)
m
a
x
∑
i
=
1
n
‍
1
-
p
i
K
i
+
1
s
.
t
.
∑
i
=
1
n
‍
K
i
+
1
≤
Δ
L
i
≤
K
i
≤
U
i
,
K
i
∈
Z
,
i
∈
1,2
,
…
,
n
,
p
i
∈
0,1
,
L
i
,
U
i
∈
0
,
+
∞
,
i
∈
1,2
,
…
,
n
.Obviously, the value of objective function∑
i
=
1
n
‍
(
1
-
p
i
K
i
+
1
) is maximized if and only if the value of ∑
i
=
1
n
‍
p
i
K
i
+
1 achieves the minimum. For any i
∈
{
1,2
,
…
,
n
}, let k
i
=
K
i
+
1
,
l
i
=
L
i
+
1 and u
i
=
U
i
+
1. Then the aforementioned optimization problem is equivalent to the following integer optimization problem:(2)
m
i
n
∑
i
=
1
n
‍
p
i
k
i
s
.
t
.
∑
i
=
1
n
‍
k
i
≤
Δ
l
i
≤
k
i
≤
u
i
,
k
i
∈
Z
,
i
∈
1,2
,
…
,
n
,
p
i
∈
0,1
,
l
i
,
u
i
∈
0
,
+
∞
,
i
∈
1,2
,
…
,
n
.Then the problem of finding the optimal retransmission thresholds for each relay node along a delivery path can be defined as follows.Input. (
1
) The set of the transmission failure probabilities of the nodes along a delivery path, {
p
1
,
…
,
p
n
}.  (
2
) The end-to-end delivery delay requirement Δ.Output. Optimal retransmission thresholds k
1
′
,
k
2
′
,
…
,
k
n
′, which are optimal solutions for integer optimization problem (2).Based on the above analysis, the key point is to design an efficient algorithm for finding the optimal solutions to integer optimization problem (2). In the following section, we prove that the optimization problem can be solved by a greedy algorithm. And the correctness of the algorithm is proved.


## 3.2.  Correctness of Greedy Algorithm

Lemma 1.
For anyi
∈
{
1,2
,
…
,
n
}, the following inequalities hold; if 0
<
p
i
<
1 and l
i
<
u
i,(3)
p
i
l
i
+
j
-
p
i
l
i
+
j
-
1
<
p
i
l
i
+
j
+
1
-
p
i
l
i
+
j
<
0
,where j
∈
{
1,2
,
…
,
u
i
-
l
i
}.Proof.
Letf
i
(
x
)
=
p
i
x; it is easily known that f
i
′
′
(
x
)
>
0.
Thusf
i
′
(
x
) is an increasing function with respect to x. According to the differential mean value theorem, the following equalities can be derived:(4)
f
i
(
l
i
+
j
+
1
)
-
f
i
(
l
i
+
j
)
=
f
i
′
(
ξ
)
·
1
f
i
(
l
i
+
j
)
-
f
i
(
l
i
+
j
-
1
)
=
f
i
′
(
η
)
·
1
,where ξ
∈
l
i
+
j
,
l
i
+
j
+
1 and η
∈
l
i
+
j
-
1
,
l
i
+
j. Since f
i
′
(
x
) is an increasing function, then f
i
′
(
η
)
<
f
i
′
(
ξ
). Then we can derive that p
i
l
i
+
j
-
p
i
l
i
+
j
-
1
<
p
i
l
i
+
j
+
1
-
p
i
l
i
+
j. Due to the decreasing of f
i
(
x
), we have p
i
l
i
+
j
+
1
-
p
i
l
i
+
j
<
0. In conclusion, we know that p
i
l
i
+
j
-
p
i
l
i
+
j
-
1
<
p
i
l
i
+
j
+
1
-
p
i
l
i
+
j
<
0.For anyi
∈
{
1,2
,
…
,
n
}
,
j
∈
Z
+, λ
i
(
j
) is defined as follows:(5)
λ
i
j
=
p
i
j
-
p
i
j
-
1
j
≤
u
i
∞
j
>
u
i
,where l
i
<
u
i.According to Lemma1, for any j
∈
[
l
i
,
u
i
-
1
], we have λ
i
(
j
+
1
)
>
λ
i
(
j
). And it can be known that p
i
l
i
+
j
=
p
i
l
i
+
∑
k
=
l
i
+
1
l
i
+
j
‍
λ
i
(
k
). For ∀
i
∈
{
1,2
,
…
,
n
}, we introduce the following sign function:(6)
χ
i
x
=
1
x
=
i
0
x
≠
i
.Lemma 2.
Leth
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}; then l
1
+
χ
1
(
h
)
,
l
2
+
χ
2
(
h
)
,
…
,
l
n
+
χ
n
(
h
) are the optimal solution to the following integer optimization problem:(7)
m
i
n
∑
i
=
1
n
‍
p
i
k
i
s
.
t
.
∑
i
=
1
n
‍
k
i
≤
1
+
∑
i
=
1
n
‍
l
i
l
i
≤
k
i
≤
u
i
,
k
i
∈
Z
,
i
∈
1,2
,
…
,
n
,
p
i
∈
0,1
,
l
i
,
u
i
∈
0
,
+
∞
,
i
∈
1,2
,
…
,
n
.Proof.
Based on the definition ofχ
i
(
x
), it is easily verified that the solution l
1
+
χ
1
(
h
)
,
l
2
+
χ
2
(
h
)
,
…
,
l
n
+
χ
n
(
h
) satisfies all the constraints of optimization problem (7). For any i
∈
{
1,2
,
…
,
n
}, the objective function is decreasing with respect to k
i. Then it is easily derived that the necessary condition of the objective function value achieving the minimal is that ∑
i
=
1
n
‍
k
i
=
1
+
∑
i
=
1
n
‍
l
i. Suppose that k
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to problem (7). According to the constraints, for any i
∈
{
1,2
,
…
,
n
}, we know that k
i
∗
≥
l
i. Thus we can derive that there must exist j
∈
{
1,2
,
…
,
n
}, such that k
i
∗ satisfies the following formula:(8)
k
i
∗
=
l
i
i
≠
j
l
i
+
1
i
=
j
.
It can be easily known that∑
i
=
1
n
‍
p
i
l
i
+
χ
i
(
h
)
-
∑
i
=
1
n
‍
p
i
k
i
∗
=
p
h
l
h
+
1
+
p
j
l
j
-
p
h
l
h
-
p
j
l
j
+
1  =
(
p
h
l
h
+
1
-
p
h
l
h
)
-
(
p
j
l
j
+
1
-
p
j
l
j
)
=
λ
h
(
l
h
+
1
)
-
λ
j
(
l
j
+
1
). Since λ
h
(
l
h
+
1
)
=
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}, then ∑
i
=
1
n
‍
p
i
l
i
+
χ
i
(
h
)
-
∑
i
=
1
n
‍
p
i
k
i
∗
≤
0. In conclusion, l
1
+
χ
1
(
h
)
,
l
2
+
χ
2
(
h
)
,
…
,
l
n
+
χ
n
(
h
) is the optimal solution to problem (7).Lemma 3.
Leth
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}; if k
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to the following integer optimization problem, then k
h
∗
≥
l
h
+
1, where Λ is a given positive integer:(9)
m
i
n
∑
i
=
1
n
‍
p
i
k
i
s
.
t
.
∑
i
=
1
n
‍
k
i
≤
Λ
+
∑
i
=
1
n
‍
l
i
l
i
≤
k
i
≤
u
i
,
k
i
∈
Z
,
i
∈
1,2
,
…
,
n
,
p
i
∈
0,1
,
l
i
,
u
i
∈
0
,
+
∞
,
i
∈
1,2
,
…
,
n
.Proof.
The proof is by induction onΛ. According to Lemma 2, k
h
∗
≥
l
h
+
1 holds, when Λ
=
1. Suppose that the proposition is true, when Λ
≤
m
-
1. In the following, we prove that when Λ
=
m, k
h
∗
≥
l
h
+
1 holds. And the proof is by contradiction.
Suppose thatk
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to problem (9), and k
h
∗
<
l
h
+
1. According to the constraints, we know that k
h
∗
=
l
h. For any i
∈
{
1,2
,
…
,
n
}, the objective function is decreasing with respect to k
i. Thus we can derive that ∑
i
=
1
n
‍
k
i
∗
=
Λ
+
∑
i
=
1
n
‍
l
i. Then there must exist r
∈
{
1,2
,
…
,
n
}, such that k
r
∗
≥
l
r
+
1. We define k
1
′
,
k
2
′
,
…
,
k
n
′ as follows:(10)
k
i
′
=
k
i
∗
i
≠
h
,
i
≠
r
k
i
∗
+
1
i
=
h
k
i
∗
-
1
i
=
r
.
It is easily verified that the solutionk
1
′
,
k
2
′
,
…
,
k
n
′ satisfies all the constraints; then it is a feasible solution to optimization problem (9). We can derive that ∑
i
=
1
n
‍
p
i
k
i
′
-
∑
i
=
1
n
‍
p
i
k
i
∗
=
p
h
l
h
+
1
+
p
r
k
r
∗
-
1
-
p
h
l
h
-
p
r
k
r
∗  =
(
p
h
l
h
+
1
-
p
h
l
h
)
-
(
p
j
k
r
∗
-
p
j
k
r
∗
-
1
)
=
λ
h
(
l
h
+
1
)
-
λ
r
(
k
r
∗
). Since λ
r
(
j
) is an increasing function with respect to j, then λ
r
(
k
r
∗
)
≥
λ
r
(
l
r
+
1
). Since λ
h
(
l
h
+
1
)
=
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}, then λ
r
(
l
r
+
1
)
>
λ
h
(
l
h
+
1
). Therefore, we have that ∑
i
=
1
n
‍
p
i
k
i
′
-
∑
i
=
1
n
‍
p
i
k
i
∗
<
0, which contradicts the fact that k
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution. In conclusion, it is proved that k
h
∗
≥
l
h
+
1.Theorem 4.
Ifk
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to integer optimization problem (9), then k
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to the following integer optimization problem, where h
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}:(11)
m
i
n
∑
i
=
1
n
‍
p
i
k
i
s
.
t
.
∑
i
=
1
n
‍
k
i
≤
Λ
-
1
+
(
l
h
+
1
)
+
∑
i
=
1
,
i
≠
h
n
‍
l
i
l
i
≤
k
i
≤
u
i
,
i
∈
1,2
,
…
,
n
-
h
l
h
+
1
≤
k
h
≤
u
h
,
k
i
∈
Z
,
i
∈
1,2
,
…
,
n
,
p
i
∈
0,1
,
l
i
,
u
i
∈
0
,
+
∞
,
i
∈
1,2
,
…
,
n
.Proof.
Based on Lemma3, it can be verified that the solution k
1
∗
,
…
,
k
n
∗ satisfies all the constraints of problem (11) and then it is a feasible solution to the problem. In the following, we prove that k
1
∗
,
…
,
k
n
∗ is the optimal solution for problem (11) by contradiction.
Suppose thatk
1
′
,
k
2
′
,
…
,
k
n
′ is the optimal solution to problem (11), and ∑
i
=
1
n
‍
p
i
k
i
′
<
∑
i
=
1
n
‍
p
i
k
i
∗. Due to l
h
+
1
≤
k
h
′
≤
u
h, we have l
h
≤
k
h
′
≤
u
h. Then k
1
′
,
k
2
′
,
…
,
k
n
′ is a feasible solution to integer optimization problem (9). It can be known that k
1
′
,
k
2
′
,
…
,
k
n
′ is a better solution to problem (9), which contradicts the fact that k
1
∗
,
…
,
k
n
∗ is the optimal solution. In conclusion, k
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to problem (11).Theorem 5.
Leth
1
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}, for any r
∈
{
2
,
…
,
Λ
}, h
r is defined as follows:(12)
h
r
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}

λ
i
j

-

⋃
z
=
1
r
-
1
λ
h
z
l
h
z

+

∑
m
=
1
z
‍
χ
h
z
h
m
,where i
∈
{
1,2
,
…
,
n
}
,
j
∈
{
l
i
+
1
,
…
,
u
i
}. Then l
1
+
∑
r
=
1
Λ
‍
χ
1
(
h
r
)
,
l
2
+
∑
r
=
1
Λ
‍
χ
2
(
h
r
)
,
…
,
l
n
+
∑
r
=
1
Λ
‍
χ
n
(
h
r
) is the optimal solution to integer optimization problem (9).Proof.
The proof is by induction onΛ. According to Lemma 2, l
1
+
∑
r
=
1
Λ
‍
χ
1
(
h
r
)
,
l
2
+
∑
r
=
1
Λ
‍
χ
2
(
h
r
)
,
…
,
l
n
+
∑
r
=
1
Λ
‍
χ
n
(
h
r
) is the optimal solution to problem (9), when Λ
=
1. Suppose that when Λ
≤
m
-
1, the proposition holds. In the following, we prove that, when Λ
=
m, the proposition is true.
Suppose thatk
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to problem (9), when Λ
=
m. Let h
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}. Based on Theorem 4, we know that k
1
∗
,
k
2
∗
,
…
,
k
n
∗ is the optimal solution to the following integer optimization problem:(13)
m
i
n
∑
i
=
1
n
‍
p
i
k
i
s
.
t
.
∑
i
=
1
n
‍
k
i
≤
m
-
1
+
l
h
+
1
+
∑
i
=
1
,
i
≠
h
n
‍
l
i
l
i
≤
k
i
≤
u
i
,
i
∈
1,2
,
…
,
n
-
h
l
h
+
1
≤
k
h
≤
u
h
,
k
i
∈
Z
,
i
∈
1,2
,
…
,
n
,
p
i
∈
0,1
,
l
i
,
u
i
∈
0
,
+
∞
,
i
∈
1,2
,
…
,
n
.
Leth
1
′
=
a
r
g
m
i
n
i
∈
{
1
,
…
,
n
}
λ
i
j
-
λ
h
l
h
+
1. For any r
∈
2
,
…
,
m
-
1, h
r
′ is defined as follows:(14)
h
r
′
=
a
r
g
m
i
n
⋃
z
=
1
r
-
1
λ
h
z
′
l
h
z
′
+
∑
m
=
1
z
‍
χ
h
z
′
(
h
m
′
)

λ
i
j
-
λ
h
l
h
+
1
-
⋃
z
=
1
r
-
1
λ
h
z
′
l
h
z
′
+
∑
m
=
1
z
‍
χ
h
z
′
(
h
m
′
)
. By the induction hypothesis, l
1
+
∑
r
=
1
m
-
1
‍
χ
1
(
h
r
′
)
,
…,  l
h
-
1
+
∑
r
=
1
m
-
1
‍
χ
h
-
1
(
h
r
′
),  l
h
+
1
+
∑
r
=
1
m
-
1
‍
χ
h
(
h
r
′
)
,  l
h
+
1
+
∑
r
=
1
m
-
1
‍
χ
h
+
1
(
h
r
′
)
,
…
,  l
n
+
∑
r
=
1
m
-
1
‍
χ
n
(
h
r
′
) is the optimal solution to problem (13), and the value of the objective function achieves ∑
i
=
1
n
‍
p
i
k
i
∗. Thus we can know that l
1
+
∑
r
=
1
m
-
1
‍
χ
1
(
h
r
′
)
+
χ
1
(
h
),  l
2
+
∑
r
=
1
m
-
1
‍
χ
2
(
h
r
′
)
+
χ
2
(
h
)
,
…,  l
h
+
∑
r
=
1
m
-
1
‍
χ
h
(
h
r
′
)
+
χ
h
(
h
)
,
…,  l
n
+
∑
r
=
1
m
-
1
‍
χ
n
(
h
r
′
)
+
χ
n
(
h
) is the optimal solution to problem (9), when Λ
=
m.
Leth
1
=
a
r
g
m
i
n
i
∈
{
1,2
,
…
,
n
}
{
λ
i
(
l
i
+
1
)
}, and, for any r
∈
{
2
,
…
,
m
}, h
r is defined based on formula (12). It is easily known that for any i
∈
{
1,2
,
…
,
n
}, l
i
+
∑
r
=
1
m
-
1
‍
χ
i
(
h
r
′
)
+
χ
i
(
h
)
=
l
i
+
∑
r
=
1
m
‍
χ
i
(
h
r
). In conclusion, for a given positive integer Λ, l
1
+
∑
r
=
1
Λ
‍
χ
1
(
h
r
)
,
…
,
l
n
+
∑
r
=
1
Λ
‍
χ
n
(
h
r
) is the optimal solution to problem (9).


## 3.3.  Greedy Algorithm for Computing Optimal Retransmission Threshold

From Theorems4 and 5, we know that integer optimization problem (9) exhibits the optimal substructure and greedy-choice properties, which are two key ingredients of the greedy approach. In this section, a greedy algorithm for computing the optimal retransmission threshold is proposed.Suppose that the end-to-end path isP
=
j
1
,
j
2
,
…
,
j
n
+
1, where j
1 and j
n
+
1 are source and destination nodes, respectively. Let p
i denote the transmission failure probability over the link from j
i to j
i
+
1. Suppose that rely node j
i receives a data packet with delay requirement Δ
′. The greedy algorithm for computing optimal retransmission threshold runs at sensor node j
i as follows. The retransmission thresholds for nodes j
i
,
j
i
+
1
,
…
,
j
n are initialized as L
i
,
L
i
+
1
,
…
,
L
n, respectively, where L
h is the given lower bound of retransmission threshold of node j
h. First, for each h
∈
{
i
,
i
+
1
,
…
,
n
}, compute p
h
L
h
+
2
-
p
h
L
h
+
1. Then, the L
h with the minimum value p
h
L
h
+
2
-
p
h
L
h
+
1 is incremented by one. The above procedures are repeated Δ
′
-
∑
h
=
i
n
‍
L
h
+
1 times. The detail of the algorithm is described in Algorithm 1.Algorithm 1:Greedy algorithm for computing optimal retransmission threshold.
Input:Δ
′, {
p
i
,
p
i
+
1
,
…
,
p
n
}
,
{
L
i
,
L
i
+
1
,
…
,
L
n
}
,
{
U
i
,
U
i
+
1
,
…
,
U
n
}
Output: optimal retransmission threshold of nodei
(1)Δ
′
=
Δ
′
-
∑
h
=
i
n
L
h
+
1,
(2)for  k
=
1 to Δ
′  do
(3)
t
e
r
m
=
0;
(4)
for  h
=
i to n  do
(5)
if  L
h
+
1
≤
U
h  then
(6)λ
h
=
p
h
L
h
+
2
-
p
h
L
h
+
1;
(7)
else
(8)λ
h
=
∞;
(9)
if  λ
h
<
t
e
r
m  then
(10)
t
e
r
m
=
λ
h;
(11)
κ
=
arg
⁡
{
t
e
r
m
};
(12)
L
κ
=
L
κ
+
1;
(13)return  L
iFor a given delay requirementΔ and a delivery path consisting of n sensor nodes, the cost for computing the optimal retransmission threshold is O
(
n
Δ
), and the memory complexity is O
(
n
).


## 4.(
α
,
β
)-Probabilistic Delay Bound Based Packet Dropped Protocol

In previous section, we investigate the problem of finding the optimal retransmission thresholds for the relay nodes along a given end-to-end delivery path. Due to the uncertainty of wireless link, stringent retransmission threshold may make the packet forwarded to the destination within deadline with high probability be dropped. Since computing the probabilistic distribution of path delays is NP-hard [27], then we develop an (
α
,
β
)-probabilistic delay bound based packet dropped protocol in this section.The main idea of the proposed protocol is as follows. When a packet fails to be transmitted after a predefined number of retransmissions, if the upper bound of the probability of the delivery delay within the deadline is smaller thanα, then the packet is dropped; if the upper bound of the probability of the delivery delay exceeding the deadline is smaller than β, then the packet is transmitted once again. In the following section, the probabilistic path delay bounds are derived.


### 4.1. Probabilistic Path Delay Bound

Given a pathP
=
j
1
,
j
2
,
…
,
j
n
+
1 from source node j
1 to destination node j
n
+
1, let d
j
i denote the number of transmission trials when j
i forwards the packet to node j
i
+
1. Then the end-to-end delivery delay over the path is d
P
=
∑
i
=
1
n
‍
d
j
i, where d
j
i follows geometric distribution G
(
1
-
p
i
). Since per-packet transmission time is stable and uncorrelated [22], then we have that E
[
d
p
]
=
∑
i
=
1
n
‍
(
1
-
p
i
)
-
1
,
V
a
r
[
d
p
]
=
∑
i
=
1
n
‍
p
i
(
1
-
p
i
)
-
2.Property 1.
Suppose thatΔ is the delay requirement, let δ
=
Δ
-
E
[
d
p
]. If Δ
<
E
[
d
p
], then the following inequality holds:(15)
P
r
d
p
≤
Δ
≤
V
a
r
d
p
V
a
r
d
p
+
δ
2
.If Δ
≥
E
[
d
p
], then the following inequality can be known:(16)
P
r
d
p
≥
Δ
≤
V
a
r
d
p
V
a
r
d
p
+
δ
2
.Proof.
According to one-sided Chebyshev inequality, the following inequality holds, ift
<
0 and V
a
r
[
x
] is bounded:(17)
P
r
x
≤
E
x
+
t
≤
V
a
r
x
V
a
r
x
+
t
2
. Similarly, the following inequality holds, if t
≥
0 and V
a
r
[
x
] is bounded:(18)
P
r
x
≥
E
x
+
t
≤
V
a
r
x
V
a
r
x
+
t
2
. Thus formula (15) and (16) are easily obtained.


### 4.2.(
α
,
β
)-Probabilistic Delay Bound Based Packet Dropped Protocol

Suppose that relay nodej
i fails to transmit a data packet to node j
i
+
1 after a predefined number of retransmission trials, and the remaining time to the deadline is Δ
′. For given probability thresholds α and β, (
α
,
β
)-probabilistic delay bound based packet dropped protocol implements at sensor node j
i as follows.Firstly, nodej
i computes the expectation and variance of the delivery delay over the path j
i
+
1
,
j
i
+
2
,
…
,
j
n, denoted by μ and σ, respectively. Let δ
=
Δ
′
-
1
-
μ be the difference between Δ
′
-
1 and the expectation of the delivery delay.Secondly, the node decides whether the packet will be dropped as follows.Case 1 (Δ
′
-
1
<
μ).
Ifσ
/
(
σ
+
δ
2
)
≤
α, then the packet is dropped; otherwise the packet is transmitted once again.Case 2 (Δ
′
-
1
≥
μ).
Ifσ
/
(
σ
+
δ
2
)
≤
β, then the packet is transmitted once again; otherwise the packet is dropped.The detail of the protocol is described in Algorithm2.Algorithm 2:
(
α
,
β
)-Probabilistic delay bound based packet dropped protocol.
Input:α
,
β
,
Δ
′, {
p
i
+
1
,
p
i
+
2
,
…
,
p
n
},
Output: nodej
i retransmits the data packet or drops the data packet
(1)μ
=
0
,
σ
=
0;
(2)for  k
=
i
+
1 to n  do
(3)
μ
=
μ
+
(
1
-
p
k
)
-
1;
(4)
σ
=
σ
+
p
k
(
1
-
p
k
)
-
2;
(5)δ
=
Δ
′
-
1
-
μ;
(6)if  Δ
′
-
1
<
μ  then
(7)
if  σ
/
σ
+
δ
2
≤
α  then
(8)The packet is dropped;
(9)
else
(10)The packet is transmitted once again;
(11)else
(12)
if  σ
/
σ
+
δ
2
≤
β  then
(13)The packet is transmitted once again;
(14)
else
(15)The packet is dropped;


## 4.1. Probabilistic Path Delay Bound

Given a pathP
=
j
1
,
j
2
,
…
,
j
n
+
1 from source node j
1 to destination node j
n
+
1, let d
j
i denote the number of transmission trials when j
i forwards the packet to node j
i
+
1. Then the end-to-end delivery delay over the path is d
P
=
∑
i
=
1
n
‍
d
j
i, where d
j
i follows geometric distribution G
(
1
-
p
i
). Since per-packet transmission time is stable and uncorrelated [22], then we have that E
[
d
p
]
=
∑
i
=
1
n
‍
(
1
-
p
i
)
-
1
,
V
a
r
[
d
p
]
=
∑
i
=
1
n
‍
p
i
(
1
-
p
i
)
-
2.Property 1.
Suppose thatΔ is the delay requirement, let δ
=
Δ
-
E
[
d
p
]. If Δ
<
E
[
d
p
], then the following inequality holds:(15)
P
r
d
p
≤
Δ
≤
V
a
r
d
p
V
a
r
d
p
+
δ
2
.If Δ
≥
E
[
d
p
], then the following inequality can be known:(16)
P
r
d
p
≥
Δ
≤
V
a
r
d
p
V
a
r
d
p
+
δ
2
.Proof.
According to one-sided Chebyshev inequality, the following inequality holds, ift
<
0 and V
a
r
[
x
] is bounded:(17)
P
r
x
≤
E
x
+
t
≤
V
a
r
x
V
a
r
x
+
t
2
. Similarly, the following inequality holds, if t
≥
0 and V
a
r
[
x
] is bounded:(18)
P
r
x
≥
E
x
+
t
≤
V
a
r
x
V
a
r
x
+
t
2
. Thus formula (15) and (16) are easily obtained.


## 4.2.(
α
,
β
)-Probabilistic Delay Bound Based Packet Dropped Protocol

Suppose that relay nodej
i fails to transmit a data packet to node j
i
+
1 after a predefined number of retransmission trials, and the remaining time to the deadline is Δ
′. For given probability thresholds α and β, (
α
,
β
)-probabilistic delay bound based packet dropped protocol implements at sensor node j
i as follows.Firstly, nodej
i computes the expectation and variance of the delivery delay over the path j
i
+
1
,
j
i
+
2
,
…
,
j
n, denoted by μ and σ, respectively. Let δ
=
Δ
′
-
1
-
μ be the difference between Δ
′
-
1 and the expectation of the delivery delay.Secondly, the node decides whether the packet will be dropped as follows.Case 1 (Δ
′
-
1
<
μ).
Ifσ
/
(
σ
+
δ
2
)
≤
α, then the packet is dropped; otherwise the packet is transmitted once again.Case 2 (Δ
′
-
1
≥
μ).
Ifσ
/
(
σ
+
δ
2
)
≤
β, then the packet is transmitted once again; otherwise the packet is dropped.The detail of the protocol is described in Algorithm2.Algorithm 2:
(
α
,
β
)-Probabilistic delay bound based packet dropped protocol.
Input:α
,
β
,
Δ
′, {
p
i
+
1
,
p
i
+
2
,
…
,
p
n
},
Output: nodej
i retransmits the data packet or drops the data packet
(1)μ
=
0
,
σ
=
0;
(2)for  k
=
i
+
1 to n  do
(3)
μ
=
μ
+
(
1
-
p
k
)
-
1;
(4)
σ
=
σ
+
p
k
(
1
-
p
k
)
-
2;
(5)δ
=
Δ
′
-
1
-
μ;
(6)if  Δ
′
-
1
<
μ  then
(7)
if  σ
/
σ
+
δ
2
≤
α  then
(8)The packet is dropped;
(9)
else
(10)The packet is transmitted once again;
(11)else
(12)
if  σ
/
σ
+
δ
2
≤
β  then
(13)The packet is transmitted once again;
(14)
else
(15)The packet is dropped;


## 5. Performance Evaluation

In this section, a series of experiments have been conducted to evaluate the performance of the retransmission threshold setting protocol based on greedy algorithm for computing optimal retransmission threshold (GAORT) and probabilistic delay bound based packet dropped (PDBPD) protocol. The simulations are carried out by MATLAB.100 sensor nodes and the sink are randomly deployed into a region of size 200 m × 200 m (m for meters) and all the sensors have the same transmission radius 25m. In each simulation, source node and destination node are randomly selected. Each simulation is repeated 100 times and the simulation result corresponds to the average value over 100 times. To understand the benefits of the GAORT based protocol, the comparison with General Method is conducted. The main idea of General Method is that we set the same retransmission threshold for all the sensor nodes along a delivery path. In the experimental simulation, Δ is the result of the deadline divided by once transmission time.The first group of experiments is to investigate the deadline success ratio (DSR) of the GAORT based protocol. In this paper, deadline success ratio is the percentage of the packets delivered to the destination before given deadlines among all the packets. And DSR can be calculated as follows:(19)
D
S
R
=
#
o
f
p
a
c
k
e
t
s
d
e
l
i
v
e
r
e
d
t
o
t
h
e
d
e
s
t
i
n
a
t
i
o
n
b
e
f
o
r
e
g
i
v
e
n
d
e
a
d
l
i
n
e
s
×
#
o
f
a
l
l
o
f
t
h
e
p
a
c
k
e
t
s
-
1
. Figure 2(a) shows the comparison of DSR between the GAORT based protocol and General Method, when the length of delivery path is 10 and the probability of transmission failure, p
i, follows normal distribution N
(
0.4,0.2
). The GAORT based protocol has better performance in terms of deadline success ratio. For example, when the deadline is 0.11 s, the DSRs of the GAORT based protocol and General Method are 82
% and 69
%, respectively. Figure 2(b) depicts the relationship between the DSRs and the deadlines, when the probability of transmission failure, p
i, follows uniform distribution U
[
0.4,0.9
]. Figure 2(c) demonstrates the comparison of DSRs under different lengths of delivery path. As expected, the GAORT based protocol can achieve a higher deadline success ratio, since delay requirement and link quality have been taken into account by our protocol. Experimental results show that the GAORT based protocol can optimize the probability of packet delivery within given deadline and the proposed protocol increases the number of retransmissions over the link of inferior quality.Figure 2
Deadline success ratio of GAORT based protocol.
(a)
DSR versus deadlines
(b)
DSR versus deadlines
(c)
DSR versus length of delivery pathThe second group of experiments is to investigate the real-time ratio (RTR) of the GAORT based protocol. Real-time ratio is the percentage of the packets delivered to the destination before given deadlines among the packets successfully delivered to the destination. And RTR can be calculated as follows:(20)
R
T
R
=
#
o
f
p
a
c
k
e
t
s
d
e
l
i
v
e
r
e
d
t
o
t
h
e
d
e
s
t
i
n
a
t
i
o
n
b
e
f
o
r
e
g
i
v
e
n
d
e
a
d
l
i
n
e
s
×
#
o
f
p
a
c
k
e
t
s
d
e
l
i
v
e
r
e
d
t
o
t
h
e
d
e
s
t
i
n
a
t
i
o
n
-
1
. As shown in Figure 3(a), the GAORT based protocol can reach higher real-time ratio than that of General Method, when the length of delivery path is 10 and the probability of transmission failure, p
i, follows normal distribution N
(
0.4,0.2
). Figure 3(b) demonstrates the comparison of RTR, when the probability of transmission failure, p
i, follows uniform distribution U
[
0.4,0.9
]. Figure 3(c) shows that the GAORT based protocol has better performance in terms of RTR, when the length of delivery path is increased from 5 to 10. For example, the RTR of the GAORT based protocol is more than 75
%. Experimental results indicate that the protocol based on GAORT can reduce the number of retransmission for the packets, which are forwarded to the destination nodes before given deadlines with low probabilities. Therefore, the GAORT based protocol improves the real-time ratio and the energy efficiency.Figure 3
Real-time ratio of GAORT based protocol.
(a)
RTR versus deadlines
(b)
RTR versus deadlines
(c)
RTR versus length of delivery pathThe third group of experiments is to investigate the performance of PDBPD protocol. The comparisons between Normal Method and PDBPD protocol are carried out. The main idea of Normal Method is that a data packet is dropped after a predefined number of retransmissions, where the retransmission threshold is the result by implementing GAORT. As shown in Figures4(a) and 4(b), PDBPD protocol achieves higher deadline success ratio than that of Normal Method, when the probability of transmission failure, p
i, follows normal distribution N
[
0.6,0.2
]. For example, the DSRs of PDBPD protocol and Normal Method are 80
% and 73
%, respectively, when the deadline is 0.12 s and the length of delivery path is 10. Figure 4(c) demonstrates the comparison of DSRs, when the probability of transmission failure follows uniform distribution U
[
0.3,0.6
]. Experimental results show that PDBPD protocol can avoid dropping the packets, which are forwarded to the destination before given deadlines with high probabilities.Figure 4
Performance of(
α
,
β
)-probabilistic delay bound based packet dropped protocol.
(a)
DSR versus deadlines
(b)
DSR versus length of delivery path
(c)
DSR versus deadlines


## 6. Conclusion

As one of the promising, high-value applications for CPS, deployments of large-scale WSNs have potential to shed light on a variety of monitoring purposes. Many time-sensitive applications impose high requirement on real-time response. There exist many algorithms and routing protocols for efficient data packet delivery. However, previous works set the same retransmission threshold for all the relay nodes along a delivery path. The method decreases the probability of a packet being transmitted through the delivery path within given deadline. In this paper, we focus on finding the optimal retransmission thresholds for the relay nodes, such that the summation of the probability of a packet being transmitted to the next relay node or destination node within the specified deadline is maximized. A distributed greedy algorithm that can be run on sensor node is proposed, which enables the sensor node to adaptively set the optimal retransmission threshold. To avoid dropping the packet forwarded to the destination within given deadline with high probability, we develop an(
α
,
β
)-probabilistic delay bound based packet dropped protocol. Experimental results show that the proposed protocols have better performance.



---

*Source: 271259-2015-09-01.xml*