Jupyter notebooks for Wolfram Language on Linux.
- Copy
JWLX_kernelfolder where jupyter expects custom kernels to be, typically in~/miniconda3/lib/python3.7/site-packages/ - Run the installation script
python JWLX_kernel/install.py - Check if
JWLS.shpoints the actualwolframscriptexecutable, then make it globally available:sudo cp JWLX.sh /usr/local/bin/JWLX
Run JWLX.
- Autocompletion of WL Symbols
- WL syntax highlighting
- Graphics and interactive objects handled by the browser
- Neat separation of Jupyter Notebook interface and Wolfram Kernel; similarly to Mathematica, you can run multiple notebooks on the same Wolfram Kernel.
There are 3 custom functions to deal with graphics and dynamical outputs:
-
showreturns a URL of the pdf export of any expression, except for images that are exported to PNG. By clicking the URL, graphics gets rendered by the browser PDF reader or, in case of images, by the Jupyter file viewer. -
manipulatemimics Manipuate and it returns a dynamic HTML page with a single slider (no multiple sliders or different types of controllers yet). Valid expressions aremanipulate[Hold @ expr, {u, u_min, u_max, du}]ormanipulate[Hold @ exp, {u, u_min, u_max}]with a default value ofdu=1/10 or the interval. Note: To wrapexprinHoldis necessary in most cases.
At every change of the slider value, the JS script sends a POST request to the Wolfram Engine that provides anHTTPResponse. -
refreshworks similarly tomanipulatethere is no slider; the JS script automatically sends POST requests at regular intervals. Valid syntax isrefresh[expr, dt]orrefresh[expr]with a default update intervaldt= 1s. -
listanimatemimics ListAnimate and it gives the smoothest experience insofar all outputs are preemptively saved in RAM. Valid syntax islistanimate[{e_1, e_2, .., e_N}].
In order to use it on a cloud compute virtual machine, edit the JWLX script at the nbAddrF function definition by adding jupyter notebook --no-browser --port=7000 . Then screen a session, run JWLX and detach it (Ctrl A + Ctrl D). Go back to your local machine and ssh -N -f -L localhost:6001:localhost:7000 <IP>".
For AWS instances also add the pem. For Google Cloud follow their instructions about remote jupyter notebooks.
- ExportList