Soft Computing

, Volume 22, Issue 8, pp 2765–2776 | Cite as

The rainbow spanning forest problem

  • Francesco Carrabs
  • Carmine CerroneEmail author
  • Raffaele Cerulli
  • Selene Silvestri
Methodologies and Application


Given an undirected and edge-colored graph G, a rainbow component of G is a subgraph of G having all the edges with different colors. The Rainbow Spanning Forest Problem consists of finding a spanning forest of G with the minimum number of rainbow components. The problem is known to be NP-hard on general graphs and on trees. In this paper, we present an integer linear mathematical formulation and a greedy algorithm to solve it. To further improve the results, we applied a multi-start scheme to the greedy algorithm. Computational results are reported on randomly generated instances.


Graph theory Edge-colored graph Rainbow components Multi-start scheme Heterochromatic components 


Compliance with ethical standards

Conflict of interest

All authors declare that they have no conflict of interest.

Ethical approval

This article does not contain any studies with human participants or animals performed by any of the authors.


  1. Akbari S, Alipour A (2007) Multicolored trees in complete graphs. J Gr Theory 54(3):221–232MathSciNetCrossRefzbMATHGoogle Scholar
  2. Andrews E, Lumduanhom C, Laforge E, Zhang P (2016) On proper-path colorings in graphs. J Comb Math Comb Comput 97:189–207MathSciNetzbMATHGoogle Scholar
  3. Brualdi RA, Hollingsworth S (2001) Multicolored forests in complete bipartite graphs. Discret Math 240:239–245MathSciNetCrossRefzbMATHGoogle Scholar
  4. Carr RD, Doddi S, Konjedov G, Marathe M (2000) On the red-blue set cover problem. In: 11th ACN-SIAM symposium on discrete algorithms, pp 345–353Google Scholar
  5. Carrabs F, Cerrone C, Cerulli R (2014) A tabu search approach for the circle packing problem. In: 2014 17th International conference on network-based information systems. pp 165–171. IEEEGoogle Scholar
  6. Carrabs F, Cerrone C, Cerulli R, Silvestri S (March 2016) On the complexity of rainbow spanning forest problem. Technical Report 14922, Department od Mathematics, University of SalernoGoogle Scholar
  7. Carrabs F, Cerulli R, Dell’Olmo P (2014) A mathematical programming approach for the maximum labeled clique problem. Proced Soc Behav Sci 108:69–78CrossRefGoogle Scholar
  8. Carrabs F, Cerulli R, Gentili M (2009) The labeled maximum matching problem. Comput Oper Res 36:1859–1871MathSciNetCrossRefzbMATHGoogle Scholar
  9. Carraher JM, Hartke SG, Horn P (2016) Edge-disjoint rainbow spanning trees in complete graphs. Eur J Comb 57:71–84MathSciNetCrossRefzbMATHGoogle Scholar
  10. Cerrone C, Cerull R, Golden B (2017) Carousel greedy: a generalized greedy algorithm with applications in optimization. Comput Oper Res (submitted)Google Scholar
  11. Cerrone C, Cerulli R, Gaudioso M (2016) Omega one multi ethnic genetic approach. Optim Lett 10(2):309–324MathSciNetCrossRefzbMATHGoogle Scholar
  12. Cerrone C, Cerulli R, Gentili M (2015) Vehicle-id sensor location for route flow recognition: models and algorithms. Eur J Oper Res 247(2):618–629MathSciNetCrossRefzbMATHGoogle Scholar
  13. Cerulli R, Dell’Olmo P, Gentili M, Raiconi A (2006) Heuristic approaches for the minimum labelling hamiltonian cycle problem. Electron Notes Discret Math 25:131–138MathSciNetCrossRefzbMATHGoogle Scholar
  14. Cerulli R, Fink A, Gentili M, Voß S (2005) Metaheuristics comparison for the minimum labelling spanning tree problem. In: The next wave in computing, optimization, and decision technologies. Springer, pp 93–106Google Scholar
  15. Chang RS, Leu SJ (1997) The minimum labeling spanning trees. Inf Process Lett 63:277–282Google Scholar
  16. Chen Y, Cornick N, Hall AO, Shajpal R, Silberholz J, Yahav I, Golden B (2008) Comparison of heuristics for solving the gmlst problem. In: Telecommunications modeling, policy, and technology. Springer, pp 191–217Google Scholar
  17. Consoli S, Darby-Dowman K, Mladenović N, Moreno-Pérez JA (2009) Variable neighbourhood search for the minimum labelling steiner tree problem. Ann Oper Res 172:71–96MathSciNetCrossRefzbMATHGoogle Scholar
  18. Consoli S, Moreno-Pérez JA, Darby-Dowman K, Mladenović N (2010) Discrete particle swarm optimization for the minimum labelling steiner tree problem. Nat Comput 9:29–46MathSciNetCrossRefzbMATHGoogle Scholar
  19. Dantzig GB, Fulkerson DR, Johnson SM (1954) Solution of a large-scale traveling-salesman problem. J Oper Res Soc Am 2:393–410MathSciNetGoogle Scholar
  20. Fischetti M, Salazar González JJ, Toth P (1995) Experiments with a multi-commodity formulation for the symmetric capacitated vehicle routing problem. In: Proceedings of the 3rd meeting of the euro working group on transportation. pp 169–173Google Scholar
  21. Jozefowiez N, Laporte G, Semet F (2011) A branch-and-cut algorithm for the minimum labeling hamiltonian cycle problem and two variants. Comput Oper Res 38:1534–1542MathSciNetCrossRefzbMATHGoogle Scholar
  22. Krumke S, Wirth H (1998) On the minimum label spanning tree problem. Inf Process Lett 66(2):81–85MathSciNetCrossRefzbMATHGoogle Scholar
  23. Li X, Zhang XY (2007) On the minimum monochromatic or multicolored subgraph partition problems. Theor Comput Sci 385:1–10MathSciNetCrossRefzbMATHGoogle Scholar
  24. Silvestri S, Laporte G, Cerulli R (2016) The rainbow cycle cover problem. Networks 68(4):260–270Google Scholar
  25. Suzuki K (2006) A necessary and sufficient condition for the existence of a heterochromatic spanning tree in a graph. Gr Comb 22:261–269MathSciNetCrossRefzbMATHGoogle Scholar
  26. Szachniuk M, De Cola M, Felici G, Błażewicz J (2014) The orderly colored longest path problem-a survey of applications and new algorithms. RAIRO Oper Res 48(1):25–51MathSciNetCrossRefzbMATHGoogle Scholar
  27. Szachniuk M, De Cola M, Felici G, De Werra D, Błażewicz J (2015) Optimal pathway reconstruction on 3d nmr maps. Discret Appl Math 182:134–149MathSciNetCrossRefzbMATHGoogle Scholar
  28. Xiong Y, Golden B, Wasil E (2007) The colorful traveling salesman problem. In: Extending the horizons: advances in computing, optimization, and decision technologies. Springer, pp 115–123Google Scholar
  29. Xiongm Y, Golden B, Wasil E, Chen S (2008) The label-constrained minimum spanning tree problem. In: Telecommunications modeling, policy, and technology, Springer, pp 39–58Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2017

Authors and Affiliations

  1. 1.Department of MathematicsUniversity of SalernoFiscianoItaly
  2. 2.Department of Computer ScienceUniversity of SalernoFiscianoItaly
  3. 3.Department of Biosciences and TerritoryUniversity of MolisePescheItaly

Personalised recommendations