# Ocean-Current-Motion-Model-Based Routing Protocol for Void-Avoided UASNs
## 4 OCMR Protocol
### Void Avoided Strategy  
If a routing void appears during data transmission, data packets cannot be forwarded effectively, resulting in energy consumption and reduced data transmission efficiency. Therefore, a void avoided strategy is proposed in the OCMR protocol to avoid the routing void. When the relay node shift happens due to ocean currents in the original route, which cause a routing void, a new relay node could be selected in the candidate forwarding set and a new route will be rapidly rebuilt. The nodes obtain information regarding residual energy, current velocity, etc., from the physical layer on initialization. Then, the relay nodes broadcast the packets to surrounding nodes to obtain information regarding their neighbors. Each node has its own local neighbor table to store the information on neighboring nodes to make routing decisions, for example, packet ID, fitness value, velocity, data, etc. Each node can exchange information with other nodes in the network either as single-hop or multi-hop transfer. The node needs to establish the communication link with the next forwarder via a handshake at first. If the node receives the CTS for the RTS, this indicates a successful handshake between the sender and receiver and the link is reliable. The source node marks the packet ID of each node once the data from this node is received, and preference is given to the relay node in the next data forwarding. During the construction phase, the set is constructed based on the node as the center and \(d_{e}\) as the radius, after the forwarding link is available for the first time. The transmitting power of the node is adjusted based on \(d_{e}\) in the search coverage to ensure that all nodes can communicate with each other by broadcasting within this protection radius. The interval of broadcasting is \(\omega T_{inter}\), where \(\omega\) is the time factor, and the \(T_{inter}\) is calculated by  
\[T_{inter}=\frac{d_{e}}{V_{Acoustic}} \tag{33}\]  
where \(V_{Acoustic}\) represents the propagation velocity of sound in water. The forwarder communicates with all nodes within the communication radius and calculates the fitness value between each node and the forwarder based on the node information. The node with the minimum fitness value can be chosen as the alternative relay node for the forwarder. The fitness value is stored in the routing table of the forwarder and is sent back to the source node during the next data transmission. After receiving the ACK message sent by the forwarder, the source node records the information of the alternate relay node. If a routing void is generated when the forwarder drifts outside the communication radius, caused by the ocean currents, the source node changes the destination node to an alternative relay node to rapidly form a new route. Taking Figure 7a as an example to illustrate this, an initial communication link is established between source node S and node A after initialization, and A is acquiescently regarded as the optimal forwarder of the next hop during data transmission. After a handshake takes place between S and A, the search coverage with radius \(d_{e}\) and the virtual cone are created. A exchanges information with nodes n1, n2, n3, and n4 in a circle at an interval of \(\omega T_{inter}\), and the corresponding fitness value is calculated between n1, n2, n3, and n4, respectively. The fitness value between A and n2 is minimally calculated. So, A saves the information of n2 to its routing table and sends the information back to S via ACK during the next data transmission. No matter which alternative node is chosen, A will always be the forwarder if it is in the search coverage. After a period of time, node B outside the area drifted into the area and became node B\({}^{\prime}\). A exchanges the information with other nodes in the area once again and calculates the corresponding fitness value of each node. The result shows that the fitness value between A and B\({}^{\prime}\) is minimum.