## 4 DMRF Protocol
### Network Congestion Detection Method
Figure 4: Jumping probability adjustment and message feedback. Meanwhile, node \(i\) will send a feedback message to its upstream node. Once receiving the feedback message, the upstream node will also adjust the jumping probability and the feedback message is forwarded hop by hop to the data source node. (2) Jumping probability adjustment of the upstream node

When the upstream node \(i-1\) receives a feedback message from node \(i\), it re-calculates the successful ratio from node \(i-1\) to node \(t\) as \(Suc_{t}=Suc_{t}-t\), where \(\tau\) is a random factor satisfying \(0\leq\tau\leq Suc_{t}\). The jumping probability from node \(i-1\) to node \(t\) can be recalculated using Equation (1). #### 4.4.2 Path Selection

To guarantee reliable transmission, in the initialization phase of the DMRF protocol, \(M\) non-overlapping paths from the source to the sink node are established. For each path, each node sends packets to the destination node and calculates the RTT (Round Trip Time) to record the time delay and the distance between the source node and the destination node. By using the heuristic method, \(k\) paths from the \(M\) paths are chosen to transmit packets. The paths that are not chosen will be used as alternative paths when necessary. In the process of transmission, when the node receives a data packet, the node will choose the next hop node according to the deadline of the received packet, the transmission delay of the current path, the jumping probability and the congestion level. Let \(T_{minDelay}\) denote the minimum transmission delay from the current node to the destination node. We denote the remaining transmission time factor of the data packet as \(\lambda=T_{minDelay}/L\). The choice of the next hop node depends on \(\lambda\), \(\theta_{low}\) (the lower bound of the remaining transmission time), and \(\theta_{high}\) (the upper bound of the remaining transmission time). The algorithm is illustrated in **Algorithm 4**. ```
Data: FCS Result: Choose the next hop node and the transmitting mode. 1 IF the state of node is JFAULTY or VOID or JCONG THEN Utilize the jumping mode. 3 IF\(\lambda\geq\theta_{low}\) THEN
4 Select the node with the maximum delay and minimum transmission times. Set the packet state as LOW. 5 IF\(\theta_{low}>\lambda\geq\theta_{high}\) THEN
6 Select the node with the maximum delay and minimum transmission times. Set the packet state as MEDIUM. 7 IF\(\theta_{high}>\lambda>\theta_{jump}\) THEN
8 Select the node with the maximum delay and minimum transmission times. Set the packet state as HIGH. 9 IF\(\lambda\leq\theta_{jump}\) THEN Utilize the jumping mode. ```

**Algorithm 4** Selecting the transmission node and transmission mode

The packet states LOW, MEDIUM, and HIGH indicating the three kinds of data packet transmission rates, _i.e._, low, medium, and high, respectively. In case \(\lambda\) is less than threshold \(\theta_{jump}\), the remaining transmission time of the data packet is nearly the same as the transmission delay between the current node and the destination. If the transmission delay in subsequent transmission is too long, the data packet may not be sent to the destination node within the specified time. In this case, the transmission mode is converted to jumping transmission mode. As for other cases (_i.e._, \(\lambda\geq\theta_{low}\), \(\theta_{low}>\lambda\geq\theta_{high}\) and \(\theta_{high}>\lambda>\theta_{jump}\)), the algorithm will adjust the package transmission rate to alleviate the congestion and select reasonably the next hop node with the minimum times of transmission and balance the nodes' energy consumption, thus prolonging the network life time. Each node calculates \(\theta_{low}\) and \(\theta_{high}\) according to local information and the data packet information, without need to consider the changes in the entire network. The calculation methods of \(\theta_{low}\) and \(\theta_{high}\) are given in the Subsection 4.4.3. #### 4.4.3 Calculation of \(\theta_{low}\) and \(\theta_{high}\)

Suppose \(P\) nodes are deployed in the path.