1 Introduction

1.1 Motivation

Most optimization problems in the real world are complex, discrete or continuous, constrained or unconstrained, static or dynamic, single-mode or multi-mode, single-objective or multi-objective (Zhang et al. 2022; Chen et al. 2022). Mathematical based optimization methods, such as integer programming, linear programming, convex optimization and so on, are no longer sufficient to solve complex and diverse practical problems (Heidari et al. 2019). More and more researchers use swarm intelligence optimization algorithms to solve optimization problems in the real world. Such as Jiao et al. (2020) used enhanced Harris hawks optimizer (HHO) to solve energy problems, and Xu et al. (2019a) used improved moth flame optimization (MFO) to solve feature selection problems. Swarm intelligence algorithms have been applied to solve optimization problems in image segmentation (Zhao et al. 2020a, b), support vector machines (Shen et al. 2016; Chen et al. 2020a), feature selection (Zhang et al. 2020; Zhao et al. 2014), extreme learning machine (ELM) (Wang et al. 2017; Xia et al. 2017), bankruptcy prediction (Zhang et al. 2020; Cai et al. 2019), engineering design (Wang et al. 2020; Tu et al. 2020), and have achieved great success. Compared with mathematical methods, the swarm intelligence algorithm is a stochastic optimization method based on group collaboration, using various heuristic rules and continuous iteration. Although the method does not necessarily converge to the global optimal solution every time, an acceptable solution can be obtained in a short time.

However, researchers in Wolpert and Macready (1997) have proven that no algorithm can obtain the optimal solution for all problems. Any algorithm performs well on some problems but cannot solve all problems in the best way. It is crucial to find the functional problem of an algorithm. For example, a genetic algorithm (GA) is good at solving combinatorial optimization problems (Li and Gao 2016), and ant colony optimization (ACO) tends to get better solutions in vehicle routing planning problems (Lee et al. 2010). Similarly, the “no free lunch (NFL)” theory has inspired many researchers to develop and improve new algorithms. SMA (Li et al. 2020a) is a new algorithm recently proposed by Li et al. It is inspired by the foraging behavior of slime mould polycephalum, and models its behavior and morphological changes during the foraging process through adaptive weights. Li et al. (2020a) tested SMA on 23 basic functions and CEC2014, which verified the effectiveness and excellent performance on four engineering domain problems. Its performance is better than most classic and advanced algorithms. However, although the SMA algorithm has performed well, it still has some drawbacks. As analyzed in Sect. 3, the original SMA algorithm is easy to fall into the local optimal solution; and has the possibility of incomplete exploitation. In order to improve its performance and enable it to better solve increasingly complex optimization problems, this paper introduces Gaussian barebone mutation and greedy selection to improve it.

1.2 Literature review

Because of its simplicity and generality, rapid solution, and no derivative information in most cases, meta-heuristic algorithms have been widely used to solve increasingly complex optimization problems in the real world (Sun et al. 2021). Researchers have developed a large number of meta-heuristics such as genetic algorithm (GA) (Aguilar-Rivera et al. 2015), particle swarm optimizer (PSO) (Kennedy and Eberhart 1995), slime mould algorithm (SMA)Footnote 1 (Li et al. 2020b), colony predation algorithm (CPA) (Tu et al. 2021), Runge Kutta optimizer (RUN)Footnote 2 (Ahmadianfar et al. 2021), weighted mean of vectors (INFO)Footnote 3 (Ahmadianfar et al. 2022), earthworm optimization algorithm (EWA) (Wang et al. 2018a), elephant herding optimization (EHO) (Wang et al. 2016), grey wolf optimization (GWO) (Mirjalili et al. 2019), whale optimization (WOA) (Mirjalili et al. 2019), moth flame optimization (MFO) (Mirjalili et al. 2019), Harris hawks optimizer (HHO)Footnote 4 (Heidari et al. 2019), hunger games search (HGS)Footnote 5 (Yang et al. 2021), moth search algorithm (MSA) (Wang 2018), monarch butterfly optimization (MBO) (Feng et al. 2021), gravitational search algorithm (GSA) (Rashedi et al. 2009), and sine–cosine algorithm (SCA) (Mirjalili et al. 2019).

Real-world optimization problems are challenging in the different areas, and accuracy of solutions, speed of algorithms, and costs, concerning constraints become more important, especially in plant disease recognition (Yu 2022), image segmentation (Hussien 2022; Su et al. 2022), economic emission dispatch problem (Dong et al. 2021), PID optimization control (Zeng et al. 2014), combination optimization problems (Zhao et al. 2021), bankruptcy prediction (Cai et al. 2019; Zhang et al. 2021a), parameter optimization for machine learning models (Shi et al. 2021; Sun et al. 2019), feature selection (Hu et al. 2021; Hu et al. 2022), traveling salesman problem (Lai and Zhou 2020), prediction problems in educational field (Wei et al. 2020; Zhu et al. 2020), multi-objective problem (Deng et al. 2022), scheduling problem (Gao et al. 2020; Wang et al. 2022a), and fault diagnosis (Deng et al. 2020; Zhao et al. 2019). Optimization methods have been successfully applied in the fields of electricity, communications, water conservancy, healthcare, energy, and machine learning. Kumar and Reddy (2007) treated irrigation and power generation from reservoirs as multiple target problems and used an improved empirical mutation PSO to effectively solve this problem. Wang et al. (2017) used chaotic mapping to improve the MFO and proposed a hybrid model with a kernel extreme learning machine (KELM) to diagnose Parkinson's disease and breast cancer. Chen et al. (2019) used the Nelder-Mead method and opposition-based learning to improve the SCA and used the improved SCA to estimate the parameters of the photovoltaic model. Luo et al. (2019) combined GWO with MFO, optimized the hyper-parameters of KELM, and verified the method’s performance on the somatization disorder data set.

Although meta-heuristic has been widely used because of its excellent performance, it still has shortcomings. When its search step is not compatible with the search speed, it can lead to a locally optimal solution or premature. To obtain a faster search speed, a larger search step is required. If the step is too large, it is easy to miss the global optimal solution. If the step is too small, a better solution may not be obtained after several iterations, which affects the search speed. Therefore, more promising solutions can only be obtained when the search step and the search speed are appropriate. This also corresponds to the balance between exploration and exploitation. The balance between diversity and convergence, which seems to be an irreconcilable contradiction, with diversity requiring individuals in the population to be as widely dispersed as possible, and convergence. On the contrary, It also requires individuals in the population to be as cohesive as possible. To alleviate this contradiction to a certain extent, researchers have proposed various improvement mechanisms to enhance the exploration or exploitation function. Common improvement strategies include parameter adaptation, Gaussian mutation, Cauchy mutation, chaotic mapping, chaotic local search, orthogonal learning, opposition-based learning, and other meta-heuristic combinations. Yu et al. (2020) used the quantum revolving door and Gaussian mutation strategies to improve the performance of the dragonfly algorithm effectively. The proposed method successfully used in feature selection and engineering optimization problems. Heidari et al. (2020) combined the memetic algorithm, Cauchy mutation, chaotic local search, opposition-based learning, and mutation strategy with DE to improve SCA, named MSCA. They test MSCA on benchmark functions, exploration, and exploitation performance outperforms conventional as well as advanced comparison algorithms. Yang et al. (2020) introduced Gaussian mutation and orthogonal learning into the FOA to enhance and balance the original algorithm. The exploration and exploitation performance were verified on benchmark functions and engineering optimization problems. Fan et al. (2020) combined the search mechanisms of WOA and FOA, and the proposed WFOA is better than the original FOA and WOA and has better performance than many variants of FOA.

There is also much work using Gaussian barebone mutation to improve classical algorithms. Kennedy (2003) first used barebone mutation to improve PSO (BBPSO), followed by Wang et al. (2013) introduced Gaussian barebone mutation into DE (GBDE). According to Wang’s work, Wei et al. (2020) used Gaussian barebone mutation to optimize the original HHO algorithm (GBHHO) and used it to improve GBHHO to optimize the hyper-parameters of KELM. The mathematical principle that makes Gaussian barebone mutation effective has been clarified in Clerc and Kennedy (2002); Bergh and Engelbrecht (2006). These efforts mentioned above are similar but different. Although GBDE is inspired by BBPSO and uses the Gaussian function to replace the mutation operation of DE, the crossover operation of GBDE inherits from DE and adapts the crossover probability instead of using 0.5 like BBPSO. Based on GBDE, Wei et al. improved the crossover strategy; the solution obtained by the Gaussian function with the solution obtained by the original DE mutation strategy performs a crossover operation. The crossover probability is a constant between [0, 1]. The method in this article is inspired by the work (Wei et al. 2020), but the details are different, presented in Sect. 3.1. In addition, Gaussian barebone mutation has also been entered into other classical algorithms, such as BFO, artificial bee colony (ABC), etc. (Gao et al. 2015; Wang et al. 2018b; Zou et al. 2014; Heidari et al. 2017).

The SMA is a new algorithm recently proposed by Li et al. (2020b). The SMA is inspired by the foraging behavior of slime mould polycephalum, and models its behavior and morphological changes during the foraging process through adaptive weights. Li tested SMA on 23 essential functions and CEC2014, and its performance is better than most classical and advanced algorithms and verified the effectiveness and excellent performance of the algorithm on four engineering domain problems. Although SMA has not been proposed for a long time, it has been used in various optimization problems. Zubaidi et al. (2020) used an artificial neural network optimized by SMA to predict urban water demand than comparison algorithms better. Zubaidi et al. (2020) combined SMA and WOA for threshold selection in multi-threshold image segmentation and then diagnosed COVID-19. Durmus (2020) used SMA to optimize the design of the antenna array. Chen and Liu (2020) proposed using the chaotic mapping function to improve SMA (CSMA) parameters, combined CSMA and k-means clustering to determine the parameters in support vector regression and obtained better prediction accuracy on three data sets.

This paper introduces Gaussian barebone mutation and greedy selection to improve the SMA. Gaussian barebone mutation is an extension of DE mutation. The Gaussian barebone update strategy is introduced to combine it with the original SMA update strategy. The population diversity is enhanced; the global search performance of GBSMA is enhanced. With the enhancement, the algorithm can converge to a higher-quality solution. The introduction of greedy selection and only retaining solutions improve the objective function. The algorithm's convergence is greatly enhanced, resulting in an improved convergence rate for GBSMA.

1.3 Contribution and paper organization

This paper's main contributions are: introducing Gaussian barebone mutation and greedy selection into the SMA, enhancing the original algorithm’s exploration and exploitation capabilities. In the CEC2017 test functions, GBSMA is compared with conventional and advanced algorithms to verify the proposed algorithm's superior performance. Applying GBSMA to engineering problems, the results prove the effectiveness of GBSMA.

This paper is structured as follows: Sect. 2 reviews the original SMA, and Sect. 3 details the two improvement mechanisms and GBSMA. In Sect. 4, exhaustive experiments are performed to verify the performance of GBSMA. Section 4.2 tests the performance of GBSMA in different dimensions. Sections 4.3 and 4.4, respectively, verify the advantages of GBSMA with conventional and advanced algorithms. In Sect. 4.5, we analyze the convergence, balance, and diversity of GBSMA. In Sect. 4.6, we design experiments to verify the effect of parameters on GBSMA performance. Engineering applications are introduced in Sect. 4.7. Finally, the paper is summarized in Sect. 5 and looks forward to future work.

2 Slime mould algorithm

This algorithm is inspired by the foraging behavior of the slime mould polycephalum and morphological changes during foraging by adaptive weights. The general idea of the SMA is clarified in Fig. 1.

Fig. 1
figure 1

The logical process of the SMA depends on three phases

The position update strategy is as follows:

  1. (1)

    When \(\mathrm{rand}<\mathrm{z}\), the position update strategy of SMA is as in Eq. (1),

    $$ {\text{X}}_{{\text{i}}} \left( {{\text{t}} + 1} \right) = {\text{r}}_{1} \times \left( {{\text{UB}} - {\text{LB}}} \right) + {\text{LB}} $$
    (1)

    where \({\mathrm{X}}_{\mathrm{i}}\), \(\mathrm{UB}\), \(\mathrm{LB}\) are all \(\mathrm{dim}\) dimensional vectors, \(\mathrm{dim}\) represents the dimension of the search space, \(\mathrm{UB}\) and \(\mathrm{LB}\) respectively represent the upper and lower boundaries of the search space, and \({\mathrm{r}}_{1}\) is a random between [0,1].

  1. (2)

    When \(\mathrm{rand}\ge \mathrm{z}\), SMA uses Eq. (2) to update the position:

    $$ {\text{X}}_{{{\text{i}},{\text{j}}}} \left( {{\text{t}} + 1} \right) = \left\{ {\begin{array}{*{20}l} {{\text{X}}_{{{\text{best}},{\text{j}}}} + {\text{vb}} \times \left( {{\text{W}}_{{\text{i}}} \times {\text{X}}_{{{\text{i}}_{1} ,{\text{j}}}} \left( {\text{t}} \right) - {\text{X}}_{{{\text{i}}_{2} ,{\text{j}}}} \left( {\text{t}} \right)} \right),} \hfill & {{\text{rand}} < {\text{p}}} \hfill \\ {{\text{vc}} \times {\text{X}}_{{{\text{i}},{\text{j}}}} \left( {\text{t}} \right),} \hfill & {{\text{otherwise}}} \hfill \\ \end{array} } \right. $$
    (2)

    where \({\mathrm{X}}_{\mathrm{best},\mathrm{j}}\) denotes the value of the \(\mathrm{j}\)-th dimension of the historically optimal individual; \({\mathrm{X}}_{{\mathrm{i}}_{1},\mathrm{j}}\), \({\mathrm{X}}_{{\mathrm{i}}_{2},\mathrm{j}}\) denotes the value of the \(\mathrm{j}\)-th dimension of two random individuals in the population, and \(\mathrm{i}\ne {\mathrm{i}}_{1}\ne {\mathrm{i}}_{2}\); \(\mathrm{rand}\) is a random number between [0, 1]. \(\mathrm{W}\), \(\mathrm{vb},\) and \(\mathrm{vc}\) simulate the contraction and expansion of venous tissue in slime mould foraging, and \(\mathrm{p}\) controls different update strategies. The calculation formulas of these four variables are as follows:

    $$ {\text{W = }}\left\{ {\begin{array}{*{20}c} {1 + {\text{r}}_{2} \times {\text{log}}\left( {\frac{{{\text{bestFitness}} - {\text{Fitness}}_{{\text{i}}} }}{{{\text{bestFitness}} - {\text{worstFitness}}}} + 1} \right),} & {{\text{Fitness}}_{{\text{i}}} < {\text{Fitness}}_{{{\text{med}}}} } \\ {1 - {\text{r}}_{2} \times {\text{log}}\left( {\frac{{{\text{bestFitness}} - {\text{Fitness}}_{{\text{i}}} }}{{{\text{bestFitness}} - {\text{worstFitness}}}} + 1} \right),} & {{\text{otherwise}}} \\ \end{array} } \right. $$
    (3)
    $$ {\text{p}} = \tanh \left( {\left| {{\text{Fitness}}_{{\text{i}}} - {\text{DF}}} \right|} \right) $$
    (4)
    $$ {\text{a}} = {\text{arctanh}}\left( {1 - \frac{{{\text{FEs}}}}{{{\text{MaxFEs}}}}} \right) $$
    (5)
    $$ {\text{b}} = 1 - \frac{{{\text{FEs}}}}{{{\text{MaxFEs}}}} $$
    (6)
    $$ {\text{vb}} = {\text{unifrnd}}\left( { - {\text{a}},{\text{a}}} \right) $$
    (7)
    $$ {\text{vc}} = {\text{unifrnd}}\left( { - {\text{b}},{\text{b}}} \right) $$
    (8)

The \(\mathrm{bestFitness}\) in Eq. (3) represents the fitness of the best individuals in the current population, which should be distinguished from the \(\mathrm{DF}\) in Eq. (4), \(\mathrm{DF}\) represents the fitness of the historical best individuals. The \(\mathrm{worstFitness}\) in Eq. (3) represents the fitness of the worst individual in the current population, and \(\mathrm{Fitness}\) represents the fitness of all individuals in the population. It is a list of size \(\mathrm{N}\), and \(\mathrm{N}\) represents population size, \({\mathrm{Fitness}}_{\mathrm{i}}\), \({\mathrm{Fitness}}_{\mathrm{med}}\) represents the current individual fitness and the median of the fitness list. The functions in Eqs. (4 and 5) have the same meaning as standard mathematical symbols, in which \(\mathrm{FEs}\) and \(\mathrm{MaxFEs}\) respectively represent the current function evaluation times and the maximum function evaluation times. The \(\mathrm{vb}\) and \(\mathrm{vc}\) are random numbers uniformly distributed between [− a, a] and [− b, b], respectively. The process for fitness checking is shown in Fig. 2.

Fig. 2
figure 2

Valuation of fitness in SMA

Algorithm 1 shows the pseudocode of SMA. The algorithm starts from a random initial population. When \(\mathrm{FEs}<\mathrm{MaxFEs}\), it updates the position of individuals in the population according to the position update strategy of Eqs. (1) and (2). The algorithm flowchart is given in Fig. 3.

Fig. 3
figure 3

The flowchart of SMA

figure a

3 The proposed GBSMA

Although the original SMA's performance is better than most swarm intelligence algorithms, it still has shortcomings. The original SMA algorithm determines the position update method according to the value of \(\mathrm{p}\) in Eq. (4). The \(\mathrm{p}\) is determined according to the difference between the fitness of the current solution and the optimal solution (i.e., the quality of the solution), as shown in Eq. (2). When the difference between the fitness of the current solution and the optimal solution is large,\(\mathrm{p}\) is close to 1. The SMA algorithm updates the position near the optimal value, which is easy to fall into the local optimal value. When the difference between the fitness of the current solution and the optimal solution is small, the position update method of the SMA algorithm directly multiplies the current solution by \(\mathrm{vc}\) (the value of \(\mathrm{vc}\) is between [− b, b] and eventually tends to 0). It is easy to produce a larger disturbance to the current solution and is not conducive to in-depth exploitation of the local area. This paper introduces Gaussian barebone mutation and greedy selection into the original SMA to improve its search capability.

3.1 Gaussian barebone idea

As described in the introduction section, Wei et al. (2020) introduced the Gaussian barebone (GB) mechanism into HHO, which effectively enhanced the original HHO algorithm’s search ability and used the improved GBHHO to optimize the hyper-parameters of KLEM. Inspired by Wei et al., this paper uses GB to improve SMA, but this paper has slightly changed its basis.

As mentioned earlier, different researchers use GB in different specific ways. This section directly describes the GB used in this paper without repeating the previous work. The GB update method used in this paper is shown in Eq. (9):

$$ {\text{X}}_{{{\text{i}},{\text{j}}}} \left( {{\text{t}} + 1} \right) = \left\{ {\begin{array}{*{20}l} {{\text{N}}\left( {\mu {\text{,}}\sigma } \right),} \hfill & {{\text{rand}} < {\text{CR}}} \hfill \\ {{\text{X}}_{{{\text{i}}_{1} ,{\text{j}}}} \left( {\text{t}} \right) + {\text{r}}_{3} \times \left( {{\text{X}}_{{{\text{i}}_{2} ,{\text{j}}}} \left( {\text{t}} \right) - {\text{X}}_{{{\text{i}}_{3} ,{\text{j}}}} \left( {\text{t}} \right)} \right),} \hfill & {{\text{otherwise}}} \hfill \\ \end{array} } \right. $$
(9)

where \(\mathrm{N}\left(\upmu ,\upsigma \right)\) represents the Gaussian function with mean \(\upmu \) and standard deviation\(\upsigma \), where \({\upmu } = \left( {{\text{X}}_{{{\text{best}},{\text{j}}}} + {\text{X}}_{{{\text{i}},{\text{j}}}} \left( {\text{t}} \right)} \right)/2\),\({\upsigma } = {\text{b}} \times \left| {{\text{X}}_{{{\text{best}},{\text{j}}}} - {\text{X}}_{{{\text{i}},{\text{j}}}} \left( {\text{t}} \right)} \right|\). b is calculated by Eq. (6). \({\mathrm{X}}_{\mathrm{best},\mathrm{j}}\) represents the value of the \(\mathrm{j}\)-th dimension of the optimal individual, \({\mathrm{X}}_{\mathrm{i},\mathrm{j}}\) represents the value on the \(\mathrm{j}\)-th dimension of the \(\mathrm{i}\)-th individual.\({\mathrm{X}}_{{\mathrm{i}}_{1},\mathrm{j}}\),\({\mathrm{X}}_{{\mathrm{i}}_{2},\mathrm{j}}\), \({\mathrm{X}}_{{\mathrm{i}}_{3},\mathrm{j}}\) represent the value of the \(\mathrm{j}\)-th dimension of three different random individuals in the population and\(\mathrm{i}\ne {\mathrm{i}}_{1}\ne {\mathrm{i}}_{2}\ne {\mathrm{i}}_{3}\). Both \({\mathrm{r}}_{3}\) and \(\mathrm{rand}\) are random numbers between [0,1]. \(\mathrm{CR}\) stands for cross probability.

The Gaussian function in GB, with the mean value of the middle position and the standard deviation, generates a new random number with a high probability of updating the position near the optimal solution. It enhances the exploitation ability of the original algorithm and accelerates the convergence speed of the algorithm. Based on Wei et al. (2020), the standard deviation in the Gaussian function is multiplied by a linear decreasing factor \(\mathrm{b}\). As the iteration progresses, the standard deviation becomes smaller and smaller and focus on exploitation in the later stage of the algorithm. The DE variation strategy, which differs from Wei et al. (2020), uses \(\mathrm{rand}\) rather than \(\mathrm{best}\) as the guiding vector in this paper, which increases the diversity of the population and enhances the algorithm's global search ability.

In general, the Gaussian function pays more attention to improving exploitation capabilities. The DE mutation strategy pays more attention to the enhancement of exploration capabilities. The Gaussian barebone mutation controls the balance of exploitation and exploration through crossover probability. From the above analysis, we can know that Gaussian barebone mutation is an extension of the DE mutation strategy. A larger \(\mathrm{CR}\) value pays more attention to exploitation. A smaller CR value pays more attention to exploration, and a reasonable CR value can make exploration and exploitation more balanced and enhance the algorithm's optimization ability. The experiment in Sect. 4.6 also verifies this analysis. By adding a Gaussian skeleton mutation, and adding a new position update strategy, the original SMA's population diversity is enhanced, resulting in enhanced global search performance of GBSMA and the discovery of more valuable solutions.

3.2 Greedy selection

The swarm intelligence algorithms are a trial-and-error mechanism, but they may move in the wrong direction if the position update is performed without judgment. Why not stay put and waits until the correct direction is found before performing position updates? Based on this consideration, this paper adopts a greedy selection strategy to avoid individual position updates. They produce worse solutions and get lost in the wrong direction, which can be tried but cannot make mistakes. The specific strategy is shown in Eq. (10),

$$ {\text{X}}_{{{\text{i}},{\text{j}}}} \left( {{\text{t}} + 1} \right) = \left\{ {\begin{array}{*{20}l} {{\text{tempX}},} \hfill & {{\text{fobj}}\left( {{\text{tempX}}} \right) < {\text{fobj}}\left( {{\text{X}}_{{\text{i}}} \left( {\text{t}} \right)} \right)} \hfill \\ {{\text{X}}_{{\text{i}}} \left( {\text{t}} \right),} \hfill & {{\text{otherwise}}} \hfill \\ \end{array} } \right. $$
(10)

where \(\mathrm{tempX}\) is the solution obtained, according to Eqs. (1), (2), and  (9). If the function value (minimization problem) is less than the function value of the individual's previous generation dual, the individual position is updated to \(\mathrm{tempX}\); otherwise, it remains unchanged. In the specific implementation, a list is used to save the solution's function value calculated in the previous generation to avoid wasting the number of function evaluation times due to repeated computation. The introduction of greedy selection enhances the algorithm's convergence capability, resulting in faster convergence of GBSMA.

3.3 Proposed GBSMA

This section describes in detail how the GB and greedy selection strategies are combined with the original SMA in the form of pseudocode and flowchart. In one iteration, the algorithm uses the SMA update strategy (i.e., Eqs. (1), (2)) to update the position of all individuals in the population and then uses the GB strategy shown in Eq. (9) to update the position, with greedy selection added to both update strategies. Algorithm 2 shows the pseudocode of GBSMA.

figure b

Figure 4 shows the flow chart of GBSMA. It is easy to know from the algorithm pseudocode and flowchart that the algorithm mainly comprises population initialization, fitness calculation, SMA position update strategy, and GB position update strategy. Let \(\mathrm{N}\) represent the population size, \(\mathrm{D}\) represent the search space dimension, and \(\mathrm{T}\) represent the maximum number of iterations. Then the complexity of population initialization is \(\mathrm{O}(\mathrm{N})\). Fitness calculation and position update are required for each iteration, so the fitness calculation complexity is \(\mathrm{O}(\mathrm{T}\times \mathrm{N})\). Considering the complexity of one iterative position update. The complexity of the SMA position update strategy involving \(\mathrm{W}\) calculation and position update, in which the complexity is \(\mathrm{O}(\mathrm{N}\times \mathrm{log}(\mathrm{N}))\) and \(\mathrm{O}(\mathrm{N}\times \mathrm{D}),\) respectively. The complexity of the GB position update strategy is \(\mathrm{O}(\mathrm{N}\times \mathrm{D})\). Since SMA and GB each perform \(\mathrm{T}/2\) position updates, the complexity of the position update is \(\mathrm{O}(\mathrm{T}/2\times \mathrm{N}\times \left(\mathrm{log}\left(\mathrm{N}\right)+2\times \mathrm{D}\right))\), so the complexity of the GBSMA algorithm is \(\mathrm{O}(\mathrm{N}\times \left(\mathrm{T}/2\times \left(\mathrm{log}\left(\mathrm{N}\right)+2\times \mathrm{D}+2\right)+1\right)\). Taking \(\mathrm{M}=\mathrm{max}(\mathrm{log}\left(\mathrm{N}\right),2\times \mathrm{D})\), then the complexity of the GBSMA algorithm can be written as \(\mathrm{O}(\mathrm{N}\times \mathrm{T}\times \mathrm{M})\).

Fig. 4
figure 4

The flowchart of GBSMA

4 Experimental results and discussions

In this section, the performance of GBSMA is comprehensively analyzed through experiments. Tests are done under a fair framework; we follow fair comparisons as per standards in other works (Zuo et al. 2022; Wu et al. 2020). This shows there is no advantage in changing system or biased conditions for compared methods, as we respect fair comparisons (Dong 2021; Sun 2021; Li, et al. 2022). Section 4.1 introduces the test functions used in the experiments. Section 4.2 conducts experiments on three dimensions to verify whether GBSMA has a comparative advantage in high-dimensional situations. The comparison experiments with conventional algorithms and advanced algorithms are shown in Sects. 4.3 and 4.4, respectively. In order to further analyze the performance of GBSMA, the convergence, balance, and diversity analysis of GBSMA is carried out in Sect. 4.5. In Sect. 4.6, by using a set of different crossover probability values, experiments are performed to verify the influence of parameters on the performance of GBSMA. In Sect. 4.7, the algorithm is applied to practical engineering problems to verify its performance.

4.1 IEEE CEC2017 function

This section introduces the IEEE CEC2017 functions used to test the performance of GBSMA. Many researchers use CEC2017 to test the algorithm's performance; detailed information can be found in LaTorre and Peña (2017). IEEE CEC2017 contains 30 test functions, which can be divided into four categories: unimodal (F1–F3), multimodal (F4–F10), hybrid (F11–F20), and composition (F21–F30). Table A1 in the Supplementary lists brief information about these functions, including categories and optimal values. The search range of all functions is [− 100, 100], and the dimension of the search space is 30.

4.2 Scalability test

In order to comprehensively evaluate the performance of GBSMA, GBSMA and SMA are tested in different dimensions. As shown in Supplementary Table A2, three dimensions of 30, 50, and 100 were selected, and 30 repeated experiments were performed. “Avg” in Supplementary Table A2 represents the mean value of the optimal values obtained by the GBSMA and SMA algorithms on CEC2017 for 30 experiments, and “Std” represents the standard deviation. From the results in the table, it can be seen that when the dimensions are 30, 50, and 100, GBSMA outperforms SMA on 27, 25, and 28 functions, respectively. And the advantages of GBSMA over SMA are not affected by the dimension of the problem. Also, as the dimension of the problem increases, the minimum values found by the two algorithms on most functions become larger, i.e., as the dimension of the problem increases, the performance of the algorithm decreases, but through observation, but it can be observed that on most functions, the optimal value of GBSMA in 100-dimension and SMA in 30-dimension search remains in the same order of magnitude, indicating that GBSMA is more suitable for high-dimensional problems. Moreover, on individual functions, such as F15 and F19, the algorithm performance has improved as the dimension increases, while on F1, F13, and F30, the performance of GBSMA has improved, while the performance of SMA has decreased, indicating that GBSMA is more adaptable to high-dimensional problems than SMA.

4.3 Comparison with conventional algorithms

In this section, GBSMA is compared with eight conventional meta-heuristic algorithms: SMA, differential evolution (DE), GWO, HHO, GSA, cuckoo search (CS) (Gandomi et al. 2013), MFO, WOA. Supplementary Table A3 shows the experimental results of GBSMA and comparison algorithms on CEC2017 test functions. Table 1 shows the results of the statistical analysis of Supplementary Table A3. The results in the " ± /−  = " column are obtained based on the Wilcoxon signed-rank test, indicating that GBSMA is statistically superior, inferior, or equal to the comparison algorithm. The “Avg” column is the mean value of the Friedman rank test. "Rank" represents the rank of “Avg”.

Table 1 Statistical analysis results of GBSMA compared with conventional algorithms

Table 1 shows that GBSMA ranks first in average results among nine algorithms, and original SMA ranks second in average results among nine algorithms. The improved GBSMA is statistically better than the original SMA on 21 functions, and it is also better than classical algorithms such as CS and DE on most functions, indicating that GBSMA outperforms the original SMA and other comparison algorithms on the CEC2017 test functions.

Supplementary Table A4 lists the p-values of GBSMA and the comparison algorithm. The p-values were calculated by Wilcoxon signed-rank test. A p-value of less than 0.05 indicates that the algorithm is statistically significantly different. Correspondingly, a p-value greater than 0.05 indicates that there is no difference between GBSMA and the comparison algorithm statistically. To better distinguish in which functions GBSMA is superior or inferior to the comparison algorithm, the p-value of the comparison algorithm in the table that is superior to GBSMA is bolded. It can be seen from the table that compared to the comparison algorithm, GBSMA shows competitive results on most functions.

Figure 5 shows the convergence curves of GBSMA and 8 comparison algorithms on 9 test functions. The test functions cover the four categories of CEC2017. As shown in the figure, on F1, GBSMA is inferior to DE and original SMA, but GBSMA has a faster search speed. On the other functions, GBSMA can converge to a better solution faster. The experimental results also verify the analysis in Sect. 3.1. The algorithm’s exploration and exploitation ability are enhanced by adding Gaussian barebone mutation, and it reaches a new balance.

Fig. 5
figure 5

The convergence curve of GBSMA and other algorithms (the first line: F1, F5, F8; the second line: F12, F13, F16; the third line: F21, F23, F30)

4.4 Comparison with advanced algorithms

To further verify the performance of GBSMA, in this section, GBSMA is compared with ten advanced algorithms on CEC2017. Comparison algorithms include HGWO (Zhu et al. 2015), ACLPSO-CA (Lin et al. 2019), ALCPSO (Chen et al. 2013), LSHADE-EpSin (Awad, et al. 2016), IWOA (Tubishat et al. 2019), MPSO (Tian and Shi 2018), CMAES (Hansen and Ostermeier 2001), PaDE (Meng et al. 2019), XPSO (Xia et al. 2020) and CBA (Adarsh et al. 2016). Table 2 shows the statistical results of the comparative experiments, and the function optimization results are presented in Supplementary Table A5. It can be seen from Table 2 that the average Friedman test rank of GBSMA is 2.44, ranking first among all algorithms. Compared with GBSMA, the most competitive algorithms are LSHADE-EpSin, PaDE, and ALCPSO; the average of Friedman's test rank is 3.39, 4.07, and 5.00, respectively. This shows that these three algorithms have a significant disadvantage compared with GBSMA. Statistically, GBSMA is superior, inferior, and equal to LSHADE-EpSin on 16, 11, and 3 functions. This shows that GBSMA is more advantageous than LSHADE-EpSin. Compared with PaDE and ALCPSO, the GBSMA has statistical advantages in 17 and 26 functions, respectively.

Table 2 Statistical analysis results of GBSMA compared with advanced algorithms

By analyzing the results in Supplementary Table A5, it can be found that GBSMA ranks in the top three on 23 test functions; this shows that GBSMA can get competitive solutions for most functions. It shows that GBSMA has strong search performance for all four categories of test functions. The most competitive LSHADE-EpSin ranks greater than or equal to 5 on 7 functions and ranks 8th on F3, which indicates that GBSMA is more robust than LSHADE-EpSin. From the rank on functions, it can also be seen that GBSMA shows superior results in the last 10 test functions, and it can be concluded that GBSMA has more advantages in solving complex composition functions. It is worth noting that although CMAES obtained the best results on 3 single-mode functions and 5 other functions, it also obtained the worst results on 9 test functions, which indicates that the performance of CMAES is unstable. CMAES may have unintended consequences if used for an unsuitable task. This fact further highlights the advantages of the stable performance of GBSMA.

The p-values of GBSMA with the advanced algorithms via the Wilcoxon signed-rank test are listed in Supplementary Table A6. The number of p-values less than 0.05 in each column of the table is the same as the number corresponding to “ = ” in the Result column in Table 2, and the number of bold is the same as the number corresponding to “−”. From the table results, we can see that GBSMA has statistical advantages over most advanced algorithms.

The convergence curves of GBSMA and other improved algorithms are shown in Fig. 6, which lists nine test functions’ convergence curves. GBSMA found the best quality solution on seven test functions. Among them, the solutions obtained by GBSMA on F9, F23, F26, F27, and F28 are significantly better than those obtained by other algorithms. It has also obtained competitive solutions on F5 and F30. Moreover, GBSMA has a faster convergence speed on F24, F26, F28, and F30, which shows that GBSMA has strong local search performance and can search for better solutions at the same time. On F5, when most comparison algorithms converge, GBSMA still has search capabilities, which shows that GBSMA has stronger global search capabilities. Although GBSMA will stagnate at a later stage, higher quality solutions can be reached on most test functions, reflecting faster search speed and stronger search performance. The experiment again verified the analysis in Sect. 3.1.

Fig. 6
figure 6

The convergence curves of GBSMA and the advanced algorithms (the first line: F5, F9, F13; the second line: F23, F24, F26; the third line: F27, F28, F30)

4.5 The impact of the Gaussian barebone mechanism

The improved GBSMA uses two mechanisms: the Gaussian bare-bone mutation and greedy selection introduced in Sect. 3. This section investigates the effects of two mechanisms on the original SMA.

Figure 7 shows the results of the qualitative analysis of 5 test functions from CEC2017 by GBSMA and SMA. Fig. Fig. 7a is the three-dimensional image of the function, Fig. 7b shows the two-dimensional distribution of the GBSMA search history, Fig. 7c shows the first-dimensional search trajectory of the GBSMA, Fig. 7d shows the average fitness of all individuals in the population of GBSMA, Fig. 7eshows the convergence curve of GBSMA and SMA.

Fig. 7
figure 7figure 7

a Three-dimensional distribution of function, b Two-dimensional distribution of GBSMA search history, c GBSMA first-dimensional search trajectory d GBSMA average fitness, e convergence curve of the two algorithms

Figure 7b shows that a large number of solutions are clustered around the optimal solution (red dot), and some solutions are scattered in other positions in the search space. Combining Fig. 7c, we can see that the algorithm starts with an extensive search in the search space and quickly converges to the optimal solution’s vicinity. Also, because the greedy selection is added to GBSMA, individual positions remain unchanged in many cases, so there are relatively few points in Fig. 7b, and the average fitness curve of Fig. 7d has a tendency to decrease or remain constant, without up and down fluctuations. Figure 7e shows the convergence curves of the two algorithms. It can be seen that GBSMA has a faster search speed and a smaller optimal value.

To further explore the impact of the two mechanisms, the balance and diversity of the two algorithms are analyzed on the test functions of CEC2017. Figure 8 shows the two algorithms' balance analysis on the four functions and the corresponding convergence curve. The convergence curve is consistent with Fig. 7e, where the red color represents the GBSMA convergence curve, and the other is the SMA convergence curve.

Fig. 8
figure 8

Algorithm balance analysis and convergence curve

In the balance plot, an incremental-decremental curve is added. The red curve represents the exploration ratio, the blue curve represents the exploitation ratio, and the green curve is the incremental-decremental curve. During the iteration process, the value of the exploration and exploitation ratio in the population is calculated by the following formula:

$$ {\text{XPL}}\left( {\text{t}} \right) = \left( {\frac{{{\text{Div}}\left( {\text{t}} \right)}}{{{\text{Div}}_{{{\text{max}}}} }}} \right) \times 100 $$
(11)
$$ {\text{XPT}}\left( {\text{t}} \right) = \left( {\frac{{\left| {{\text{Div}}\left( {\text{t}} \right) - {\text{Div}}_{{{\text{max}}}} } \right|}}{{{\text{Div}}_{{{\text{max}}}} }}} \right) \times 100 $$
(12)
$$ {\text{Div}}_{{\text{j}}} \left( {\text{t}} \right) = \frac{1}{{\text{n}}} \times \mathop \sum \limits_{{{\text{i}} = 1}}^{{\text{n}}} \left| {{\text{median}}\left( {{\text{X}}^{{\text{j}}} } \right) - {\text{X}}_{{\text{i}}}^{{\text{j}}} } \right| $$
(13)
$$ {\text{Div}}\left( {\text{t}} \right) = \frac{1}{{\text{m}}} \times \mathop \sum \limits_{{{\text{j}} = 1}}^{{\text{m}}} {\text{Div}}_{{\text{j}}} \left( {\text{t}} \right) $$
(14)

where \(\mathrm{t}\) is the current iteration number, \(\mathrm{XPL}\) is the exploration ratio, and \(\mathrm{XPT}\) is the exploitation ratio. \(\mathrm{Div}\) represents the diversity metric, and its value is calculated by Eqs. (13) and  (14). \({\mathrm{Div}}_{\mathrm{max}}\) represents the maximum value of the diversity metric in the iterative process. In Eq. (13), \(\mathrm{n}\) represents the number of individuals in the population, \(\mathrm{median}\left({\mathrm{X}}^{\mathrm{j}}\right)\) represents the median of \({\mathrm{X}}^{\mathrm{j}}\), \({\mathrm{X}}^{\mathrm{j}}\) represents the value of the j-th dimension of all individuals in the population, which is an n-dimensional vector, and \({\mathrm{X}}_{\mathrm{i}}^{\mathrm{j}}\) represents the value of the j-th dimension of the i-th individual. The \(\mathrm{m}\) in Eq. (14) represents the dimension of the solution. From the \(\mathrm{Div}\) calculation formula, it can be seen that when the individuals in the population are closer, the population diversity is smaller, the \(\mathrm{XPL}\) value is correspondingly smaller, and the \(\mathrm{XPT}\) value is correspondingly larger, which is in line with our subjective judgment.

$$ {\text{Div}}\_{\text{delta}}\left( {\text{t}} \right) = {\text{Div}}\_{\text{delta}}\left( {{\text{t}} - 1} \right) + {\text{XPL}}\left( {\text{t}} \right) - {\text{XPT}}\left( {\text{t}} \right) $$
(15)
$$ {\text{Div}}\_{\text{delta}}\left( {\text{t}} \right) = \left\{ {\begin{array}{*{20}c} {0,} & {{\text{Div}}\_{\text{delta}}\left( {\text{t}} \right) < 0} \\ {{\text{Div}}\_{\text{delta}}\left( {\text{t}} \right),} & {{\text{otherwith}}} \\ \end{array} } \right. $$
(16)
$$ {\text{Increment}}\left( {\text{t}} \right) = \frac{{{\text{Div}}\_{\text{delta}}\left( {\text{t}} \right)}}{{{\text{Div}}\_{\text{delta}}_{{{\text{max}}}} }} \times 100 $$
(17)

The incremental-decremental curve is measured by Eq. (17), where \(\mathrm{Div}\_\mathrm{delta}\) represents the increment of the population exploration and exploitation ratio, \({\mathrm{Div}\_\mathrm{delta}}_{\mathrm{max}}\) represents the maximum value of the \(\mathrm{Div}\_\mathrm{delta}\), and the \(\mathrm{Increment}\) is equivalent to the normalized operation of \(\mathrm{Div}\_\mathrm{delta}\), and the incremental-decremental curve is drawn according to the \(\mathrm{Increment}\) value. The increment-decrement curve rises means that the algorithm exploration effect is stronger, and it falls means that the algorithm exploitation effect is stronger. When the incremental value is equal to 1, exploration and exploitation are equivalent. The rising phase of the curve indicates that the algorithm is mainly affected by the exploration strategy. On the contrary, it means that it is affected by the exploitation strategy.

It can be seen from Fig. 8 that SMA spent less time on exploration and a lot of time on exploitation. Compared with SMA, the improved GBSMA uses more time for exploration, which shows that the two improved mechanisms effectively enhance the algorithm’s global search capability. And it can be seen from the convergence graph that the improved GBSMA can converge to a better solution, indicating that the two mechanisms improve the local search capability of the algorithm. The results in Fig. 8 show that by adding Gaussian barebone mutation and greedy selection, the exploration and exploitation capabilities of the original SMA are improved, and a new balance is reached, so higher quality solutions can be searched.

The results of algorithm diversity analysis are shown in Fig. 9, where the x-axis represents the number of iterations and the y-axis represents the average distance between individuals. The algorithm diversity is evaluated by measuring the distance between individuals. As can be seen from the figure, due to random initialization at the beginning, both algorithms start with an average distance of about 500. After the position of SMA is updated, individuals are scattered in the search space. The average distance between individuals increases rapidly, and diversity increases accordingly. After several iterations, the diversity quickly decreases to below 2000. However, because GBSMA introduces greedy selection and avoids invalid position updates to a certain extent, the diversity of GBSMA is not much different from the initial case. As the iteration progresses, the diversity of the algorithm steadily decreases. After about 200 iterations, the diversity of the two algorithms is at the same level. Combining with the convergence curve of Fig. 8, it can be clearly known that GBSMA can effectively prevent individuals in the population from getting lost in the wrong direction by introducing greedy selection and can find more potential solutions faster than SMA. Because GBSMA introduces Gaussian barebone strategy, exploitation is more effective.

Fig. 9
figure 9

Diversity analysis of algorithms

4.6 Parameter influence analysis

To conduct a more comprehensive analysis of GBSMA performance, for the crossover probability \(\mathrm{CR}\) in the Gaussian barebone mechanism, this section sets a set of different values to conduct self-comparison experiments to analyze the impact of crossover probability on the performance of GBSMA. GBSMA0 means CR = 0, GBSMA1 means CR = 0.1, and so on. The experimental results are shown in Table 3. It can be seen from the results in Table 3 that when the crossover probability is equal to 0.4, the overall performance of GBSMA is the best, and with GBSMA4 as the center, the algorithm performance decreases sequentially. Larger cross-probability relies more on the DE update method, which is more inclined to exploration, and smaller cross-probability relies more on the Gaussian function to update individual positions, which is more inclined to exploitation so that either too large or too small a cross-probability will lead to poorer results because exploration and exploitation are not balanced. The result also verifies the analysis in Sect. 3.1. However, it should also be noted that even the GBSMA4 with the best overall performance does not perform very well in some functions, such as F3, F12, F14. Therefore, this paper suggests that the crossover probability value should be selected after testing for different problems.

Table 3 Results of GBSMA with different crossover probability values

4.7 Engineering application

In real-world problems, decision-makers need to consider minimizing the overall costs (fitness function), but they should also not violate specific constraints of the projects (Liao et al. 2021; Li et al. 2017; Liu et al. 2021a; Zhang et al. 2021b). The proposed SMA method needs to be suitable for the objective and has some limits in its variables. Therefore, we selected some case studies on truss optimization to further validate the developed SMA variant’s effectiveness. This section verifies the performance of the proposed GBSMA on three truss structure optimization problems. Section 4.7.1 introduces the mathematical form of truss structure optimization. The following three sections introduce the results of GBSMA on 10-bar planar truss, 25-bar space truss, and 72-bar space truss. For each problem, 100 repeated experiments were run with a population size of 50, and the number of iterations is 200 generations. In addition, the unit abbreviations involved in this section are given the corresponding full spellings in Table 4.

Table 4 The unit abbreviation corresponds to the full spelling

4.7.1 Optimization of the truss structure

According to the problem, the structural optimization of trusses can be divided into cross-sectional size optimization, geometric shape optimization, and topology optimization. According to the variable type, it can be divided into discrete optimization and continuous optimization (Camp and Farshchin 2014; Ozbasaran and Yildirim 2020). This paper focuses on the continuous variable optimization of the cross-sectional size of the truss.

$$ \min {\text{w}} = { }\mathop \sum \limits_{{{\text{i}} = 1}}^{{\text{n}}} {\upgamma }_{{\text{i}}} {\text{L}}_{{\text{i}}} {\text{A}}_{{\text{i}}} $$
$$ \begin{aligned} {\text{subject to}}:\; & {\upsigma }^{{\text{L}}} \le {\upsigma }_{{\text{i}}} \le {\upsigma }^{{\text{U}}} \, \\ & {\updelta }^{{\text{L}}} \le {\updelta }_{{\text{j}}} \le {\updelta }^{{\text{U}}} \, \\ & {\text{A}}^{{\text{L}}} \le {\text{A}}_{{\text{i}}} \le {\text{A}}^{{\text{U}}} \\ \end{aligned} $$

The mathematical form of the optimization of the truss’s cross-sectional size is shown in the above formula. The geometry of the truss is fixed. The optimization aims to solve a cross-sectional area for each bar that satisfies the stress and deflection constraints while minimizing the structural weight. Among them, \({\upgamma }_{\mathrm{i}}\) and \({\mathrm{L}}_{\mathrm{i}}\) represent the density and length of the rod, respectively, which are given values. \({\mathrm{A}}_{\mathrm{i}}\) represents the cross-sectional area of the member, which is an optimization variable. \({\upsigma }_{\mathrm{i}}\) represents the stress on the bar, \({\updelta }_{\mathrm{j}}\) represents the deflection at the connection point, and \({\upsigma }_{\mathrm{i}}\), \({\updelta }_{\mathrm{j}}\) and \({\mathrm{A}}_{\mathrm{i}}\) must satisfy the upper bound \(\mathrm{U}\) and lower bound \(\mathrm{L}\) constraints.

For infeasible solutions, the researchers defined a penalty function to measure. When the stress of bars or the deflection of nodes does not meet the constraints, the loss will be calculated by the following formula:

$${\mathrm{\varnothing }}_{\upsigma }^{\mathrm{i}}=\left\{\begin{array}{c}({\upsigma }^{\mathrm{U}}-{\upsigma }_{\mathrm{i}})/{\upsigma }^{\mathrm{L}}, {\upsigma }_{\mathrm{i}}<{\upsigma }^{\mathrm{L}}\\ ({{\upsigma }_{\mathrm{i}}-\upsigma }^{\mathrm{U}})/{\upsigma }^{\mathrm{U}}, {\upsigma }_{\mathrm{i}}\ge {\upsigma }^{\mathrm{U}}\end{array}\right.$$
$${\mathrm{\varnothing }}_{\updelta }^{\mathrm{j}}=\left\{\begin{array}{c}({\updelta }^{\mathrm{U}}-{\updelta }_{\mathrm{j}})/{\updelta }^{\mathrm{L}}, {\updelta }_{\mathrm{j}}<{\updelta }^{\mathrm{L}}\\ ({{\updelta }_{\mathrm{j}}-\updelta }^{\mathrm{U}})/{\updelta }^{\mathrm{U}}, {\updelta }_{\mathrm{j}}\ge {\updelta }^{\mathrm{U}}\end{array}\right.$$
$${\mathrm{\varnothing }}_{\upsigma }= {\sum }_{\mathrm{i}=1}^{\mathrm{n}}{\mathrm{\varnothing }}_{\upsigma }^{\mathrm{i}}$$
$${\mathrm{\varnothing }}_{\updelta }= {\sum }_{\mathrm{j}=1}^{\mathrm{m}}{\mathrm{\varnothing }}_{\updelta }^{\mathrm{j}}$$

Among them, \({\mathrm{\varnothing }}_{\upsigma }^{\mathrm{i}}\) and \({\mathrm{\varnothing }}_{\updelta }^{\mathrm{j}}\) represent the stress loss of the i-th member and the deflection loss of the j-th node, respectively, and \(\mathrm{n}\) and \(\mathrm{m}\) represent the number of members and the number of nodes, respectively, and the total stress loss and deflection loss are respectively are \({\mathrm{\varnothing }}_{\upsigma }\) and \({\mathrm{\varnothing }}_{\updelta }\). Therefore, the final optimization target penalty weight \(\mathrm{W}\) can be expressed as the following formula:

$$ \min {\text{W}} = {\text{ w}} \times \left( {1 + \emptyset_{{\upsigma }} + \emptyset_{{\updelta }} } \right)^{2} $$

4.7.2 10-bar planar truss

The ten-bar planar truss problem (Camp and Farshchin 2014; Ozbasaran and Yildirim 2020) has become a benchmark problem in structural optimization. Figure 10 shows its planar structure, and the member’s number and length are shown in the figure. The range of cross-sectional area of all members is [0.1, 35] in2, the density is 0.1 lb/in3, and the modulus of elasticity is 107 psi. The constraints are: the maximum allowable stress of the members is ± 25kpsi, and the maximum deflection of the nodes is ± 2.0 in.

Fig. 10
figure 10

Configuration of 10-bar planar truss (Camp and Farshchin 2014)

Table 5 shows the results of GBSMA and other optimization methods, where W represents the total weight of the truss, and N represents the number of evaluations. It can be seen from the table that the optimal solution obtained by GBSMA and PSO is better than other optimization algorithms, but the average result of GBSMA does not perform well. On the one hand, it reflects the potential of GBSMA, and on the other hand, it also shows that GBSMA is easy to fall into the local optimum on the 10-bar planar truss structure optimization problem. However, there is a problem that needs to be pointed out. Some of the designs listed in the table do not meet the constraints. Only the TLBO design meets the constraints, while the results of GBSMA are not much worst. This shows the reliability of the GBSMA.

Table 5 Results of GBSMA and other algorithms on 10-bar planar truss

4.7.3 25-bar space truss

Figure 11 shows the 25-bar transmission tower space truss structure (Camp and Farshchin 2014; Kaveh and Zakian 2018). The 25 members are divided into eight groups; each group member has the same cross-sectional area, the cross-sectional area's range is [0.01, 3.4] in2, the member's density is 0.1 lb/in3, and the modulus of elasticity is 107psi. The node coordinates and grouping of the 25-bar space truss can be referred to in this paper (Camp and Farshchin 2014). The constraint conditions to be satisfied by the structure include: the stress constraint of members, two load cases constraints, and the maximum allowable deflection of nodes in all directions are ± 0.35in. The stress constraints and load case constraints are listed in Table 6.

Fig. 11
figure 11

Configuration of 25-bar space truss (Camp and Farshchin 2014; Kaveh and Zakian 2018)

Table 6 Stress limits and multiple loading cases for the 25-bar space truss

Table 7 lists the optimization results of GBSMA and other optimization algorithms on the 25-bar space truss structure. From the results in the table, we can see that the best results of multiple experiments have three better algorithms than GBSMA, namely TLBO, CSAM, and EBA, but except for CSAM, the average value of GBSMA is better than other algorithms, reflecting the stability of GBSMA. After observation, it can be found that the number of evaluations used by GBSMA is much smaller than that used by CSAM, which indicates that the convergence speed of GBSMA is faster than that of CSAM.

Table 7 Results of GBSMA and other algorithms on 25-bar space truss

4.7.4 72-bar space truss

Figure 12 shows the 72-bar space truss structure (Degertekin 2012; Kaveh and Zakian 2018), Fig. 12a shows the node numbers, and Fig. 12b shows the edge numbers. The 72 members are divided into 16 groups, and the grouping information and optimization results are given in Table 9. The range of the cross-sectional area of the members is [0.1, 3.0] in2, the density of the rod is 0.1 lb/in3, and the modulus of elasticity is 107 psi. The constraints to be satisfied are: the maximum allowable stress of each member is ± 25ksi, and the maximum allowable deflection in any direction of the node is ± 0.25 in. The two load cases constraints to be satisfied are listed in Table 8.

Fig. 12
figure 12

Configuration of 72-bar space truss (Degertekin 2012; Kaveh and Zakian 2018)

Table 8 Multiple loading conditions for the 72-bar space truss

Table 9 compares the optimization results of GBSMA and other methods. The optimal weight of GBSMA is 379.735 lb, and the average weight of GBSMA is 380.023 lb, which is better than the six comparison methods listed in the table, indicating the powerful search ability of GBSMA. The closest thing to GBSMA is CBO, but the number of evaluations of CBO is 1.8 times that of GBSMA, which shows that the convergence speed of GBSMA is faster. From the results in the table, we can see that the standard deviation of multiple experiments of GBSMA is also the smallest, reflecting the stability of the algorithm. It should be noted that these truss cases are not enough to prove the effectiveness of the proposed GBSMA. In future work, the GBSMA can also be applied to more cases, such as optimization of machine learning models (Liu 2022; Zheng et al. 2022; Li et al. 2021a), text clustering (Guan 2020), recommender system (Wang et al. 2018c), kayak cycle phase segmentation (Qiu et al. 2021), and network analysis (Liu et al. 2021b; Su et al. 2019a). Also, It can be applied to optimize the features of more complex scenarios in crystal structures optimization (Huang et al. 2022), bionic electronic skin sensing (Wang et al. 2022b; Ouyang et al. 2022), active surveillance (Pei et al. 2022), and disease prediction (Su et al. 2019b; Li et al. 2021b).

Table 9 Results of GBSMA and other algorithms on 72-bar space truss

5 Conclusions and future works

In this paper, Gaussian barebone mutation and greedy selection are introduced to improve the original SMA. The Gaussian function in Gaussian barebone mutation enlarges the search space, enhances the algorithm's global search capability, accelerates the algorithm's convergence speed, and strengthens the algorithm's local search capability. The DE mutation strategy in Gaussian barebone mutation uses \(\mathrm{rand}\) as the guiding vector, enhancing the original algorithm’s exploration capability to a certain extent. By introducing Gaussian barebone mutation, exploration and exploitation reach a new balance. To a certain extent, introducing greedy selection avoids individual ineffective position updates. In the CEC2017 test functions, the proposed GBSMA is compared with conventional algorithms and advanced algorithms. The experimental results prove the advantages of GBSMA. Using GBSMA for engineering problems shows the GBSMA algorithm's advantages over other algorithms.

Other strategies can be considered in future work to be introduced into the Gaussian barebone mutation to replace the DE mutation strategy among GBSMA. It is also possible to study the strategies such as mutation (Xu et al. 2019b), opposition-based learning, orthogonal learning, and multiple populations (Chen et al. 2020b) to improve the performance of SMA.