# Robust and Secure Data Transmission Using Artificial Intelligence Techniques in Ad-Hoc Networks
## 4 Proposed Work
### Artificial Bee Colony (ABC)  
In this research, ABC is used for obtaining the best or most optimized node properties of the created route using the AODV protocol. ABC is a swarm-based metaheuristic algorithm used to solve combinatorial optimization challenges. The intelligent foraging behavior of bees acts as the inspiration of this algorithm which is particularly based on the model due to its foraging behavior of honeybee colonies. The aim of the ABC algorithm (Algorithm 2) is to differentiate the sensors nodes based on their basic features like coordinates, required time, and energy to transmit or receive the data packets using the fitness function. Here, total sensor node properties act as employee bees rather than the comparing parameter which is known as the threshold and acts as an onlooker bee. Based on the fitness of the bee, the ABC algorithm helps to differentiate the sensor nodes into two possible categories, such as communicating and non-communicating nodes. The workflow of ABC is shown in Figure 6.  
To solve the complex problems in different domains, the foraging behavior of honeybees is considered. To establish communication between the bees, a waggle dance is required. That is composed of three pieces of information regarding the flower patch: (a) the direction in which it can go, (b) distance from the hive, and (c) its quality rating. To collect the knowledge of the outside environment separately, information is gathered through the waggle dance [32]. This dance enables the colony to compute the relative merit of multiple patches based on food quality as well as the energy amount to harvest it. The observer nodes observe the dance (energy consumed, delay, etc.) and based on that extract the food (apt node). The location of each food source (source and destination node) represents the optimized solution related to the problem. The working flow of ABC is shown in Figure 6.  
ABC is mainly composed of three kinds of bees: onlooker, forger, and scout bees. The onlooker bee's role is to select a food source by just watching the waggle dance of the other bees. The role of forger bees is to constantly visit the food source to obtain nectar. Scout bees are those who conduct random searches to discover new sources of food [33]. The pictorial representation of the bees' searching process of food is illustrated in Figure 7.  
Figure 5: New user connection request using AODV. The main steps that are followed by ABC are listed below. 1. Initialize food sources as population size. 2. REPEAT: 1. Employed bees visit food sources and assess the amount of nectar based on their memories, and then return to the hive to perform a waggle dance at that location. 2. After the food source is exhausted, the onlooker bees start to randomly look for new food sources and memorize the best food source. 3. The process is repeated until the best food source is obtained. Figure 6: Working flow of ABC. Figure 7: Scouting mechanism of ABC. Every time ABC visits a node (that is, the network topology or several nodes themselves), it computes the energy, delay, and packet drop rate. ABC includes an initialization process along with a search cycle process, iterating through the main search cycle until it finds the best suitable solution for the communicating node. After the arrival of the on-looker bees, the algorithm will strictly check to identify the source routing and the number of nodes present in the route performed by the AODV routing mechanism. If there is no source route, it will broadcast the packet and rescan the nodes' properties to crosscheck whether it is used to transmit outgoing energy or incoming broadcast packets [34]. ABC with the AODV algorithm enhanced the routing process by selecting the best route between the source node and the destination node. The role of the scout bee is to measure the energy as well as the distance from one node to another node. The higher the distance is, the higher the transmission delay is which results in greater energy loss. ```
1.