Skip to content
BoJakobsenPublic
forked from JoeRiel/maplev

About

Emacs mode for Maple

Resources

Stars

0 stars

Watchers

0 watching

Forks

 
 

Latest commit

 

History

974 Commits

Folders and files

Repository files navigation

MapleV: An Emacs Package for Maple Developers

Version 3.2.5

MapleV is an Emacs package for developing Maple code. Maple is computer algebra system sold by Maplesoft. MapleV provides several major modes:

  • maplev-mode : edit Maple source files
  • maplev-mint : view the output of mint, the Maple syntax checker, and use it to correct the source
  • maplev-help : view Maple help pages
  • maplev-view : view archived Maple modules and procedures
  • maplev-cmaple : interact with a Maple engine

Requirements

To interact with the Maple engine, display help pages, and view library procedures,the pmaple binary executable is required; this is a change from pre 3.0 versions of MapleV which used cmaple, a part of the Maple distribution. The pmaple binary can be compiled from source using Maple's OpenMaple package; pre-compiled executables for Linux and Windows are available at github.com/JoeRiel.

Installation

The release tag file maplev-built.zip in a release tag, a pre-built Maple archive file (lib/maplev.mla), help database (lib/maplev.help), and documentation: doc/maplev.info, doc/maplev.html, and doc/maplev.pdf. The doc files contain the same information but in different formats. The doc/maplev.info is the most useful as it can be accessed from Emacs if properly installed. These files can be built from the source.

git clone https://github.com/JoeRiel/maplev
cd maplev
export MAPLE_ROOT=/opt/maple2026/    # set to current maple root
make prebuilt-download # download maplev-built.zip
make prebuilt-unpack   # unpack the zip file
make prebuilt-install  # install maplev.info, maplev.help, and maplev.mla
make mla-install       # Optional for developing maplev:
                         recreate and install maplev.mla using installed lineinfo data
make package           # create the tar file of .el files and dir
make package-install   # install and byte-compile the lisp files and doc/dir

make package-install runs a batch Emacs that ignores your init file and installs the package into ~/.emacs.d/elpa/maplev-<version>. If you have customized package-user-dir, start Emacs with --init-directory, or do not use package.el, use one of the following options instead.

Install from within your own Emacs (custom settings apply):

M-x package-install-file RET /path/to/maplev-<version>.tar RET

Or unpack the tar file wherever you like and add it to load-path:

tar xf maplev-<version>.tar -C ~/some/dir
(add-to-list 'load-path "~/some/dir/maplev-<version>")
(add-to-list 'Info-additional-directory-list "~/some/dir/maplev-<version>")
(require 'maplev)

In that case, use the absolute directory as the :load-path.

Configuration

Add the following lines to the Emacs initialization file, which is given by the value of the emacs variable user-init-file:

(use-package maplev
  :ensure nil
  :load-path "elpa/maplev-3.2.5"
  :mode (("\\.mpl\\'" . maplev-mode))
  :config
    (setq maplev-config-default
	      (let* ((mapledir "/opt/maple2025"))
	        (make-instance 'maplev-config-class
				:bindir (file-name-concat mapledir "bin.X86_64_LINUX")
				:mapledir mapledir
				:maple (file-name-concat mapledir "bin" "maple")
				:maple-options "-B -A2 -e2"
				:mint (file-name-concat mapledir "bin" "mint")
				:pmaple (file-name-concat (getenv "HOME") "maple/toolbox/maplev/bin.X86_64_LINUX/pmaple")))))

Use the Emacs custom group maplev-group to access MapleV's many customizations.

Usage

Fire up Emacs. If you configured auto-mode-alist via use-package, as above, opening a Maple source file with extension .mpl should cause it to be opened in maplev-mode. If the maplev.info file was installed where it can be found by Emacs, you can get help by calling maplev-goto-info-node. An html version of the help, maplev.html, is distributed with the source.

Org Mode

The https://github/JoeRiel/ob-maple package provides functions to interact with Maple in an Org file.

About

Emacs mode for Maple

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages