Ask Your Question

jsmol problem in Sagemath/Jupyter notebooks

asked 2019-02-03 00:07:02 +0200

cenobyte gravatar image

Whenevr plotting 3d functions I get:

Interactive 3D plots using the default viewer do not work in SageNB, because JSmol cannot currently be packaged for Debian. See the README.source of the jmol package for more details on this situation. You have the following alternative options: View an interactive WebGL-based plot by giving the option viewer='threejs'. This should work out-of-the box on Firefox, but may require you to adjust some settings in Chromium - see chrome://flags for options and chrome://gpu for status. In both cases, the functionality also depends on your graphics hardware and drivers, but support should exist in most cases. View a less sophisticated interactive plot that does not require WebGL, by giving the option viewer='canvas3d'. View a non-interactive plot by giving the option viewer='tachyon'. Use the default viewer (Jmol) from the SageMath command-line interface, instead of the notebook.

I can use threejs for everything except plotting vector fields. Is there any way to get Jsmol working on a debian system? I've found nothing on google that would help.

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2019-02-03 10:06:08 +0200

tmonteil gravatar image

The easiest way in your settings is definitely to compile Sage by yourself, so that jsmol will be installed as a standard package. On Debian-like systems, it is pretty straightforward, see the doc at : The source code of Sage can be downloaded at

edit flag offensive delete link more

answered 2019-02-03 21:59:20 +0200

eric_g gravatar image

Regarding vector fields, you can use threejs via the method plot of vector fields on the Euclidean space:

E.<x,y,z> = EuclideanSpace()
v = E.vector_field((x*cos(z), -y*cos(z), sin(z)))
v.plot(max_range=pi/2, viewer='threejs')

See here for more details.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2019-02-03 00:07:02 +0200

Seen: 435 times

Last updated: Feb 03 '19