# An Improved Machine Learning Model with Hybrid Technique in VANET for Robust Communication
## 5 Simulated Steps for Proposed Methodology
### Phase: 1--Security-Based Modified SVM
#### 5.2.2 Selection of Optimal Kernel Based on Harris Hawks Optimization (HHO)  
HHO is defined by a meta-heuristic technique based on a natural population. Harris hawks cooperative hunting behavior is for prey such as rabbits. Exploration, transformation, and exploitation are the three steps included in the HHO optimization technique. * Initialization Phase  
The initial hawk population initializes the solution for this phase. The number of nearest vehicles (\(n_{1},\ n_{2},\ \ldots,\ n_{N}\)) encompasses the population. Here, the number of populations are denoted as \(N\). The execution of the technique was done by cluster vehicle (\(n_{cl}\)). The cluster and nearby vehicles are denoted as \"hawks\", whereas the destination vehicle is referred to as prey (rabbit). For all cars, the fitness function was determined in this phase. The fitness of \(j\)th vehicle was calculated as follows,  
\[f(n_{j})=\{\sum D,\ M,\ \delta,\ K\} \tag{9}\]  
Here, the fitness function is developed as mobility (\(M\)), direction (\(D\)), vehicle state (\(\delta\)), and availability of spectrum (\(K\)). Binary values '0' and '1' are described as vehicles' direction. The fitness of the vehicle is enhanced if target and cluster vehicles are in the same direction, so that \(D=1\) or 0. Furthermore, to enrich the computation fitness, the mobility will be mapped as 0 and 1. When \(M=0\) or 1, mobility of \(n_{j}\) is higher than average mobility. For data transmission \(K=0\) or 1, if \(n_{j}\) has an available channel. The function of evaluation metrics is represented as follows:  
\[\delta=\frac{P+DR}{D} \tag{10}\]  
The throughput function of \(\delta\) is \(n_{j}\) (\(P\)) for \(n_{j}\), delay (\(D\)), and data rate (\(DR\)). For data transmission, the optimal path can be achieved by the deciding factor \(\delta\) of computation fitness with effective channel estimation. In the population, for all vehicles, \(f(n_{j})\) was computed. Exploration, transformation, and exploitation are the three phases of HHO. These three phases are described as follows:  
* Exploration Phase  
During this phase, the process of waiting, searching, and detecting prey is carried out. The following is an example of a hawk's position: The \(V\) represents the current iteration and \(V+1\) represents the next iteration. Hawks can be found at the locations \(\gamma_{1}\),\(\gamma_{2}\), \(\gamma_{3}\), and \(\gamma_{4}\), with the range [0, 1] expressing the random integer \(y\). \(n_{j_{a}}\) is the average location of the hawk. \[n_{j}\ (V+1)=\Big{\{}n_{j_{rand}}(V)-\gamma_{1}\left|n_{j_{rand}}(V)-2\ n_{j} \gamma_{2}(V)\right|\ if\ m\ \geq 0.5n_{j_{a}}\ (V)n_{j_{a}}\ (V)-\gamma_{3}\left(l_{1}+\gamma_{4}(v_{b}-l_{1}) \right)\ if\ m<0.5 \tag{11}\]  
\[n_{j_{a}}\ (V)=\ \frac{1}{N}\sum_{i=1}^{N}n_{j}(V) \tag{12}\]  
* Transformation Phase  
In the exploitation phase, the exploration phase is transformed into the exploitation phase. The energy of the prey degrades from the evading behaviour. Equation (17) defined the transformation phase. \[\omega_{prey}=2\omega_{0}\ (1-\frac{V}{V_{max}}) \tag{13}\]  
where \(\omega_{0}\) shows the initial energy state of prey, \(V\) represents the current iteration numbers, and \(V_{max}\) represents the maximum number of iterations. * Phase of ExploitationThe hawk's attack in the previous step serves as a barometer for the quality of the picked prey. In this stage, we tested four distinct approaches: soft besiege, hard besiege, soft besiege with advancing fast dives, and hard besiege with advanced rapid dives. The occurrence of hard and soft relies on the energy level, where \(\left|\omega_{prey}\right|\geq 0.5\) and \(\left|\omega_{prey}\right|<0.5\), respectively. Attack on a Soft Target:  
The attack on a soft target known as a soft besiege and this method may be chosen if \(\left|\omega_{prey}\right|\geq 0.5\) and \(\gamma\geq 0.5\).