Skip to main content
. 2020 Nov 9;20(21):6378. doi: 10.3390/s20216378
Algorithm 1. Pseudo Code of PSO Algorithm.
    For each particle
        Set particles in a random manner
    End
    Do
          Estimate the Local best “pBest” for each particle
          If the “pBest” is enhanced
      Update “pBest” value
    End
          Global Best (gBest) is updated as the best of “pBests
          For each particle
           Estimate the velocity of particles via Equations (5) and (6)
           Update the positions of the particles
          End
End