• No se han encontrado resultados

5th International Conference on Computer Science and Computational Intelligence 2020

N/A
N/A
Protected

Academic year: 2024

Share "5th International Conference on Computer Science and Computational Intelligence 2020"

Copied!
8
0
0

Texto completo

(1)

ScienceDirect

Available online at www.sciencedirect.com

Procedia Computer Science 179 (2021) 432–439

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.026

10.1016/j.procs.2021.01.026 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

Multi-threaded Spotted Hyena Optimizer with thread-crossing techniques

Felix Martinez-Rios, Alfonso Murillo-Suarez

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

Abstract

This paper presents a Multi-threaded version of the Spotted Hyena Optimizer algorithm with thread-crossing techniques (MT-SHO) to improve the ability of the algorithm to explore the search space. The original algorithm is inspired by the hunting behavior of the spotted hyena.

Along the different sections of the work, we explain in detail how the original algorithm simulates the spotted hyena’s behavior to optimize highly complex mathematical functions and how we handle the procedures and results of the multi-threaded version, with thread-crossing techniques that improve the ability to explore and exploit the search space by letting threads learn between them.

We present the experiments used to determine the best value of the parameters used in the parallel version of the algorithm and to prove that our proposal obtains significantly good results we compare the results obtained by evaluating 24 benchmark functions with the results published for the original algorithm as well as other metaheuristic algorithms.

©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: Spotted Hyena Optimizer; Metaheuristic; Global optimization; Multi-threaded algorithms; Nature-inspired algorithms; Simulated annealing; Genetic algorithms

1. Introduction

Different fields like engineering, logistics, or manufacturing are nowadays presenting global optimization problems that involve a high mathematical complexity. Due to these new problems there is a need for global optimization algorithms to solve diverse kinds of problems, not only specialized ones

Metaheuristic optimization methods explore more efficiently the search space based on algorithms that implement a partial search, also called heuristic algorithms [1,2]. They are ideal for solving real-life problems despite the high complexity generated by all the variables involved with results that approximate to the optimum, as explained in [3]

Metaherusitc algorithms generate multiple points in the search space that explore by interacting and learning between

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

Multi-threaded Spotted Hyena Optimizer with thread-crossing techniques

Felix Martinez-Rios, Alfonso Murillo-Suarez

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

Abstract

This paper presents a Multi-threaded version of the Spotted Hyena Optimizer algorithm with thread-crossing techniques (MT-SHO) to improve the ability of the algorithm to explore the search space. The original algorithm is inspired by the hunting behavior of the spotted hyena.

Along the different sections of the work, we explain in detail how the original algorithm simulates the spotted hyena’s behavior to optimize highly complex mathematical functions and how we handle the procedures and results of the multi-threaded version, with thread-crossing techniques that improve the ability to explore and exploit the search space by letting threads learn between them.

We present the experiments used to determine the best value of the parameters used in the parallel version of the algorithm and to prove that our proposal obtains significantly good results we compare the results obtained by evaluating 24 benchmark functions with the results published for the original algorithm as well as other metaheuristic algorithms.

©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: Spotted Hyena Optimizer; Metaheuristic; Global optimization; Multi-threaded algorithms; Nature-inspired algorithms; Simulated annealing; Genetic algorithms

1. Introduction

Different fields like engineering, logistics, or manufacturing are nowadays presenting global optimization problems that involve a high mathematical complexity. Due to these new problems there is a need for global optimization algorithms to solve diverse kinds of problems, not only specialized ones

Metaheuristic optimization methods explore more efficiently the search space based on algorithms that implement a partial search, also called heuristic algorithms [1,2]. They are ideal for solving real-life problems despite the high complexity generated by all the variables involved with results that approximate to the optimum, as explained in [3]

Metaherusitc algorithms generate multiple points in the search space that explore by interacting and learning between

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. Classification and examples of metaheuristic algorithms based on [10].

them, similar to behaviors found in nature. Some examples of these algorithms and the references to their original authors are Particle Swarm Optimization [4], Genetic Algorithms, Ant Colony Optimization [5], Artificial Bee Colony [6], Firefly Algorithm [7], Bat Algorithm [8], and Cuckoo Search Algorithm [9]. More examples can be found in Fig.

1.

Although these algorithms have shown to obtain good results, they tend to use too much memory or take too much time to execute due to the big populations generated and the need to perform lots of iterations. The algorithm we are proposing in this paper takes advantage of the multicore processors found nowadays in commercial computers for being able to perform an optimization algorithm simultaneously and independently searching for optimal solutions but communicating periodically with each other for being able to learn and head to potential solutions without losing diversity.

With a simple multi-threaded implementation that does not need costly and complex computer systems, we offer an efficient and reliable solution to complex problems that are increasingly found in different fields.

2. Spotted Hyena Optimizer mathematical model and algorithm

Our algorithm is based on Spotted Hyena Optimizer, presented by Dhiman in 2017 [10], which is enclosed in the nature-inspired metaheuristic algorithms [11]. It simulates the different processes involved in hyena’s hunting.

2.1. Encircling the prey (Exploration)

Spotted hyenas surround their prey (the best-located search agent), which means that the best agent in each iteration is going to be considered the prey for the encircling process. For this process, the equations used for the mathematical model are:

−→Dh=→−Bh·−→Pp(x)−−→Ph(x) (1)

−→Ph(x+1)=−→Pp(x)−→−Eh·−→Dh (2)

Equation 1 calculates the distance−→Dh between the positions of each spotted hyena −→Ph and of the prey−→Pp for the respective iterationx.→−B and→−E are co-efficient vectors calculated for each dimension of each hyena obtained by

(2)

Felix Martinez-Rios et al. / Procedia Computer Science 179 (2021) 432–439 433 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

Multi-threaded Spotted Hyena Optimizer with thread-crossing techniques

Felix Martinez-Rios, Alfonso Murillo-Suarez

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

Abstract

This paper presents a Multi-threaded version of the Spotted Hyena Optimizer algorithm with thread-crossing techniques (MT-SHO) to improve the ability of the algorithm to explore the search space. The original algorithm is inspired by the hunting behavior of the spotted hyena.

Along the different sections of the work, we explain in detail how the original algorithm simulates the spotted hyena’s behavior to optimize highly complex mathematical functions and how we handle the procedures and results of the multi-threaded version, with thread-crossing techniques that improve the ability to explore and exploit the search space by letting threads learn between them.

We present the experiments used to determine the best value of the parameters used in the parallel version of the algorithm and to prove that our proposal obtains significantly good results we compare the results obtained by evaluating 24 benchmark functions with the results published for the original algorithm as well as other metaheuristic algorithms.

©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: Spotted Hyena Optimizer; Metaheuristic; Global optimization; Multi-threaded algorithms; Nature-inspired algorithms; Simulated annealing; Genetic algorithms

1. Introduction

Different fields like engineering, logistics, or manufacturing are nowadays presenting global optimization problems that involve a high mathematical complexity. Due to these new problems there is a need for global optimization algorithms to solve diverse kinds of problems, not only specialized ones

Metaheuristic optimization methods explore more efficiently the search space based on algorithms that implement a partial search, also called heuristic algorithms [1,2]. They are ideal for solving real-life problems despite the high complexity generated by all the variables involved with results that approximate to the optimum, as explained in [3]

Metaherusitc algorithms generate multiple points in the search space that explore by interacting and learning between

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

Multi-threaded Spotted Hyena Optimizer with thread-crossing techniques

Felix Martinez-Rios, Alfonso Murillo-Suarez

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

Abstract

This paper presents a Multi-threaded version of the Spotted Hyena Optimizer algorithm with thread-crossing techniques (MT-SHO) to improve the ability of the algorithm to explore the search space. The original algorithm is inspired by the hunting behavior of the spotted hyena.

Along the different sections of the work, we explain in detail how the original algorithm simulates the spotted hyena’s behavior to optimize highly complex mathematical functions and how we handle the procedures and results of the multi-threaded version, with thread-crossing techniques that improve the ability to explore and exploit the search space by letting threads learn between them.

We present the experiments used to determine the best value of the parameters used in the parallel version of the algorithm and to prove that our proposal obtains significantly good results we compare the results obtained by evaluating 24 benchmark functions with the results published for the original algorithm as well as other metaheuristic algorithms.

©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: Spotted Hyena Optimizer; Metaheuristic; Global optimization; Multi-threaded algorithms; Nature-inspired algorithms; Simulated annealing; Genetic algorithms

1. Introduction

Different fields like engineering, logistics, or manufacturing are nowadays presenting global optimization problems that involve a high mathematical complexity. Due to these new problems there is a need for global optimization algorithms to solve diverse kinds of problems, not only specialized ones

Metaheuristic optimization methods explore more efficiently the search space based on algorithms that implement a partial search, also called heuristic algorithms [1,2]. They are ideal for solving real-life problems despite the high complexity generated by all the variables involved with results that approximate to the optimum, as explained in [3]

Metaherusitc algorithms generate multiple points in the search space that explore by interacting and learning between

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. Classification and examples of metaheuristic algorithms based on [10].

them, similar to behaviors found in nature. Some examples of these algorithms and the references to their original authors are Particle Swarm Optimization [4], Genetic Algorithms, Ant Colony Optimization [5], Artificial Bee Colony [6], Firefly Algorithm [7], Bat Algorithm [8], and Cuckoo Search Algorithm [9]. More examples can be found in Fig.

1.

Although these algorithms have shown to obtain good results, they tend to use too much memory or take too much time to execute due to the big populations generated and the need to perform lots of iterations. The algorithm we are proposing in this paper takes advantage of the multicore processors found nowadays in commercial computers for being able to perform an optimization algorithm simultaneously and independently searching for optimal solutions but communicating periodically with each other for being able to learn and head to potential solutions without losing diversity.

With a simple multi-threaded implementation that does not need costly and complex computer systems, we offer an efficient and reliable solution to complex problems that are increasingly found in different fields.

2. Spotted Hyena Optimizer mathematical model and algorithm

Our algorithm is based on Spotted Hyena Optimizer, presented by Dhiman in 2017 [10], which is enclosed in the nature-inspired metaheuristic algorithms [11]. It simulates the different processes involved in hyena’s hunting.

2.1. Encircling the prey (Exploration)

Spotted hyenas surround their prey (the best-located search agent), which means that the best agent in each iteration is going to be considered the prey for the encircling process. For this process, the equations used for the mathematical model are:

−→Dh =→−Bh·−→Pp(x)−−→Ph(x) (1)

−→Ph(x+1)=−→Pp(x)−→−Eh·−→Dh (2)

Equation1 calculates the distance −→Dh between the positions of each spotted hyena−→Ph and of the prey −→Pp for the respective iterationx.→−Band→−E are co-efficient vectors calculated for each dimension of each hyena obtained by

(3)

434 Felix Martinez-Rios et al. / Procedia Computer Science 179 (2021) 432–439

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

B =2·−−→rd1and→−E =2→−h·−−→rd2−→−h ;−−→rd1and−−→rd2are random vectors in [0,1]. Vector→−h, obtained as→−h =5−(t∗(5/Maxt)), decreases linearly from 5 to 0 as iterations increase to the maximum number of iterationsMaxt.

2.2. Hunting

Spotted hyenas hunt in groups, once the prey is located, a subgroup of hyenas (cluster) attack. This cluster is defined as−→Ch = −→Pk+−−−→Pk+1+...+−→PN, where−→Pkdescribes the position of the hyenas. The number of hyenas in the clusterNis obtained byN=count−→Ph,−−−→Ph+1,−−−→Ph+2, ...,

−→Ph+−→M .

Where−→M is a random vector in [0.5,1]. This means that, for the cluster−→Ch, we use all those hyenas that their distance to the best spotted hyena is minor than−→M and these hyenas determine the value ofN. In other words, the valueNis the number of hyenas−→Pkthat meet the condition−→Pk−−→Ph≤→−M, where−→Phis the position of the best spotted hyena. After obtaining the hyenas to form the cluster, in vector−→Chthe sum of all their positions is stored.

2.3. Attacking the prey (exploitation)

The exploitation for this algorithm is obtained thanks to decreasing vector→−h in the course of iterations. The attack mechanism is used to exploit the search space since the beginning. The mathematical formulation to simulate the attack to the prey uses is given by Equation3that updates the position→−P of all the hyenas that are part of the cluster to the average of their previous positions.

P(x+1)= C−→h

N (3)

2.4. SHO Algorithm

Algorithm 1:Spotted Hyena Optimizer Algorithm

1 Generate random initial population of Spotted Hyenas;

2 Evalute the fitness of each Spotted Hyena;

3 Determine the best Spotted Hyena and its distance between other hyenas with Equation1;

4 Determine the cluster;

5 t←0;

6 whiletMax Iterationsdo

7 Generate random vectors−−→rd1,−−→rd2,→−B, and→−E;

8 Determine the best Spotted Hyena and use the cluster to attack as shown in Equation3;

9 foreachhyenado

10 Calculate the distance to the prey/best spotted hyena with Equation1;

11 Update the position according to Equation2;

12 Check that each dimension of the hyena is inside the search boundaries, if not set it to the closest one;

13 end

14 Determine the new best Spotted Hyena;

15 Update the cluster;

16 tt+1;

17 end

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

3. Multi-threaded Spotted Hyena Optimizer with thread-crossing techniques (MT-SHO) 3.1. Multi-threaded implementation of SHO

We propose a multi-threaded implementation of the SHO algorithm (Algorithm1) where we periodically interrupt the execution in all threads to compare the results and to apply crossover techniques between them as in [12] and [13], incorporating elements of Simulated Annealing [14] and Genetic Algorithms [15]. This process is described in Algorithm2.

Algorithm 2:MT-SHO: Multi-threaded implementation of SHO

1 Initialize the SHO parameters in eachτthread inΥ;t←0;

2 whiletMAX NIdo

3 foreachτinΥdo

4 ExecuteCNIτiterations of the SHO (Algorithm1);

5 Sbestτ ←best solution obtained inτ;

6 ifSbestτ is better than Sbestthen

7 SbestSbestτ ;

8 end

9 end

10 foreachτinΥdo

11 Implement the selected thread-crossover technique;

12 end

13 tt+1;

14 end

15 ReturnSbest;

MT-SHO (Algorithm2) uses the following parameters:

1. Υ←set of threadsthat will be used in the process.

2. N←number of Spotted Hyenasthat are going to be generated in each thread to execute the algorithm.

3. CNI←crossover number of iterationsindicates the number iterations of MT-SHO before the crossover.

4. MAX NI←indicates thetotal number of iterationsof SHO Algorithm that each thread is going to execute.

5. Sbest ←is thebest solutionobtained in the entire process.

3.2. Thread-crossover techniques

MT-SHO runs independent versions of SHO (Algorithm1) until the number of iterations in each thread reaches theCNIvalue, then the threads are stopped and their best solutionsSbestτ are compared for obtaining the general best solutionSbestand executing the selected crossover from the following variants:

• No restart (NR):No crossover technique is applied.

• To the best (TB):Obtains the thread with the best solution (Sbest) and copies its parameters to all the other threads, so when they restart their independent executions with the same values.

• Annealing to the best (ATB):Inspired by Simulated Annealing [14], this crossover technique uses the best thread’s solutionSbest to copy its parameters to other threads if the following condition in Equation4 is ac- complished [12]. The condition is evaluated for each thread (where the maximum number of iterations for the

(4)

Felix Martinez-Rios et al. / Procedia Computer Science 179 (2021) 432–439 435 Felix Martinez-Rios et al./Procedia Computer Science 00 (2020) 000–000 3

B=2·−−→rd1and→−E =2→−h·−−→rd2−→−h ;−−→rd1and−−→rd2are random vectors in [0,1]. Vector→−h, obtained as→−h =5−(t∗(5/Maxt)), decreases linearly from 5 to 0 as iterations increase to the maximum number of iterationsMaxt.

2.2. Hunting

Spotted hyenas hunt in groups, once the prey is located, a subgroup of hyenas (cluster) attack. This cluster is defined asC−→h =−→Pk+−−−→Pk+1+...+−→PN, where−→Pkdescribes the position of the hyenas. The number of hyenas in the clusterNis obtained byN=count−→Ph,−−−→Ph+1,−−−→Ph+2, ...,

−→Ph+→−M .

Where→−M is a random vector in [0.5,1]. This means that, for the cluster−→Ch, we use all those hyenas that their distance to the best spotted hyena is minor than→−Mand these hyenas determine the value ofN. In other words, the valueNis the number of hyenas−→Pkthat meet the condition−→Pk−−→Ph≤→−M, where−→Phis the position of the best spotted hyena. After obtaining the hyenas to form the cluster, in vectorC−→hthe sum of all their positions is stored.

2.3. Attacking the prey (exploitation)

The exploitation for this algorithm is obtained thanks to decreasing vector→−h in the course of iterations. The attack mechanism is used to exploit the search space since the beginning. The mathematical formulation to simulate the attack to the prey uses is given by Equation3that updates the position→−Pof all the hyenas that are part of the cluster to the average of their previous positions.

P(x+1)=

−→Ch

N (3)

2.4. SHO Algorithm

Algorithm 1:Spotted Hyena Optimizer Algorithm

1 Generate random initial population of Spotted Hyenas;

2 Evalute the fitness of each Spotted Hyena;

3 Determine the best Spotted Hyena and its distance between other hyenas with Equation1;

4 Determine the cluster;

5 t←0;

6 whiletMax Iterationsdo

7 Generate random vectors−−→rd1,−−→rd2,→−B, and→−E;

8 Determine the best Spotted Hyena and use the cluster to attack as shown in Equation3;

9 foreachhyenado

10 Calculate the distance to the prey/best spotted hyena with Equation1;

11 Update the position according to Equation2;

12 Check that each dimension of the hyena is inside the search boundaries, if not set it to the closest one;

13 end

14 Determine the new best Spotted Hyena;

15 Update the cluster;

16 tt+1;

17 end

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

3. Multi-threaded Spotted Hyena Optimizer with thread-crossing techniques (MT-SHO) 3.1. Multi-threaded implementation of SHO

We propose a multi-threaded implementation of the SHO algorithm (Algorithm1) where we periodically interrupt the execution in all threads to compare the results and to apply crossover techniques between them as in [12] and [13], incorporating elements of Simulated Annealing [14] and Genetic Algorithms [15]. This process is described in Algorithm2.

Algorithm 2:MT-SHO: Multi-threaded implementation of SHO

1 Initialize the SHO parameters in eachτthread inΥ;t←0;

2 whiletMAX NIdo

3 foreachτinΥdo

4 ExecuteCNIτiterations of the SHO (Algorithm1);

5 Sbestτ ←best solution obtained inτ;

6 ifSbestτ is better than Sbestthen

7 SbestSbestτ ;

8 end

9 end

10 foreachτinΥdo

11 Implement the selected thread-crossover technique;

12 end

13 tt+1;

14 end

15 ReturnSbest;

MT-SHO (Algorithm2) uses the following parameters:

1. Υ←set of threadsthat will be used in the process.

2. N ←number of Spotted Hyenasthat are going to be generated in each thread to execute the algorithm.

3. CNI←crossover number of iterationsindicates the number iterations of MT-SHO before the crossover.

4. MAX NI←indicates thetotal number of iterationsof SHO Algorithm that each thread is going to execute.

5. Sbest←is thebest solutionobtained in the entire process.

3.2. Thread-crossover techniques

MT-SHO runs independent versions of SHO (Algorithm1) until the number of iterations in each thread reaches theCNIvalue, then the threads are stopped and their best solutionsSbestτ are compared for obtaining the general best solutionSbestand executing the selected crossover from the following variants:

• No restart (NR):No crossover technique is applied.

• To the best (TB):Obtains the thread with the best solution (Sbest) and copies its parameters to all the other threads, so when they restart their independent executions with the same values.

• Annealing to the best (ATB):Inspired by Simulated Annealing [14], this crossover technique uses the best thread’s solutionSbest to copy its parameters to other threads if the following condition in Equation4is ac- complished [12]. The condition is evaluated for each thread (where the maximum number of iterations for the

(5)

436 Felix Martinez-Rios et al. / Procedia Computer Science 179 (2021) 432–439

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

algorithm is represented byMAX NIandtis the actual iteration).

rand[0,1)≤e

log(MAX NI1t )

(4)

• Genetic with the best (GTB): Based on the Genetic Algorithm procedures [15] where a random number between 1 and the dimensions of the problem is selected for each thread. Dimensions 1 torandare copied from theSbestsolution for each thread, while the remaining dimensions stay the same.

• Annealing genetic with the best (AGTB):This technique combines the two previous ones. For each thread, we evaluate the condition in Equation4to determine if we perform a Genetic Crossover with theSbestvalues.

4. Experiments

The benchmark functions used for the experiments are shown in Tables1,2,3, and4. The algorithm was developed in C# and for the experiments we used 30 hyenas.

Table 1. Unimodal benchmark functions. Based on [10]

f Function Mathematical Equation Dimensions Search space Minimum

f1 Sphere f(x)=d

i=1x2i 30 xi[100,100] f(x)=0

f2 Schwefel 2.22 f(x)=d

i=1|xi|+d

i=1|xi| 30 xi[10,10] f(x)=0

f3 Rotated Hyperellipsoid f(x)=d

i=1

i

j=1xj

2 30 xi[100,100] f(x)=0

f4 Schwefel 2.21 f(x)= max

i=1,...,d|xi| 30 xi[−10,10] f(x)=0

f5 Rosenbrock f(x)=d

i=1

100

xi+1x2i2

+(xi1)2

30 xi[30,30] f(x)=0

f6 Step 2 f(x)=d

i=1xi+0.52 30 xi[100,100] andf(x)=0

f7 Quartic with noise f(x)=d

i=1ix2i +random[0,1) 30 xi[−1.28,1.28] f(x)=0+random[0,1)

4.1. Tuning parameters

To determine the number of threads, six of the benchmark functions were used (f8, f12,f13,f14, f15, f17) with aCNIvalue of 500, the ’Crossover to the best’ technique, varying from 2 to 15 threads; we used the average of 30 executions.

Table5shows the results obtained with the best one for each function shown in bold numbers. To determine the number of threads we made a ponderate average with the number of minimums obtained in each thread, with a result of 12. With the same parameters and functions, but with this number of threads we executed the different crossover techniques to determine the best one.

Table6shows the results obtained for the different crossover techniques where it is evident that the one that gives the most minimums is Genetic to the best. The next experiment uses five functions (excluding f8), with the ’Genetic to the best’ crossover technique and varying theCNI parameter from 100 to 900 in intervals of 100 to determine the best value. After the calculation we obtained that the best value was 400.

(6)

Felix Martinez-Rios et al. / Procedia Computer Science 179 (2021) 432–439 437 Felix Martinez-Rios et al./Procedia Computer Science 00 (2020) 000–000 5

algorithm is represented byMAX NIandtis the actual iteration).

rand[0,1)≤e

log(MAX NI1t )

(4)

• Genetic with the best (GTB): Based on the Genetic Algorithm procedures [15] where a random number between 1 and the dimensions of the problem is selected for each thread. Dimensions 1 torandare copied from theSbestsolution for each thread, while the remaining dimensions stay the same.

• Annealing genetic with the best (AGTB):This technique combines the two previous ones. For each thread, we evaluate the condition in Equation4to determine if we perform a Genetic Crossover with theSbestvalues.

4. Experiments

The benchmark functions used for the experiments are shown in Tables1,2,3, and4. The algorithm was developed in C# and for the experiments we used 30 hyenas.

Table 1. Unimodal benchmark functions. Based on [10]

f Function Mathematical Equation Dimensions Search space Minimum

f1 Sphere f(x)=d

i=1x2i 30 xi[100,100] f(x)=0

f2 Schwefel 2.22 f(x)=d

i=1|xi|+d

i=1|xi| 30 xi[10,10] f(x)=0

f3 Rotated Hyperellipsoid f(x)=d

i=1

i

j=1xj

2 30 xi[100,100] f(x)=0

f4 Schwefel 2.21 f(x)= max

i=1,...,d|xi| 30 xi[−10,10] f(x)=0

f5 Rosenbrock f(x)=d

i=1

100

xi+1x2i2

+(xi1)2

30 xi[30,30] f(x)=0

f6 Step 2 f(x)=d

i=1xi+0.52 30 xi[100,100] and f(x)=0

f7 Quartic with noise f(x)=d

i=1ix2i+random[0,1) 30 xi[−1.28,1.28] f(x)=0+random[0,1)

4.1. Tuning parameters

To determine the number of threads, six of the benchmark functions were used (f8, f12, f13, f14, f15,f17) with aCNI value of 500, the ’Crossover to the best’ technique, varying from 2 to 15 threads; we used the average of 30 executions.

Table5shows the results obtained with the best one for each function shown in bold numbers. To determine the number of threads we made a ponderate average with the number of minimums obtained in each thread, with a result of 12. With the same parameters and functions, but with this number of threads we executed the different crossover techniques to determine the best one.

Table6shows the results obtained for the different crossover techniques where it is evident that the one that gives the most minimums is Genetic to the best. The next experiment uses five functions (excluding f8), with the ’Genetic to the best’ crossover technique and varying theCNIparameter from 100 to 900 in intervals of 100 to determine the best value. After the calculation we obtained that the best value was 400.

6 Felix Martinez-Rios et al./Procedia Computer Science 00 (2020) 000–000 Table 2. Multimodal benchmark functions. Based on [10]

f Function Mathematical Equation Dimensions Search space Minimum

f8 Schwefel f(x)=418.9829dd

i=1xisin

|xi|

30 xi[500,500] f(x)=0

f9 Rastrigin f(x)=

d i=1

x2i10 cos (2πxi)+10

30 xi[5.12,5.12] f(x)=0

f10 Ackley 1 f(x)=−20 exp



−0.2

1 d

d i=1x2i



exp 1

d

d i=1cos (2πxi)

+20+exp (1) 30 xi[−32,32] f(x)=0

f11 Griewank f(x)=d

i=1 x2i 4000d

i=1cosx

ii

+1 30 xi[−600,600] f(x)=0

f12 Generalized Penalized 1

f(x)=πd

10 sin2y1)+d−1

i=1(yi1)2

1+10 sin2yi+1) +(yn1)2

+

d

i=1u(xi,a,k,m),where yi=1+14(xi+1),u(xi,a,k,m)=





k(xia)m xi>a

0 axia

k(xia)m xi<a a=10,k=100,m=4

30 xi[−50,50] f(x)=0

f13 Generalized Penalized 2

f(x)=0.1

sin2(3πx1)+d−1

i=1(xi1)2

1+sin2(3πxi+1)

+(xd1)2

1+sin2(2πxd) +d

i=1u(xi,a,k,m),where u(xi,a,k,m)=





k(xia)m xi>a

0 axia

k(xia)m xi<a a=5,k=100,m=4

30 xi[50,50] f(x)=0

Table 3. Multimodal fixed-dimension benchmark functions. Based on [10]

f Function Mathematical Equation Dimensions Search space Minimum

f14 Shekel Foxhole f(x)=



5001+ d

j=25 1 j+2

i=1(xiai,j)6





−1

,where ai,j=

3216 0 16 3232...0 16 32

−32−32−32−32−32−16...32 32 32

2 xi[65.536,65.536] f(x)=0.9980038377

f15 Kowalik f(x)=10

i=1

aix1(b2i+bix2)

b2i+bix3+x4

2

,where

a=[0.1957,0.1947,0.1735,0.16,0.0844,0.0627,0.0456,0.0342,0.0323,0.0235,0.0246]

b=[4,2,1,0.5,0.25,1/6,0.125,0.1,1/12,1/14,0.0625]

4 xi[−5,5] f(x)=0.00030748610

f16 Six Hump Camel f(x)=

42.1x21+x341 x21+x1x2+

4+4x22

x22 2 xi[5,5] f(x)=1.0316285

f17 Branin 1 f(x)=

x25.1x221+5xπ162

+10 11

cos (x1)+10 2 xi[5,5] f(x)=0.397887 f18 Goldstein Price f(x)=

1+(x1+x2+1)2

1914x1+3x2114x2+6x1x2+3x22 30+(2x13x2)2

1832x1+12x21+48x236x1x2+27x22 2 xi[−2,2] f(x)=3

4.2. Final experiments

For the final experiment of MT-SHO we used 30 hyenas, 30 repetitions, 12 threads, and Genetic with the best crossover with aCNIvalue of 400. We compared the results with the ones published in [10] and made the Wilcoxon test to validate that our results improved. Table7compares nine algorithms with MT-SHO; the best results obtained are shown in bold.

4.3. Results analysis

In Table 7 we list the results obtained by our algorithm and the ones obtained by other nine algorithms. We performed the Wilcoxon test to the results obtained as presented in [16]. The test helped us confirm that our algorithm obtained a significantly better result in 21 of the 24 functions tested. In the table the values resalted in bold are the ones that obtained the most significantly better result. The functions in which our algorithm did not improve the

Referencias

Documento similar