Example of using color palette
This is an example to implement HSV scheme to objects without changing the color settings of the objects manually.
I used this applet: Color palettes
Script Setup
n = 20
Ln = 1...n
speed = 1
t = Slider(0, 2 pi, 0.01, speed, 200)
f(x) = sin( (20x + t))
Execute(Zip("P"+k+" = ("+k+", f("+k+"))", k, Ln))
Execute(Zip("ShowLabel(P"+k+", false)", k, Ln))
Execute(Zip("C"+k+" = Circle(P"+k+", 1)", k, Ln))
Execute(Zip("ShowLabel(C"+k+", false)", k, Ln))
A = (0.5, 0.5, 0.5)
B = (0.5, 0.5, 0.5)
C = (1, 1, 0.85)
D = (0, 0.33, 0.67)
Red(x) = x(A) + x(B) * cos(2pi(x(C)*x+x(D)))
Green(x) = y(A) + y(B) * cos(2pi(y(C)*x+y(D)))
Blue(x) = z(A) + z(B) * cos(2pi(z(C)*x+z(D)))
SetVisibleInView(Red, 1, false)
SetVisibleInView(Green, 1, false)
SetVisibleInView(Blue, 1, false)
Execute(Zip("SetDynamicColor(C"+k+", Red("+k+"/n), Green("+k+"/n), Blue("+k+"/n), 1)", k, Ln))
ShowGrid(false)
ShowAxes(false)