Wuhan University Journal of Natural Sciences

, Volume 24, Issue 6, pp 524–536 | Cite as

Enhancing Firefly Algorithm with Best Neighbor Guided Search Strategy

  • Shuangke Wu
  • Zhijian WuEmail author
  • Hu Peng
Computer Science


Firefly algorithm (FA) is a recently-proposed swarm intelligence technique. It has shown good performance in solving various optimization problems. According to the standard firefly algorithm and most of its variants, a firefly migrates to every other brighter firefly in each iteration. However, this method leads to defects of oscillations of positions, which hampers the convergence to the optimum. To address these problems and enhance the performance of FA, we propose a new firefly algorithm, which is called the Best Neighbor Firefly Algorithm (BNFA). It employs the best neighbor guided strategy, where each firefly is attracted to the best firefly among some randomly chosen neighbors, thus reducing the firefly oscillations in every attraction-induced migration stage, while increasing the probability of the guidance a new better direction. Moreover, it selects neighbors randomly to prevent the firefly form being trapped into a local optimum. Extensive experiments are conducted to find out the optimal parameter settings. To verify the performance of BNFA, 13 classical benchmark functions are tested. Results show that BNFA outperforms the standard FA and other recently proposed modified FAs.

Key words

firefly algorithm (FA) global optimization random neighbour exploration and exploitation 

CLC number

TN 918.4 


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. [1]
    Kennedy J. Particle swarm optimization [C]// Encyclopedia of Machine Learning. New York: Springer-Verlag, 2010: 760–766.Google Scholar
  2. [2]
    Peng H, Guo Z, Deng C, et al. Enhancing differential evolution with random neighbors based strategy [J]. Journal of Computational Science, 2018, 26: 501–511.CrossRefGoogle Scholar
  3. [3]
    Peng H, Wu Z. Heterozygous differential evolution with Taguchi local search [J]. Soft Computing, 2015, 19(11): 3273–3291.CrossRefGoogle Scholar
  4. [4]
    Karaboga D. An Idea Based on Honey Bee Swarm for Numerical Optimization [R]. Kayseri: Erciyes University, 2005.Google Scholar
  5. [5]
    Yang X S. Nature-Inspired Metaheuristic Algorithms [M]. United Kingdom: Luniver Press, 2010.Google Scholar
  6. [6]
    Jaradat A S, Hamad S B. Community structure detection using firefly algorithm[J]. International Journal of Applied Metaheuristic Computing (IJAMC), 2018, 9(4): 52–70.CrossRefGoogle Scholar
  7. [7]
    Moazenzadeh R, Mohammadi B, Shamshirband S, et al. Coupling a firefly algorithm with support vector regression to predict evaporation in northern Iran[J]. Engineering Applications of Computational Fluid Mechanics, 2018, 12(1): 584–597.CrossRefGoogle Scholar
  8. [8]
    Spea S R. Economic-emission dispatch problem using firefly algorithm[C]//2017 Nineteenth International Middle East Power Systems Conference (MEPCON). Washington D C: IEEE, 2017: 671–676.Google Scholar
  9. [9]
    Yu S, Su S, Lu Q, et al. A novel wise step strategy for firefly algorithm[J]. International Journal of Computer Mathematics, 2014, 91(12): 2507–2513.CrossRefGoogle Scholar
  10. [10]
    Yu S, Zhu S, Ma Y, et al. A variable step size firefly algorithm for numerical optimization[J]. Applied Mathematics and Computation, 2015, 263: 214–220.CrossRefGoogle Scholar
  11. [11]
    Fister Jr I, Yang X S, Fister I, et al. Memetic firefly algorithm for combinatorial optimization [EB/OL]. [2012-05-10].
  12. [12]
    Gandomi A H, Yang X S, Talatahari S, et al. Firefly algorithm with chaos[J]. Communications in Nonlinear Science and Numerical Simulation, 2013, 18(1): 89–98.CrossRefGoogle Scholar
  13. [13]
    Wang H, Wang W, Sun H, et al. Firefly algorithm with random attraction[J]. International Journal of Bio-Inspired Computation, 2016, 8(1): 33–41.CrossRefGoogle Scholar
  14. [14]
    Yang X S. Engineering Optimization: An Introduction with Metaheuristic Applications[M]. New York: John Wiley & Sons, 2010.CrossRefGoogle Scholar
  15. [15]
    Farahani S M, Abshouri A A, Nasiri B, et al. A Gaussian firefly algorithm[J]. International Journal of Machine Learning and Computing, 2011, 1(5): 448–453.CrossRefGoogle Scholar
  16. [16]
    Surafel L T, Hong C. Modified firefly algorithm[J]. J Appl Math, 2012, 39: 1–12.Google Scholar
  17. [17]
    Fister I, Yang X S, Brest J, et al. Modified firefly algorithm using quaternion representation[J]. Expert Systems with Applications, 2013, 40(18): 7220–7230.CrossRefGoogle Scholar
  18. [18]
    Poursalehi N, Zolfaghari A, Minuchehr A. Multi-objective loading pattern enhancement of PWR based on the discrete firefly algorithm[J]. Annals of Nuclear Energy, 2013, 57: 151–163.CrossRefGoogle Scholar
  19. [19]
    Sayadi M K, Hafezalkotob A, Naini S G J. Firefly-inspired algorithm for discrete optimization problems: An application to manufacturing cell formation[J]. Journal of Manufacturing Systems, 2013, 32(1): 78–84.CrossRefGoogle Scholar
  20. [20]
    Chandrasekaran K, Simon S P. Network and reliability constrained unit commitment problem using binary real coded firefly algorithm[J]. International Journal of Electrical Power & Energy Systems, 2012, 43(1): 921–932.CrossRefGoogle Scholar
  21. [21]
    Marichelvam M K, Prabaharan T, Yang X S. A discrete firefly algorithm for the multi-objective hybrid flowshop scheduling problems[J]. IEEE Transactions on Evolutionary Computation, 2014, 18(2): 301–305.CrossRefGoogle Scholar
  22. [22]
    Rahmani A, Mirhassani S A. A hybrid firefly-genetic algorithm for the capacitated facility location problem [J]. Information Sciences, 2014, 283: 70–78.CrossRefGoogle Scholar
  23. [23]
    Baykasoğlu A, Ozsoydan F B. An improved firefly algorithm for solving dynamic multidimensional knapsack problems [J]. Expert Systems with Applications, 2014, 41(8): 3712–3725.CrossRefGoogle Scholar
  24. [24]
    Xu M, Liu G. A multipopulation firefly algorithm for correlated data routing in underwater wireless sensor networks [J]. International Journal of Distributed Sensor Networks, 2013, 9(3): 865154.CrossRefGoogle Scholar
  25. [25]
    Hassanzadeh T, Kanan H R. Fuzzy FA: A modified firefly algorithm [J]. Applied Artificial Intelligence, 2014, 28(1): 47–65.CrossRefGoogle Scholar
  26. [26]
    Verma O P, Aggarwal D, Patodi T. Opposition and dimensional based modified firefly algorithm [J]. Expert Systems with Applications, 2016, 44: 168–176.CrossRefGoogle Scholar
  27. [27]
    Wang B, Li D X, Jiang J P, et al. A modified firefly algorithm based on light intensity difference [J]. Journal of Combinatorial Optimization, 2016, 31(3): 1045–1060.CrossRefGoogle Scholar
  28. [28]
    Wang H, Wang W, Zhou X, et al. Firefly algorithm with neighborhood attraction [J]. Information Sciences, 2017, 382: 374–387.CrossRefGoogle Scholar
  29. [29]
    Yao X, Liu Y, Lin G. Evolutionary programming made faster [J]. IEEE Transactions on Evolutionary computation, 1999, 3(2): 82–102.CrossRefGoogle Scholar
  30. [30]
    Garcia S, Fernández A, Luengo J, et al. Advanced nonparametric tests for multiple comparisons in the design of experiments in computational intelligence and data mining: Experimental analysis of power [J]. Information Sciences, 2010, 180(10): 2044–2064.CrossRefGoogle Scholar
  31. [31]
    García S, Molina D, Lozano M, et al. A study on the use of non-parametric tests for analyzing the evolutionary algorithms’ behaviour: A case study on the CEC’2005 special session on real parameter optimization [J]. Journal of Heuristics, 2009, 15(6): 617–644.CrossRefGoogle Scholar
  32. [32]
    Alcalá-Fdez J, Sánchez L, Garcia S, et al. KEEL: A software tool to assess evolutionary algorithms for data mining problems [J]. Soft Computing, 2009, 13(3): 307–318.CrossRefGoogle Scholar

Copyright information

© Wuhan University and Springer-Verlag GmbH Germany 2019

Authors and Affiliations

  1. 1.School of Computer ScienceWuhan UniversityHubeiChina
  2. 2.School of Information Science and TechnologyJiujiang UniversityJiangxiChina

Personalised recommendations