Skip to main content

A general-purpose computer algebra system.

Project description

CI status Pypi Installs Latest Version Supported Python Versions

Packaging status

mathicsscript is a command-line interface to Mathics.

screenshot

See the screenshot directory for a description and another example.

Features

  • GNU Readline terminal interaction. This includes
    • saving command history between sessions.

    • variable completion, even for symbol names like \[Sigma]

    • limited ESC keyboard input; for example esc p esc is π

  • Syntax highlighting using pygments.

  • Automatic detection of light or dark terminal background color.

  • Entering and displaying Unicode symbols such as used for Pi or Rule arrows

  • Provision for running in non-interactive batch mode which an be used inside POSIX shells

Installing

To install, run

$ make install

To install from git sources so that you run from the git source tree:

$ make develop

Running

Once install run using mathicsscript:

$ mathicsscript
Mathicscript: 2.1.2, Mathics 2.1.1.dev0
on CPython 3.7.10 (default, Feb 27 2021, 08:15:51)
using SymPy 1.7.1, mpmath 1.2.1, numpy 1.20.1

Copyright (C) 2011-2021 The Mathics Team.
This program comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to redistribute it
under certain conditions.
See the documentation for the full license.

Quit by evaluating Quit[] or by pressing CONTROL-D.

In[1]:=

For batch use:

$ mathicsscript -c "N[Pi, 30]"
3.14159265358979323846264338328

To read from a file

In file /tmp/test.m:

sum=2+2
integral=Integrate[1,x]
Print["Results: ",{sum,integral}]

Feeding this into mathicsscript:

$ mathicsscript --no-prompt </tmp/test.m
4
x
Results: {4, x}
None

For a full list of options, type mathicsscript --help.

Why not IPython via Jupyter?

There will always be a need for simple terminal-like interaction. Although there is IPython support via Jupyter all of this is pretty heavy-weight. To code to this protocol, a developer needs to write a kernel, and use a wire protocol. This adds complexity not only for the person developing this package, but also for the user who needs to load the extra layers that aren’t used. And when something goes wrong, it is harder to track down problems.

At the other end of the spectrum, if the dependencies of this package are too onerous and you want even simpler, lighter-weight terminal interaction _without_ and of the features mentioend above, use mathics which is distributed as part of the core Mathic3 package.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mathicsscript-3.2.0.tar.gz (50.7 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

mathicsscript-3.2.0-py3.9.egg (77.7 kB view details)

Uploaded Egg

mathicsscript-3.2.0-py3.8.egg (77.7 kB view details)

Uploaded Egg

mathicsscript-3.2.0-py3.7.egg (77.4 kB view details)

Uploaded Egg

mathicsscript-3.2.0-py3.6.egg (77.3 kB view details)

Uploaded Egg

mathicsscript-3.2.0-py2.py3-none-any.whl (53.9 kB view details)

Uploaded Python 2Python 3

File details

Details for the file mathicsscript-3.2.0.tar.gz.

File metadata

  • Download URL: mathicsscript-3.2.0.tar.gz
  • Upload date:
  • Size: 50.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.5

File hashes

Hashes for mathicsscript-3.2.0.tar.gz
Algorithm Hash digest
SHA256 5dbef413fbceaad8988e44810f7f9b3b01e60ee10125cbe6782a5f81b6ed8dc4
MD5 1d92fa2f65e1fb2e9044141bf0b734cc
BLAKE2b-256 7b153dfdf3f8f0e17146b89077ecd9cd73026781a19e7967a5870bfe4149f826

See more details on using hashes here.

File details

Details for the file mathicsscript-3.2.0-py3.9.egg.

File metadata

  • Download URL: mathicsscript-3.2.0-py3.9.egg
  • Upload date:
  • Size: 77.7 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.5

File hashes

Hashes for mathicsscript-3.2.0-py3.9.egg
Algorithm Hash digest
SHA256 3bf20f2164307be5587ded1d1db881399c78ecc407411b6070a6337ca70e83cc
MD5 5145a71cb86e0d962f10f83bd329c14a
BLAKE2b-256 ec7a4d08300bbda2a2c504cf9271cd99a4cc4894afedf947d987996458c72609

See more details on using hashes here.

File details

Details for the file mathicsscript-3.2.0-py3.8.egg.

File metadata

  • Download URL: mathicsscript-3.2.0-py3.8.egg
  • Upload date:
  • Size: 77.7 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.5

File hashes

Hashes for mathicsscript-3.2.0-py3.8.egg
Algorithm Hash digest
SHA256 1c61a721635571f3231dc33d8bc27f7e3a9a520c673d69482c85a156a3d9e6ac
MD5 e8f31759c74b3271b35eb1ed78e5e2b8
BLAKE2b-256 7b4486511f843c267d4e582c6f3d5e71b9f733bc4327984452301a8af0c7d22d

See more details on using hashes here.

File details

Details for the file mathicsscript-3.2.0-py3.7.egg.

File metadata

  • Download URL: mathicsscript-3.2.0-py3.7.egg
  • Upload date:
  • Size: 77.4 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.5

File hashes

Hashes for mathicsscript-3.2.0-py3.7.egg
Algorithm Hash digest
SHA256 b876c099f28a99b1b59230ad519a9758b0329e52b7ab708050c791691e1ef2ed
MD5 1d2de35510784d90e05ce3fb801fbe4d
BLAKE2b-256 12d2a05eab9664c053cb27f2a1163471edebd0fa6ce2146ab86269f4cc6ba700

See more details on using hashes here.

File details

Details for the file mathicsscript-3.2.0-py3.6.egg.

File metadata

  • Download URL: mathicsscript-3.2.0-py3.6.egg
  • Upload date:
  • Size: 77.3 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.5

File hashes

Hashes for mathicsscript-3.2.0-py3.6.egg
Algorithm Hash digest
SHA256 4b9cdde6d58208a52b8e86b336c1221eb3bf63b0331af8406efa943c9e25d26d
MD5 d892765fedce2740b337bb174cb065f6
BLAKE2b-256 2459e35c3aee3e84f1ac70d32dc8259f87591f6574d073acce77f225645c4fd7

See more details on using hashes here.

File details

Details for the file mathicsscript-3.2.0-py2.py3-none-any.whl.

File metadata

  • Download URL: mathicsscript-3.2.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 53.9 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.5

File hashes

Hashes for mathicsscript-3.2.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 d517a1fed97a7160a4e5dca79a2283dab6b6f41a58b5182872fb2725d2c2c102
MD5 4571056b529f219780e68b84aa1797c1
BLAKE2b-256 6716e85a5bae9499237f75ac118b907031257d7027928ffb6c021121a3f355d5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page