|
Algorithm 2. The pseudocode of ARO |
| Inputs: number of search agents (), number of iterations (), problem dimension (), and lower () and upper () boundaries of search space |
| Outputs: the best rabbit () and its fitness () |
| //Initialization |
|
| while () |
| Initialize by Equation (16) |
| Calculate
|
|
|
| end for |
| Find and
|
|
| while () |
|
|
| while () |
| Calculate energy shrink () by Equation (17) |
| if
|
| //Detour foraging |
| Update using Equation (19) |
| else |
| //Random hiding |
| Update using Equation (27) |
| end if |
| Compute
|
|
|
| end for |
| Update and
|
|
|
| end while |
| Return and
|