On Efficiently Solving the Vehicle Routing Problem with Time Windows Using the Bat Algorithm with Random Reinsertion Operators

  • Eneko OsabaEmail author
  • Roberto Carballedo
  • Xin-She Yang
  • Iztok Fister Jr.
  • Pedro Lopez-Garcia
  • Javier Del Ser
Part of the Studies in Computational Intelligence book series (SCI, volume 744)


An evolutionary and discrete variant of the Bat Algorithm (EDBA) is proposed for solving the Vehicle Routing Problem with Time Windows, or VRPTW. The EDBA developed not only presents an improved movement strategy, but it also combines with diverse heuristic operators to deal with this type of complex problems. One of the main new concepts is to unify the search process and the minimization of the routes and total distance in the same operators. This hybridization is achieved by using selective node extractions and subsequent reinsertions. In addition, the new approach analyzes all the routes that compose a solution with the intention of enhancing the diversification ability of the search process. In this study, several variants of the EDBA are shown and tested in order to measure the quality of both metaheuristic algorithms and their operators. The benchmark experiments have been carried out by using the 56 instances that compose the 100 customers Solomon’s benchmark. Two statistical tests have also been carried out so as to analyze the results and draw proper conclusions.


Bat algorithm Discrete bat algorithm Vehicle routing problem with time windows VRPTW Combinatorial optimization Traveling salesman problem 


  1. 1.
    Laporte, G.: The vehicle routing problem: an overview of exact and approximate algorithms. Eur. J. Operat. Res. 59(3), 345–358 (1992)CrossRefzbMATHGoogle Scholar
  2. 2.
    Kirkpatrick, S., Gellat, C., Vecchi, M.: Optimization by simmulated annealing. Science 220(4598), 671–680 (1983)MathSciNetCrossRefzbMATHGoogle Scholar
  3. 3.
    Glover, F.: Tabu search, part I. ORSA J. Comput. 1(3), 190–206 (1989)CrossRefzbMATHGoogle Scholar
  4. 4.
    Dorigo, M., Blum, C.: Ant colony optimization theory: a survey. Theor. Comput. Sci. 344(2), 243–278 (2005)MathSciNetCrossRefzbMATHGoogle Scholar
  5. 5.
    Goldberg, D.: Genetic Algorithms in Search, Optimization, and Machine Learning. Addison-Wesley Professional (1989)Google Scholar
  6. 6.
    De Jong, K.: Analysis of the behavior of a class of genetic adaptive systems. PhD thesis, University of Michigan, Michigan, USA (1975)Google Scholar
  7. 7.
    Kennedy, J., Eberhart, R., et al.: Particle swarm optimization. In: Proceedings of IEEE International Conference on Neural Networks. Vol. 4., Perth, Australia, pp. 1942–1948 (1995)Google Scholar
  8. 8.
    Atashpaz-Gargari, E., Lucas, C.: Imperialist competitive algorithm: an algorithm for optimization inspired by imperialistic competition. In: Evolutionary Computation, 2007. CEC 2007. IEEE Congress on, IEEE pp. 4661–4667 (2007)Google Scholar
  9. 9.
    Karaboga, D., Basturk, B.: A powerful and efficient algorithm for numerical function optimization: artificial bee colony (abc) algorithm. J. Glob. Optim. 39(3), 459–471 (2007)MathSciNetCrossRefzbMATHGoogle Scholar
  10. 10.
    Yang, X.S.: A new metaheuristic bat-inspired algorithm. In: Nature Inspired Cooperative Strategies for Optimization. Springer pp. 65–74 (2010)Google Scholar
  11. 11.
    Yang, X.S., He, X.: Bat algorithm: literature review and applications. Int. J. Bio-Ins. Comput. 5(3), 141–149 (2013)CrossRefGoogle Scholar
  12. 12.
    Parpinelli, R.S., Lopes, H.S.: New inspirations in swarm intelligence: a survey. Int. J. Bio-Ins. Comput. 3(1), 1–16 (2011)CrossRefGoogle Scholar
  13. 13.
    Dhar, S., Alam, S., Santra, M., Saha, P., Thakur, S.: A novel method for edge detection in a gray image based on human psychovisual phenomenon and bat algorithm. In: Computer, Communication and Electrical Technology. CRC Press, pp. 3–7 (2007)Google Scholar
  14. 14.
    Tharakeshwar, T., Seetharamu, K., Prasad, B.D.: Multi-objective optimization using bat algorithm for shell and tube heat exchangers. Appl. Therm. Eng. 110, 1029–1038 (2017)CrossRefGoogle Scholar
  15. 15.
    Osaba, E., Carballedo, R., Yang, X.S., Diaz, F.: An evolutionary discrete firefly algorithm with novel operators for solving the vehicle routing problem with time windows. In: Nature-Inspired Computation in Engineering. Springer, pp. 21–41 (2016)Google Scholar
  16. 16.
    Lawler, E.L.: The traveling salesman problem: a guided tour of combinatorial optimization. Wiley-Interscience Series in Discrete Mathematics (1985)Google Scholar
  17. 17.
    Christofides, N.: The vehicle routing problem. RAIRO Operat. Res. Recherche Opérationnel. 10(V1), 55–70 (1976)MathSciNetzbMATHGoogle Scholar
  18. 18.
    Wassan, N., Wassan, N., Nagy, G., Salhi, S.: The multiple trip vehicle routing problem with backhauls: formulation and a two-level variable neighbourhood search. Comput. Operat. Res. 78, 454–467 (2017)MathSciNetCrossRefGoogle Scholar
  19. 19.
    Veenstra, M., Roodbergen, K.J., Vis, I.F., Coelho, L.C.: The pickup and delivery traveling salesman problem with handling costs. Eur. J. Operat. Res. 257(1), 118–132 (2017)MathSciNetCrossRefGoogle Scholar
  20. 20.
    Bräysy, O., Gendreau, M.: Vehicle routing problem with time windows, part I: route construction and local search algorithms. Transport. Sci. 39(1), 104–118 (2005)CrossRefGoogle Scholar
  21. 21.
    Potvin, J.Y., Bengio, S.: The vehicle routing problem with time windows part II: genetic search. INFORMS J. Comput. 8(2), 165–172 (1996)CrossRefzbMATHGoogle Scholar
  22. 22.
    Laporte, G.: The traveling salesman problem: an overview of exact and approximate algorithms. Eur. J. of Oper. Res. 59(2), 231–247 (1992)MathSciNetCrossRefzbMATHGoogle Scholar
  23. 23.
    Bräysy, O., Gendreau, M.: Vehicle routing problem with time windows, part II: metaheuristics. Transport. Sci. 39(1), 119–139 (2005)CrossRefGoogle Scholar
  24. 24.
    Yang, X.S.: Nature-inspired metaheuristic algorithms. Luniver press (2010)Google Scholar
  25. 25.
    Taha, A., Hachimi, M., Moudden, A.: Adapted bat algorithm for capacitated vehicle routing problem. Int. Rev. Comput. Soft. (IRECOS) 10(6), 610–619 (2015)CrossRefGoogle Scholar
  26. 26.
    Zhou, Y., Luo, Q., Xie, J., Zheng, H.: A hybrid bat algorithm with path relinking for the capacitated vehicle routing problem. In: Metaheuristics and Optimization in Civil Engineering. Springer, pp. 255–276 (2016)Google Scholar
  27. 27.
    Yang, X.S.: Nature-Inspired Metaheuristic Algorithms. Luniver Press, UK (2008)Google Scholar
  28. 28.
    Fister, I., Yang, X.S., Fister, D., Fister Jr, I.: Firefly algorithm: a brief review of the expanding literature. In: Cuckoo Search and Firefly Algorithm. Springer, pp. 347–360 (2014)Google Scholar
  29. 29.
    Fister, I., Fister Jr., I., Yang, X.S., Brest, J.: A comprehensive review of firefly algorithms. Swarm Evolut. Comput. 13, 34–46 (2013)CrossRefGoogle Scholar
  30. 30.
    Jati, G.K., Suyanto. In: Evolutionary Discrete Firefly Algorithm for Travelling Salesman Problem. Springer, Berlin Heidelberg, pp. 393–403 (2011)Google Scholar
  31. 31.
    Alinaghian, M., Naderipour, M.: A novel comprehensive macroscopic model for time-dependent vehicle routing problem with multi-alternative graph to reduce fuel consumption: a case study. Comput. Indust. Eng. 99, 210–222 (2016)CrossRefGoogle Scholar
  32. 32.
    Del Ser, J., Torre-Bastida, A.I., Lana, I., Bilbao, M.N., Perfecto, C.: Nature-inspired heuristics for the multiple-vehicle selective pickup and delivery problem under maximum profit and incentive fairness criteria. In: IEEE Congress on Evolutionary Computation (2017)Google Scholar
  33. 33.
    Yang, X.S., Deb, S.: Cuckoo search via lévy flights. In: World Congress on Nature & Biologically Inspired Computing. IEEE, pp. 210–214 (2009)Google Scholar
  34. 34.
    Ouaarab, A., Ahiod, B., Yang, X.S.: Discrete cuckoo search algorithm for the travelling salesman problem. Neural Comput. Appl. 24(7–8), 1659–1669 (2014)CrossRefGoogle Scholar
  35. 35.
    Alssager, M., Othman, Z.A.: Taguchi-based parameter setting of cuckoo search algorithm for capacitated vehicle routing problem. In: Advances in Machine Learning and Signal Processing. Springer, pp. 71–79 (2016)Google Scholar
  36. 36.
    Teymourian, E., Kayvanfar, V., Komaki, G.M., Zandieh, M.: Enhanced intelligent water drops and cuckoo search algorithms for solving the capacitated vehicle routing problem. Informat. Sci. 334, 354–378 (2016)CrossRefGoogle Scholar
  37. 37.
    Chen, X., Wang, J.: A novel hybrid cuckoo search algorithm for optimizing vehicle routing problem in logistics distribution system. J. Comput. Theor. Nanosci. 13(1), 114–119 (2016)CrossRefGoogle Scholar
  38. 38.
    Geem, Z.W., Kim, J.H., Loganathan, G.: A new heuristic optimization algorithm: harmony search. Simulation 76(2), 60–68 (2001)CrossRefGoogle Scholar
  39. 39.
    Manjarres, D., Landa-Torres, I., Gil-Lopez, S., Del Ser, J., Bilbao, M.N., Salcedo-Sanz, S., Geem, Z.W.: A survey on applications of the harmony search algorithm. Eng. Appl. Artific. Intell. 26(8), 1818–1831 (2013)CrossRefGoogle Scholar
  40. 40.
    Assad, A., Deep, K.: Applications of harmony search algorithm in data mining: a survey. In: Proceedings of Fifth International Conference on Soft Computing for Problem Solving. Springer , pp. 863–874 (2016)Google Scholar
  41. 41.
    Mohd Alia, O., Mandava, R.: The variants of the harmony search algorithm: an overview. Artific. Intell. Rev. 36(1), 49–68 (2011)CrossRefGoogle Scholar
  42. 42.
    Geem, Z.W., Lee, K.S., Park, Y.: Application of harmony search to vehicle routing. Am. J. Appl. Sci. 2(12), 1552–1557 (2005)CrossRefGoogle Scholar
  43. 43.
    Del Ser, J., Bilbao, M.N., Perfecto, C., Salcedo-Sanz, S.: A harmony search approach for the selective pick-up and delivery problem with delayed drop-off. In: Harmony Search Algorithm. Springer, pp. 121–131 (2016)Google Scholar
  44. 44.
    Rashedi, E., Nezamabadi-Pour, H., Saryazdi, S.: Gsa: a gravitational search algorithm. Informat. Sci. 179(13), 2232–2248 (2009)CrossRefzbMATHGoogle Scholar
  45. 45.
    Precup, R.E., David, R.C., Petriu, E.M., Radac, M.B., Preitl, S.: Adaptive gsa-based optimal tuning of pi controlled servo systems with reduced process parametric sensitivity, robust stability and controller robustness. IEEE Trans. Cybernet. 44(11), 1997–2009 (2014)CrossRefGoogle Scholar
  46. 46.
    Precup, R.E., David, R.C., Petriu, E.M., Preitl, S., Rădac, M.B.: Fuzzy logic-based adaptive gravitational search algorithm for optimal tuning of fuzzy-controlled servo systems. IET Control Theor. Appl. 7(1), 99–107 (2013)MathSciNetCrossRefGoogle Scholar
  47. 47.
    Duman, S., Güvenç, U., Sönmez, Y., Yörükeren, N.: Optimal power flow using gravitational search algorithm. Energy Convers. Manag. 59, 86–95 (2012)CrossRefGoogle Scholar
  48. 48.
    Nodehi, A.N., Fadaei, M., Ebrahimi, P.: Solving the traveling salesman problem using randomized gravitational emulation search algorithm. J. Curr. Res. Sci. 2, 818 (2016)Google Scholar
  49. 49.
    Hosseinabadi, A.A.R., Kardgar, M., Shojafar, M., Shamshirband, S., Abraham, A.: Gravitational search algorithm to solve open vehicle routing problem. In: Innovations in Bio-Inspired Computing and Applications. Springer, pp. 93–103 (2016)Google Scholar
  50. 50.
    Hosseinabadi, A.A.R., Rostami, N.S.H., Kardgar, M., Mirkamali, S., Abraham, A.: A new efficient approach for solving the capacitated vehicle routing problem using the gravitational emulation local search algorithm. Appl. Mathemat, Model (2017)Google Scholar
  51. 51.
    Desaulniers, G., Errico, F., Irnich, S., Schneider, M.: Exact algorithms for electric vehicle-routing problems with time windows. Les Cahiers du GERAD G-2014-110, GERAD, Montréal, Canada (2014)Google Scholar
  52. 52.
    Belhaiza, S., Hansen, P., Laporte, G.: A hybrid variable neighborhood tabu search heuristic for the vehicle routing problem with multiple time windows. Comput. Operat. Res. 52, 269–281 (2014)MathSciNetCrossRefzbMATHGoogle Scholar
  53. 53.
    Toklu, N.E., Gambardella, L.M., Montemanni, R.: A multiple ant colony system for a vehicle routing problem with time windows and uncertain travel times. J. Traffic Logist. Eng. 2(1) (2014)Google Scholar
  54. 54.
    Nguyen, P.K., Crainic, T.G., Toulouse, M.: A hybrid generational genetic algorithm for the periodic vehicle routing problem with time windows. J. Heurist. 20(4), 383–416 (2014)CrossRefGoogle Scholar
  55. 55.
    Yassen, E.T., Ayob, M., Nazri, M.Z.A., Sabar, N.R.: Meta-harmony search algorithm for the vehicle routing problem with time windows. Informat. Sci. 325, 140–158 (2015)CrossRefGoogle Scholar
  56. 56.
    Yang, X.S., Deb, S.: Cuckoo search: recent advances and applications. Neural Comput. Appl. 24(1), 169–174 (2014)CrossRefGoogle Scholar
  57. 57.
    Kallehauge, B., Larsen, J., Madsen, O.B., Solomon, M.M.: Vehicle routing problem with time windows. Springer (2005)Google Scholar
  58. 58.
    Gendreau, M., Tarantilis, C.D.: Solving large-scale vehicle routing problems with time windows: the state-of-the-art. CIRRELT (2010)Google Scholar
  59. 59.
    Afifi, S., Guibadj, R.N., Moukrim, A.: New lower bounds on the number of vehicles for the vehicle routing problem with time windows. In: Integration of AI and OR Techniques in Constraint Programming. Springer, pp. 422–437 (2014)Google Scholar
  60. 60.
    Agra, A., Christiansen, M., Figueiredo, R., Hvattum, L.M., Poss, M., Requejo, C.: The robust vehicle routing problem with time windows. Comput. Operat. Res. 40(3), 856–866 (2013)MathSciNetCrossRefzbMATHGoogle Scholar
  61. 61.
    Azi, N., Gendreau, M., Potvin, J.Y.: An exact algorithm for a single-vehicle routing problem with time windows and multiple routes. Eur. J. Operat. Res. 178(3), 755–766 (2007)MathSciNetCrossRefzbMATHGoogle Scholar
  62. 62.
    Bräysy, O., Gendreau, M.: Tabu search heuristics for the vehicle routing problem with time windows. Top 10(2), 211–237 (2002)MathSciNetCrossRefzbMATHGoogle Scholar
  63. 63.
    Cordeau, J.F., Desaulniers, G., Desrosiers, J., Solomon, M.M., Soumis, F.: Vrp with time windows. Vehicle Rout. Prob. 9, 157–193 (2001)MathSciNetzbMATHGoogle Scholar
  64. 64.
    Glover, F.: Ejection chains, reference structures and alternating path methods for traveling salesman problems. Discr. Appl. Mathemat. 65(1–3), 223–253 (1996)MathSciNetCrossRefzbMATHGoogle Scholar
  65. 65.
    Osaba, E., Yang, X.S., Diaz, F., Onieva, E., Masegosa, A.D., Perallos, A.: A discrete firefly algorithm to solve a rich vehicle routing problem modelling a newspaper distribution system with recycling policy. Soft Comput. 1–14 (2016)Google Scholar
  66. 66.
    Irnich, S.: A unified modeling and solution framework for vehicle routing and local search-based metaheuristics. INFORMS J. Comput. 20(2), 270–287 (2008)MathSciNetCrossRefzbMATHGoogle Scholar
  67. 67.
    Campbell, A.M., Savelsbergh, M.: Efficient Insertion heuristics for vehicle routing and scheduling problems. Transport. Sci. 38(3), 369–378 (2004)CrossRefGoogle Scholar
  68. 68.
    Solomon, M.M.: Algorithms for the vehicle routing and scheduling problems with time window constraints. Oper. Res. 35(2), 254–265 (1987)MathSciNetCrossRefzbMATHGoogle Scholar
  69. 69.
    Derrac, J., García, S., Molina, D., Herrera, F.: A practical tutorial on the use of nonparametric statistical tests as a methodology for comparing evolutionary and swarm intelligence algorithms. Swarm Evol. Computat. 1(1), 3–18 (2011)CrossRefGoogle Scholar

Copyright information

© Springer International Publishing AG 2018

Authors and Affiliations

  • Eneko Osaba
    • 1
    Email author
  • Roberto Carballedo
    • 1
  • Xin-She Yang
    • 2
  • Iztok Fister Jr.
    • 3
  • Pedro Lopez-Garcia
    • 1
  • Javier Del Ser
    • 4
    • 5
    • 6
  1. 1.Deusto Institute of Technology (DeustoTech)University of DeustoBilbaoSpain
  2. 2.School of Science and TechnologyMiddlesex UniversityLondonUK
  3. 3.Faculty of Electrical Engineering and Computer ScienceUniversity of MariborMariborSlovenia
  4. 4.TECNALIADerioSpain
  5. 5.University of the Basque Country (UPV/EHU)BilbaoSpain
  6. 6.Basque Center for Applied Mathematics (BCAM)BilbaoSpain

Personalised recommendations