Research Article
A Modified Whale Optimization Algorithm and Its Application in Seismic Inversion Problem
| | Input: Population size N | | | Group size k | | | The halting criterion | | | Output: The best solution | | (1) | Generate the initial population Xi (i = 1, 2, …, N) | | (2) | for i = 1 to N do | | (3) | if (rand < 0.6) | | (4) | Generate new solution with OBL | | (5) | end if | | (6) | end for | | (7) | Calculate the fitness for each solution in the population | | (8) | Find the best solution with the best fitness | | (9) | while the halting criterion is not satisfied do | | (10) | Update a and CR | | (11) | Decompose population into k groups by density peak clustering algorithm | | (12) | for i = 1 to N do | | (13) | Update A, C, l and p | | (14) | R1 is the group with Xi and R2 are the groups without Xi | | (15) | Select randomly r1 from R1 and r2 from R2 | | (16) | jrand = randint (1, m) | | (17) | for j = 1 to m do | | (18) | ifthen | | (19) | if (|A| < 1) then | | (20) | if rand (0, 1) ≤ CR and j == jrandthen | | (21) | Update F | | (22) | Select randomly r1 from R1 and r2 from R2 | | (23) | | | (24) | Else | | (25) | | | (26) | | | (27) | end if | | (28) | elseif (|A| ≥ 1) then | | (29) | Select a random solution Xrand | | (30) | | | (31) | | | (32) | end if | | (33) | ifthen | | (34) | | | (35) | | | (36) | end if | | (37) | end if | | (38) | end for | | (39) | for i = 1 to N do | | (40) | if (rand < 0.6) | | (41) | Generate new solution Oi with OBL | | (42) | if Oi is better than Xithen | | (43) | Xi = Oi | | (44) | end if | | (45) | end if | | (46) | end for | | (47) | Find the best solution with the best fitness | | (48) | end while |
|