MCP server that exposes SymPy's symbolic mathematics functionality
Project description
mcp-sympy
MCP server that exposes SymPy's symbolic mathematics functionality
Install
pip install mcp-sympy
MCP Server
mcp-name: io.github.daedalus/mcp-sympy
Usage
As MCP Server
Configure in your MCP client:
{
"mcpServers": {
"mcp-sympy": {
"command": "mcp-sympy",
"env": {}
}
}
}
Python API
from mcp_sympy import tools
# Simplify expressions
result = tools.sympy_simplify("sin(x)**2 + cos(x)**2")
print(result) # "1"
# Solve equations
result = tools.sympy_solve("x**2 - 4", "x")
print(result) # "[2, -2]"
# Differentiate
result = tools.sympy_diff("x**2", "x")
print(result) # "2*x"
# Integrate
result = tools.sympy_integrate("x**2", "x")
print(result) # "x**3/3"
# Create matrices
result = tools.sympy_matrix("1,2; 3,4")
print(result) # "Matrix([[1, 2], [3, 4]])"
# Number theory
result = tools.sympy_isprime("7")
print(result) # "True"
Available Tools
The MCP server exposes comprehensive SymPy functionality including:
- Symbolic Expressions: symbols, sympify, simplify, expand, factor
- Calculus: diff, integrate, limit, series, Derivative, Integral
- Solving: solve, solveset, nsolve, diophantine, dsolve
- Matrices: Matrix operations, inverse, determinant, eigenvalues
- Trigonometry: sin, cos, tan, and their inverses
- Special Functions: gamma, zeta, erf, fibonacci, etc.
- Number Theory: isprime, prime, gcd, lcm, totient
- Sets: FiniteSet, Interval, Union, Intersection
- Logic: And, Or, Not, Xor
- Printing: LaTeX, MathML, Python code
Development
git clone https://github.com/daedalus/mcp-sympy.git
cd mcp-sympy
pip install -e ".[test]"
# run tests
pytest
# format
ruff format src/ tests/
# lint
ruff check src/ tests/
# type check
mypy src/
License
MIT License - see LICENSE file.
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 Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mcp_sympy-0.1.0.tar.gz.
File metadata
- Download URL: mcp_sympy-0.1.0.tar.gz
- Upload date:
- Size: 8.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
52b463351a04922f4073ac1180b45bf3583a0ff78ac3eea54b43ba2f77614511
|
|
| MD5 |
300c568b141c0cc90f62908c81d655d7
|
|
| BLAKE2b-256 |
fccd20c551d13deb379e19860f026c34b335b12387187eed56298e5f873a64f1
|
Provenance
The following attestation bundles were made for mcp_sympy-0.1.0.tar.gz:
Publisher:
pypi-publish.yml on daedalus/mcp-sympy
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mcp_sympy-0.1.0.tar.gz -
Subject digest:
52b463351a04922f4073ac1180b45bf3583a0ff78ac3eea54b43ba2f77614511 - Sigstore transparency entry: 1191869589
- Sigstore integration time:
-
Permalink:
daedalus/mcp-sympy@1c5935f09f2701eff653fe60192bf51a12fbb085 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/daedalus
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi-publish.yml@1c5935f09f2701eff653fe60192bf51a12fbb085 -
Trigger Event:
release
-
Statement type:
File details
Details for the file mcp_sympy-0.1.0-py3-none-any.whl.
File metadata
- Download URL: mcp_sympy-0.1.0-py3-none-any.whl
- Upload date:
- Size: 9.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4d6bb5218b6c2765b42601c536a93d80ace148b547869fe7329a5527449c6e7e
|
|
| MD5 |
06f2e382b53712414efbb086421ae617
|
|
| BLAKE2b-256 |
d444bd7b1429483996971f2249e4dc6c59b7f968a0cfd090321406da7689683b
|
Provenance
The following attestation bundles were made for mcp_sympy-0.1.0-py3-none-any.whl:
Publisher:
pypi-publish.yml on daedalus/mcp-sympy
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mcp_sympy-0.1.0-py3-none-any.whl -
Subject digest:
4d6bb5218b6c2765b42601c536a93d80ace148b547869fe7329a5527449c6e7e - Sigstore transparency entry: 1191869591
- Sigstore integration time:
-
Permalink:
daedalus/mcp-sympy@1c5935f09f2701eff653fe60192bf51a12fbb085 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/daedalus
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi-publish.yml@1c5935f09f2701eff653fe60192bf51a12fbb085 -
Trigger Event:
release
-
Statement type: