Skip to content

Mathematica package to convert Mathematica expressions to Numpy-compatible ones.

License

Notifications You must be signed in to change notification settings

gwiederhecker/ToPython

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 

Repository files navigation

ToPython

Mathematica package to convert MATHEMATICA expressions to Python Numpy

Input arguments

x: your mathematica expression, it can be numbers, literals, complexes or lists; numpy\[LetterSpace]prefix: string defining your Numpy import prefix, e.g.:

  • if your used import numpy as np, your prefix should be the string np
  • if your used from numpy import *, your prefix should be the empty string ''

Output

  • The Numpy python-ready expression (to be copied as a string)
  • The formatted expression will be copied to your clipboard, ready to paste to Python

Installation

To install the package

  1. Download it
  2. Click on Mathematica' File menu-> Install->From file...
  3. Select the file on your disk

You should be ready to go.

Disclaimer

This has not been tested for every possible combinations of all the things, use at your own risks.

License

MIT © Gustavo Wiederhecker

About

Mathematica package to convert Mathematica expressions to Numpy-compatible ones.

Resources

License

Stars

Watchers

Forks

Packages

No packages published