Skip to main content
. 2022 Sep 10;22(18):6860. doi: 10.3390/s22186860
Algorithm 1 PI control method with HGSO parameter regulator
Import: trajectory points
Output: PI parameters and tracking trajectory
Initialization: Initialize HGSO parameters, N, M, Xi (about PI controller parameters 4K), Hj, Pi,j, Cj, etc. using Equation (17) and Equation (18) (i=1,,N; j=1,M)
while t < the maximum number of iterations do
 Set the Xi obtained by HGSO to PI parameters K for solving joint angles according to the part of PI controller.
 Complete the evaluation of the current Xi by Equation (24).
for each search gas particles do
 Update the position information Xi using Equation (21).
for end
 Update Henry’s coefficient of each gas type clusters using Equation (19).
 Update solubility of each gas using Equation (20)
 Select the poor particles according to Equation (22) by Ffitness.
 Reset the position of these worst particles by Equation (19) to Equation (21).
t = t + 1
while end
return Xbest (The final optimized parameters K)