Keywords

1 Introduction

Fireworks Algorithm (FWA) [1] is a new group of intelligent algorithms developed in recent years based on the natural phenomenon of simulating fireworks sparking, and can solve some optimization problems effectively. Compared with other intelligent algorithms such as particle swarm optimization and genetic algorithm, the FWA algorithm adopts a new type of explosive search mechanism, which is explosive. In addition, to calculate the explosion amplitude and the number of explosive sparks through the interaction mechanism between fireworks.

However, many researchers quickly find that traditional FWA has some disadvantages in solving optimization problems, the main disadvantages include slow convergence speed and low accuracy, thus, many improved algorithms have been proposed. So far, research on the FWA has concentrated on improving the operators. One of the most important improvements of the FWA, the enhanced fireworks algorithm (EFWA) [2], the operators of the conventional FWA were thoroughly analyzed and revised. Based on the EFWA, an adaptive fireworks algorithm (AFWA) [3] was proposed, which was the first attempt to control the explosion amplitude without preset parameter by detecting the results of the search process. In [4], a dynamic search fireworks algorithm (dynFWA) was proposed in which divided the fireworks into core firework and non-core fireworks according to the fitness value and adaptive adjustment of explosion amplitude for the core firework. In addition, since the FWA was proposed, it has been applied to many areas [5], including digital filters design [6], nonnegative matrix factorization [7], spam detection [8], etc.

Aforementioned AFWA variants can improve the performance of FWA to some extent. However, inhibition of premature convergence and solution accuracy improvement is still a challenge issue for further research on AFWA.

In order to improve the above problems, in this paper, the searching range of AFWA is expanded by searching the mutual cooperation between the two groups of master sub-populations, to accelerate the convergence rate and improve the search ability of the algorithm. In addition, a new selection strategy is proposed to keep the diversity of the population. Based on this, an improved fireworks optimization algorithm (TMSFWA) is proposed to improve the convergence speed and precision.

The paper is organized as follows. In Sect. 2, the adaptive fireworks algorithm is introduced. The TMSFWA algorithm is presented in Sect. 3. The simulation experiments and results analysis are given in details in Sect. 4. Finally, the conclusion summarizes in final part.

2 Adaptive Fireworks Algorithm

The TMSFWA is based on the AFWA because its ideal is very simple and it works stably. In this section, we will briefly introduce the framework and the operators of the AFWA for further discussion.

In AFWA, there are two important components: the explosion operator (the sparks generated by the explosion) and the selection strategy.

2.1 Explosion Operator

Each firework explodes and generates a certain number of explosion sparks within a certain range (explosion amplitude). The numbers of explosion sparks (Eq. (1)) calculated according to the qualities of the fireworks.

For each firework X i , its explosion sparks’ number is calculated as follows:

$$ S_{i} = m \times \frac{{y_{\hbox{max} } - f(X_{i} ) + \varepsilon }}{{\sum\limits_{i = 1}^{N} {(y_{\hbox{max} } - f(X_{i} )) + \varepsilon } }} $$
(1)

where y max  = max(f(X i )), m is a constant to control the number of explosion sparks, and ε is the machine epsilon to avoid S i is equal to 0.

In AFWA, the calculation of the amplitude of the normal fireworks and the optimal firework (the value of the objective function is smallest) are different. The normal fireworks’ explosion amplitudes are calculated just as in the previous versions of FWA:

$$ A_{i} = A \times \frac{{f(X_{i} ) - y_{\hbox{min} } + \varepsilon }}{{\sum\limits_{i = 1}^{N} {(f(X_{i} ) - y_{\hbox{min} } ) + \varepsilon } }} $$
(2)

where y min  = minf(X i )), A is a constant to control the explosion amplitude, and ε is the machine epsilon to avoid A i is equal to 0.

But for the optimal firework, its explosion amplitude is adjusted according to the search results in the last generation:

$$ A_{i} (t + 1) = \left\{ {\begin{array}{*{20}l} {UB - LB} \hfill & {t = 0\,\;or\,\;f(s_{i} )\, <\, f(x)} \hfill \\ {0.5 \times (\lambda \times ||s_{i} - s^{*} ||_{\infty } + A_{i} (t))} \hfill & {otherwise} \hfill \\ \end{array} } \right. $$
(3)

where UB and LB stand for the upper bound and lower bound of the search space respectively, s 1 …s n denote all sparks generated in generation t, s* denotes the best spark and x stands for fireworks in generation t, and the parameter λ is suggested to be fixed value of 1.3 empirically.

2.2 Selection Strategy

In AFWA, it applies a selection method, which is referred to as elitism-random selection method. In this selection process, the optima of the set will be selected first. Then, the other individuals are selected randomly.

3 The Proposed Algorithm (TMSFWA)

The proposed algorithm (TMSFWA) is a simple and easy to implement AFWA based on two-master sub-populations and new selection strategy.

3.1 Two-Master Sub-population

The realization of the two-master sub-populations’ idea is: in a random initialization of a group of fireworks, it is divided into two independent sub-populations, one is the master sub-population, and the other is the assistant sub-population. The definitions are as follows.

Definition 1.

Master sub-population is the optimal firework in the current fireworks population.

Definition 2.

Assistant sub-population is the fireworks except the optimal in the current fireworks population.

For the assistant sub-populations are iteratively searched by the AFWA, but displacement operation of the master sub-population is calculated by two methods. Displacement operation of a master sub-population is calculated as the AFWA (Eq. (4)). As we known, the position of the master sub-population is the best information in the population, therefore, the other master sub-population is added into the AFWA, and its displacement operation is calculated by Eq. (5).

$$ \Delta x_{i}^{k} = x_{i}^{k} + rand(0,A_{i} ) $$
(4)
$$ \Delta x_{i}^{k} = x_{i}^{k} - rand(0,A_{i} ) $$
(5)

where rand(0, A i ) represents a uniform random number within the amplitude A i .

At the end of each iteration, the fitness values corresponding to the optimal positions of the two master sub-populations are compared, and the optimal fireworks are retained. The two master sub-populations complement each other and co-evolve to fully extend the search range and mine the useful information in the search domain to reduce the risk of the AFWA falling into the local optimal.

The Algorithm 1 is proposed to generate the explosion sparks with two-master sub-population.

3.2 New Selection Strategy

In AFWA, it applies a selection method, which is referred to as elitism-random selection method. In this selection process, the optima of the set will be selected firstly. Then, the other individuals are selected randomly. Obviously, this method cannot ensure the diversity of the population. Based on this, this paper proposes a new selection strategy: elitism-tournament selection strategy.

The same as AFWA, elitism-tournament selection also requires that the current best location is always kept for the next iterations. And then, two individuals were randomly selected from the remaining individuals in the population. Each time the individual with the best fitness is placed in the next generation group, the next generation was obtained by repeating N−1 times [9].

From the above, we know that the elitism-tournament selection not only maintaining the competitive advantage, but also considering the diversity of the population. This method can maintain the diversity of the population, reflect the better global searching ability.

4 Experiments

4.1 Experiment Settings

Similar to AFWA, the number of fireworks in TMSFWA is set to 5, and the number of mutation sparks is also set to 5, the maximum number of sparks is set to 200 each generation.

In the experiment, the function of each algorithm is repeated 51 times, and the final results after the 300000 function evaluations are presented. In order to verify the performance of the algorithm proposed in this paper, we use the CEC2013 test set [10], including 28 different types of test functions. All experimental test functions dimensions are set to 30, d = 30.

Finally, we use Matlab R2014a software on a PC with a 3.2 GHz CPU (Intel Core i5-3470), and 4 GB RAM, and Windows 7 (64 bit).

4.2 Simulation Results and Analysis

Comparison of TMSFWA with FWA-Based algorithms.

To assess the performance of TMSFWA, TMSFWA is compared with EFWA, dynFWA and AFWA, and EFWA parameters set in accordance with [2], AFWA parameters set in accordance with [3], dynFWA parameters set in accordance with [4].

For each test problems, each algorithm runs 51 times, all experimental test functions dimensions are set as 30, and their mean errors and total number of rank 1 are reported in Table 1. The best results among the comparisons are shown in bold. It can be seen that the proposed TMSFWA clearly outperforms among EFWA, AFWA and dynFWA on the test functions.

Table 1. Mean errors and total number of rank 1 achieved by EFWA, AFWA, dynFWA and TMSFWA.

To clear show the advantages of TMSFWA, the convergence curves of mean objective function value which have great difference in evolution speed are plotted in Fig. 1. Evidently, TMSFWA has better solution accuracy, convergence rate and robustness than all the competitors on majority of cases.

Fig. 1.
figure 1

Convergence curves of the TMSFWA, the AFWA, the EFWA and the dynFWA.

Comparison of TMSFWA with other swarm intelligence algorithms.

In order to measure the relative performance of the TMSFWA, a comparison among the TMSFWA and other swarm intelligence algorithms is conducted on the CEC 2013 single objective benchmark suite. The algorithms compared here are described as follows.

  • Artificial bee colony (ABC) [11]: A powerful swarm intelligence algorithm. The results were reported in [12].

  • Standard particle swarm optimization (SPSO2011) [13]: The most recent standard version of the famous swarm intelligence algorithm PSO. The results were reported in [5].

  • Differential evolution (DE) [14]: One of the best evolutionary algorithms for optimization. The results were reported in [15].

  • Covariance matrix adaptation evolution strategy (CMA-ES) [16]: A developed evolutionary algorithm. The results are based on the code from (https://www.lri.fr/~hansen/purecmaes.m) using default settings.

The above four algorithms are using the default settings. The comparison results of among ABC, DE, CMA-ES, SPSO2011, and TMSFWA are presented in Table 2, where ‘Mean error’ is the mean error of best fitness value. The best results among the comparisons are shown in bold. ABC beats other algorithms on 12 functions (some differences are not significant), which is the most, but performs poorly on other functions. CMA-ES performs extremely well on unimodal functions, but suffers from premature convergence on some complex functions. From the Table 3, the TMSFWA ranked the top three (25/28) more than the other four algorithms, and in terms of average ranking, the TMSFWA performs the best among these 5 algorithms on this benchmark suite due to its stability. DE and ABC take the second place and the third place respectively. The performances of CMA-ES and the SPSO2011 are comparable.

Table 2. Mean errors achieved by ABC, DE, CMA-ES, SPSO2011 and TMSFWA.
Table 3. Total number of rank and average rankings.

5 Conclusions

TMSFWA was developed by applying two-master sub-population and a new selection strategy to AFWA. We apply the CEC2013 standard functions to examine and compare the proposed algorithm TMSFWA with ABC, DE, SPSO2011, CMA-ES, AFWA, EFWA and dynFWA. The results clearly indicate that TMSFWA can perform significantly better than other seven algorithms in terms of solution accuracy. Overall, the research demonstrates that TMSFWA performed the best for solution accuracy.