Metadata-Version: 2.4
Name: libsymtorch
Version: 0.1.0
Summary: SymPy-to-Torch conversion and numerical integration
Author-email: "Ibrahim H.I. Abushawish" <ibrahim.hamed2701@gmail.com>
License-Expression: MIT
Project-URL: Homepage, https://github.com/ibeuler/symtorch
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: OS Independent
Classifier: Topic :: Scientific/Engineering :: Physics
Classifier: Topic :: Scientific/Engineering :: Mathematics
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: torch>=2.5.1
Requires-Dist: sympy>=1.13.1
Requires-Dist: torchquad>=0.5.0
Requires-Dist: numpy>=2.4.2
Requires-Dist: scipy>=1.17.0
Requires-Dist: loguru>=0.7.3
Provides-Extra: dev
Requires-Dist: pytest>=8; extra == "dev"
Requires-Dist: build>=1; extra == "dev"
Requires-Dist: twine>=5; extra == "dev"
Provides-Extra: examples
Requires-Dist: matplotlib>=3.8; extra == "examples"
Dynamic: license-file

﻿# symtorch (distribution: libsymtorch)

SymPy-to-Torch conversion and numerical integration helpers.

Note: this module was first developed for libphysics (and remains compatible): https://github.com/ferhatpy/libphysics — then it was split out into a standalone library.

## Install (dev)

pip install -e .

## Install (PyPI/TestPyPI)

```bash
pip install libsymtorch
```

## Quick usage

```python
import symtorch
import sympy as sp

x = sp.Symbol("x", real=True)
expr = sp.Integral(sp.exp(-x**2), (x, -sp.oo, sp.oo))

lt = symtorch.SymTorch()
texpr = lt.torchify(expr)
re, im = texpr.torchquad_integrate(N=121)
print(re, im)
```
