A general-purpose computer algebra system.
Project description
Mathics Scanner
This is the tokeniser or scanner portion for the Wolfram Language.
As such, it also contains a full set of translation between Wolfram Language named characters, their Unicode/ASCII equivalents and code-points.
Uses
This is used as the scanner inside Mathics but it can also be used for tokenizing and formatting Wolfram Language code. In fact we intend to write one. This library is also quite usefull if you need to work with Wolfram Language named character and convert them to various formats.
Usage
For tokenizing and scanning Wolfram Language code, use the mathics_scanner.tokenizer.Tokenizer class.
To convert between Wolfram Language named characters and Unicode/ASCII, use the mathics_scanner.characters.replace_wl_with_plain_text and mathics_scanner.characters.replace_unicode_with_wl functions.
To convert between qualified names of named characters (such FormalA for \[FormalA]) and Wolfram’s internal representation use the m̀athics_scanner.characters.named_characters dictionary.
To regenerate scanner tables run:
$ mathics-generate-json-table
Implementation
For notes on the implementation of the packages or details on the conversion scheme please read implementation.rst.
Contributing
Please feel encouraged to contribute to this package or Mathics! Create your own fork, make the desired changes, commit, and make a pull request.
License
Mathics is released under the GNU General Public License Version 3 (GPL3).
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Hashes for Mathics_Scanner-1.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f2e912655882d940babdc4440c1713ff07878ffeb125cec5ca657819b164974a |
|
MD5 | 07c3a27c3fbe95645d7e5c3fb7036941 |
|
BLAKE2b-256 | 138ca43a15650265cf5eaef7e3d6ba8eaeca491a103c45ad1e7fc7550dc5e8ce |
Hashes for Mathics_Scanner-1.1.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a9c6c0bc67bfc625378eaa1e9e353c13d2cf316f3ea7d928b44050a300208161 |
|
MD5 | 9c9f0130e2cb7d2088f5479895c93d5b |
|
BLAKE2b-256 | 49abb34bb40946c8b3bbc695bd188f38af4dd328e0f90190a94c044828443f93 |