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.1.tar.gz (50.9 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.1-py3.9.egg (77.7 kB view details)

Uploaded Egg

mathicsscript-3.2.1-py3.8.egg (77.8 kB view details)

Uploaded Egg

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

Uploaded Egg

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

Uploaded Egg

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

Uploaded Python 2Python 3

File details

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

File metadata

  • Download URL: mathicsscript-3.2.1.tar.gz
  • Upload date:
  • Size: 50.9 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.1.tar.gz
Algorithm Hash digest
SHA256 b6cf4ee8490cb5bce92e57197ccaab8fd0de4e7c333c38931f0f1fee6424b5b9
MD5 919bda38bec361badab6633840eb5e16
BLAKE2b-256 673e8189b1d128e574b50c5db42ec4069d8c32d76f0846434de9a109515d0e4b

See more details on using hashes here.

File details

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

File metadata

  • Download URL: mathicsscript-3.2.1-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.1-py3.9.egg
Algorithm Hash digest
SHA256 d911342e999c753a99945c52737a1864bca6be1abe1d3f2318412818c240465b
MD5 298a43b4398342817956538c3a85b75c
BLAKE2b-256 f8f82336b43b6ef1c9924165d883c57f706dfe83854300d86335504b19c4e8e7

See more details on using hashes here.

File details

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

File metadata

  • Download URL: mathicsscript-3.2.1-py3.8.egg
  • Upload date:
  • Size: 77.8 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.1-py3.8.egg
Algorithm Hash digest
SHA256 c081fb38ee0d3eb21e715e7084cff4c126b3d9f6ccb332babc462332ee2868ff
MD5 97da092d1f4f14f35b3bf76febeb4947
BLAKE2b-256 32ba7d44910b2e29554790793401af6fadf3058e63096ee325a79476a30fc5e3

See more details on using hashes here.

File details

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

File metadata

  • Download URL: mathicsscript-3.2.1-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.1-py3.7.egg
Algorithm Hash digest
SHA256 86020cfe0901f5a54bbddef8b369460aa6adab8a6467537297cdd717cbadc384
MD5 9bb5213ca2a01705ef9defd63d36fc66
BLAKE2b-256 2d8d222887a7e28cc8d28b53139ec595b1d9d8515bb2d0aedd6bda88b075cf3d

See more details on using hashes here.

File details

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

File metadata

  • Download URL: mathicsscript-3.2.1-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.1-py3.6.egg
Algorithm Hash digest
SHA256 6eff4bcff477ff3cd3e7981bf63e2f051e55c6d92cb545357e900946c78940cd
MD5 0bcaa0210a26697855508adbb6f64e2a
BLAKE2b-256 98e703823952fb2726ebef708df746fe5dc398aef68883efb0f042425ccdfb9a

See more details on using hashes here.

File details

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

File metadata

  • Download URL: mathicsscript-3.2.1-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.1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 01d4c68377865e10f79c0c4a29de4cdc6cce1c92e793d5c8cbc1715a67684c10
MD5 b5bfc5129ba9c96fbda112daa3f26822
BLAKE2b-256 f0abdf2dce79d78a37630293a2a20bc2c08da65ad2afd0b02381eab65fc5ff28

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