smoke to use gradient from red to violet through rainbow How can i get my smoke to change from red to violet through the rainbow as a gradient throughout my animation?

I am trying to create smoke that will have a gradient from red to violet through the rainbow.

I have the smoke, i am not able to make it change colors throughout my animation though.

I would love to use nodes to do this, because i am trying to learn nodes right now. I have not been able to find a good tutorial on how to change smoke colors with nodes though.

Thanks
Here's a variant of the 'Quick Smoke' material (as created by selecting the default cube, pressing Space and typing 'Quick Smoke' Enter).



The differences are the addition of the Emission shader to make the smoke glow (this would normally be the 'flames') and the additional of a Color Ramp set to vary based on the Generated 'Z' coordinate (adjust the color ramp colors to get the desired 'rainbow').

Note that setting the smoke domain objects to be 'Smoke Adaptive Domain' the smoke rainbow will dynamically span the height of the extent of the smoke.