Implicit Plot 3D - ThreeJS

asked 2018-03-13 05:11:37 -0500

jepstra gravatar image

I'm trying to plot several algebraic surfaces, most of which have singularities and other especial properties. Using implicit_plot3d and viewer='threejs' works fine for instance

s = implicit_plot3d(p==0, (x,-r,r), (y,-r,r), (z,-r,r), plot_points=50, region=lambda x,y,z: x**2+y**2+z**2<=r*r, color=color), viewer='threejs')

But when increasing plot_points=100, SageCell does note return any output (demo) (in a Sage Notebook, everything works fantastic). I guess the query may be too hard for SageCell...

Is there a way to optimize the code / query for SageCell to plot algebraic surfaces with acceptable quality?

edit retag flag offensive close merge delete



implicit_plot3d computes the function to plot at a number of points proportional to the cube of plot_points. If you double plot_points, you (roughly) octuple the necessary RAM and time.

You might, for example, search for a way to parameterize your surfaces, thus reducing your needs to the square of your resolution.

Emmanuel Charpentier gravatar imageEmmanuel Charpentier ( 2018-03-13 19:30:05 -0500 )edit