# ARNS: Adaptive Relay-Node Selection Method for Message Broadcasting in the Internet of Vehicles
## 4 Method Design
### Adaptive Relay-Node Selection Method  
In this subsection, we design an adaptive relay-node selection method based on the criterion of road structures, combining the relay-node selection method in curved road scenarios with obstacles proposed in Section 4.1 and an improved EPBP-based junction relay-node selection method in this subsection.  
The termination condition of message broadcasting is to achieve complete coverage of RoI. That is, all ends of the roads at the RoI boundary are covered by the broadcasting message. Moreover, in order to avoid the multiple coverage of a message on one road section, the termination condition in junction scenarios is that the message covers the RoI boundary, or that the branch has been covered by the same message.  
The EPBP-based junction relay-node selection method [26] includes a junction phase and a branch phase. It is suitable for urban scenarios where each branch of junctions is a straight road. Two types of nodes are selected successively as relay-nodes in the junction phase and the branch phase, which are closest to the center point of the junction and to the farthest point in the branches. However, in the real world, the branch of the junction, e.g., Junction J\({}_{1}\) in Figure 1, may not be a straight road.  
Therefore, we improve the EPBP-based junction relay-node selection method as follows. In the branch phase, first, the sender of the branch phase, i.e., the relay-node at the center of the junction, uses GIS information and the criterion of road structures to determine the road structure of each branch when it enters the branch phase. Then, according to the judgment result, a method suitable for the structure of branch is selected to complete the relay-node selection in the branch phase.  
The flow diagram of the improved method is shown in Figure 2. The improved method realizes the adaptive relay-node selection in the branch phase. Compared with the original method [26], it has stronger robustness in real-world scenarios.  
The adaptive relay-node selection mechanism is shown in the flowchart in Figure 3. First, ARNS determine whether the broadcast completely covers RoI. If a full coverage of RoI is not achieved, the criterion of road structures is adopted to judge the road structure within the current communication scenario. If the road structure is judged as a junction scenario, we adopt the improved EPBP-based junction relay-node selection method to realize relay-node selection in the current scenario; if the judgment result is a curved road scenario, we use the method proposed in Section 4.1 to select a relay-node in the current scenario; if the judgment result is a straight road scenario, we directly adopt the intersection of the sender's communication boundary and road in the message propagation direction as the optimal position to implement straight road relay-node selection through EPBP. What is more, to ensure the security of message transmission, a caching optimization method [41] is used for each vehicle.  
Figure 2: Flow diagram of the improved exponent-based partitioning broadcast protocol (EPBP)-based junction relay-node selection.