## 3 Proposed Mix Optimizer
### The Proposed HFAJAYA Optimization Algorithm  
As mentioned above, in engineering, we encounter a diversity of complex problems. One of the effective ways to reach a range of acceptable solutions for these problems is to use a combination of two algorithms with different structures and functions [23].  
Therefore, in this paper, we used a combination of two powerful and well-known algorithms, FA and JAYA, to achieve an optimal solution to our desired engineering problem, such as the optimal power flow. This method is shown in Figure 2. In the first modification, only the members with a better fitness merit than the \(i\)th member (e.g., \(j\)th member) can affect its movement. This can speed up the algorithm convergence rate and provide more opportunities to search. In the second modification, two ranges are defined regarding the objective function of the \(i\)th member and other members (e.g., \(j\)th member). In other words, if \(F\left(x_{j}^{t}\right)\leq 0.9*F\left(x_{i}^{t}\right)\), then the \(j\)th member is directed to the FA algorithm; otherwise, the \(j\)th member is directed to the JAYA algorithm. When the objective function value of the \(j\)th member is very close to the objective function of the \(i\)th member, i.e., \(\left(x_{j}-x_{i}\right)\) tends to zero in the FA algorithm. The optimization process is assigned to the JAYA algorithm, which can help avoid trapping in the local optimum.  
In FA, three popular test functions were designated. The optimization process was performed in two modes: dimension 30 with a population of 25 and a maximum value of iteration 400 and dimension 100 with a population of 75 and a maximum value of iteration 1200. For each function, 30 independent runs were carried out by each algorithm. The simulation results for FA and HFAJAYA are given in Table 1, showing that HFAJAYA is a more robust and more suitable algorithm than the original one. The convergence characteristics of the algorithms for the test functions 1 and 2 are also given in Figure 3. The suggested approach had a reasonable and operative convergence speed.  
\begin{table}
\begin{tabular}{c c c c c c} \hline \hline  & & & \multicolumn{2}{c}{\(D\) = 30} & \multicolumn{2}{c}{\(D\) = 100} \\ \cline{3-6} \multirow{2}{*}{\begin{tabular}{c} **Function** \\ **Limits** \\ \end{tabular} } & \multirow{2}{*}{\begin{tabular}{c} **Mathematical Model** \\ **Property** \\ \end{tabular} } & **FA** & **HFAJAYA** & **FA** & **HFAJAYA** \\ \cline{3-6}  & & & **Mean** & **Mean** & **Mean** & **Mean** \\  & & & **Best** & **Best** & **Best** \\  & & & **Std** & **Std** & **Std** \\ \hline \multirow{3}{*}{\begin{tabular}{c} Rosenbrock \\ \([-32,32]\) \\ \end{tabular} } & \multicolumn{2}{c}{\(f_{1}=\)} & & & & \\ \cline{3-6}  & \(\sum\limits_{i=1}^{D-1}\left(100(x_{i}^{2}-x_{i+1})^{2}+(x_{i}-1)^{2}\right)\) & 56.7494 & **45.246** & 26.3190 & **17.8910** \\  & & 23.2999 & **0.1357** & 23.8039 & **15.8155** \\  & & 81.0251 & **29.1884** & 10.8648 & **1.1293** \\ \hline \multirow{3}{*}{\
\begin{tabular}{c} Sphere \\ \([-100,100]\) \\ \end{tabular} } & \(f_{2}=\sum\limits_{i=1}^{D}x_{i}^{2}\) & \(2.7196\times 10^{-6}\) & \(\textbf{4.3637}\times\textbf{10}^{-15}\) & \(1.4702\times 10^{-19}\) & \(2.6648\times 10^{-20}\) \\  & & \(1.9314\times 10^{-6}\) & \(\textbf{7.3028}\times\textbf{10}^{-17}\) & \(1.3292\times 10^{-19}\) & \(5.9287\times 10^{-21}\) \\  & & Unimodal & \(3.5034\times 10^{-7}\) & \(\textbf{8.5226}\times\textbf{10}^{-15}\) & \(8.1340\times 10^{-21}\) & \(2.0183\times 10^{-20}\) \\ \hline \multirow{3}{*}{
\begin{tabular}{c} Rastigrn’s \\ \([-5.12,512]\) \\ \end{tabular} } & \(f_{3}=\sum\limits_{i=1}^{D}\left(x_{i}^{2}-10\cos(2\pi x_{i})+10\right)\) & **20.5293** & 43.5562 & 34.9728 & **30.8437** \\  & & 6.9647 & **4.0738** & 19.8992 & **17.8841** \\ \cline{1-1}  & & Multimodal & **6.0745** & 13.5772 & 11.8223 & **8.2046** \\ \hline \hline \end{tabular}
\end{table}
Table 1: Optimization results for three selected popular functions by the algorithms.  
Figure 2: The optimization process of the HFAJAYA optimizer.