# Game theory-based Routing for Wireless Sensor Networks: A Comparative Survey
## 3 Game Theory-Based Routing Protocols in WSNs
### Routing Protocol Based on Reputation-Based Game  
#### 3.4.1 Game Theory-Based Routing Algorithm (GBRA) Based on Reputation  
Typical WSNs consist of resource-limited (processing power, energy, memory, bandwidth, etc.) sensor nodes. Energy is wasted more when the malicious nodes deliberately drop the data packets forwarded to them. This kind of phenomenon is known as selective forwarding attack. This type of security problem results in more challenges while designing an energy-efficient routing protocol for WSNs. Keeping this in mind, [PERSON] et al. designed a game theory-based routing approach (GBRA) [43] using a reputation-based game in which sensor nodes were modeled as rational and intelligent agents that could cooperate with each other for increasing their pay-offs in a sensor game. In this routing protocol, each hop is a game between a sender and the next hop relay node. Both nodes would attempt to increase their own pay-offs owing to the selfish nature of the designed game. The pay-off function of the sensor node was designed on the basis of the competing node's reputation, remaining energy, and distance between the competing node and the destination. The pay-off function of the relay node was designed based on the proportion of the sender's reputation. The sender selects the relay nodes that could maximize its pay-off. Conversely, relay nodes are supposed to help only those sensor nodes that have a higher reputation. Using a watchdog mechanism, every single node monitors the behavior of the neighbors and evaluates their reputation. The detailed steps of the designed routing protocol are given below:  
1. When there is a packet to send and the destination was within the communication range, the sender sends a _ROUTE REQUEST_ message to its neighbors;
2. After certain nodes have received the _ROUTE REQUEST_ message, there could be two scenarios. In the first scenario, a node receiving the _ROUTE REQUEST_ message is itself the destination or knows the destination. In this case, step 5 is followed. In the second scenario, each node getting the _ROUTE REQUEST_ message checks its remaining energy \(E_{rem}\). If \(E_{rem}\) was less than \(E_{c}\), the energy cost of the data transmission, the node would not transmit the data packet to save its energy. The node calculates its pay-off only when \(E_{rem}\geq E_{c}\). If the value obtained through this calculation is greater than zero, the node sends an acknowledgement (ACK) to the sending node and acts as a relay node. 3. After receiving back the ACKs from the receiving nodes, the sender node selects one among them (receiving nodes) that could maximize the sender's pay-off to the greatest extent. Next, the sender sends a _REPLY_ message to the chosen relay node. 4. When the _REPLY_ messages reach the relay node, a new game starts between the relay node and its next hop. The new sender attaches its ID in the source route and again forwards the _ROUTE REQUEST_ message to its neighbors. Step 2 is repeated until a route is found. 5. If the receiving node is the destination node or at least has a route to the destination, the node does not forward the packet. Rather, it replies to the sending node with the full route in a reverse order. 6. Finally, when the message reaches the destination, the deduced routing path is selected. In GBRA, the reputation of a node is determined based on the cooperativeness of a node. The value of reputation (\(R_{ij}\)) is fixed between 0 and 1.