Ask Your Question

oscarbranson's profile - activity

2016-02-14 03:51:55 +0100 received badge  Famous Question (source)
2016-02-14 03:51:55 +0100 received badge  Notable Question (source)
2015-12-08 14:59:35 +0100 received badge  Popular Question (source)
2015-10-21 20:37:52 +0100 commented answer jupyter (ipython notebook) kernel math display

Thanks. If I understand you correctly, I should either get a beta release, or wait for the next release (I'm running 6.9 at the moment)?

I'm intrigued by the differences between the notebook started by 'sage -n ipython' and the sage kernel added to jupyter by SageKernelSpec... it seems like it should be possible to make the 'sage -n ipython' kernel the default, but I'm not familiar enough with the jupyter architecture to work out how to do this!

2015-10-21 20:34:38 +0100 received badge  Scholar (source)
2015-10-21 07:27:36 +0100 received badge  Student (source)
2015-10-21 03:25:38 +0100 asked a question jupyter (ipython notebook) kernel math display

I'm trying to set up sage as a jupyter (ipython notebook 4.0+) kernel on my local machine.

To do this, I have installed sage in /usr/local/sage, and set up a kernel using the SageKernelSpec tool (following instructions here).

My sage kernel.json looks like this:

{"display_name": "Sage 6.9", "argv": ["/usr/local/sage/sage", "-python", "-m", "sage.repl.ipython_kernel", "-f", "{connection_file}"]}

The kernel starts from within jupyter, and I am able to run sage. However, math text is not rendered. As an example:

x, y = var('x y')

> \newcommand{\Bold}[1]{\mathbf{#1}}\frac{x}{y}

The problem seems to be that the notebook is not recognising and formatting mathjax input properly. I have tried manually linking the sage mathjax library to ipython using:


But it still does not work.

I can get a properly functioning sage notebook by entering:

sage -n ipython

in terminal, but when starting the notebook from my standard jupyter environment (i.e. choosing the kernel from the dropdown list), the mathtype is not rendered.

I can't work out what's going on... any pointers appreciated.