From d584975f68149c8d61a3e1e519592c74192a2946 Mon Sep 17 00:00:00 2001 From: Ralf Hemmecke Date: Sun, 26 Mar 2023 15:00:40 +0200 Subject: [PATCH] document installation of binary distribution --- INSTALL | 445 ++++++++++++++++++++++++-- src/doc/sphinx/source/download.rst | 104 ++++--- src/doc/sphinx/source/install.rst | 482 +++++++++++++++++++++++++++-- 3 files changed, 942 insertions(+), 89 deletions(-) diff --git a/INSTALL b/INSTALL index a1f719d99..015e40c7b 100644 --- a/INSTALL +++ b/INSTALL @@ -21,6 +21,101 @@ should work. The above will install FriCAS files into You can give arguments to "configure" to change those locations. +Installation of binary distribution +----------------------------------- + +The binary distribution has been created via the following commands + + + FDIR=$HOME/fricas + GITREPOS=$FDIR + FRICASBUILD=$FDIR/build + FRICASINSTALL=$FDIR/install + export PATH=$FRICASINSTALL/bin:$PATH + QUICKLISPINSTALL=$FDIR/quicklisp + mkdir -p $FDIR $GITREPOS $FRICASBUILD $FRICASINSTALL + cd $FDIR + curl -O https://beta.quicklisp.org/quicklisp.lisp + curl -O https://beta.quicklisp.org/quicklisp.lisp.asc + curl -O https://beta.quicklisp.org/release-key.txt + # Check integrity of the download (not absolutely necessary). + gpg --import release-key.txt + gpg --verify quicklisp.lisp.asc quicklisp.lisp + # Load QuickLisp + sbcl --load quicklisp.lisp \ + --eval "(quicklisp-quickstart:install :path \"$QUICKLISPINSTALL\")" \ + --eval "(push :hunchentoot-no-ssl *features*)" \ + --eval "(ql:quickload \"hunchentoot\")" \ + --eval "(quit)" + cd $FRICASBUILD + $GITREPOS/fricas/configure --enable--gmp --with-lisp=sbcl \ + --enable-webspad --with-quicklisp=$QUICKLISPINSTALL + make -j 7 > makelog 2>&1 + make DESTDIR=$FRICASINSTALL install + cd $FRICASINSTALL + tar -cjf $FDIR/fricas-x.y.z.amd64.tar.bz2 usr + +You can download the latext release of such a ".tar.bz2" from +https://github.com/fricas/fricas/releases and install as follows (of +course, you can set "FDIR" to anything you like. + + FDIR=$HOME/fricas + mkdir -p $FDIR + cd $FDIR + tar xjf fricas-x.y.z.amd64.tar.bz2 + +Adapt the "fricas" and "efricas" scripts to point to the right paths. + + F=$FDIR + L=$F/usr/local + sed -i "s|^exec_prefix=|FRICAS_PREFIX=\"$L\"\nexport FRICAS_PREFIX\nexec_prefix=|" $L/bin/fricas + sed -i "s|^FRICASCMD='/usr/local|FRICAS_PREFIX=\"$L\"\nexport FRICAS_PREFIX\nexec_prefix=\"\${FRICAS_PREFIX:-/usr/local}\"\nFRICAS=\"\${exec_prefix}\"'|;s|^export FRICASCMD|export FRICAS\nFRICASCMD=\"\$FRICAS\"\nexport FRICASCMD|;s|quote \"/usr/local|quote \"$L|" $L/bin/efricas + +If you use the default setting of "FDIR" from above, the relevant +lines in your "$L/bin/fricas" file should look like this. + + FRICAS_PREFIX="$HOME/fricas/usr/local" + export FRICAS_PREFIX + exec_prefix="${FRICAS_PREFIX:-/usr/local}" + +And in the "efricas" script like this. + + FRICAS_PREFIX="$HOME/fricas/usr/local" + export FRICAS_PREFIX + exec_prefix="${FRICAS_PREFIX:-/usr/local}" + FRICAS="${exec_prefix}"'/lib/fricas/target/x86_64-linux-gnu/bin/fricas' + export FRICAS + FRICASCMD="$FRICAS" + export FRICASCMD + +Start FriCAS with one of the following commands. + + $FDIR/usr/local/bin/fricas + $FDIR/usr/local/bin/efricas + +Of course, you must have Emacs installed for the "efricas" +script to work correctly. + +You might have to install + + sudo apt install xfonts-75dpi xfonts-100dpi + +and restart the X server (log out and log in again) in case the font +in HyperDoc does not look pretty. + +That is, however, not necessary, if you do not intend to use HyperDoc +a lot and rather look at the FriCAS homepage in order to find +relavant information. + +Set the PATH in "$HOME/.bashrc". + +Edit the file "$HOME/.bashrc" (or whatever your shell initialization +resource is) and put in somthing like the following in order to make +all fricas scripts available. + + FDIR=$HOME/fricas + export PATH=$FDIR/usr/local/bin:$PATH + Prerequisites ------------- @@ -124,6 +219,206 @@ LaTeX packages (available from CTAN). tikz +jFriCAS (optional) + +There is currently a branch "wip/fricas-sbcl-hunchentoot" of the +FriCAS repository of Ralf Hemmecke +that contains code to include the Hunchentoot webserver into the +"FRICASsys" lisp image of FriCAS. That is aimed to be the future way +of running FriCAS in a Jupyter notebook. It is currently +**work-in-progress**. It works, but do not rely on the actual source +code. That may change at any time untit it is ready to be included +into the official FriCAS repository. + +There are a couple of things to install. + +#. Quicklisp +#. Jupyter +#. jFriCAS + +Except for the file "$HOME/.jupyter/jupyter_notebook_config.py" that +maybe necessary to create, the following description will put most of +the things (in particular the git repositories) under the directory +"$FDIR". FriCAS will be installed into "$FRICASINSTALL". jFriCAS +and Jupyter will go into "$JFRICASINSTALL". You can change any of +these paths or even install without a python virtual environment, but +there is no description for an installation without venv. + + FDIR=$HOME/fricas + GITREPOS=$FDIR + FRICASBUILD=$FDIR/build + FRICASINSTALL=$FDIR/install + export PATH=$FRICASINSTALL/bin:$PATH + VENV=$FDIR/venv + JFRICASINSTALL=$VENV/jfricas + QUICKLISPINSTALL=$FDIR/quicklisp + mkdir -p $FDIR $GITREPOS $FRICASBUILD $FRICASINSTALL $JFRICASINSTALL + + +Installation of quicklisp and hunchentoot +""""""""""""""""""""""""""""""""""""""""" + +To be most flexible, install quicklisp and hunchentoot via quicklisp. +Note that we aim at a local installation of the Jupyter-FriCAS +connection, so no ssl is needed. Of course, you need not disable ssl, +but then you have to make sure that FRICASsys finds the "libssl.so" +in the appropriate version. + +The following will create a new directory "QUICKLISPINSTALL" +(you can use any name, even the defaul "~/quicklisp/" should work). + + cd $FDIR + curl -O https://beta.quicklisp.org/quicklisp.lisp + curl -O https://beta.quicklisp.org/quicklisp.lisp.asc + curl -O https://beta.quicklisp.org/release-key.txt + + # Check integrity of the download (not absolutely necessary). + gpg --import release-key.txt + gpg --verify quicklisp.lisp.asc quicklisp.lisp + + # Load QuickLisp + + sbcl --load quicklisp.lisp \ + --eval "(quicklisp-quickstart:install :path \"$QUICKLISPINSTALL\")" \ + --eval "(push :hunchentoot-no-ssl *features*)" \ + --eval "(ql:quickload \"hunchentoot\")" \ + --eval "(quit)" + +jFriCAS installation +"""""""""""""""""""" + +jFriCAS is the Jupyter notebook interface to FriCAS. Of course, +jFriCAS needs Jupyter in a reasonably recent version (at least 4). + +Install prerequisites if not yet available (needs root access, but it +may already be installed on your system). + + sudo apt install python3-pip python3-venv + +Prepare directories and download jFriCAS. + + cd $GITREPOS + git clone -b wip/fricas-jfricas https://github.com/hemmecke/jfricas + +Install prerequisites, Jupyter and jFriCAS. + +**WARNING**: Do not install jfricas 1.0.0 from PyPI, as that will +currently not work. If you have it installed, then uninstall it first. + + python3 -m venv $JFRICASINSTALL + source $JFRICASINSTALL/bin/activate + pip3 install wheel jupyter + cd $GITREPOS/jfricas + pip3 install . + jupyter kernelspec list + +The output of the last command should show something similar to the +following. + + Available kernels: + jfricas /home/hemmecke/fricas/venv/jfricas/share/jupyter/kernels/jfricas + python3 /home/hemmecke/fricas/venv/jfricas/share/jupyter/kernels/python3 + +Create the script "jfricas". + + cat > $FRICASINSTALL/bin/jfricas < as they live in a separate repository. Do the following to get a local copy and thus have working references. - cd $BUILD/src/doc/html + cd $FRICASBUILD/src/doc/html git clone -b gh-pages https://github.com/fricas/fricas-notebooks @@ -372,11 +700,12 @@ Then, checkout the "gh-pages" branch and put the data from "$BUILD/src/doc/html" into your "gh-pages" branch. git clone git@github.com:hemmecke/fricas.git + cd fricas git checkout gh-pages git rm -rf . rm '.gitignore' echo 'https://help.github.com/articles/using-jekyll-with-pages' > .nojekyll - cp -a $BUILD/src/doc/html/* . + cp -a $FRICASBUILD/src/doc/html/* . rm -r _sources/api/ git add . git commit -m "$PACKAGE_VERSION" @@ -440,6 +769,68 @@ The program "sieve.as" is +Execute jfricas and enjoy +------------------------- + +Put the following input into the file "$FDIR/foo.input". + + -- # FriCAS demo notebook + + )set output algebra off + setFormat!(FormatMathJax)$JFriCASSupport + + -- Here we compute $\frac{d^2}{dx^2} sin(x^3)$. + + D(sin(x^3),x,2) + + -- We compute the indefinite integral $\int \sin x \cdot e^x dx$. + + integrate(exp(x)*sin(x), x) + + +Then start via "jfricas", load "foo.input" and enjoy. + + cd $FDIR + jfricas + +If something does not work then look at the end of "fricaskernel.py" +and experiment with different versions of how to start FriCAS. + + FRICASKERNEL=$(find $JFRICASINSTALL -type f | grep 'fricaskernel\.py$') + emacs $FRICASKERNEL + +You can also download or clone the demo notebooks from +https://github.com/fricas/fricas-notebooks/ and compare them with what +you see at +FriCAS Demos and Tutorials . + + +Install frimacs (optional) +-------------------------- + +frimacs_ is an Emacs mode for FriCAS with special features to +edit ".input" and ".spad" files as well as executing a FriCAS_ +session inside an Emacs buffer. + +Install as follows. + + cd $GITREPOS + git clone https://github.com/pdo/frimacs.git + +If your "GITREPOS=/home/hemmecke/fricas", then add the line + + (load-file "/home/hemmecke/fricas/frimacs/frimacs.el") + +to your ".emacs" or ".emacs.d/init.el" file. + +To start a FriCAS session use + + M-x run-fricas + + + + + Known problems -------------- @@ -582,8 +973,12 @@ CMUCL: https://www.cons.org/cmucl/ CTAN: https://www.ctan.org/ ECL: http://ecls.sourceforge.net Emacs: https://www.gnu.org/software/emacs/ +frimacs: https://github.com/pdo/frimacs GCL: https://www.gnu.org/software/gcl GMP: https://gmplib.org +jFriCAS: https://jfricas.readthedocs.io +Jupyter: https://jupyter.org +JupyText: https://jupytext.readthedocs.io SBCL: http://sbcl.sourceforge.net/platform-table.html Sphinx: https://www.sphinx-doc.org FriCAS git repository: https://github.com/fricas/fricas diff --git a/src/doc/sphinx/source/download.rst b/src/doc/sphinx/source/download.rst index 1d95e429b..cc95759c2 100644 --- a/src/doc/sphinx/source/download.rst +++ b/src/doc/sphinx/source/download.rst @@ -1,60 +1,88 @@ Download --------- +======== -* Official |git repository| (read-only access). Fork it on github if - you like. - :: +.. contents:: Table of Contents + :local: - git clone https://github.com/fricas/fricas.git -* Release tarballs (up to version 1.3.6): - https://sourceforge.net/projects/fricas/files/fricas/. +Official releases +----------------- - The release tarballs are identical to the respective version in the - |git repository|, but additionally contain pregenerated (machine - independent) files, i.e., compilation from release tarballs takes - less time. +https://github.com/fricas/fricas/releases/ -* `FriCAS Docker Image `_ - (`Announcement `_) -* FriCAS on Windows - https://groups.google.com/d/msg/fricas-devel/zMY1IADEx3A/dO4c0-UlBAAJ +Binary distribution +^^^^^^^^^^^^^^^^^^^ +- ``fricas-x.y.z.amd64.tar.bz2`` (64-bit binary for amd64 (x86_64) Linux) +- ``fricas-x.y.z.i386.tar.bz2`` (32-bit binary for i386 Linux) +- ``fricas-x.y.z-macOS-x64.dmg`` ((beta) 64 binary for macOS) +- ``fricas-x.y.z-windows-x64.zip`` ((beta) 64 binary for Windows) - https://drive.google.com/file/d/1CI8IF9ScrAGG0KIhbldrRpVkXo-Q7S-Y/view?usp=sharing -* Nightly builds:: +Source distribution +^^^^^^^^^^^^^^^^^^^ - * linux: https://github.com/oldk1331/fricas/actions/runs/654525090 - * macos: https://github.com/oldk1331/fricas/actions/runs/654525087 - * windows: https://github.com/oldk1331/fricas/actions/runs/654525092 +- ``fricas-x.y.z-full.tar.bz2`` is a "full" source tarball. + It is identical to the respective version in the |git repository|, + but additionally contains pregenerated (machine independent) files, + i.e., compilation from these tarballs takes less time than from the + git sources. - A few downsides: +- ``x.y.z.tar.gz`` and ``x.y.z.zip`` source as in git repository - #. You have to login GitHub to download this "CI artifact". - (Not necessarily a bad thing, I don't want to pollute the - "Release" page in GitHub.) - #. It only exists for a short period. (90 days?) - #. The packaging is very crude for now, not out-of-box user experience. - (You have to "cd" in the shell and set "FRICAS" env variable.) - #. It's double compressed, you have to unpack twice. +FriCAS x.y.z should build on Linux and many Unix like systems (for +example Mac OSX and Cygwin). -* Here is a `list of versions of FriCAS - `_ - that can be installed by the package manager of your operating - system. Note, however, that these packages are not provided by - the FriCAS developers, but by other volunteers. +Official |git repository| (read-only access). Fork it on github if +you like. +:: - .. * Debian package + git clone https://github.com/fricas/fricas.git - * `ArchLinux package `_ - * `Gentoo package `_ - * `NetBSD package `_ - * `MacPort `_ +Old releases +------------ +Release tarballs (up to version 1.3.6): +https://sourceforge.net/projects/fricas/files/fricas/. +Other forms of distribution +--------------------------- + +Here is a `list of versions of FriCAS +`_ +that can be installed by the package manager of your operating +system. Note, however, that these packages are not provided by +the FriCAS developers, but by other volunteers. + +* `Debian package `_ + (build on GCL_) + +* `ArchLinux package `_ +* `Gentoo package `_ +* `NetBSD package `_ +* `MacPort `_ + + +Nightly builds +-------------- + +https://github.com/fricas/fricas-nightly-builds/releases/tag/nightly + +A few downsides: + +#. It only exists for a short period. (90 days?) +#. The packaging is very crude for now, not out-of-box user experience. + (You have to "cd" in the shell and set "FRICAS" env variable.) + + +Installation Guide +------------------ .. toctree:: :maxdepth: 1 install + + + +.. _GCL: https://www.gnu.org/software/gcl/ diff --git a/src/doc/sphinx/source/install.rst b/src/doc/sphinx/source/install.rst index 5aefda640..93c1ffa3c 100644 --- a/src/doc/sphinx/source/install.rst +++ b/src/doc/sphinx/source/install.rst @@ -3,6 +3,7 @@ Installation Guide .. contents:: Table of Contents :local: + :depth: 2 Quick installation @@ -20,6 +21,108 @@ should work. The above will install FriCAS files into You can give arguments to ``configure`` to change those locations. +Installation of binary distribution +----------------------------------- + +The binary distribution has been created via the following commands +:: + + FDIR=$HOME/fricas + GITREPOS=$FDIR + FRICASBUILD=$FDIR/build + FRICASINSTALL=$FDIR/install + export PATH=$FRICASINSTALL/bin:$PATH + QUICKLISPINSTALL=$FDIR/quicklisp + mkdir -p $FDIR $GITREPOS $FRICASBUILD $FRICASINSTALL + cd $FDIR + curl -O https://beta.quicklisp.org/quicklisp.lisp + curl -O https://beta.quicklisp.org/quicklisp.lisp.asc + curl -O https://beta.quicklisp.org/release-key.txt + # Check integrity of the download (not absolutely necessary). + gpg --import release-key.txt + gpg --verify quicklisp.lisp.asc quicklisp.lisp + # Load QuickLisp + sbcl --load quicklisp.lisp \ + --eval "(quicklisp-quickstart:install :path \"$QUICKLISPINSTALL\")" \ + --eval "(push :hunchentoot-no-ssl *features*)" \ + --eval "(ql:quickload \"hunchentoot\")" \ + --eval "(quit)" + cd $FRICASBUILD + $GITREPOS/fricas/configure --enable--gmp --with-lisp=sbcl \ + --enable-webspad --with-quicklisp=$QUICKLISPINSTALL + make -j 7 > makelog 2>&1 + make DESTDIR=$FRICASINSTALL install + cd $FRICASINSTALL + tar -cjf $FDIR/fricas-x.y.z.amd64.tar.bz2 usr + +You can download the latext release of such a ``.tar.bz2`` from +https://github.com/fricas/fricas/releases and install as follows (of +course, you can set ``FDIR`` to anything you like. +:: + + FDIR=$HOME/fricas + mkdir -p $FDIR + cd $FDIR + tar xjf fricas-x.y.z.amd64.tar.bz2 + +Adapt the ``fricas`` and ``efricas`` scripts to point to the right paths. +:: + + F=$FDIR + L=$F/usr/local + sed -i "s|^exec_prefix=|FRICAS_PREFIX=\"$L\"\nexport FRICAS_PREFIX\nexec_prefix=|" $L/bin/fricas + sed -i "s|^FRICASCMD='/usr/local|FRICAS_PREFIX=\"$L\"\nexport FRICAS_PREFIX\nexec_prefix=\"\${FRICAS_PREFIX:-/usr/local}\"\nFRICAS=\"\${exec_prefix}\"'|;s|^export FRICASCMD|export FRICAS\nFRICASCMD=\"\$FRICAS\"\nexport FRICASCMD|;s|quote \"/usr/local|quote \"$L|" $L/bin/efricas + +If you use the default setting of ``FDIR`` from above, the relevant +lines in your ``$L/bin/fricas`` file should look like this. +:: + + FRICAS_PREFIX="$HOME/fricas/usr/local" + export FRICAS_PREFIX + exec_prefix="${FRICAS_PREFIX:-/usr/local}" + +And in the ``efricas`` script like this. +:: + + FRICAS_PREFIX="$HOME/fricas/usr/local" + export FRICAS_PREFIX + exec_prefix="${FRICAS_PREFIX:-/usr/local}" + FRICAS="${exec_prefix}"'/lib/fricas/target/x86_64-linux-gnu/bin/fricas' + export FRICAS + FRICASCMD="$FRICAS" + export FRICASCMD + +Start FriCAS with one of the following commands. +:: + + $FDIR/usr/local/bin/fricas + $FDIR/usr/local/bin/efricas + +Of course, you must have Emacs installed for the ``efricas`` +script to work correctly. + +You might have to install +:: + + sudo apt install xfonts-75dpi xfonts-100dpi + +and restart the X server (log out and log in again) in case the font +in HyperDoc does not look pretty. + +That is, however, not necessary, if you do not intend to use HyperDoc +a lot and rather look at the FriCAS_ homepage in order to find +relavant information. + +Set the PATH in ``$HOME/.bashrc``. + +Edit the file ``$HOME/.bashrc`` (or whatever your shell initialization +resource is) and put in somthing like the following in order to make +all fricas scripts available. +:: + + FDIR=$HOME/fricas + export PATH=$FDIR/usr/local/bin:$PATH + Prerequisites ------------- @@ -135,6 +238,223 @@ LaTeX packages (available from CTAN_). tikz +jFriCAS (optional) +^^^^^^^^^^^^^^^^^^ + +There is currently a branch ``wip/fricas-sbcl-hunchentoot`` of the +`FriCAS repository of Ralf Hemmecke `_ +that contains code to include the Hunchentoot webserver into the +``FRICASsys`` lisp image of FriCAS_. That is aimed to be the future way +of running FriCAS_ in a Jupyter_ notebook. It is currently +**work-in-progress**. It works, but do not rely on the actual source +code. That may change at any time untit it is ready to be included +into the official FriCAS repository. + +There are a couple of things to install. + +#. Quicklisp +#. Jupyter +#. jFriCAS + +Except for the file ``$HOME/.jupyter/jupyter_notebook_config.py`` that +maybe necessary to create, the following description will put most of +the things (in particular the git repositories) under the directory +``$FDIR``. FriCAS will be installed into ``$FRICASINSTALL``. jFriCAS +and Jupyter will go into ``$JFRICASINSTALL``. You can change any of +these paths or even install without a python virtual environment, but +there is no description for an installation without venv. +:: + + FDIR=$HOME/fricas + GITREPOS=$FDIR + FRICASBUILD=$FDIR/build + FRICASINSTALL=$FDIR/install + export PATH=$FRICASINSTALL/bin:$PATH + VENV=$FDIR/venv + JFRICASINSTALL=$VENV/jfricas + QUICKLISPINSTALL=$FDIR/quicklisp + mkdir -p $FDIR $GITREPOS $FRICASBUILD $FRICASINSTALL $JFRICASINSTALL + + +Installation of quicklisp and hunchentoot +""""""""""""""""""""""""""""""""""""""""" + +To be most flexible, install quicklisp and hunchentoot via quicklisp. +Note that we aim at a local installation of the Jupyter-FriCAS +connection, so no ssl is needed. Of course, you need not disable ssl, +but then you have to make sure that FRICASsys finds the ``libssl.so`` +in the appropriate version. + +The following will create a new directory ``QUICKLISPINSTALL`` +(you can use any name, even the defaul ``~/quicklisp/`` should work). +:: + + cd $FDIR + curl -O https://beta.quicklisp.org/quicklisp.lisp + curl -O https://beta.quicklisp.org/quicklisp.lisp.asc + curl -O https://beta.quicklisp.org/release-key.txt + + # Check integrity of the download (not absolutely necessary). + gpg --import release-key.txt + gpg --verify quicklisp.lisp.asc quicklisp.lisp + + # Load QuickLisp + + sbcl --load quicklisp.lisp \ + --eval "(quicklisp-quickstart:install :path \"$QUICKLISPINSTALL\")" \ + --eval "(push :hunchentoot-no-ssl *features*)" \ + --eval "(ql:quickload \"hunchentoot\")" \ + --eval "(quit)" + +jFriCAS installation +"""""""""""""""""""" + +jFriCAS_ is the Jupyter_ notebook interface to FriCAS_. Of course, +jFriCAS_ needs Jupyter_ in a reasonably recent version (at least 4). + +Install prerequisites if not yet available (needs root access, but it +may already be installed on your system). +:: + + sudo apt install python3-pip python3-venv + +Prepare directories and download jFriCAS_. +:: + + cd $GITREPOS + git clone -b wip/fricas-jfricas https://github.com/hemmecke/jfricas + +Install prerequisites, Jupyter_ and jFriCAS_. + +**WARNING**: Do not install jfricas 1.0.0 from PyPI, as that will +currently not work. If you have it installed, then uninstall it first. +:: + + python3 -m venv $JFRICASINSTALL + source $JFRICASINSTALL/bin/activate + pip3 install wheel jupyter + cd $GITREPOS/jfricas + pip3 install . + jupyter kernelspec list + +The output of the last command should show something similar to the +following. +:: + + Available kernels: + jfricas /home/hemmecke/fricas/venv/jfricas/share/jupyter/kernels/jfricas + python3 /home/hemmecke/fricas/venv/jfricas/share/jupyter/kernels/python3 + +Create the script ``jfricas``. +:: + + cat > $FRICASINSTALL/bin/jfricas < .nojekyll - cp -a $BUILD/src/doc/html/* . + cp -a $FRICASBUILD/src/doc/html/* . rm -r _sources/api/ git add . git commit -m "$PACKAGE_VERSION" @@ -487,6 +845,74 @@ The program ``sieve.as`` is:: +Execute jfricas and enjoy +------------------------- + +Put the following input into the file ``$FDIR/foo.input``. +:: + + -- # FriCAS demo notebook + + )set output algebra off + setFormat!(FormatMathJax)$JFriCASSupport + + -- Here we compute $\frac{d^2}{dx^2} sin(x^3)$. + + D(sin(x^3),x,2) + + -- We compute the indefinite integral $\int \sin x \cdot e^x dx$. + + integrate(exp(x)*sin(x), x) + + +Then start via ``jfricas``, load ``foo.input`` and enjoy. +:: + + cd $FDIR + jfricas + +If something does not work then look at the end of ``fricaskernel.py`` +and experiment with different versions of how to start FriCAS. +:: + + FRICASKERNEL=$(find $JFRICASINSTALL -type f | grep 'fricaskernel\.py$') + emacs $FRICASKERNEL + +You can also download or clone the demo notebooks from +https://github.com/fricas/fricas-notebooks/ and compare them with what +you see at +`FriCAS Demos and Tutorials `_. + + +Install frimacs (optional) +-------------------------- + +frimacs_ is an Emacs_ mode for FriCAS with special features to +edit ``.input`` and ``.spad`` files as well as executing a FriCAS_ +session inside an Emacs_ buffer. + +Install as follows. +:: + + cd $GITREPOS + git clone https://github.com/pdo/frimacs.git + +If your ``GITREPOS=/home/hemmecke/fricas``, then add the line +:: + + (load-file "/home/hemmecke/fricas/frimacs/frimacs.el") + +to your ``.emacs`` or ``.emacs.d/init.el`` file. + +To start a FriCAS_ session use +:: + + M-x run-fricas + + + + + Known problems -------------- @@ -633,7 +1059,11 @@ Known problems .. _CTAN: https://www.ctan.org/ .. _ECL: http://ecls.sourceforge.net .. _Emacs: https://www.gnu.org/software/emacs/ +.. _frimacs: https://github.com/pdo/frimacs .. _GCL: https://www.gnu.org/software/gcl .. _GMP: https://gmplib.org +.. _jFriCAS: https://jfricas.readthedocs.io +.. _Jupyter: https://jupyter.org +.. _JupyText: https://jupytext.readthedocs.io .. _SBCL: http://sbcl.sourceforge.net/platform-table.html .. _Sphinx: https://www.sphinx-doc.org