Abstract
The core fireworks dynamic explosion radius strategy is used in dynamic search fireworks algorithm (dynFWA), it is an important algorithm to solve the optimization problem. DynFWA accuracy is low and is too early to fall into local optimal solutions. In order to improve the defects, the traditional dynamic search fireworks algorithm is improved by embedding two different learning factors, it is called as the improved dynFWA (IdynFWA). The learning factor of the algorithm makes full use of the individual fireworks information of each generation in the search process, the fireworks can search for information to the group’s excellent search information, its two different generating ways are helpful to balance the local search and global search ability. The improved algorithm is tested on 28 Benchmark functions of CEC2013. The experimental results show that IdynFWA is superior to dynFWA, it is better than particle swarm algorithm SPSO2011 and differential evolution algorithm DE optimize performance.
Keywords
Introduction
Fireworks algorithm (FWA) is a new group of intelligent algorithms in recent years [1], the natural phenomenon of the fireworks explosion sparking is simulated, some optimization problems can be solved effectively. Compared with other intelligent algorithms such as particle swarm optimization and genetic algorithm, a new type of explosive search mechanism is used in FWA. In addition, the fireworks are used by means of an interaction mechanism to calculate the explosion radius and the number of the exploded sparks. Many researchers quickly found that the traditional FWA has some shortcomings in solving the optimization problem, such as the scope of application is small, there is slow convergence, time-consuming calculation is large. In view of these shortcomings, the researchers put forward many improvement programs, the improvement of the traditional fireworks algorithm is divided into two aspects: one is to analyze and improve the four operators of the fireworks algorithm; the other is to combine with other evolutionary algorithms to form a hybrid algorithm. Pei et al. used the population position and fitness value information of the explosion spark and Gaussian variation spark generated during the iterative process of the fireworks algorithm to estimate the search space shape of the objective function, and provide heuristic acceleration information for the algorithm [2]. Si and Ghosh constructed a new method for calculating the number and magnitude of fireworks explosions, achieving the effects of controlling the number of fireworks explosions, the development and exploratory nature of the algorithm [3]. Zheng et al. had improved the traditional fireworks algorithm operator, mapping rules and selection strategy, the enhanced fireworks algorithm (EFWA) was proposed [4]. He classified the fireworks population as the core fireworks and non-core fireworks according to the merits of the fitness value, the dynamic search fireworks algorithm (dynFWA) was put forward by adaptively adjusting the explosion radius of the core fireworks [5], the search performance of the algorithm can be improved, its performance is strengthened due to the improvement of the fitness value of the best local fire search ability. In addition, Li et al. proposed an adaptive fireworks algorithm (AFWA) by automatically adjusting the radius of the explosion [6]. Yu et al. proposed a novel algorithm FWADM, the differential mutation operator was used to replace the Gaussian mutation operator in the fireworks algorithm [7]. Zheng et al. proposed to introduce the mutation, crossover and selection operator in the differential evolution algorithm into the fireworks algorithm, the hybrid algorithm FWADE was obtained [8]. There are other improvements and additions, such as the multi-target fireworks algorithm [9, 10], the hybrid fireworks algorithm [11, 12] and the parallel fireworks algorithm [13]. In addition, FWA has been applied in many fields, including non-negative matrix factorization (NMF) calculations [14, 15, 16], digital filter design [17], selective harmonic elimination [18], other fields.
The mutation test is a fault-based software test technique. This technology has been extensively studied and used for more than 30 years. It contributes a range of methods, tools, and reliable results for software testing.
Let’s use an example to explain what a mutation test is. Consider the following code snippet:
If (a && b) c
If the conditional operator replaces && with
If (a
In order to kill this mutation, the following conditions must be met:
The test data must be covered by the different states caused by the mutation and the original program. For example, a The value of c should be propagated to the program output and tested.
The weak mutation coverage needs to be satisfied (1), and the strong mutation coverage needs to satisfy (1) (2).
The mutation test aims to find valid test cases and discover real errors in the program. In a project, the number of potential bugs is huge, and it is impossible to fully cover all errors by generating mutants. Therefore, traditional mutation testing aims to find a subset of these errors and to adequately approximate these bugs. This theory is based on two assumptions: Competent Programmer Hypothesis (CPH) and Coupling Effect (CE) [19].
CPH means: assuming that programmers are capable, they try to develop programs better and achieve correct and feasible results, rather than destroying them. It focuses on the behavior and intent of the programmer. The CE (coupling effect) is more concerned with the category of errors in the mutation test. A simple error is often caused by a single mutation (such as a syntax error), and a large and complex error is often caused by multiple mutations. Complex variants are often composed of many simple variants.
In this paper, the traditional dynamic search fireworks algorithm is improved, a dynamic search algorithm (improved dynFWA, IdynFWA) is proposed with learning factor, the ability of the fireworks is enhanced to search for the excellent search information of the population, it helps to balance the local search and global search capabilities, the accuracy of the algorithm is improved, and there is better search performance. The CEC2013 28 benchmark function is used to test the effectiveness of the algorithm.
Without loss of generality, it is assumed that the optimization problem to be solved is as follows:
Explosion operator
When the fireworks explodes, it will produce a lot of sparks in a certain area around, they are the number of explosive sparks and the explosion radius. For the
Where
In the Eq. (1), in order to limit the explosion sparks, the fireworks’ individual with the good fitness value does not produce too much explosion sparks, while the fireworks’ individual with the poor fitness value will not produce too little explosion sparks. The following restrictions were made for the number of exploded sparks [1]:
Where
Fireworks are divided into two categories, namely, non-core fireworks and core firework, where the core fireworks is the smallest fireworks individual in the fireworks population. The radius calculation of the non-core fireworks is not the same as the core fireworks. In this paper,
Where
Where
The above mentioned sparks may be out of the feasible domain. To solve this problem, the following mapping rules are given to deal with sparks beyond the boundary:
Where
In order to enable the excellent information in the fireworks population to be passed to the next generation of population, an elite random selection strategy is used in the algorithm, N individuals are selected from the fireworks population and the explosive sparks into the next generation. The individuals with the smallest fitness value (optimal) in the candidate set are selected first, the random selection strategy is adopted to select the remaining N-1 individuals.
Dynamic search fireworks algorithm with learning factor
In the optimization algorithm, the balance between the local search ability and the global search ability is one of the important factors that affect the performance of the algorithm. IdynFWA is improved on the basis of dynFWA, and the difference is that IdynFWA adds a new operator that produces a variant sparks, it is called a mutation operator.
The traditional dynFWA core fireworks calculation method is too simple, the last iteration is just considered to find a better solution, the search performance is mainly dependent on the zoom of the core fireworks explosion radius, it did not make full use of some of the information in the search process, the search strategy is localized in the vicinity of the fireworks with the best fitness value, it helps to find the optimal solution. However, in the optimization of the multi-peak problem, there is a large risk of falling into the local optimum, it is resulting in premature convergence of the algorithm. Therefore, the dynFWA algorithm tends to search for more locally in search strategy, it is difficult to jump out of the local optimal solution when multi-peak optimization is achieved. Moreover, the core fireworks radius of each generation will be updated, it is too frequent. These shortcomings lead to that the traditional dynFWA has a poor search ability, optimization accuracy is low, it is easy to fall into the local optimal solution. In order to solve the above problems and increase the diversity of the population, a new spark mutation operator is designed for IdynFWA. These new sparks are collectively referred to as variation sparks in this paper. The variation operator takes full advantage of the best fireworks’ location and historical success information for each generation. The following describes the mutation operator in detail:
Where
Where
28 Benchmark functions of CEC2013
Results of 4 algorithms test on 28 Benchmark functions (D
Results of 4 algorithms test on 28 Benchmark functions (D
Where
Under the assumption that the population obeys the Cauchy distribution, the algorithm uses the median and scale parameters of the individual distribution to adaptively adjust the search range of the population in each iteration, thus achieving a good balance relationship between local search and global search.
IdynFWA’s algorithmic process is described as follows:
Generate N locations randomly at the initial moment, ie N fireworks. Calculate the fitness value for each fireworks. Cycle the following steps Eqs (1) to (4) until the termination condition is satisfied.
Use algorithm 1 to generate explosive sparks. Use algorithm 2 to produce variant sparks. Calculate the fitness values for all exploding sparks and variation sparks. The selection strategy is used from the fireworks population, explosive sparks and variation sparks, N individuals are selected as the next iteration calculation of fireworks. Return the position of the optimal individual, and its fitness value is calculated.
Experimental dataset and parameter settings
In order to verify the performance of the proposed IdynFWA algorithm in this paper, the 28 different Benchmark functions of the CEC2013 are analyzed in 30-dimensional and 50-dimensional simulations. The Benchmark function is listed in Table 1, and the specific definition of the function is in the reference [22]. In addition, the traditional dynFWA algorithm, the standard particle swarm algorithm SPSO2011 and the differential evolution algorithm DE were compared and analyzed. Among them, dynFWA parameter setting is as reference [5], particle swarm algorithm SPSO 2011 parameter setting is as reference [23, 24]. The parameters of the DE algorithm are set as follows: F
Experimental results and analysis
Tables 2 and 3 show the average error and standard deviation of the four algorithms on the 30 and 50 dimensions of the 28 Benchmark functions. Tables 4 and 5 show the average error rankings for their different types of functions. Among them, the bold representation of the four algorithms are in the optimal solution.
Rank of mean errors on 28 Benchmark functions (D
30)
Rank of mean errors on 28 Benchmark functions (D
Rank of mean errors on 28 Benchmark functions (D
It can be seen from Tables 2 and 3 that the optimization performance of IdynFWA is better than that of the other three algorithms, especially on the functions f
From the Tables 4 and 5, IdynFWA ranking is better than the other three algorithms in the unimodal function, multi-peak function and all the function, in the composite function, IdynFWA ranking is better than SPSO2011 and DE, and it is same as dynFWA.
Function evolution curve.
In the 28 Benchmark functions, f
The most of the parameters of dynFWA and IdynFWA are the same. The improvement of the optimization effect is mainly due to the introduction of the learning factor. If the learning factor is generated by the Cauchy distribution with large positional parameters, it is favorable to the global search, and the learning factor is generated by the Cauchy distribution with small positional parameters,it factors favors local search. Their introduction in the search process has played a better direction of the guidelines, the ineffective search has been reduced; the automatic adjustment of learning factor improves the search accuracy to a certain extent, it results in better search performance. In addition, IdynFWA’s superior performance is far superior to the SPSO2011 and DE algorithms.
Mean errors of different T on 28 Benchmark functions
In addition, according to the above description, the mutation operator summarizes the previous search process every T times, and the value of T has a great influence on the optimization effect of the algorithm. In this paper, we adjust the analysis of T, the control variable method is used, that is, other related parameters arefixed and unchanged, by changing the value of T alone, its impact is observed on the algorithm results. In the single-peak function, multi-peak function and composite function, T value of 100, 500 and 1000 in the experiment, in each test function, D
The learning factor in the improved algorithm (IdynFWA) makes full use of the historical success information in the search process, so that the individual fireworks can learn from the excellent search information in the group, so that the size can be adaptively adjusted, and the two different ways of generating the learning factor can help. Local search and global search capabilities of the balance algorithm. In order to prove the optimization characteristics and effectiveness of the improved algorithm proposed in this paper, the experimental simulation of an international standard test function for a set of optimization problems is carried out for the improved algorithm, basic algorithm and other representative algorithms, and the experimental results are compared and analyzed. The improved dynamic search fireworks algorithm avoids the defects of the premature convergence of the basic algorithm to a certain extent, and the optimization precision is also improved. Secondly, by applying the dynamic search fireworks algorithm to the subset generation process of feature selection (also known as feature extraction), a feature selection method based on dynamic search fireworks algorithm is proposed. Feature selection refers to the process of selecting the optimal feature subset from a complete set of original data features, and evaluates the pros and cons of the selected feature subsets through specific evaluation criteria. Feature selection has a wide range of applications in machine learning, pattern recognition and data mining, and it is also one of the key issues affecting the classification effect of classifiers. Each dimension of the final feasible solution produced by the method at the end of the subset generation phase represents whether its corresponding feature is selected. Then, the classification error rate is used as the fitness function to evaluate the pros and cons of the selected feature subset. The smaller the fitness function value is, the smaller the classification error rate is, indicating that the currently selected feature subset is better. Therefore, selecting the optimal feature subset is to find a feasible solution that makes the fitness function (classification error rate) minimum.
Conclusion
In this paper, for the traditional dynamic search fireworks algorithm with low optimization precision, it easy to fall into the local optimal solution, an improved dynamic search fireworks algorithm (IdynFWA) is proposed with learning factor. The learning factor is introduced by using historical success information, the newly added mutation operator has automatic adjustment, the better searching direction and better candidate solution are provided for the later search process, and the search performance of the algorithm is improved. Based on the simulation results of 28 Benchmark functions on CEC2013, IdynFWA can effectively improve the optimization precision of the algorithm, local search ability and global search ability are balanced for the algorithm. However, the disadvantage of IdynFWA is that the algorithm takes a long time, because a new type of explosion search mechanismis used.
The IdynFWA fireworks algorithm has the following characteristics: randomness, locality, explosiveness, hidden parallelism, diversity, and transientity. The following describes these features of the fireworks algorithm.
Explosive
After an iteration of the fireworks algorithm begins, the fireworks explode within the radiation range, creating other sparks. After the end of this iteration, the fireworks algorithm selected sparks as the next generation of fireworks, restored the number of fireworks, and prepared for the next iteration. Every time iteration, the fireworks will burst, indicating that the fireworks algorithm is explosive.
Transient
When an iterative calculation begins, each fireworks produces different numbers of sparks and explosions depending on the fitness value. Then, the fireworks algorithm will generate sparks under the action of the explosion operator and the mutation operator. Finally, the best individual is selected first, and then other individuals are selected according to the distance. These selected individuals will be used as fireworks for the next generation of explosions, and the rest of the sparks will not be retained. Unseen sparks or fireworks will die, indicating that the fireworks algorithm is instantaneous.
Simplicity
Like the swarm intelligence algorithm, each fireworks only needs to perceive the information around itself and follow simple rules to accomplish its mission. In general, the fireworks algorithm itself is not complicated, composed of simple individuals, indicating that the fireworks algorithm is simple.
Local coverage
In the fireworks algorithm, all fireworks will spark in the corresponding explosion range. Unless it is beyond the feasible domain, the spark generated is limited to a certain range. The local characteristics of the fireworks algorithm reflect the powerful local search ability of the fireworks algorithm, which can be used to search for the optimal solution in the later stage of the algorithm operation. Therefore, the fireworks algorithm is local.
Emergence
Through competition and collaboration between fireworks, groups show a high degree of intelligence that simple individuals do not have. The interaction between fireworks is much more complicated than the behavior of individual individuals, so the fireworks algorithm is emerging.
Distribution parallelism
During each iteration of the fireworks algorithm, each fireworks explode in different coordinate ranges, that is, a search for different coordinate intervals, and at the end, all the sparks and fireworks will be combined to select the next generation of fireworks. In one iteration, the algorithm is essentially a parallel search, showing the distributed parallelism of the fireworks algorithm.
Diversity
Population diversity is the key to the performance of the population optimization algorithm. The maintenance of group diversity can ensure that the algorithm jumps out of the local extreme points, so that it can converge to the global best, which is the significant difference between the group optimization algorithm and the general optimization algorithm. The greater the diversity of the group, the wider the individual distribution in the algorithm, the greater the possibility of finding the optimal value, and it will not significantly affect the convergence ability of the algorithm. Therefore, population diversity is an important part of the fireworks algorithm. The diversity of fireworks algorithms mainly reflects the following three aspects.
Diversity of sparks and explosion amplitude: Under the action of the explosion operator, depending on the fitness value of each fireworks, it produces different numbers of sparks and different explosion amplitudes. Fireworks with high fitness values produce more sparks, and the explosion range is relatively small, while fireworks with low fitness values produce less sparks, and the explosion range is relatively large. Therefore, the variety of sparks and the magnitude of the explosion are guaranteed. Displacement operations and diversity of Gaussian variation: The fireworks algorithm has two kinds of operators, the first is the explosion operator and the second is the mutation operator. In the displacement operation of the blast operator, a displacement is randomly generated for the calculated amplitude range, and the random displacement is added to the selected fireworks. Under the influence of the mutation operator, the selected fireworks need to be multiplied by a random number that satisfies the Gaussian distribution. The blast operator is related to the fitness value of the fireworks, and the mutation operator is related to the coordinate value of the fireworks itself. The two operators are essentially different and guarantee the diversity of the explosion. Fireworks diversity: Through a certain selection mechanism, the remaining fireworks coordinate values are different, thus ensuring the diversity characteristics of the fireworks algorithm. In addition, in the selection strategy, sparks larger than other sparks are easier to select, and also reflect the diversity of fireworks in the fireworks algorithm.
The number of fireworks and sparks in the fireworks algorithm is uncertain and can be determined by the complexity of the problem. The number of fireworks and sparks can be more or less, and the increase and decrease of individuals can effectively solve the problem, so the fireworks algorithm is scalable.
Adaptability
When the fireworks algorithm solves the problem, the problem is not required to have a display expression, and the problem can be solved by calculating the fitness value. At the same time, the fireworks algorithm has low requirements on the problem and can also solve the problem of display expression. Therefore, the fireworks algorithm is adaptable.
Footnotes
Acknowledgments
This work is sponsored by the Scientific Research Project (NO. 17C0896) of Hunan Provincial Education Department, China.
