# An Easily Understandable Grey Wolf Optimizer and Its Application to Fuzzy Controller Tuning
## 4 Case Study  
Both GWO and the tuning approach are validated in this section by the design and tuning of T-S PI-FCs for the angular position control of an experimental setup [58]. The experimental setup operates in the Intelligent Control Systems Laboratory of the Politehnica University of Timisoara, Romania. The nominal values of the parameters of the process models of Equations (1) and (2) have been obtained by least squares identification algorithms as \(u_{a}=0.15\), \(u_{b}=1\), \(u_{c}=0.15\), \(k_{P0}=k_{EP0}=140\), and \(T_{\Sigma 0}=0.92\) s. The simulations were performed using the Matlab environment being run on several machines with various configurations, thus parallelizing the computations in order to reduce the execution time. The weighting parameters presented in Equation (13) have been defined to satisfy a ratio of \(\{0.1,1,10\}\) of the initial values of the terms presented in the sums. The following values have been used:  
\[ \begin{array}{l}\left(\gamma_{k_{P}}\right)^{2}\in\{0.006858,0.06858,0.6858\}, \\ \left(\gamma_{T_{\Sigma}}\right)^{2}\in\{0.0066695,0.066695,0.66695\}.\end{array}  \tag{53}\]  
The upper limit of the sums in Equation (13) has been set to \(t_{df}=2000\) instead of \(t_{df}\rightarrow\infty\), which corresponds to the evaluation of the objective functions by experiments conducted on a time horizon of 20 s. The vector variables \(\rho\) of the objective functions have been initialized and are then validated to belong to the feasible (search) domain \(D_{\rho}\)  
\[D_{\rho}=\{\beta|3\leq\beta\leq 17\}\times\{B_{e}|20\leq B_{e}\leq 40\}\times\{ \eta|0.25\leq\eta\leq 0.75\}. \tag{54}\]  
The dynamic regimes characterized by \(r=r_{0}=40\) rad step type modification applied to the reference input and disturbance input \(d=d_{0}=0\) have been used. The integral term in the T-S PI-FC structure carries out the disturbance rejection. The parameters of GWO have been defined based on the designers' experience and aim to achieve an acceptable balance between convergence and computational resources as \(N=20\) and \(k_{\max}=100\). The optimal controller parameters and the associated minimum objective function values of the two optimization problems defined in Equation (13) are presented in Tables 1 and 2. The quality of GWO is analyzed through three sets of performance indices that try to quantify the use of allocated resources and asses the search process. The first set of performance indexes used in the analysis of the solution quality is the average value of the objective functions \(J_{k_{P}}\) and \(J_{T_{\Sigma}}\) obtained by running several independent runs of GWO and are referred to as \(Avg(J_{k_{p}\min})\) and \(Avg(J_{T_{\Sigma}\min})\):  
\[Avg(J_{k_{p}\min})=(1/N_{best})\sum_{j=1}^{N_{best}}J_{k_{p}\min}{}^{(j)},\ Avg(J_{T_{\Sigma}\min})=(1/N_{best})\sum_{j=1}^{N_{ best}}J_{T_{\Sigma}\min}{}^{(j)}, \tag{55}\]  
where \(J_{k_{p}\min}\) and \(J_{T_{\Sigma}\min}\) are the values obtained by running GWO, \(N_{best}\) is the number of best values (i.e., the smallest values) obtained for the objective functions, and the superscript \(j,j=1...N_{best}\), indicates the values of the objective functions obtained by one of the best \(N_{best}\) runs of GWO, namely by the run \(j,j=1...N_{best}\). The value \(N_{best}=5\) is considered in the context of the current analysis. The values of this performance index have already been presented in Tables 1 and 2 for a fair assessment. \begin{table}
\begin{tabular}{c c c c c c c c} \hline \hline \(\left(\gamma_{k_{P}}\right)^{2}\) & \(B_{\Delta e}^{*}\) & \(B_{e}^{*}\) & \(\eta^{*}\) & \(\beta^{*}\) & \(k_{e}^{*}\) & \(T_{i}^{*}\) & \(J_{k_{P}\min}\) \\ \hline
0.006858 & 0.085588 & 40 & 0.747404 & 5.08539 & 0.003443 & 4.67856 & 32604.4 \\
0.06858 & 0.085016 & 40 & 0.740636 & 5.11954 & 0.003431 & 4.70998 & 118689 \\
0.6858 & 0.012792 & 20 & 0.250669 & 17 & 0.001883 & 15.64 & 873561 \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Weighting parameter and controller parameters for the minimization of \(J_{k_{P}}\).