ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Wed, 21 Oct 2015 03:25:38 +0200jupyter (ipython notebook) kernel math displayhttps://ask.sagemath.org/question/30163/jupyter-ipython-notebook-kernel-math-display/I'm trying to set up sage as a [jupyter](https://jupyter.org/) (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](http://doc.sagemath.org/html/en/reference/repl/sage/repl/ipython_kernel/install.html)).
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')
show(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:
use_local_mathjax()
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.
Thanks!oscarbransonWed, 21 Oct 2015 03:25:38 +0200https://ask.sagemath.org/question/30163/