Harmonious Coloring: Greedy & Suboptimal Algos

  • Context: Graduate 
  • Thread starter Thread starter bob j
  • Start date Start date
Join the discussion
Registration is free. Ask a follow-up in this thread, or start your own.
2 replies · 3K views
bob j
Messages
22
Reaction score
0
Hi All,
does anyone know of any greedy or suboptimal algorithm to obtain harmonious coloring on a graph?
 
Mathematics news on Phys.org
what exactly do u want to use it for?
 
Sure, you could easily imagine a greedy suboptimal algorithm. Start with a connected graph where all nodes are colorless but one, which has color 1. Maintain a list of color pairs that have already been used. At every step, color a node which is adjacent to a previous node, using an existing color if possible, otherwise using a new color. Continue until all nodes are colored.