## 3 Efficient Multi-Parent Hierarchical Routing Protocol
### Network Implementation under the MPH Protocol
If the environment affects the network behavior with less impact, the percentage of packet loss will vary between 1% and 2%. If the impact on the network performance is greater, the packet loss rate will vary between 2% and 5%. This percentage of packet loss will be reflected in the network delays and in the momentary connections and disconnections of nodes: it will therefore affect the number of hops. We took into account the average delay as a parameter to consider one or the other packet loss interval. Thus, we obtained a mean value of the delay for the ten day interval; for the days with delay above the mean, a packet loss in the interval (2%-5%) was used, whereas for those with delay below the mean, a packet loss in the interval [1%-2%] was used. Figures 4 and 5 show, respectively, the mean delay per packet averaged over a day for the selected relay and source nodes, considering a monitoring time of each node every 30 s in a day, approximately. The continuous lines show the performance of the real network described before, whereas the dotted lines show the simulated network using the C++ simulator constructed by us. Here, we can see that the delay depends on the channel conditions, and not every day had the same environmental conditions. Another important metric that clearly shows the connections and disconnections of the nodes during the operation of the network is the number of hops, also called hop count. Figures 6 and 7 show the mean number of hops per packet averaged over a day for each of the nodes (source and relay, respectively) that were chosen as examples. The number of hops will directly impact the packet delivery delay, because if a node is disconnected, the packet route will change, perhaps making it slightly longer and requiring more time to reach the coordinator node. Both metrics, the number of hops and delay, also affect the energy consumption, because the more the node disconnects, the more the number of hops to the destination and the greater the packet delay. Here, we observe that the simulated network has a behavior very close to the real network. Therefore, the physical layer parameters assumed, from one day that extreme environmental conditions took place, reflect quite well the behavior of the network. The coordinator node is a robust node, with more processing resources than the other nodes. Consequently, this node has the ability to process all of the statistical information collected from the network nodes. The coordinator has a source routing mechanism [13] to request information from the nodes. This information can be statistical processes, neighbor tables, sensing measurements and all of the features that the coordinator node needs to know to be aware of the nodes that form the network topology. When the coordinator needs to communicate with a network node, it sends a packet to that node, and this is called a \"try\". The mean number of tries is a metric that reflects the number of times that the coordinator attempts to connect to a node before an ACK is received. Figures 8 and 9 show the average number of tries per packet averaged over a day for 10 nodes chosen as the example. Figures 8 and 9 show that the source routing mechanism programmed into the simulator is quite similar and has a performance comparable to the mechanism of the real network. We see that the simulator displays a trend close to the behavior of each node in the network, which shows that we have a reliable computational approach with respect to a network in a real-life environment. We confirm this statement by calculating the mean relative error of the measurements obtained by the simulation with respect to the measurements given by the real network. For the delay, the simulator has an error of 2.97%; for the number of hops, the simulator has a 0.87% error; and for the number of tries, the simulator has an error of 1.08%.