Research Article
Node-Dependence-Based Dynamic Incentive Algorithm in Opportunistic Networks
Algorithm 1
The Node-dependence-based dynamic gaming incentive algorithm.
(1) Initialize the parameters in Table 1 and the weight coefficient when nodes encounter | at the first time, and Calculate NAC, NIC, and NDD. | (2) Node asks node for relaying a packet, and waits for ’s response. | (3) if rejects | (4) if == false | (5) ← + 1 |
(6) end if | (7) if == false and ≥ | (8) ← true | (9) ← | (10) end if | (11) else | (12) if == true | (13) ← | (14) if ⩽ | (15) ← false | (16) end if | (17) end if | (18) if is not punished for a time period | (19) ← | (20) end if | (21) end if |
|