• No se han encontrado resultados

A multiprocess Salp swarm optimization with a heuristic based on crossing partial solutions

N/A
N/A
Protected

Academic year: 2024

Share "A multiprocess Salp swarm optimization with a heuristic based on crossing partial solutions"

Copied!
8
0
0

Texto completo

(1)

ScienceDirect

Available online at www.sciencedirect.com

Procedia Computer Science 179 (2021) 440–447

1877-0509 © 2021 The Authors. Published by Elsevier B.V.

This is an open access article under the CC BY-NC-ND license (https://creativecommons.org/licenses/by-nc-nd/4.0)

Peer-review under responsibility of the scientific committee of the 5th International Conference on Computer Science and Computational Intelligence 2020

10.1016/j.procs.2021.01.027

10.1016/j.procs.2021.01.027 1877-0509

© 2021 The Authors. Published by Elsevier B.V.

This is an open access article under the CC BY-NC-ND license (https://creativecommons.org/licenses/by-nc-nd/4.0)

Peer-review under responsibility of the scientific committee of the 5th International Conference on Computer Science and Computational Intelligence 2020

Available online at www.sciencedirect.com

Procedia Computer Science 00 (2020) 000–000

www.elsevier.com/locate/procedia

5th International Conference on Computer Science and Computational Intelligence 2020

A multiprocess Salp swarm optimization with a heuristic based on crossing partial solutions

Felix Martinez-Rios, Alfonso Murillo-Suarez

Universidad Panamericana, Facultad de Ingenier´ıa, Augusto Rodin 498, Ciudad de M´exico, 03920, M´exico

Abstract

The Salp swarm algorithm (SSA) is one of the most recent metaheuristic optimization algorithms. SSA has been used successfully to solve optimization problems in different research areas such as machine learning, engineering design, wireless networks, image processing, mobile robotics, and energy. In this article, we present a multi-threaded implementation of the SSA algorithm. Each thread executes an SSA algorithm that shares information among the swarms to get a better solution. The best partial solutions of each swarm intersect in a similar way of genetic algorithms. The experiments with nineteen benchmark functions (unimodal, multimodal, and composite) show the results obtained with this new algorithm are better than those achieved with the original algorithm.

©2020 The Authors. Published by Elsevier B.V.

This is an open access article under the CC BY-NC-ND licensehttps://creativecommons.org/licenses/by-nc-nd/4.0/)

Peer-review Statement: Peer-review under responsibility of the scientific committee of the 4th International Conference on Computer Science and Computational Intelligence 2020.

Keywords: Salp swarm algorithm; Continuous optimization; Population-based optimization; Nature-inspired algorithm; Multi-threading algorithms

1. Introduction

Actual optimization problems have high complexity and require high-level algorithms to be solved, making many optimization algorithms obsolete fast but have also motivated the development of metaheuristic algorithms that pro- vide reliable results for a continuous search space [1].

Authors have found inspiration on natural behaviors such as of animal swarms seeking for food or flocks hunting, obtaining efficient algorithms that imitate natural behaviors, and that are even used to solve problems like autonomous vehicles’ path planning [2].

Throughout the years, various algorithms have been presented, some inspired by bird’s flocks and fish swarms (Particle Swarm Optimization [3]), in the behavior of ant’s colonies (Ant Colony Optimization [4]) and bee colonies (Artificial Bee Colony [5]), the mating behavior of fireflies (Firefly Algorithm [6]), or the hunting behavior of Spotted Hyenas

Corresponding author. Tel.:+52-55-5482-1600 ext. 5249 ; fax:+52-55-5482-1600 ext. 5249.

E-mail address:[email protected]

1877-0509©2020 The Authors. Published by Elsevier B.V.

This is an open access article under the CC BY-NC-ND licensehttps://creativecommons.org/licenses/by-nc-nd/4.0/)

Peer-review Statement: Peer-review under responsibility of the scientific committee of the 4th International Conference on Computer Science and Computational Intelligence 2020.

Available online at www.sciencedirect.com

Procedia Computer Science 00 (2020) 000–000

www.elsevier.com/locate/procedia

5th International Conference on Computer Science and Computational Intelligence 2020

A multiprocess Salp swarm optimization with a heuristic based on crossing partial solutions

Felix Martinez-Rios, Alfonso Murillo-Suarez

Universidad Panamericana, Facultad de Ingenier´ıa, Augusto Rodin 498, Ciudad de M´exico, 03920, M´exico

Abstract

The Salp swarm algorithm (SSA) is one of the most recent metaheuristic optimization algorithms. SSA has been used successfully to solve optimization problems in different research areas such as machine learning, engineering design, wireless networks, image processing, mobile robotics, and energy. In this article, we present a multi-threaded implementation of the SSA algorithm. Each thread executes an SSA algorithm that shares information among the swarms to get a better solution. The best partial solutions of each swarm intersect in a similar way of genetic algorithms. The experiments with nineteen benchmark functions (unimodal, multimodal, and composite) show the results obtained with this new algorithm are better than those achieved with the original algorithm.

©2020 The Authors. Published by Elsevier B.V.

This is an open access article under the CC BY-NC-ND licensehttps://creativecommons.org/licenses/by-nc-nd/4.0/)

Peer-review Statement: Peer-review under responsibility of the scientific committee of the 4th International Conference on Computer Science and Computational Intelligence 2020.

Keywords: Salp swarm algorithm; Continuous optimization; Population-based optimization; Nature-inspired algorithm; Multi-threading algorithms

1. Introduction

Actual optimization problems have high complexity and require high-level algorithms to be solved, making many optimization algorithms obsolete fast but have also motivated the development of metaheuristic algorithms that pro- vide reliable results for a continuous search space [1].

Authors have found inspiration on natural behaviors such as of animal swarms seeking for food or flocks hunting, obtaining efficient algorithms that imitate natural behaviors, and that are even used to solve problems like autonomous vehicles’ path planning [2].

Throughout the years, various algorithms have been presented, some inspired by bird’s flocks and fish swarms (Particle Swarm Optimization [3]), in the behavior of ant’s colonies (Ant Colony Optimization [4]) and bee colonies (Artificial Bee Colony [5]), the mating behavior of fireflies (Firefly Algorithm [6]), or the hunting behavior of Spotted Hyenas

Corresponding author. Tel.:+52-55-5482-1600 ext. 5249 ; fax:+52-55-5482-1600 ext. 5249.

E-mail address:[email protected]

1877-0509©2020 The Authors. Published by Elsevier B.V.

This is an open access article under the CC BY-NC-ND licensehttps://creativecommons.org/licenses/by-nc-nd/4.0/)

Peer-review Statement: Peer-review under responsibility of the scientific committee of the 4th International Conference on Computer Science and Computational Intelligence 2020.

2 Felix Martinez-Rios et al./Procedia Computer Science 00 (2020) 000–000

Fig. 1. Box (a) shows an individual salp and box (b) shows the swarm of wasps with chain configuration (salp chain) [8].

(Spotted Hyena Optimizer [7]).

For this work, we are basing our algorithm in the Salp Swarm Algorithm, presented in 2017 by Mirjalili et al. [8]

We are proposing a multiprocess implementation where we use the capacity of the multi-core processors to run var- ious independent instances of the Salp algorithm process simultaneously, exchanging information after a determined amount of time for them to learn from each other and managing to explore more the search space, keeping diversity and reducing the time and resources needed for the original implementation of the algorithm.

2. Salp swarm algorithm

The Salp swarm algorithm [8] is inspired by the behavior of salp swarms for navigating the ocean. This sea animal member of theSalpidaefamily has a barrel-shaped transparent body, similar to the jellyfish (Figure 1.a). The way salps move is also similar to jellyfish, but they form a salp chain for achieving better locomotion and foraging despite the low accessibility in their living environments (Figure1.b) [9].

2.1. Mathematical model to represent salp chains

To model the behavior of salps, the population is divided into two groups: leaders and followers. The leaders represent the salps at the front of the salp chain guiding the swarm, the rest of the group (followers) follow each other and also follow the leader directly or indirectly.

The position of the salps is expressed in anndimensional space, wheren is the number of variables of the problem. Also, it is assumed that the swarm knows the position of the food sourceFso the leaders move towards the food source.

The following equation is used for updating the leaders’ positions:

xij=



Fj+c1

ubjlbj

c2+lbj

c3<0.5 Fjc1

ubjlbj

c2+lbj

c3≥0.5 (1)

Wherexijrepresents thej-thdimension of thei-thleader.Fjis thej-thdimension of the food source position;ubk

andlbjrepresents the upper and lower search bounds, respectively, for thej-thdimension;c1 is a reduction coefficient that decreases with the iterations for the salps to exploit the search space;c2 andc3 are random numbers in the interval [0,1).

The leaders’ movement equation (Equation1) shows that the leader always moves according to the position of the food source. The food source positionFat the beginning is the position of the best salp after initialization. After that, it is only updated if some salp obtains a better result.

The reduction coefficientc1 is calculated in each iteration usingc1=2e(4lL)2. Wherelis the current iteration, and Lis the maximum number of iterations.

(2)

Felix Martinez-Rios et al. / Procedia Computer Science 179 (2021) 440–447 441

Procedia Computer Science 00 (2020) 000–000

www.elsevier.com/locate/procedia

5th International Conference on Computer Science and Computational Intelligence 2020

A multiprocess Salp swarm optimization with a heuristic based on crossing partial solutions

Felix Martinez-Rios, Alfonso Murillo-Suarez

Universidad Panamericana, Facultad de Ingenier´ıa, Augusto Rodin 498, Ciudad de M´exico, 03920, M´exico

Abstract

The Salp swarm algorithm (SSA) is one of the most recent metaheuristic optimization algorithms. SSA has been used successfully to solve optimization problems in different research areas such as machine learning, engineering design, wireless networks, image processing, mobile robotics, and energy. In this article, we present a multi-threaded implementation of the SSA algorithm. Each thread executes an SSA algorithm that shares information among the swarms to get a better solution. The best partial solutions of each swarm intersect in a similar way of genetic algorithms. The experiments with nineteen benchmark functions (unimodal, multimodal, and composite) show the results obtained with this new algorithm are better than those achieved with the original algorithm.

©2020 The Authors. Published by Elsevier B.V.

This is an open access article under the CC BY-NC-ND licensehttps://creativecommons.org/licenses/by-nc-nd/4.0/)

Peer-review Statement: Peer-review under responsibility of the scientific committee of the 4th International Conference on Computer Science and Computational Intelligence 2020.

Keywords: Salp swarm algorithm; Continuous optimization; Population-based optimization; Nature-inspired algorithm; Multi-threading algorithms

1. Introduction

Actual optimization problems have high complexity and require high-level algorithms to be solved, making many optimization algorithms obsolete fast but have also motivated the development of metaheuristic algorithms that pro- vide reliable results for a continuous search space [1].

Authors have found inspiration on natural behaviors such as of animal swarms seeking for food or flocks hunting, obtaining efficient algorithms that imitate natural behaviors, and that are even used to solve problems like autonomous vehicles’ path planning [2].

Throughout the years, various algorithms have been presented, some inspired by bird’s flocks and fish swarms (Particle Swarm Optimization [3]), in the behavior of ant’s colonies (Ant Colony Optimization [4]) and bee colonies (Artificial Bee Colony [5]), the mating behavior of fireflies (Firefly Algorithm [6]), or the hunting behavior of Spotted Hyenas

Corresponding author. Tel.:+52-55-5482-1600 ext. 5249 ; fax:+52-55-5482-1600 ext. 5249.

E-mail address:[email protected]

1877-0509©2020 The Authors. Published by Elsevier B.V.

This is an open access article under the CC BY-NC-ND licensehttps://creativecommons.org/licenses/by-nc-nd/4.0/)

Peer-review Statement: Peer-review under responsibility of the scientific committee of the 4th International Conference on Computer Science and Computational Intelligence 2020.

Procedia Computer Science 00 (2020) 000–000

www.elsevier.com/locate/procedia

5th International Conference on Computer Science and Computational Intelligence 2020

A multiprocess Salp swarm optimization with a heuristic based on crossing partial solutions

Felix Martinez-Rios, Alfonso Murillo-Suarez

Universidad Panamericana, Facultad de Ingenier´ıa, Augusto Rodin 498, Ciudad de M´exico, 03920, M´exico

Abstract

The Salp swarm algorithm (SSA) is one of the most recent metaheuristic optimization algorithms. SSA has been used successfully to solve optimization problems in different research areas such as machine learning, engineering design, wireless networks, image processing, mobile robotics, and energy. In this article, we present a multi-threaded implementation of the SSA algorithm. Each thread executes an SSA algorithm that shares information among the swarms to get a better solution. The best partial solutions of each swarm intersect in a similar way of genetic algorithms. The experiments with nineteen benchmark functions (unimodal, multimodal, and composite) show the results obtained with this new algorithm are better than those achieved with the original algorithm.

©2020 The Authors. Published by Elsevier B.V.

This is an open access article under the CC BY-NC-ND licensehttps://creativecommons.org/licenses/by-nc-nd/4.0/)

Peer-review Statement: Peer-review under responsibility of the scientific committee of the 4th International Conference on Computer Science and Computational Intelligence 2020.

Keywords: Salp swarm algorithm; Continuous optimization; Population-based optimization; Nature-inspired algorithm; Multi-threading algorithms

1. Introduction

Actual optimization problems have high complexity and require high-level algorithms to be solved, making many optimization algorithms obsolete fast but have also motivated the development of metaheuristic algorithms that pro- vide reliable results for a continuous search space [1].

Authors have found inspiration on natural behaviors such as of animal swarms seeking for food or flocks hunting, obtaining efficient algorithms that imitate natural behaviors, and that are even used to solve problems like autonomous vehicles’ path planning [2].

Throughout the years, various algorithms have been presented, some inspired by bird’s flocks and fish swarms (Particle Swarm Optimization [3]), in the behavior of ant’s colonies (Ant Colony Optimization [4]) and bee colonies (Artificial Bee Colony [5]), the mating behavior of fireflies (Firefly Algorithm [6]), or the hunting behavior of Spotted Hyenas

Corresponding author. Tel.:+52-55-5482-1600 ext. 5249 ; fax:+52-55-5482-1600 ext. 5249.

E-mail address:[email protected]

1877-0509©2020 The Authors. Published by Elsevier B.V.

This is an open access article under the CC BY-NC-ND licensehttps://creativecommons.org/licenses/by-nc-nd/4.0/)

Peer-review Statement: Peer-review under responsibility of the scientific committee of the 4th International Conference on Computer Science and Computational Intelligence 2020.

2 Felix Martinez-Rios et al./Procedia Computer Science 00 (2020) 000–000

Fig. 1. Box (a) shows an individual salp and box (b) shows the swarm of wasps with chain configuration (salp chain) [8].

(Spotted Hyena Optimizer [7]).

For this work, we are basing our algorithm in the Salp Swarm Algorithm, presented in 2017 by Mirjalili et al. [8]

We are proposing a multiprocess implementation where we use the capacity of the multi-core processors to run var- ious independent instances of the Salp algorithm process simultaneously, exchanging information after a determined amount of time for them to learn from each other and managing to explore more the search space, keeping diversity and reducing the time and resources needed for the original implementation of the algorithm.

2. Salp swarm algorithm

The Salp swarm algorithm [8] is inspired by the behavior of salp swarms for navigating the ocean. This sea animal member of the Salpidaefamily has a barrel-shaped transparent body, similar to the jellyfish (Figure1.a). The way salps move is also similar to jellyfish, but they form a salp chain for achieving better locomotion and foraging despite the low accessibility in their living environments (Figure1.b) [9].

2.1. Mathematical model to represent salp chains

To model the behavior of salps, the population is divided into two groups: leaders and followers. The leaders represent the salps at the front of the salp chain guiding the swarm, the rest of the group (followers) follow each other and also follow the leader directly or indirectly.

The position of the salps is expressed in anndimensionalspace, wheren is the number of variables of the problem. Also, it is assumed that the swarm knows the position of the food sourceFso the leaders move towards the food source.

The following equation is used for updating the leaders’ positions:

xij=



Fj+c1

ubjlbj

c2+lbj

c3<0.5 Fjc1

ubjlbj

c2+lbj

c3≥0.5 (1)

Wherexijrepresents thej-thdimension of thei-thleader.Fjis thej-thdimension of the food source position;ubk

andlbjrepresents the upper and lower search bounds, respectively, for thej-thdimension;c1 is a reduction coefficient that decreases with the iterations for the salps to exploit the search space;c2 andc3 are random numbers in the interval [0,1).

The leaders’ movement equation (Equation1) shows that the leader always moves according to the position of the food source. The food source positionFat the beginning is the position of the best salp after initialization. After that, it is only updated if some salp obtains a better result.

The reduction coefficientc1 is calculated in each iteration usingc1=2e(4lL)2. Wherelis the current iteration, and Lis the maximum number of iterations.

(3)

442 Felix Martinez-Rios et al. / Procedia Computer Science 179 (2021) 440–447

Felix Martinez-Rios et al./Procedia Computer Science 00 (2020) 000–000 3

The positions of the remaining salps (the followers) are calculated based on Newton’s law of motion with the Equationxij= 12at2+v0t, wherexijrepresents thej-thdimension of thei-thparticle fori≥2. Time is shown bytand v0represents the initial speed,a= vf inalv

0 , andv= xxt0.

Considering that the time is the iteration, the difference is equal to 1, and if we considerv0=0, then the equation can be reformulated asxij=12

xij+xij−1 . 2.2. Salp swarm implementation

The Salp Swarm Algorithm can be found in[8]. It starts by initializing a random position population of salps and calculates the fitness value for each of them; the food sourceF gets the position of the salp that obtained the best fitness value.

The best position is always saved as the food position so that it never gets lost, although the salps keep exploring and exploiting the search space. As parameterc1 decreases with iterations, the algorithm first explores the search space and then exploits it.

3. Multiprocess Salp swarm algorithm

In this section, we describe the implementation of the multiprocess salp swarm algorithm with the heuristic based on crossing partial solutions.

3.1. Multiple processes in different threads

Implementing processes in multiple threads improves the efficiency of software by avoiding leaving multiple units of a processor unutilized [10,11]. By running multiple processes simultaneously and independently from each other, we can generate different solutions that can be partially shared between them to improve the exactitude of results, also by hybridizing some other heuristic techniques that have proved to obtain good results [12].

3.2. Implementation of the multiprocess Salp swarm algorithm

For taking advantage of the computing power available nowadays, we decided to implement multiple processes of the Salp swarm algorithm in threads to improve the results obtained by also implementing some methodologies to cross partial solutions obtained by each thread. In Algorithm1, this process is carefully defined in pseudo-code.

As shown in Algorithm1, the process starts by initializing the parameters needed for the algorithm in each process and aSbestτ parameter to store the best solution obtained for every single process. After this, the process starts executing the iterations of the algorithms until theCNI(crossover number of iterations) value is reached and all the results are compared to determine if a better solution than the actualSbestwas obtained, then the crossing method is implemented with the partial solutions obtained by each thread.

3.3. Crossing techniques for partial solutions

Having multiple processes executing simultaneously increments the possibility of finding better solutions, but we are also proposing methodologies to cross the partial solutions obtained after eachCNIiterations so that the processes can also learn from each other and improve the chances to get to a better result.

Figure2illustrates how the multiprocess SSA works. Each threadT of thePthreads executes the SSA process independently and generates its solutions for each iteration. WhenCNIiterations are reached (shown in the diagram as iteration C), the crossover operation is executed. In this case, we are representing thegenetic crossover with the bestand assuming that the best result was obtained byT3, so the crossover is executed with the values in this thread.

The crossing operations we are proposing are listed below:

• Genetic with the best:we select the thread that obtained the best result to implement a genetic crossover [13], where we choose a random dimension from each thread different than the best one and let from the first dimension to the one selected as same as it finished, and the remaining ones are taken from the best thread.

(4)

The positions of the remaining salps (the followers) are calculated based on Newton’s law of motion with the Equationxij= 12at2+v0t, wherexijrepresents thej-thdimension of thei-thparticle fori≥2. Time is shown bytand v0represents the initial speed,a=vf inalv

0 , andv= xxt0.

Considering that the time is the iteration, the difference is equal to 1, and if we considerv0 =0, then the equation can be reformulated asxij=12

xij+xij−1 . 2.2. Salp swarm implementation

The Salp Swarm Algorithm can be found in[8]. It starts by initializing a random position population of salps and calculates the fitness value for each of them; the food source F gets the position of the salp that obtained the best fitness value.

The best position is always saved as the food position so that it never gets lost, although the salps keep exploring and exploiting the search space. As parameterc1 decreases with iterations, the algorithm first explores the search space and then exploits it.

3. Multiprocess Salp swarm algorithm

In this section, we describe the implementation of the multiprocess salp swarm algorithm with the heuristic based on crossing partial solutions.

3.1. Multiple processes in different threads

Implementing processes in multiple threads improves the efficiency of software by avoiding leaving multiple units of a processor unutilized [10,11]. By running multiple processes simultaneously and independently from each other, we can generate different solutions that can be partially shared between them to improve the exactitude of results, also by hybridizing some other heuristic techniques that have proved to obtain good results [12].

3.2. Implementation of the multiprocess Salp swarm algorithm

For taking advantage of the computing power available nowadays, we decided to implement multiple processes of the Salp swarm algorithm in threads to improve the results obtained by also implementing some methodologies to cross partial solutions obtained by each thread. In Algorithm1, this process is carefully defined in pseudo-code.

As shown in Algorithm1, the process starts by initializing the parameters needed for the algorithm in each process and aSbestτ parameter to store the best solution obtained for every single process. After this, the process starts executing the iterations of the algorithms until theCNI(crossover number of iterations) value is reached and all the results are compared to determine if a better solution than the actualSbestwas obtained, then the crossing method is implemented with the partial solutions obtained by each thread.

3.3. Crossing techniques for partial solutions

Having multiple processes executing simultaneously increments the possibility of finding better solutions, but we are also proposing methodologies to cross the partial solutions obtained after eachCNIiterations so that the processes can also learn from each other and improve the chances to get to a better result.

Figure2illustrates how the multiprocess SSA works. Each threadT of thePthreads executes the SSA process independently and generates its solutions for each iteration. WhenCNIiterations are reached (shown in the diagram as iteration C), the crossover operation is executed. In this case, we are representing thegenetic crossover with the bestand assuming that the best result was obtained byT3, so the crossover is executed with the values in this thread.

The crossing operations we are proposing are listed below:

• Genetic with the best:we select the thread that obtained the best result to implement a genetic crossover [13], where we choose a random dimension from each thread different than the best one and let from the first dimension to the one selected as same as it finished, and the remaining ones are taken from the best thread.

Algorithm 1:Multiprocess salp swarm algorithm Data:n, CNI, MaxIterations, k best

Result:Best position and best value

1 begin

2 InitializeSbest

3 foreachτinΓdo

4 Initialize the parameters for eachτ

5 InitializeSbestτ

6 end

7 t←0

8 whiletMaxIterationsdo

9 foreachτinΓdo

10 Execute the original SSA untilCNIiterations are reached

11 Sτbest←best solution obtained so far inτ

12 ifSbestτ is better than Sbestthen

13 SbestSbestτ

14 end

15 end

16 foreachτinΓdo

17 Implement the crossing method with the partial solution

18 end

19 end

20 ReturnS bestvalue and position

21 end

Fig. 2. Multiprocess execution.

Fig. 3. Crossing method.

• Genetic with best K:here is where thek bestparameter is used. We select thek bestnumber of best threads and, for all other threads, pick a random dimension to make a genetic crossover.

Figure3illustrates the crossing method, in whichSbestis the best thread for thegenetic with the bestmethod or a random thread for thegenetic to k bestmethod, andSkis the thread that is going to be altered. In theSknewthread, the result of the crossing method is represented with a crossover point valueC; the first dimensions (untilC–1) belong to the originalSkthread, and the remaining dimensions correspond to theSbestthread.

(5)

444 Felix Martinez-Rios et al. / Procedia Computer Science 179 (2021) 440–447

Felix Martinez-Rios et al./Procedia Computer Science 00 (2020) 000–000 5

4. Experiments and results 4.1. Experimental setup

For testing our algorithm, we used nineteen benchmark functions (unimodal, multimodal and composite) that are defined inAppendix Aalong with the dimensions used, and the value of their global minimum.

All the experiments were run in a Dell PrecisionM6800 Laptop with Intel Core i7-4900MQ (Quad Core 2.80GHz, 3.8GHz Turbo, 8MB) and 32 GB in RAM.

Each function was tested 30 times for each experiment using a population of 30 salps. The first experiment was used to determine the best number of threads to run the process, so we tested from 1 to 10 threads with thegenetic with the best crossing method. The results of this experiment have been normalized for easier comparison and are shown in Table1, where the best algorithm’s result is shown in bold.

The best results of the first experiment were obtained for 7, 8, 9, and 10 threads, so we tested them with thegenetic with best Kmethod, with thek bestparameter with values 2 and 3 to obtain the best combination of number of threads andk best. We determined that the best combinations were 7 with 3, 8 with 3, 10 with 2, and 10 with 3.

4.2. Results interpretation and comparison with other algorithms

Once having determined the values for the parameters, we compared their results with the original Salp swarm algorithm and other five algorithms from the literature. The codes for obtaining the results from these algorithms were obtained from the MATLAB Central File Exchange webpage.

The algorithms used to compare our results were Salp Swarm Algorithm (SSA) [14], States of Matter Search (SMS) [15], Particle Swarm Optimization (PSO) [16], Genetic Algorithm (GA) [17], Firefly Algorithm (FA) [18], and Flower Pollination Algorithm (FPA) [19].

The results obtained by six different algorithms and our algorithm, with four different combinations of threads and k best, for all the functions are listed in Table2, where the best values obtained for each function are marked in bold so that it is clear which algorithm performed the best for that particular function. At first sight, our algorithm achieves the best results (sometimes it improves the results from other algorithms, and sometimes it equals the best result); this is the case for 16 of the 19 functions tested, but for being sure that our algorithm obtains significantly better results we performed the Wilcoxon test[20] to these results obtained, allowing us to determine if our algorithm was effectively better.

Table3shows the results of the Wilcoxon test[20] mentioned before. For a better understanding, the table is divided diagonally in two parts. The bottom left half of the table shows the values obtained from the Wilcoxon test, where a value near 1 indicates that the fitness values obtained for the functions with the algorithm in the left column are not significantly better than the ones obtained by the algorithm in the header. The top right half of the table shows only true/false values, indicating if the results obtained by the algorithms in the header are significantly better thant the ones in the left column. With this representation, it is easier to see that our algorithm obtains significantly better results.

5. Conclusions

With the results shown in Tables2and3, we prove that the multiprocess Salp swarm algorithm obtains good results.

As mentioned before, Table2shows that we reached the best result for 16 of the 19 functions with our implementa- tion, and Table3shows that our algorithm has a better performance than all the compared algorithms.

Allowing the different processes to explore the solutions independently and once in a while learning from each other improves significantly the results obtained while taking advantage of the computer’s capabilities. The results ob- tained confirm the advantages of this implementation, where we obtain significantly better results, confirmed with the Wilcoxon test, than other similar algorithms. Being able to implement this algorithm, easily developed in C#, in commercial computers with multi-core processors allows multiple fields to obtain reliable results in their optimization problems with accessible hardware.

6 Felix Martinez-Rios et al./Procedia Computer Science 00 (2020) 000–000 Table 1. Experimental results with different amount of threads and using genetic crossover with the best

Functions 2 3 4 5 6 7 8 9 10

f1 1 5.66E-01 5.27E-01 1.45E-01 1.37E-01 1.76E-01 1.41E-01 0 2.85E-02

f2 1 6.32E-01 5.42E-01 2.02E-01 3.06E-01 2.09E-01 7.14E-02 6.75E-02 0

f3 1 3.53E-01 3.24E-01 2.62E-01 1.36E-01 7.69E-02 1.53E-02 7.45E-02 0

f4 9.32E-01 1 5.79E-01 3.50E-01 1.57E-01 2.43E-01 9.54E-02 1.24E-01 0

f5 5.39E-01 3.45E-01 2.75E-03 4.91E-02 1 0 3.75E-01 3.75E-02 3.26E-02

f6 0 0 0 0 0 0 0 0 0

f7 1 7.97E-01 8.63E-01 4.75E-01 4.46E-23 1.19E-23 7.95E-24 8.63E-24 0

f8 1 8.05E-01 5.05E-01 6.79E-01 2.19E-01 5.05E-01 6.60E-01 5.22E-01 0

f9 7.58E-01 8.30E-01 1 4.78E-01 2.51E-01 2.18E-01 8.33E-02 0 5.68E-02

f10 1 9.10E-01 5.92E-01 4.47E-01 2.83E-01 2.76E-01 2.31E-01 0 1.26E-01

f11 1 8.22E-01 4.69E-01 2.37E-01 2.60E-01 1.29E-01 0 1.00E-01 9.00E-04

f12 1 7.82E-01 1.59E-01 2.55E-01 0 1.80E-01 2.80E-01 1.96E-02 4.06E-02

f13 7.41E-01 1 3.76E-01 8.75E-01 0 2.50E-01 5.01E-01 5.01E-01 3.76E-01

f14 1 2.78E-01 3.30E-01 4.82E-01 3.39E-01 1.38E-01 1.47E-01 1.76E-01 0

f15 5.07E-10 1 1.53E-01 2.63E-10 1.87E-10 1.59E-10 8.46E-11 0 7.73E-11

f16 1 7.73E-01 2.02E-01 5.57E-01 4.12E-01 2.25E-01 1.63E-01 2.26E-01 0

f17 8.23E-01 9.79E-01 5.67E-01 1 0 8.11E-01 9.49E-01 3.79E-01 3.61E-01

f18 3.23E-02 4.02E-12 1.77E-01 2.50E-02 1.59E-12 1.29E-12 9.15E-02 0 1

f19 7.94E-01 5.88E-01 5.36E-02 2.00E-02 5.17E-02 0 7.81E-03 1 1.70E-02

Table 2. Finals results

Functions SSA SMS PSO GA FA FPA 7 with 3 8 with 3 10 with 2 10 with 3

f1 1.08E-11 2.19E-07 1.70E-05 1.21E-03 1.70E-06 1 7.01E-14 4.02E-14 1.01E-13 0

f2 3.56E-02 3.49E-03 9.38E-04 2.99E-02 1.13E-02 1 5.17E-08 3.63E-08 5.76E-08 0

f3 1.57E-01 1.17E-04 1 4.02E-01 9.26E-02 8.75E-01 0 2.33E-12 2.70E-12 3.72E-12

f4 1.16E-01 1.80E-03 4.92E-01 7.68E-02 2.68E-03 1 0 1.15E-09 3.61E-09 2.32E-10

f5 2.56E-03 0 9.03E-04 3.20E-03 2.74E-03 1 3.01E-05 3.14E-05 2.31E-05 1.84E-05

f6 1.10E-02 0 2.97E-04 4.46E-03 0 1 0 0 0 0

f7 2.48E-01 1.04E-01 1.76E-01 4.18E-02 1.53E-01 1 6.59E-27 1.76E-27 4.65E-27 0

f8 2.69E-01 6.00E-01 1.54E-01 0 3.68E-01 2.04E-01 1 1.14E-01 1.01E-01 1.08E-01

f9 8.39E-01 4.96E-02 6.68E-01 2.34E-01 2.16E-01 1 7.02E-13 0 8.10E-13 3.20E-13

f10 1.70E-01 1.17E-03 1.41E-02 1.41E-01 9.83E-04 1 3.57E-08 0 6.22E-08 1.85E-08

f11 4.99E-03 2.10E-06 6.33E-02 1.85E-01 2.91E-04 1 1.39E-10 0 8.22E-11 6.09E-11

f12 1 2.27E-02 1.54E-01 8.39E-03 1.29E-05 2.39E-01 4.08E-03 4.17E-03 0 1.16E-12

f13 3.88E-03 9.36E-06 4.99E-02 5.99E-02 1.75E-04 1 2.22E-04 1.38E-10 2.22E-04 0

f14 6.86E-12 3.15E-05 1.30E-11 1.21E-06 2.55E-07 1 5.60E-13 3.69E-13 3.80E-13 0

f15 1.33E-01 3.02E-02 2.29E-01 1.78E-01 8.44E-02 1 2.95E-12 0 2.60E-12 1.59E-12

f16 0 1.18E-05 6.38E-01 8.43E-01 1.14E-07 1 2.97E-13 8.56E-13 4.56E-13 2.11E-02

f17 5.14E-01 9.62E-01 1 8.15E-01 4.71E-01 5.05E-01 2.38E-01 1.14E-01 1.49E-01 0

f18 2.77E-01 7.12E-02 5.00E-02 2.03E-01 6.05E-02 1 1.05E-12 1.77E-12 1.71E-12 0

f19 5.10E-01 1 4.19E-01 8.97E-01 6.98E-01 3.56E-01 2.15E-02 2.99E-02 5.86E-02 0

For future research, we will develop better communication techniques between the different processes to really explore the search space for more complex functions, allowing us to implement the algorithms in real-world problems.

Appendix A. Benchmark functions References

1. Lozano, M., Molina, D., Herrera, F.. Editorial scalability of evolutionary algorithms and other metaheuristics for large-scale continuous optimization problems.Soft Computing2011;15:2085–2087. doi:\bibinfo{doi}{10.1007/s00500-010-0639-2}.

(6)

4. Experiments and results 4.1. Experimental setup

For testing our algorithm, we used nineteen benchmark functions (unimodal, multimodal and composite) that are defined inAppendix Aalong with the dimensions used, and the value of their global minimum.

All the experiments were run in a Dell PrecisionM6800 Laptop with Intel Core i7-4900MQ (Quad Core 2.80GHz, 3.8GHz Turbo, 8MB) and 32 GB in RAM.

Each function was tested 30 times for each experiment using a population of 30 salps. The first experiment was used to determine the best number of threads to run the process, so we tested from 1 to 10 threads with thegenetic with the bestcrossing method. The results of this experiment have been normalized for easier comparison and are shown in Table1, where the best algorithm’s result is shown in bold.

The best results of the first experiment were obtained for 7, 8, 9, and 10 threads, so we tested them with thegenetic with best Kmethod, with thek bestparameter with values 2 and 3 to obtain the best combination of number of threads andk best. We determined that the best combinations were 7 with 3, 8 with 3, 10 with 2, and 10 with 3.

4.2. Results interpretation and comparison with other algorithms

Once having determined the values for the parameters, we compared their results with the original Salp swarm algorithm and other five algorithms from the literature. The codes for obtaining the results from these algorithms were obtained from the MATLAB Central File Exchange webpage.

The algorithms used to compare our results were Salp Swarm Algorithm (SSA) [14], States of Matter Search (SMS) [15], Particle Swarm Optimization (PSO) [16], Genetic Algorithm (GA) [17], Firefly Algorithm (FA) [18], and Flower Pollination Algorithm (FPA) [19].

The results obtained by six different algorithms and our algorithm, with four different combinations of threads and k best, for all the functions are listed in Table2, where the best values obtained for each function are marked in bold so that it is clear which algorithm performed the best for that particular function. At first sight, our algorithm achieves the best results (sometimes it improves the results from other algorithms, and sometimes it equals the best result); this is the case for 16 of the 19 functions tested, but for being sure that our algorithm obtains significantly better results we performed the Wilcoxon test[20] to these results obtained, allowing us to determine if our algorithm was effectively better.

Table3shows the results of the Wilcoxon test[20] mentioned before. For a better understanding, the table is divided diagonally in two parts. The bottom left half of the table shows the values obtained from the Wilcoxon test, where a value near 1 indicates that the fitness values obtained for the functions with the algorithm in the left column are not significantly better than the ones obtained by the algorithm in the header. The top right half of the table shows only true/false values, indicating if the results obtained by the algorithms in the header are significantly better thant the ones in the left column. With this representation, it is easier to see that our algorithm obtains significantly better results.

5. Conclusions

With the results shown in Tables2and3, we prove that the multiprocess Salp swarm algorithm obtains good results.

As mentioned before, Table2shows that we reached the best result for 16 of the 19 functions with our implementa- tion, and Table3shows that our algorithm has a better performance than all the compared algorithms.

Allowing the different processes to explore the solutions independently and once in a while learning from each other improves significantly the results obtained while taking advantage of the computer’s capabilities. The results ob- tained confirm the advantages of this implementation, where we obtain significantly better results, confirmed with the Wilcoxon test, than other similar algorithms. Being able to implement this algorithm, easily developed in C#, in commercial computers with multi-core processors allows multiple fields to obtain reliable results in their optimization problems with accessible hardware.

Table 1. Experimental results with different amount of threads and using genetic crossover with the best

Functions 2 3 4 5 6 7 8 9 10

f1 1 5.66E-01 5.27E-01 1.45E-01 1.37E-01 1.76E-01 1.41E-01 0 2.85E-02

f2 1 6.32E-01 5.42E-01 2.02E-01 3.06E-01 2.09E-01 7.14E-02 6.75E-02 0

f3 1 3.53E-01 3.24E-01 2.62E-01 1.36E-01 7.69E-02 1.53E-02 7.45E-02 0

f4 9.32E-01 1 5.79E-01 3.50E-01 1.57E-01 2.43E-01 9.54E-02 1.24E-01 0

f5 5.39E-01 3.45E-01 2.75E-03 4.91E-02 1 0 3.75E-01 3.75E-02 3.26E-02

f6 0 0 0 0 0 0 0 0 0

f7 1 7.97E-01 8.63E-01 4.75E-01 4.46E-23 1.19E-23 7.95E-24 8.63E-24 0

f8 1 8.05E-01 5.05E-01 6.79E-01 2.19E-01 5.05E-01 6.60E-01 5.22E-01 0

f9 7.58E-01 8.30E-01 1 4.78E-01 2.51E-01 2.18E-01 8.33E-02 0 5.68E-02

f10 1 9.10E-01 5.92E-01 4.47E-01 2.83E-01 2.76E-01 2.31E-01 0 1.26E-01

f11 1 8.22E-01 4.69E-01 2.37E-01 2.60E-01 1.29E-01 0 1.00E-01 9.00E-04

f12 1 7.82E-01 1.59E-01 2.55E-01 0 1.80E-01 2.80E-01 1.96E-02 4.06E-02

f13 7.41E-01 1 3.76E-01 8.75E-01 0 2.50E-01 5.01E-01 5.01E-01 3.76E-01

f14 1 2.78E-01 3.30E-01 4.82E-01 3.39E-01 1.38E-01 1.47E-01 1.76E-01 0

f15 5.07E-10 1 1.53E-01 2.63E-10 1.87E-10 1.59E-10 8.46E-11 0 7.73E-11

f16 1 7.73E-01 2.02E-01 5.57E-01 4.12E-01 2.25E-01 1.63E-01 2.26E-01 0

f17 8.23E-01 9.79E-01 5.67E-01 1 0 8.11E-01 9.49E-01 3.79E-01 3.61E-01

f18 3.23E-02 4.02E-12 1.77E-01 2.50E-02 1.59E-12 1.29E-12 9.15E-02 0 1

f19 7.94E-01 5.88E-01 5.36E-02 2.00E-02 5.17E-02 0 7.81E-03 1 1.70E-02

Table 2. Finals results

Functions SSA SMS PSO GA FA FPA 7 with 3 8 with 3 10 with 2 10 with 3

f1 1.08E-11 2.19E-07 1.70E-05 1.21E-03 1.70E-06 1 7.01E-14 4.02E-14 1.01E-13 0

f2 3.56E-02 3.49E-03 9.38E-04 2.99E-02 1.13E-02 1 5.17E-08 3.63E-08 5.76E-08 0

f3 1.57E-01 1.17E-04 1 4.02E-01 9.26E-02 8.75E-01 0 2.33E-12 2.70E-12 3.72E-12

f4 1.16E-01 1.80E-03 4.92E-01 7.68E-02 2.68E-03 1 0 1.15E-09 3.61E-09 2.32E-10

f5 2.56E-03 0 9.03E-04 3.20E-03 2.74E-03 1 3.01E-05 3.14E-05 2.31E-05 1.84E-05

f6 1.10E-02 0 2.97E-04 4.46E-03 0 1 0 0 0 0

f7 2.48E-01 1.04E-01 1.76E-01 4.18E-02 1.53E-01 1 6.59E-27 1.76E-27 4.65E-27 0

f8 2.69E-01 6.00E-01 1.54E-01 0 3.68E-01 2.04E-01 1 1.14E-01 1.01E-01 1.08E-01

f9 8.39E-01 4.96E-02 6.68E-01 2.34E-01 2.16E-01 1 7.02E-13 0 8.10E-13 3.20E-13

f10 1.70E-01 1.17E-03 1.41E-02 1.41E-01 9.83E-04 1 3.57E-08 0 6.22E-08 1.85E-08

f11 4.99E-03 2.10E-06 6.33E-02 1.85E-01 2.91E-04 1 1.39E-10 0 8.22E-11 6.09E-11

f12 1 2.27E-02 1.54E-01 8.39E-03 1.29E-05 2.39E-01 4.08E-03 4.17E-03 0 1.16E-12

f13 3.88E-03 9.36E-06 4.99E-02 5.99E-02 1.75E-04 1 2.22E-04 1.38E-10 2.22E-04 0

f14 6.86E-12 3.15E-05 1.30E-11 1.21E-06 2.55E-07 1 5.60E-13 3.69E-13 3.80E-13 0

f15 1.33E-01 3.02E-02 2.29E-01 1.78E-01 8.44E-02 1 2.95E-12 0 2.60E-12 1.59E-12

f16 0 1.18E-05 6.38E-01 8.43E-01 1.14E-07 1 2.97E-13 8.56E-13 4.56E-13 2.11E-02

f17 5.14E-01 9.62E-01 1 8.15E-01 4.71E-01 5.05E-01 2.38E-01 1.14E-01 1.49E-01 0

f18 2.77E-01 7.12E-02 5.00E-02 2.03E-01 6.05E-02 1 1.05E-12 1.77E-12 1.71E-12 0

f19 5.10E-01 1 4.19E-01 8.97E-01 6.98E-01 3.56E-01 2.15E-02 2.99E-02 5.86E-02 0

For future research, we will develop better communication techniques between the different processes to really explore the search space for more complex functions, allowing us to implement the algorithms in real-world problems.

Appendix A. Benchmark functions References

1. Lozano, M., Molina, D., Herrera, F.. Editorial scalability of evolutionary algorithms and other metaheuristics for large-scale continuous optimization problems.Soft Computing2011;15:2085–2087. doi:\bibinfo{doi}{10.1007/s00500-010-0639-2}.

Referencias

Documento similar