## 3 Improved Grey Wolf Optimizer Algorithm to Optimize Support Vector Machine
### Improved GWO Algorithm  
In catching the target, the value of coefficient vector \(A\) changes with the constant change of convergence factor \(a\). When \(\mid A\mid\leq 1\), the wolves will begin to concentrate on capturing the target. When \(\mid A\mid>1\), the grey wolf abandons the target and starts to find the next best solution. This is the local optimum solution [47]. Therefore, in the optimization process's late stage, the GWO algorithm easily falls into the local optimum solution and slows down the optimization process [48]. In order to solve the problem that the algorithm is easy to fall into local optimization in the later stage, this paper proposes the improvement of the GWO algorithm through the use of the DE algorithm. The GWO algorithm is prompted to jump out of local optimization using mutation, crossover, and selection in the DE algorithm. Furthermore, the excellent searchability of the DE algorithm can also promote the convergence speed and optimization accuracy of the GWO algorithm. The variation mode of the DE algorithm is:  
\[v_{i,G+1}=x_{\gamma 1,G}+F(x_{\gamma 2,G}-x_{\gamma 3,G}) \tag{22}\]  
where \(v_{i,G+1}\) is the variant gray wolf individual generated by the \(G\)-th iteration, \(\gamma_{1}\), \(\gamma_{2}\), and \(\gamma_{3}\) are completely different random individuals, \(x_{\tau 1,G}\) is the corresponding individual value, \(x_{\tau 2,G}\) and \(x_{\gamma 3,G}\) have the same meaning, and \(F\) represents the scaling factor. There is a crossover model. \[u_{i,G+1}=\left\{ \begin{array}{l}v_{i,G+1}\;rand(0,1)\leq P_{CR}\\ x_{i,G+1}\;\text{rand}(0,1)\leq P_{CR}\\ \end{array} \right. \tag{23}\]  
where \(u_{i,G+1}\) is the new variant generated by the \(G\)-th iteration crossover, and \(P_{CR}\) is the crossover probability factor. Finally, it uses the greedy criterion to select the individuals of the grey wolf variation. Meanwhile, this paper proposes a nonlinear convergence factor \(a^{\prime}\) to handle the premature problem of the GWO algorithm caused by the linear decrease in convergence factor \(a\). \[a^{\prime}=2\sqrt{1-\left(\frac{t}{Iter_{\max}}\right)^{3}} \tag{24}\]  
Furthermore, it establishes the exponential convergence factor \(a_{1}\), the cosine convergence factor \(a_{2}\), and the logarithmic convergence factor \(a_{3}\), as shown in Formula (25). \[\left\{ \begin{array}{l}a_{1}=2-2\Big{(}2^{\frac{t}{Iter_{\max}}}-1\Big{)}\\ a_{2}=2\cos\Big{(}\frac{\pi t}{2 Iter_{\max}}\Big{)}\\ a_{3}=\frac{2}{\lg^{2}}\times\lg\Big{(}2-\Big{(}\frac{t}{Iter_{\max}}\Big{)} ^{2}\Big{)}\end{array} \right. \tag{25}\]  
The trend comparison of five convergence factors is obtained, as drawn in Figure 1.  
Figure 1 demonstrates that, compared with the linear convergence factor of the traditional GWO algorithm, the other four convergence factors show the convergence trend of the convex function. In the early iteration, the time of the nonlinear convergence factor that is greater than \(1\) is significantly more than other convergence factors, which helps to enrich the diversity of the grey wolf population and improves the algorithm's global searchability. At the end of the iteration, the nonlinear convergence factor decreases in an obvious manner, which accelerates the convergence speed of the algorithm. This paper applies the IGWO algorithm to optimize the SVM parameters. The primary process of optimization is as follows. 1. Set the initial scale and related parameters of the IGWO algorithm, and initialize the parameters of the SVM model \([c,g]\). 2. Randomly initialize the parent, mutation, and offspring gray wolf populations, and determine the \(\alpha\), \(\beta\) and \(\delta\) wolves in the parent grey wolf population. 3. Update the parent population, generate mutations and offspring grey wolf populations, and perform crossover operations. 4. Compare the fitness value of the parent population and the offspring variant population. If the offspring population is preferable, replace the parent population fitness value and update the parent population.