1 | initial version |
I have once managed to get plot3d use a colormap, see here:
import matplotlib.cm
matplotlib.cm.datad.keys()
lists you the colormaps, you can also create your own. Note, the cmsel list in the following snippet defines the actual colors.
var('r v')
cmsel = [matplotlib.cm.get_cmap('autumn')(_) for _ in sxrange(0,1,0.05)]
p = plot3d(0.2*(r**2 + v**2) + cos(2*r)*sin(2*v),(r,-2,2), (v,-2,2), adaptive=True, color=cmsel, plot_points=10, opacity=0.9)
p2 = sphere((0,0,0),1,color='black',opacity=0.5)
(p+p2).show(aspect_ratio=(1,1,1), figsize=[7,3])