Question: From "HSV" colormap to "cold-to-hot" colormap

Hello!

I have a question about densityplot.

I want to get this colormap:

As I understand, I should use plots:-densityplot(...) comand and "HSV" colorscheme, where H = [240..0], S=1, V=1.

But if i use zcoloring with this options, I will get wrong result.

My code:

restart;

a := 0; b := 1; #first and final point

plots:-densityplot(z, dummy = 0 .. 1, z = a .. b, grid = [2, 10], size = [90, 100], colorscheme = ["zcoloring", [proc (z) options operator, arrow; -240*(z-a)/(b-a)+240 end proc, proc (z) options operator, arrow; 1 end proc, proc (z) options operator, arrow; 1 end proc], colorspace = "HSV"], style = surface, axes = frame, labels = ["", ""], axis[1] = [tickmarks = []], title = "Test", titlefont = ["Calibri", "Bold", 16], axesfont = ["Arial", 14], size = [100, 500]); #densityplot with zcoloring option.

 

My result (zero must be equal to "Blue"):

I can't find mistake....

Please Wait...