Skip to main content
. 2025 May 9;10(5):303. doi: 10.3390/biomimetics10050303
Algorithm 1: Pseudocode of ADVCSO algorithm
Initialize population using good point set and apply perturbation to top 10% of elites;
Define parameters: epoch, Gmax, pop_size, N, G, and jixiaoliang;
1: While t < Gmax:
2:     If (t % Gcurrent == 0):
3:         Sort population by fitness and dynamically assign roles:
4:            -Roosters (NR): top-ranked individuals
5:            -Hens (NH): middle-ranked individuals
6:            -Chicks (NC): remaining individuals
7:         Update mating pairs and mother–chick relationships;
8:         Adaptively adjust Gcurrent via cosine annealing;
9:     End if
10:     For i = 1 to NR:
11:         Update roosters’ positions with adaptive learning factor;
12:         Apply hybrid mutation (Cauchy/Gaussian based on diversity threshold);
13:     End for
14:     For i = 1 to NH:
15:         Update hens’ positions using rank-based following strategy;
16:         Replace partial dimensions with global best values;
17:     End for
18:     For i = 1 to NC:
19:         Update chicks’ positions via spiral learning with FL factor;
20:         Inherit elite dimensions from global best;
21:     End for
22:     Evaluate new solutions and update local/global best;
23:     Adjust mutation threshold based on population diversity;
24: End while
25: Return global best solution;