Metadata-Version: 2.1
Name: human_math
Version: 0.1
Summary: Structured math expression representation & parsing.
Keywords: parser,math,maths,expression,token
Author: anatom3000
Requires-Python: >=3.7
Description-Content-Type: text/markdown
Classifier: Development Status :: 4 - Beta
Classifier: License :: OSI Approved :: GNU Lesser General Public License v3 (LGPLv3)
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: OS Independent
Classifier: Topic :: Scientific/Engineering :: Mathematics
Classifier: Topic :: Text Processing
Classifier: Typing :: Typed
Project-URL: Issues, https://github.com/anatom3000/human_math/issues
Project-URL: Source, https://github.com/anatom3000/human_math

# human_math
A mathematical expression parser

### Example usage
```python
>>> import human_math as hm                     # import module
>>> tree = hm.parse("2 - (-sin(3pi/2)) - 3.0")  # parse string (user input, etc.)
>>> tree
((2 - (-1 * sin(3 * (pi / 2)))) - 3)            # console representation uses parentheses everywhere to be strictly non-ambigious
>>> tree.evaluate()                             # evaluate the expression tree
-2                                              # nb: sin(3pi/2) = -1 so 2 - (-1) - 3 = -2
```
