## 3 RAR: Reliability-Aware Routing
### Determination of Neighbors and Their Information  
Nodes' deployment follows broadcasting of a hello packet by every sensor node. Initially, a hello packet comprises of the unique ID of the broadcasting node and its depth value. The depth value is known to every node using pressure sensor. After broadcasting the hello packet, every node waits for a preset particular interval of time to hear in response from its neighbors. This waiting interval is double of the time in which the hello packet reaches the farthest neighbor node from the broadcasting node plus the processing delay of the broadcasting node and its receiving neighbor. The double of the time from the broadcasting node to its farthest neighbor signifies the time of the two-way journey from the broadcasting node to the farthest neighbor and the corresponding reply the broadcasting node receives. Since all nodes have almost the same design parameters at the manufacturing level, the processing delay is assumed to be the same for all nodes. When a reply is not received within the predefined threshold time, the hello packet is broadcasted by the node again. It declares no neighbor when it does not receive any response even after it broadcasts the hello packet for the maximum number of times. When a neighbor of the broadcasting node receives the hello packet, the node's ID and depth values are inserted in the hello packet by the node, which is then broadcasted. The original broadcasting node receives this information. This process is repeated by every neighbor node. In this way, every node receives the vital information about its neighbors and knows its number of neighbors. After knowing the number of its neighbors, a hello packet is broadcasted again by every node. This time the hello packet consists of the unique ID, depth and the neighbor count of the node that broadcasts it. When this packet is received by a neighbor node of the broadcasting node, it rebroadcasts the hello packet after inserting its own ID, depth and neighbor count. This process is repeated by every node. This leads to sharing of IDs, depth and neighbors information even among the sensor nodes that are not one-hop neighbors. Instead, such information is shared even among the multi-hop neighbors. This process is elaborated in Figure 2.  
In Figure 2, a hello packet is broadcasted by node 1 comprising of its ID, depth and number of neighbor count denoted by \((1,100,7)\), respectively. This hello packet is different from the hello packet initially broadcasted by the sensor nodes just after deployment that contained broadcasting node's ID and its depth. The hello packet broadcasted by node 1 is received by node 2 through the node A that acts as a relay node between node 1 and node 2. Node 2 adds its own information to the hello packet it receives from node 1 and broadcasts the extended hello packet. The extended hello packet now contains information about node 1 and node 2 as denoted by \((1,100,7)\) and \((2,225,4)\), respectively. Finally, node 3 receives the extended hello packet through the relay node B, inserts its own information and broadcasts it in the form \((1,100,7)(2,225,4)(3,350,2)\). In this way, node 3 gets the vital information about its two-hops neighbor (node 1), in addition to its one-hop neighbor (node  
Figure 1: Network model. 2). In a similar fashion, node 1 also gets vital information about node 3, which is not shown in Figure 2 for simplicity. Every node performs this process and, in effect, every node gets information about the depth, IDs and neighbor count of its one- and multi-hop neighbors. This information is very critical in building reliable trajectories towards the water surface, as explained later. To overcome redundant data transfer within a hello packet, every node uses a history buffer. As soon as a node gets a hello packet from a neighbor, it extracts the information about the ID, depth and neighbor count of the neighbor and saves it in a history buffer.