# Game-Theory-Based Multimode Routing Protocol for Internet of Things
## 3 Proposed Mechanism
### Architecture and Functions of Smart Nodes
#### 3.4.2 Algorithms
As a result, smart nodes experience minimal energy loss, resulting in superior average remaining energy values. \begin{table}
\begin{tabular}{l c c c} \hline \hline \multicolumn{4}{c}{**Parameters of Nodes**} \\ \hline Type of Nodes & DSDV & AODV & Smart \\ Color of Nodes & Blue & Green & Red \\  & 35 & 35 & 30 \\ Number of Nodes & (0–34) & (35–69) & (70–99) \\ Source nodes & 0, 1 & 35, 36 & - \\ Destination node & 34 & 69 & - \\ Locations & Random & Random & Random \\ \hline \hline \end{tabular}
\end{table} 
Table 10: Case 2: Parameters for classes of nodes. Figure 12: Case scenario 2: Random placement of heterogeneous nodes. ### Case 3: Proactive Nodes Are Deployed in an L Pattern

In this example, we assume that all of the nodes of a particular class are clustered together in an L shape. The DSDV nodes are considered in this case. A similar instance was described in the previous section. If we do not use the smart nodes, the route entails all of the nodes of DSDV class, which is a lengthier route. The reactive AODV nodes can also be used by incorporating the smart nodes, and a diagonal route can be constructed, minimizing the number of intermediate nodes. Figure 13 depicts the screenshot for case 3. Table 11 shows the parameters used in this case scenario. \begin{table}
\begin{tabular}{l c c c} \hline \hline \multicolumn{4}{c}{**Parameters of Nodes**} \\ \hline Type of Nodes & DSDV & AODV & Smart \\ Color of Nodes & Blue & Green & Red \\ Number of Nodes & 20 & 20 & 20 \\  & (0–19) & (20–39) & (40–59) \\ Source node & 9 & - & - \\ Destination node & 19 & - & - \\ Locations & Fixed (L Form) & Random & Random \\ \hline \hline \end{tabular}
\end{table} 
Table 11: Case 3: Parameters for classes of nodes. Figure 13: Case scenario 3: NS2 NetAnim Screenshot. The results for case 3 are shown in Figure 14. With a smart node-based network, the results for PDR, delays, and throughput are better. This is because of the establishment of a shorter route. However, the remaining energy is quite comparable. Because the non-proactive nodes are not employing their energies, less energy is spent without smart nodes. If we simply consider the values of DSDV nodes, the ratio of remaining energy in the absence of smart nodes will be significantly greater. Because the AODV routing burden is taken into account, the throughput of the smart node-based network is high. The AODV nodes were not involved in routing in the absence of smart nodes and so there was minimal routing overhead. The proposed protocol, identified as GMRP in the simulation results, has been compared with AODV and ZRP for further evaluation. A network of 100 nodes with an area of 1500 ms\({}^{2}\) was taken. The nodes were programmed with AODV, ZRP and GMRP respectively and results were recorded for 200 pause times. The performance of the protocols in terms of PDR, average energy consumption, and end-to-end latency were accessed. Figures 15-17 show the results. We can infer from the results that GMRP is a highly adaptive protocol that reacts to time. The nodes tend to alter their routing behavior as time progresses. This is because the nodes consume their energy with the passage of time. Figure 14: Case scenario 3: Proactive nodes are deployed in an L pattern. The performance of GMRP is comparable to AODV in terms of energy consumption and PDR. The smart nodes choose to adopt the reactive routing behavior since they initially have greater energies. The performance steadily declines after pause time 100 as a result of the change to proactive routing behavior. In case of end-to-end delays, the protocol performance is similar to AODV in the beginning but improves later. This is also due to the change of routing behavior from reactive to proactive. The nodes gradually start changing their routing protocol with the passage of time by looking into their remaining energies. Figure 16: End-to-end delays (milliseconds). Figure 15: Packet delivery ratio (No. of packets received/No. of packets sent).