Abstract

Bacterial foraging optimization (BFO) algorithm is a novel swarm intelligence optimization algorithm that has been adopted in a wide range of applications. However, at present, the classical BFO algorithm still has two major drawbacks: one is the fixed step size that makes it difficult to balance exploration and exploitation abilities; the other is the weak connection among the bacteria that takes the risk of getting to the local optimum instead of the global optimum. To overcome these two drawbacks of the classical BFO, the BFO based on self-adaptive chemotaxis strategy (SCBFO) is proposed in this paper. In the SCBFO algorithm, the self-adaptive chemotaxis strategy is designed considering two aspects: the self-adaptive swimming based on bacterial search state features and the improvement of chemotaxis flipping based on information exchange strategy. The optimization results of the SCBFO algorithm are analyzed with the CEC 2015 benchmark test set and compared with the results of the classical and other improved BFO algorithms. Through the test and comparison, the SCBFO algorithm proves to be effective in reducing the risk of local convergence, balancing the exploration and the exploitation, and enhancing the stability of the algorithm. Hence, the major contribution in this research is the SCBFO algorithm that provides a novel and practical strategy to deal with more complex optimization tasks.

1. Introduction

Bacterial foraging optimization (BFO) algorithm is a novel swarm intelligence optimization algorithm based on the foraging behavior of E. Coli, which was proposed by Professor Passino in 2002 [1, 2]. Compared with other optimization algorithms, the BFO algorithm aces in fast convergence and global search by its simple bacterial individual structure and behavior, varied group types and characteristics, and efficient life cycle [35] even though it is still in a preliminary stage of research. Therefore, the BFO algorithm has been successfully applied in many fields. Literature in [68] adopted the BFO algorithm to optimize the probabilistic planning, load dispatch, reconstruction, and loss minimization of the power energy network. Artificial intelligence learning and robot automatic control can also refer to the BFO algorithm [911]. Research in [12, 13] applied the BFO algorithm to the optimization of the wireless network, including the structure design and routing topology.

At present, the research of BFO focuses on improving its performance for more applications. One of the commonly used methods is to adjust the algorithmic logic. For example, Tang et al. [14] proposed an improved multilevel thresholding approach to improve the global search ability of the classical BFO. By adjusting the search scope and chemotaxis variables dynamically, the bacterial population was guided to move towards the global optimum [15]. Besides, the combination of BFO and other algorithms is also an appealing topic. The convergence speed and the local search ability of the BFO algorithm were proved by referring to some other algorithms, such as the neural network in [16], the genetic algorithm (GA) in [17], the particle swarm optimization (PSO), and unit step function in [18], as well as new chemotaxis with the differential evolution (DE) operator in [19, 20].

According to the research on the improvement of the BFO, the classical BFO algorithm still has some drawbacks, in which the fixed chemotactic step size and the weak connection among bacteria matter the most. The first drawback, the fixed chemotactic step size, makes the balance between exploration and exploitation difficult to realize. The second drawback, the weak connection among bacteria, leads to poor randomicity in chemotaxis. When searching in a complex multimodal solution set, the above two drawbacks will lead the bacteria community to the local convergence rather than the global one.

To overcome these drawbacks, this paper proposed the BFO with self-adaptive chemotaxis strategy (SCBFO) as one of the novel BFO algorithms, which improves the classical algorithm theoretically via the following two aspects.

First, a self-adaptive swimming method based on bacterial search state features is proposed to overcome the classical drawback caused by a fixed step size. Three important features of the bacterial search state, the population diversity, the iteration, and the mean fitness are extracted and calculated. They are taken as the inputs of a multidimension fuzzy logic controller (MFLC) to obtain the chemotaxis swimming step size suitable for the current search state.

Then, the chemotaxis flipping is improved in the SCBFO based on information exchange strategy. By introducing the strategy of information exchange between bacteria, the state perception between bacteria is improved so that bacteria can understand the overall optimization state in the optimal solution space and instantly adjust the flipping of bacterial chemotaxis.

Therefore, the SCBFO algorithm can effectively solve the performance degradation caused by the drawbacks of the classical BFO and improve the search performance stability.

This paper is structured as follows: Section 2 analyses the general solving process of the BFO algorithm. Section 3 proposes the SCBFO algorithm, which is based on the self-adaptive chemotaxis strategy. In Section 4, the SCBFO algorithm is tested using the CEC 2015 benchmark test set and compared with other algorithms, in which the optimization results, the convergence trend, and the performance stability of the algorithm are analyzed. Section 5 summarizes the performance of the SCBFO algorithm.

2. Fundamental Structure of the BFO Algorithm

The fundamental structure of the BFO algorithm was proposed in the classical BFO algorithm and is shared by all the improved versions of the BFO algorithm [2, 18]. Thus, the fundamental structure of the BFO algorithm is established in this section alongside essential functions that will be used and optimized in this paper, as shown in Figure 1.

To start with, the initialization of the classical BFO algorithm includes two important contents:(1)Solution space initialization: the solving spatial dimension D, range, and mapping function are designed.(2)Bacterial initialization: the number of bacteria is nominated by S. The position of the ith bacterium in the optimization space is expressed as Pi (j, k, l), which equals to the optimal parameter of the solution, i.e., Pi (j, k, l) = [m1, m2, …, mD].

Therefore, the fitness of the ith bacterium in the optimization space is expressed as Ji (j, k, l), which is determined by the function of the bacterium position in the following:

In (1), the lower values of the function indicate the higher fitness [1]. i represents the ith bacterium, while j, k, and l correspond to the main processes of the BFO algorithm: chemotaxis, reproduction, and elimination and dispersal.

2.1. Chemotaxis

The chemotaxis process consists of a great amount of swimming and flipping motions. In the jth chemotaxis process, the movement of the ith bacterium can be expressed in the following:where the swimming step length of the ith bacterium is divided into single swimming step size and the number of swimming n and is the direction vector of the ith bacterium in the p-dimension optimization space. Each element of is a numeric value at the range of [−1,1], whose initialization is set as a random value within the range. When the ith bacterium finds a higher fitness position to be a favorable environment during the jth chemotaxis, it continues to move in the same direction based on this time. Instead, chooses a new random direction.

2.2. Swarming

The swarming behavior of the bacteria can be characterized by attraction and repulsion. The numerical relationship can be defined in the following:where datt indicates the depth at which the attracted material is released by the ith bacterium, while ωatt indicates the width of the same attracted material. Similarly, because two bacteria cannot be in exactly the same position, the repulsion is adopted as hrep and ωrep. After the swarming process, the fitness of the ith bacterium is shown in the following:

2.3. Reproduction

The bacteria replicate when they reach a better environment; otherwise, they will pass away. Thus, after the chemotaxis and the swarming process, the fitness of all the bacteria is calculated and sorted. The fitness of the ith bacterium is expressed in the following:

Half of the bacteria at better condition are selected to survive, while the other half pass away. The survived bacteria then reproduce into two colonies located in the same region, keeping the total number of bacteria S fixed.

2.4. Elimination and Dispersal

After the reproduction, each bacterium is dispersed with the probability of Ped, but the total number of bacteria remains the same. Once a bacterium is eliminated, it will be randomly dispersed to a new location.

As shown in (6), elimination occurs when ri < Ped. The original position of the ith bacterium Pi was replaced by a new one . As a result, the optimal parameter m is updated to a random parameter m′ that will be solved in the optimization space.

3. Improvement Based on Self-Adaptive Chemotaxis Strategy

The chemotaxis process has a great influence on the exploration and exploitation of the BFO algorithm, and it is the most important computing process of the BFO algorithm in searching the optimization space. The effect of chemotaxis is mainly achieved by two operations: swimming step size and flipping direction.

Therefore, to improve the performance of the BFO algorithm, two improvements are proposed in this paper, in which the features in the search state of the BFO algorithm are extracted and calculated and the information exchange between bacteria is increased. With these two improvements, the dynamic self-adaptive ability for bacterial swimming and flipping motions is designed, and a novel BFO algorithm, the SCBFO algorithm, is proposed.

3.1. Self-Adaptive Swimming Based on Bacterial Search State Features

According to the above research, the single swimming step size and the number of swimming n of chemotaxis determine the swimming step size of the algorithm. Then, the swimming step size determines whether the search performance of the algorithm can adapt to the current search state. When the search state is in the early stage, the algorithm needs the exploration ability for global search; then, in the later stage, the exploitation ability is required for local development.

For different optimization problems, the change of the BFO search state is also different. Meanwhile, because the chemotaxis process is nonlinear, it is so complex that the transition from the global exploration to the local exploitation cannot be simply described and divided by the means of analytical equations.

Therefore, to realize the dynamic adjustment of the BFO algorithm to the appropriate chemotaxis swimming, this paper extracts three important features of the BFO in each search state, including population diversity, iteration, and mean fitness, as shown in Figure 2.

The population diversity of bacteria describes the dispersion of the bacteria. The population diversity will get up to a higher level if the bacteria disperse at a wider range, and vice versa. This paper measures the population diversity of the bacterial colony in the chemotaxis process of BFO aswhere L represents the longest radius in the solution space and within the range of [0,1] measures the distance from each bacterium to the center of the population, which is irrelevant to the size of the solution space or the number of bacteria.

The iteration of the BFO algorithm is expressed by a parameter T, which is defined as an expression in the range of (0,1] in (8), where t and Tmax represent the index of the current chemotaxis and the maximum iteration, respectively. Thus, the definition of parameter T is generally suitable to different algorithms no matter how the parameters, the dimension, and the solution space are set in the algorithms:

The change of the mean fitness in two chemotaxis processes, dJ, is mainly investigated as one of the crucial standards to evaluate the BFO algorithm [21]. To give a general definition, the change of the mean fitness dJ is defined in the per-unit form within [−1,1] seen in the following:where Jmax and Jmin show the maximum and minimum of the fitness, respectively.

Therefore, in this paper, the three variables, the population diversity in (7), iterations in (8), and the mean fitness of bacteria in (9), are set as inputs of the multidimension fuzzy logic controller (MFLC), which is designed to investigate the search status of the algorithm in this paper. Then, with the two outputs of the MFLC, the chemotaxis swimming processes are adjusted in the following:where the two output variables of the controller are the bacterial swimming activity increment and the bacterial swimming step multiple .

The variable sets of the MFLC are shown in Table 1.

The fuzzy rules of the variables may be expressed in Table 2.

According to the aforementioned principles, the membership function of each variable can be combined to form a complete function corresponding to the inputs and outputs. As is shown in Figure 3, under the control of MFLC, the single swimming step size and the number of swimming n can be dynamically adjusted in different stages.

3.2. Improvement of Chemotaxis Flipping Based on Information Exchange Strategy

The flipping of the bacteria is another important operation during the chemotaxis process of the BFO algorithm. Each bacterium controls its own chemotaxis direction based on the extremum found during its swimming. The flipping variable is in (2). Although this method is beneficial to the randomness of the search, the blocked information among the bacteria slows down the searching process. Thus, the BFO algorithm with (2) suffers the disadvantage of falling into the local optimum.

In order to solve this problem, referring to the information exchanging strategy of individuals in the particle swarm optimization (PSO) algorithm [22, 23], the flipping variable in the BFO algorithm is updated in (11) and shown in Figure 4:

Coefficients that adjust the process of chemotaxis are utilized in (11): ω is the inertia factor, which represents the chemotaxis inertia of the bacteria at a certain direction. C1 and C2 are acceleration constants. C1 represents the rate at which the ith bacterium moves towards its individual optimal value Plocal during the process of individual bacterial chemotaxis, while C2 indicates the adjusting rate to the global optimum value Pglobal for all the bacterial chemotaxis. R1 and R2 are random values at the range of (0,1), which are used to improve the randomness of the bacterial flipping and enhance the searching ability.

3.3. Description of the SCBFO Algorithm

Therefore, based on Sections 3.1 and 3.2, with (7)–(11) and MFLC, the SCBFO algorithm is established via the improvements of the BFO algorithm. The flowchart of the proposed SCBFO algorithm is summarized in Figure 5.

The special steps of the SCBFO algorithm are described as follows:(1)According to formulas (1)–(11), the initial parameters are described in Table 3.(2)The completion conditions of exploration and exploitation steps in the chemotaxis process are as follows:According to formula (2), when the fitness of the ith bacterium is worse than the original position after the chemotaxis process or when its number of swimming n = 0, the exploration and exploitation steps are terminated, and the next process is started; otherwise, continue.(3)The completion conditions of chemotaxis, reproduction, and elimination and dispersal process are as follows:According to the definition and initialization of bacteria in Section 2, the position of the ith bacterium in the optimization space is expressed as , j represents the jth chemotaxis process, k represents the kth reproduction process, and l represents the lth elimination and dispersal process. When the count value of the corresponding process is 0, the process is completed, and the next process is started.

4. Experiments and Analysis

4.1. Test Set and Parameters

The SCBFO algorithm was investigated with 10 test functions provided by the CEC 2015 benchmark test set [24], shown in Table4 and Figure 6. Because these 10 test functions are commonly used key functions selected by related literature [1419], including the new algorithms (CEBFO and MBFO) used in this experiment, it is convincing to process the experiment with these test functions in the validation of the SCBFO algorithm. The first five test functions in Table 4 are unimodal functions, and the others are multimodal functions. However, for each of the ten functions, there is only one unique global optimal solution in the optimization space.

Under the same test conditions, SCBFO was tested and compared with the classical BFO algorithm and the classical PSO algorithm.

At the same time, two newly improved bacteria foraging algorithms in recent years, CEBFO (2017) [14] and MBFO (2015) [19], were also taken into account and compared with the SCFBO algorithm proposed in this paper.

To guarantee the fairness and credibility of algorithms in comparison, some initializations were determined preliminarily. The initial parameters of the classical BFO, the CEBFO, the MBFO, and the SCBFO algorithm maintained the same. Besides, the iteration number of the classical PSO algorithm was defined as to make it comparable with other algorithms. The essential parameter settings of five algorithms are shown in Table 5.

According to the calculation flow in Section 3.3, because the solution spaces vary among the test functions, the initial step size of bacterial swimming C is different according to the order of the solution space, as shown in Table 5.

Under the test conditions of 5, 10, 30, and 50 dimensions (D = 5, 10, 30, and 50), the five algorithms were calculated 100 times, respectively. Then, the computational results were collected and analyzed.

4.2. Results and Comparison

After the computation, the convergence trend and typical data such as the best value, the worst value, the mean value, and the variance can be achieved from the computed search results, which will be used in the following analysis on the performance of the SCBFO algorithm.

Since the trends of the computed results in different dimensions are similar for a certain test function and a higher dimension makes the optimization more challenging, the highest dimension D = 50 is chosen to illustrate the feasibility and the advantages of the SCBFO. The search results with dimension D = 50 are listed in Table 6.

For better understanding, the comparison among the SCBFO algorithm and other algorithms is processed in the optimization results, the convergence trend, and the performance stability, respectively.

4.2.1. Comparison of Optimization Results

The optimization results are listed in Table 6. According to the mean value of each test in Table 6, the comparison in Figure 7 can be formed, which is logarithmically arranged to achieve a unified contrast.

From Table 4, we can see the theoretical value of the optimal solutions in the test set is 0. As shown clearly in Table 6 and Figure 7, we find that, for each of the 10 test functions, the optimization result of the SCBFO algorithm remains the smallest, which means the SCBFO algorithm gets the optimal solution closest to the theoretical value. Even compared with other improved algorithms including CEBFO and MBFO, the SCBFO algorithm has higher accuracy in the optimization results.

Therefore, the SCBFO algorithm reduces the risk of local convergence to a large extent and improves the accuracy when searching for the global optimum, which proves the SCBFO algorithm is effective in the optimization.

4.2.2. Comparison of Convergence Trends

To evaluate the performances of an algorithm, the exploration ability in the early stage and the exploitation ability in the later stage are also the key standards. The mean values in different processes during the iteration are calculated according to the 100 times of computation with five kinds of algorithms. The convergence trends are plotted in Figure 8 and also logarithmically presented for clearer illustration.

As shown in Figure 8, in the exploration stage T < 40% (iteration number t < 800), the convergence of the SCBFO algorithm is not as fast as the classical BFO and the PSO algorithm because of a large-scale exploration search. However, the SCBFO algorithm shows the continuous convergence trend similar to the CEBFO and the MBFO algorithm, which means the SCBFO algorithm can keep a sufficient exploration stage for the large-scale exploration search.

Then, in the exploitation stage T > 40% (iteration number t > 800), especially 90% < T < 100% (iteration number 1,800 < t < 2,000), the SCBFO algorithm shows high convergence speed and excellent optimization results. At this stage, the convergence speed of the classical BFO and the PSO algorithm is reduced or even stopped when the algorithm reaches the optimal solution of 10−1 order. This proves that their exploitation activity in this stage is so weak that they are more likely to get into the local optimum. On the contrary, compared with other algorithms, SCBFO in this stage keeps a considerable declining speed until the end of the iterative process, which accelerates the process of convergence.

Therefore, the SCBFO algorithm is proved to effectively balance the exploration and the exploitation, which means the SCBFO algorithm can reduce the risk of falling into local optimum and make the convergence to optimal results more reliable.

4.2.3. Comparison of Performance Stability

As a swarm intelligence algorithm with wide application prospects, the SCBFO algorithm also needs to take the performance stability as one of the key standards to evaluate its performances. This section focuses on the variance, the best value, and the worst value according to the 100 times of computation with each algorithm in the highest dimension D = 50, as shown in Table 7. And Figure 9 plots all the variances logarithmically. Meanwhile, all results with the dimension D = 50 are rearranged as discrete data statistics used for the box graph in Figure 10. The box graph in Figure 10 can clearly show the stability differences of five algorithms under the current dimension in each test function.

As shown in Figures 9 and 10 and Table 7, the SCBFO algorithm shows the best variance. It can be seen that the results of the classical BFO algorithm and PSO algorithm fluctuate considerably. The classical BFO and PSO algorithms have a lot of outliers and a wider quartile range, which is in accord with the regularity delivered by Table 7 and indicates their unstable performances. On the contrary, referring to the variances in the box graph, the computed results of the SCBFO algorithm show the smallest medium value, the most concentrated quartile range, and the least outlier value.

Therefore, it is proved that the SCBFO algorithm shows the strongest stability of search performance among the five algorithms, which means the SCBFO algorithm proposed in this research will be more suitable to complex real-world applications of optimization.

5. Conclusions

To overcome the fixed step size and the weak correlation among bacteria of the classical BFO algorithm, the SCBFO algorithm was proposed in this paper. The self-adaptive chemotaxis strategy was designed by proposing the self-adaptive swimming method based on bacterial search state features and improving the chemotaxis flipping based on information exchange strategy.

The SCBFO algorithm was tested and verified by the CEC 2015 benchmark test set and compared with the classical BFO, the classical PSO, and two improved bacteria foraging algorithms in recent years: the CEBFO and the MBFO algorithm. The validation results proved the SCBFO algorithm effective and accurate in obtaining the optimal solution. Meanwhile, the stronger exploitation ability in the later stage and the more stable search performance of the SCBFO algorithm were also illustrated.

To sum up, the SCBFO algorithm does well in balancing the exploration and the exploitation and reducing the risk of local convergence, which means it can overcome the aforementioned two drawbacks of the classical BFO. Meanwhile, the SCBFO algorithm presents excellent search performance stability. Therefore, the SCBFO provides a novel and efficient theory to deal with complex optimization tasks.

Data Availability

The related benchmark problems used to support the findings of this study can be found in this article or the website (https://github.com/P-N-Suganthan).

Conflicts of Interest

The authors declare that they have no conflicts of interest.

Acknowledgments

This work was supported by the Natural Science Foundation of Beijing Municipality (no. L171009) and the Fundamental Research Funds for the Central Universities (no. 2020JBM069).