Multiscale Quantum Gradual Approximation Algorithm: An Optimization Algorithm With a Step-by-Step Approximation Strategy

In quantum swarm intelligence algorithms, the tunneling effect of the particles is determined by the potential energy acting on the particles. The tunneling effect of the particles affects the global search ability and convergence speed of the algorithm. Quantum algorithms with a single potential energy are prone to premature convergence under certain complex test functions. In this paper, we propose a multiscale quantum gradual approximation algorithm (MQGAA), which simply uses different approximation strategies to obtain different potential energy functions, to solve the premature problem of the optimization algorithm. In the MQGAA, particles undergo a transition from an unconstrained state to a constrained state at each scale. To demonstrate the effectiveness of the proposed algorithm, experiments are carried out with several common and effective stochastic algorithms on N-dimensional double-well potential functions and classical benchmark functions. We also use the Wilcoxon rank test to detect the performance of MQGAA. The experimental results show that the algorithm using a step-by-step approximation strategy achieves a better optimization performance on some complex test functions.


I. INTRODUCTION
Swarm intelligence is a kind of bionic algorithm inspired by the organization inherent in natural biological behavior. The algorithm simulates the mutual cooperation between natural biological groups. It is an algorithm in which one or more individuals with simple intelligence show advanced intelligence through the cooperation between them. In the past few decades, many swarm intelligence algorithms have been proposed, such as evolutionary strategy [1], particle swarm optimization [2], simulated annealing [3], genetic algorithm [4], differential evolution [5], ant colony optimization [6], fireworks algorithm [7], etc. These swarm intelligence The associate editor coordinating the review of this manuscript and approving it for publication was Siddhartha Bhattacharyya . algorithms have developed rapidly since they were proposed. The improvement of numerous algorithms greatly improves their performance.
In the swarm intelligence algorithm, particles exhibit aggregation. This aggregation, which means that the differences between individuals are limited, is a basic characteristic of swarm intelligence algorithms. In quantum mechanics, aggregation is described by the bound states of particles. The formation of the bound states is caused by the existence of an attractive potential field at the center of the particle motion. In recent years, many scholars have applied quantum theory to swarm intelligence algorithms. The quantum annealing algorithm (QA) is developed from the classical simulated annealing algorithm [8]. The algorithm uses the fluctuation characteristics of particles in quantum theory to design the algorithm. The quantum tunneling effect of the quantum wavefunction will enable particles to cross the obstacles that cannot be crossed in classical physics, and the target system will be optimized by simulating this process. Sun et al. proposed a quantum behaved particle swarm optimization (QPSO) by combining the quantum system with particle swarm [9]. In the QPSO algorithm, a quantized attractive potential field is set up as the bound particle of the constrained state, which makes the particle move toward the aggregation state. The multiscale quantum harmonic oscillator optimization algorithm (MQHOA) is based on the physical meaning of the quantum theoretical wavefunction. The ground state of the quantum system corresponds to the probability distribution of the optimal solution of the objective function. In MQHOA, particles are attracted by the potential field of a harmonic oscillator [10]. The bare bones fireworks algorithm (BBFWA) is a simplified fireworks algorithm. The particles in BBFWA are evenly distributed in the definition domain, which is simple and easy to implement [11].
In the optimization process, we establish a quantized potential field to bind particles such that not only will the algorithm exhibit aggregation but also will the particles be able to appear in any position in the space with a certain probability. It is important to obtain and select a suitable potential constrained particle in the optimization algorithm.
In quantum mechanics, the bound state of a particle is determined by the wavefunction. The wavefunction can be solved by the Schrödinger equation, which is shown in (1), where v(x) is the attraction potential of particles in a quantum system, i.e., the potential energy function.
The objective function f (x) of the optimization problem corresponds to the potential energy v(x) in the Schrödinger' equation, and the square of the absolute value of the wavefunction ψ(x) corresponds to the probability distribution of the optimal solution in the solution space. In the process of optimization, particles will eventually concentrate near the optimal solution. That is, the probability distribution of particles will eventually be stable, which corresponds to the wavefunction of particles in the ground state in the quantum model. When we obtain the ground state wavefunction corresponding to the objective function, we can obtain the position of the optimal solution. When v(x) is complex, it is difficult to solve the wavefunction with the Schrödinger' equation. Consequently, we need to simplify the objective function of the optimization. The MQHOA used the second-order Taylor approximation to simplify the optimization problems. MQHOA is an efficient quantum optimization algorithm that is proposed based on the wavefunction in quantum physics. MQHOA converts the optimization problem into solving the wavefunction of a time-dependent quantum system. The wavefunction defined in MQHOA reflects the potential field force on the particles in MQHOA. When the optimization problem is approximated by a second-order Taylor expansion, the wavefunction in MQHOA is the wavefunction of a quantum harmonic oscillator. The particles in MQHOA are bounded by the potential field of the quantum harmonic oscillator [10].
In quantum mechanics, the potential energy of a quantum system exerts a force field on the particles, which determines the tunneling effect of the particles in the system. Different potential energies determine different tunneling effects of the particles. By comparing the tunneling effects of different quantum systems, we propose a new algorithm called the multiscale quantum gradual approximation algorithm (MQGAA). In the MQGAA, at each scale, the particles undergo a transition from an unconstrained state to a constrained state. Particles in the unconstrained state have a strong global search ability, whereas the local search ability of the constrained particles is strong. After satisfying certain conditions, the particles can be transformed into the constrained state to enhance the local search ability, thus speeding up the convergence of the algorithm. The change in the particle state is realized by the change in the potential energy. The first-and second-order Taylor approximations are applied to the new algorithm to obtain quantum systems with different potential energies. Compared with other algorithms, this effectively enhances the exploitation ability in the global area; however, the convergence speed of the algorithm is lower.
To verify the performance of MQGAA, N-dimensional double-well potential functions and some classical benchmark functions are used as test functions. The double-well potential is one of a number of quartic potentials in quantum mechanics, in quantum field theory and elsewhere for the exploration of various physical phenomena and mathematical properties. The one-dimensional double-well function is an ideal potential well model objective function that has a globally optimal region and a locally optimal region. Many scholars have used the one-dimensional double-well potential function as the objective function to analyze the performance of quantum algorithms. The double-well potential function is used to analyze the performance of QA as a heuristic optimization algorithm [12]. Reference [13] used the one-dimensional double-well potential function as the ideal potential well model in quantum physics to study the annealing properties of wavefunctions in quantum systems. Reference [14] used the double-well potential function as a simple one-dimensional case study system to investigate the basic behavior and performance of simulated QA in comparison with classical annealing (CA). To further verify the performance difference between MQGAA and MQHOA, we use the bilateral Wilcoxon rank test to detect the experimental datas of the two algorithms through the method described in [15]. This paper is organized as follows. In Section II, we introduce the basic definitions and formulas of Taylor's formula. We briefly introduce the principle of MQHOA and analyze the approximation strategy of MQHOA in Section III. In Section IV, we give the approximation strategy of MQGAA and compare the tunneling effects of different approximation strategies for corresponding wavefunctions. The framework of MQGAA is also described in Section IV. In Section V, the efficiency of MQGAA is evaluated on benchmark functions with different characteristics and N-dimensional double-well potential functions. The Wilcoxon rank test is also in this section. The simulation results and performance analysis validate the effectiveness of the proposed approach. In Section VI, conclusions and future work are outlined.

II. TAYLOR's FORMULA
In mathematics, Taylor's formula describes the value of a function in its vicinity with the information of a point. If the function is sufficiently smooth, Taylor's formula can construct a polynomial to approximate the value of the function in the neighborhood of this point by using the corresponding multiples of these derivatives as coefficients when the derivatives of the function at a certain point are known. In practical applications, Taylor's formula needs to be truncated, taking only a finite number of terms. The Taylor series of the finite terms of a function is called Taylor's expansion. The remainder of Taylor's formula can be used to estimate the error. The number of terms of Taylor's expansion determines the degree of approximation. The higher the number of terms is, the higher the degree of approximation. In optimization problems, we only care about the function values near the optimal solutions. Therefore, Taylor's formula is often used to simplify the optimization problems.
For a function f (x) with n-order derivative at x = x 0 , Taylor's formula can be used to approximate f (x) by using an n-order polynomial of (x − x 0 ). It is an important part of advanced mathematics to study Taylor's formula for approximating some complex functions as the simplest polynomial functions, a process called Taylor approximation. In optimization problems, we care about the function values near the optimal solutions. Therefore, the Taylor approximation is often used to simplify optimization problems.
Taylor's formula is defined as follows [16]: If a function f (x) has n-order derivatives on a closed interval [a, b] containing x 0 and n + 1 order derivatives on an open interval (a, b), the following formula (2) is established for any point To conveniently describe the approximation strategy of the algorithm, we define Taylor's first-order approximation and second-order approximation, which are described as follows. f 1 (x) in Formula (3) and f 2 (x) in Formula (4) are two finite terms of the Taylor formula shown in Formula (2).

A. FIRST-ORDER TAYLOR APPROXIMATION
We intercept the first two terms of Formula (2) for the approximation of f (x) which is shown in Formula (3).
We intercept the first three terms of Formula (2) for the approximation of f (x). The approximation of f (x) is shown in (4)

III. MULTISCALE QUANTUM HARMONIC OSCILLATOR ALGORITHM
The MQHOA with the energy level stabilizing process proposed in 2016 [17] is an efficient quantum optimization algorithm that was proposed based on the wavefunction in quantum physics.
In MQHOA, the optimization problem is transformed into the problem of solving for the time-dependent wavefunction. The Schrödinger equation is shown in (1). The objective function f (x) of the optimization problem corresponds to the potential energy v(x) in the Schrödinger equation, and the square of absolute value of the wavefunction ψ(x) corresponds to the probability distribution of the optimal solution in the solution space. The optimal solutions correspond to the lowest potential energy. In other words, the ground state wavefunction of the quantum system reflects the distribution of the optimal solutions. The Schrödinger equation can only be used to obtain the wavefunctions of some simple potential energy functions. Therefore, we need to simplify complex objective functions by approximation.
In MQHOA, we approximate the objective function f (x) by Taylor's formula about the optimal solution x 0 . The Taylor expansion is shown in formula (2). x 0 is the extremum point of the objective function; thus, f (x 0 ) = 0. By substituting f (x 0 ) = 0 for Formula (4), we obtain Formula (5).
The solution of the wavefunction of f (x) is simplified to the solution of the wavefunction of the quantum harmonic oscillator system. The probability density of the wavefunction that is shown in (6) can be derived from Formula (1) [18].
The wavefunction ψ σ s (x) of MQHOA shown in (7) is defined as a superposition of n Gaussian probability density functions with µ i as the sampling center, and σ s represents the current scale [19].

IV. MULTISCALE QUANTUM GRADUAL APPROXIMATION ALGORITHM
The wavefunction in MQHOA can ensure that the solutions can escape from local optima with a certain probability; however, for certain complex problems, the solutions often fall into a local optimum, which makes MQHOA converge prematurely. To address this problem, we propose the MQGAA algorithm.
MQGAA is a quantum optimization algorithm based on the wavefunction, which consists of two key components: a diffusion (D) process and a multiscale (M) process. In the D process, the particles can be in one of two states: an unconstrained state or a constrained state. Particles in the unconstrained state have a strong global search ability. When a certain condition is reached, the particles transit from the unconstrained state to the constrained state. Particles in the constrained state have a weaker global search ability but a stronger local search ability, which can make the algorithm converge quickly. The transformation of the particle state is realized by the transformation of the wavefunction, and different wavefunctions are obtained by different approximation strategies for the objective function.

A. APPROXIMATION STRATEGY OF MQGAA
For an optimization algorithm, a stronger tunnel effect does not necessarily provide better performance by the algorithm, as we are uncertain that the position of the particle at the next moment will be closer to the optimal solution. In MQGAA, we adopt a step-by-step Taylor approximation strategy. At each scale, the first-order Taylor approximation is used to make the particles sufficiently disperse. When the sampled particles reach the metastable state, the second-order Taylor approximation is applied to the objective function to make the particles converge quickly.
We approximate the objective function f (x) by Taylor's formula at the optimal solution x 0 . Because f (x 0 ) = 0, Formula (3) can be simplified to Formula (8), in which C is constant.
The wavefunction of f (x) can be obtained by solving the wavefunction of a free particle. The wavefunction of a free particle is shown in Formula (9).
The probability density of a free particle described in Formula (10) is the square of the wavefunction shown in Formula (9)..
The wavefunction ψ σ s (x) corresponding to the first-order Taylor approximation of the objective function, which we used in MQGAA, shown in (11), is defined as a superposition of n uniform distributions. The a and b are the upper and lower limit of the domain. The wavefunction corresponding to the second-order Taylor approximation of the objective function is the same as MQHOA, which is shown in (7).

B. COMPARISON OF DIFFERENT WAVEFUNCTIONS
We compare the tunneling effects of different quantum systems by using the probability of solutions located outside the local optimum. The greater the probability of locating outside of the local optimum region is, the stronger the tunneling effect of the quantum system. As mentioned above, the wavefunctions corresponding to the first-order Taylor approximation and the second-order Taylor approximation are shown in Formulas (11) and (7), respectively. The comparison of quantum tunneling effects is shown in Figure 1. The objective function f (x), which we used here, is the one-dimensional double-well potential function. The expression of f (x) is shown in Formula (12), where V = 6, a = 2, δ = 1. ψ 1 (x) and ψ 2 (x), which are shown in (13), are the wavefunctions corresponding to the functions after the first-and second-order Taylor approximations of f (x), respectively.
When the solution locates at point A, the algorithm falls into a local optimum. The problem of comparing the ability of algorithms to escape from local optima is transformed into a problem of comparing the quantum tunneling effects of particles from region A to region B. We use the probabilities of the particle locating at point A to the left region of point C, which are shown in the shadows of Figure 1, to represent the tunneling effect. Substituting the values in Figure 1 into Formula (13), we obtain Formula (14). We use Formula (14) to calculate two probabilities. Through numerical calculation, we obtain p 1 = 0.5317 and p 2 = 0.2323. The tunneling effect of the quantum system based on the first-order Taylor approximation of the objective function is stronger.
C. THE FRAMEWORK OF MQGAA Algorithm 1 describes the MQGAA pseudocode. The notations are represented in Table 1. Similar to MQHOA, MQGAA is also a quantum optimization algorithm based on VOLUME 8, 2020 the wavefunction, therein consisting of two key components: a Diffuse (D) process and a Multiscale (M) process.
In MQGAA, the D process utilizes two behaviors: diffusion stabilization and particle renewal. The diffusion stabilization consists of two stages: the global diffusion and the local diffusion state. As shown in Algorithm 1, when σ < 1.5 * σ s , the global diffusion reaches the stable state; when σ < σ s , the local diffusion becomes stable. Choosing the right time to switch between global diffusion and local diffusion can not only improve the local search ability of MQGA, but also ensure the efficiency. We use experiments to compare the effects of different switching conditions in diffusion stages on the performance of MQGAA. The experimental results are shown in subsection V-B. When the diffusion is stable, the worst particle will be replaced by the mean of all particles.
As discussed in [20], the M process is a necessary and problem-independent process for optimization algorithms according to the principle of uncertainty. The M process is the variable sampling step size strategy. The MQGAA gradually reduces the search step to precisely obtain the globally optimal solutions. Large step sizes correspond to a global search, and small step sizes correspond to a local search. Different scales determine the different accuracy levels of the solutions.

V. SIMULATION AND DISCUSSION
In this section, we first introduce the experimental environment, the comparison algorithms and test functions used in the experiment. Then, we analyze the switching conditions of the diffusion stage by experiment. Subsequently, to prove the effectiveness of the MQGAA, two experiments are conducted on test functions with different characteristics.
One experiment is conducted to compare the global search abilities between MQGAA, MQHOA-SMC and MQHOA on the double-well potential function. The second experiment is conducted to compare with MQHOA-SMC, MQHOA, QPSO, SPSO2011, and BBFWA on classical benchmark functions. The 14 benchmark functions include 6 unimodal functions and 8 multi-modal functions. The functions f 2 , f 4 , f 5 , f 7 , f 9 and f 10 are unimodal functions. The last three functions are rotated multi-modal functions. The remaining 5 functions are multi-modal functions. In this paper, the orthogonal matrix M is generated by Salomon's method [21]. The function name, ID, search space and optimum are listed in Table 2. After the experiments, we use the bilateral Wilcoxon rank to compare MQGAA with MQHOA and MQHOA-SMC to judge the effectiveness of the successive approximation strategy.

A. PARAMETER SETTINGS
The parameters used are listed in Table 3. The experimental environment is as follows: MATLAB 2014b, Windows Server 2016, Intel Xeon E5-2630 (2.4 GHz) CPU, 32G of RAM. The results are recorded for 51 independent runs for each function.

B. EXPERIMENTS ON THE SWITCHING CONDITION OF THE DIFFUSION STAGE
To analyze the influence of different switching conditions on the performance of the MQGAA, we choose different switching conditions of the diffusion stage, such as σ s , 1.25 * σ s , 1.5 * σ s , 1.75 * σ s , 2 * σ s , 2.5 * σ s . In this subsection, we use the 14 benchmark functions shown in Table 2 as test functions. For the dimension of test functions, we choose 10 dimensions. The results are listed in Table 4. According to the results, different switching conditions have little effect on the performance of MQGAA. To balance the efficiency and global search ability of MQGAA, we choose the switching condition as 1.5 * σ s .

C. EXPERIMENTS BASED ON DOUBLE-WELL POTENTIAL FUNCTION
The one-dimensional double-well potential function that is used in this paper is represented in Formula (12). To better determine the performance of the algorithm, we define a multidimensional double-well potential function. The higher the VOLUME 8, 2020 function dimension is, the greater the number of local optimal solutions. The N-dimensional double-well potential function is described in (15) which is a stack of N one-dimensional double-well potential functions. The N-dimensional doublewell potential function has 2 N − 1 local optimal solutions.
In this subsection, we compare the global search capability between MQGAA, MQHOA-SMC and MQHOA using the 3-, 5-, and 10-dimensional double-well potential functions as test functions. The parameters of the N-dimensional double-well potential function used are listed in Table 5. The experimental results are listed in Table 6. The best results are marked in boldface. The parameters used are listed in Table 3. For further observations, a boxplot of the results obtained by each algorithm is given in Figure 2 for different dimensions with 51 independent runs. Table 6 shows that with increasing number of dimensions, the success rate of MQGAA is obviously better than that of MQHOA-SMC and MQHOA. Figure 2 shows the distribution of the optimal solution of 51 runs. The global search ability of the algorithm can be improved by using a step-by-step Taylor approximation strategy.

D. EXPERIMENTS BASED ON THE CLASSICAL BENCHMARK FUNCTIONS
In this subsection, MQGAA is compared with MQHOA-SMC, MQHOA, QPSO, SPSO2011, and BBFWA. The experimental results are listed in Table 7, Table 8 and Table 9, corresponding to 10, 30 and 60 dimensions, respectively. The best results are marked in boldface. The parameters used are listed in Table 3. Table 7 lists the results for 10 dimensions. For the unimodal functions f 2 , f 4 , f 5 , f 7 , f 9 and f 10 , although MQGAA does not achieve higher accuracy, it can find the optimal solution in each of the 51 runs. For multi-modal functions, there are large numbers of local optima that are more difficult to locate. Therefore, the success rate is more reflective of the performance of the algorithm. Based on the results, MQGAA achieved success rates of 100% on three multi-modal functions. For the other two multi-modal functions, MQGAA achieved the best performance on f 1 , while QPSO performed best on f 11 . For f 11 , the success rate of MQGAA is much better than that of MQHOA-SMC and MQHOA. MQGAA achieved the best performance on f 1 , with a success rate of 92.31%. For the rotated multi-modal functions f 12 -f 14 , MQGAA achieved success rates of 100% on f 12 and f 13 , as did most of the other algorithms. MQHOA-SMC achieved the best performance on f 14 , with a success rate of 88.24%.    Table 9 lists the results for 60 dimensions. For the unimodal functions f 2 , MQGAA achieved the best results out of all the evaluation options. Although MQGAA does not achieve higher accuracy for f 4 and f 10 , it can find the optimal solution in each of 51 runs. For multi-modal functions, MQGAA achieved a success rate of 100% on f 1 and f 11 . For rotated multi-modal functionsf 12 and f 14 , MQGAA achieved a better success rate than all the other algorithms with success rates of 92.16% and 100%, respectively.
Above, we analyzed the simulation results for 10, 30 and 60 dimensions. For 10 dimensions, QPSO and MQGAA achieved the highest success rates for 12 functions. When the dimensionality increased to 30, MQGAA achieved the highest success rate for 10 functions, while QPSO achieved the highest success rate for only 8 functions. However, when the dimensionality increased to 60, QPSO achieved the highest success rate for only 1 functions, while MQGAA achieved the highest success rate for 7 functions. SPSO2011 achieved the highest success rates for 9 functions which is the worst in all the algorithms. When the dimensionality increased to 30, SPSO2011 achieved the highest success rates for 8 functions, which is just less than MQGAA and the same as other algorithms. However, when the dimensionality increased to 60, SPSO2011 achieved the highest success rate for 7 functions which is the best of all algorithms, as in MQGAA. When we compare the seven functions of SPSO2011 with those of MQGAA, we find that the functions of SPSO2011 are mainly the unimodal functions while the functions of MQGAA are mostly multi-mode functions.
Compared with other algorithms, the performance of MQGAA is more stable on 14 test functions, and for multi-mode function, the performance of MQGAA is better than other algorithms. f 1 has many regularly distributed, widespread local minima; thus, it is very difficult to find the true solution. For all of the 10, 30 and 60 dimensions, MQGAA achieves the highest success rate on f 1 out of all tested algorithms. Compared with MQHOA-SMC and MQHOA, MQGAA performs better on f 7 , f 9 and f 11 . This means that MQGAA, which uses the step-by-step Taylor approximation strategy, has a stronger global search ability and can effectively avoid premature convergence.
MQGAA uses two different wavefunctions to enhance the ability of the algorithm to escape from the local optimum when there are many local optimum solutions. Higher dimensions cannot increase the number of local optimal solutions, so we did not experiment with a higher dimension.

E. THE BILATERAL WILCOXON RANK
We use the bilateral Wilcoxon rank test to detect the experimental data of MQGAA, MQHOA and MQHOA-SMC by the method described in [15]. We use the experimental results of the benchmark functions for rank detection. The results of different dimensions are shown in Table 10 and Table 11. When the p − value is less than the confidence value 0.05, MQGAA is proved to be effective. Table 10 lists the Wilcoxon rank results of MQGAA, MQHOA and MQHOA-SMC for 10 dimensions. In Table  10 there are some results indicated as NaN . In MATLAB, NaN means calculation error, which usually occurs when the divisor or denominator is 0 or the data exceed the accuracy. Here, we ignore these results. In the results of the comparison of MQGAA and MQHOA, the p − value of 2 functions is less than the confidence value, including f 2 and f 10 . The p − value of 12 functions is less than 0.05, except f 1 and f 11 in the results of the comparison of MQGAA and MQHOA-SMC. Table 11 lists the Wilcoxon rank results of MQGAA, MQHOA and MQHOA-SMC for 30 dimensions. In the results of the comparison of MQGAA and MQHOA, the p − value of 3 functions is less than the 0.05, including f 2 ,f 9 and f 10 . The p − value of 11 functions is less than the confidence value, except f 5 , f 11 and f 12 in the results of the comparison of MQGAA and MQHOA-SMC.
MQHOA-SMC, which is introduced in [24] with a strict metastability constraint, has a stronger global search ability than MQHOA. According to the results in Table 7, MQGAA also has a better global search ability. In addition to the global search ability, MQGAA also achieves a good accuracy of the optimal solutions.

VI. CONCLUSION
This paper proposes an MQGAA with a step-by-step Taylor approximation strategy. Theoretical analysis and experimental results indicate that the new strategy enhances the global exploitation ability. Statistical analysis of the experimental results also shows that MQGAA effectively improves the robustness and exploitation ability of the original algorithm. Comprehensive simulations between MQGAA and some efficient meta-heuristic methods, including MQHOA-SMC, MQHOA, QPSO, SPSO2011 and BBFWA under different dimensionalities, are conducted on N-dimensional doublewell potential functions and classical benchmark functions. The simulation results reveal that the MQGAA is a competitive algorithm.
In the near future, we will further theoretically study the approximation strategy used by MQGAA and apply it to solve real-world engineering optimization problems.