Introduction - If you have any usage issues, please Google them yourself
Code, there are very complete notes and explanations Automatic identification in the matlab environment the size of the connected area, Based on piecewise nonlinear weight value Pso algorithm.