| 1 | initial version |
One suggestion would be to use
M=10
surfaces = [ParametrizedSurface3D( (x,y,exp(-(x^2+y^2)/n)), (x,y)) for n in range(1,M+1)]
plot = sum([ s.plot(color=rainbow(M)[i],opacity=0.5) for i,s in enumerate(surfaces)])
plot.show()
Just learned that ParametrizedSurface3D is a surface object, not a plot. So we first create the surfaces and then we render the plot, which will be the sum of all plots of the previously defined surfaces. I guess you can replace exp(-(x^2+y^2)/n by any other function, but that is just a guess.
Copyright Sage, 2010. Some rights reserved under creative commons license. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.