sympy-mcp

sympy-mcp

3.5

If you are the rightful owner of sympy-mcp and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

Sympy-MCP is a Model Context Protocol server designed to enable LLMs to perform symbolic mathematics and computer algebra autonomously.

Sympy-MCP is a specialized server that leverages the capabilities of SymPy, a Python library for symbolic mathematics, to provide a robust environment for performing complex mathematical operations. The server is designed to address the limitations of language models in handling symbolic manipulation, which often results in errors such as variable hallucination and incorrect term permutation. By integrating SymPy's core functionalities, Sympy-MCP allows language models to execute a wide range of mathematical tasks, including algebraic equation solving, integration, differentiation, vector calculus, tensor calculus for general relativity, and solving both ordinary and partial differential equations. This server is particularly useful for applications that require precise mathematical computations, such as scientific research, engineering, and education. By exposing symbolic tools directly to MCP clients, Sympy-MCP provides a seamless experience for users who need to perform on-the-fly calculations or use the LLM as an agent.

Features

  • Algebraic equation solving
  • Integration and differentiation
  • Vector and tensor calculus
  • Ordinary and partial differential equations solving
  • General relativity calculations

Tools

  1. Variable Introduction

    Introduces a variable with specified assumptions and stores it

  2. Multiple Variables

    Introduces multiple variables with specified assumptions simultaneously

  3. Expression Parser

    Parses an expression string using available local variables and stores it

  4. LaTeX Printer

    Prints a stored expression in LaTeX format, along with variable assumptions

  5. Algebraic Solver

    Solves an equation algebraically for a given variable over a given domain

  6. Linear Solver

    Solves a system of linear equations

  7. Nonlinear Solver

    Solves a system of nonlinear equations

  8. Function Variable

    Introduces a function variable for use in differential equations

  9. ODE Solver

    Solves an ordinary differential equation

  10. PDE Solver

    Solves a partial differential equation

  11. Standard Metric

    Creates a predefined spacetime metric (e.g. Schwarzschild, Kerr, Minkowski)

  12. Metric Search

    Searches available predefined metrics

  13. Tensor Calculator

    Calculates tensors from a metric (Ricci, Einstein, Weyl tensors)

  14. Custom Metric

    Creates a custom metric tensor from provided components and symbols

  15. Tensor LaTeX

    Prints a stored tensor expression in LaTeX format

  16. Simplifier

    Simplifies a mathematical expression using SymPy's canonicalize function

  17. Substitution

    Substitutes a variable with an expression in another expression

  18. Integration

    Integrates an expression with respect to a variable

  19. Differentiation

    Differentiates an expression with respect to a variable

  20. Coordinates

    Creates a 3D coordinate system for vector calculus operations

  21. Vector Field

    Creates a vector field in the specified coordinate system

  22. Curl

    Calculates the curl of a vector field

  23. Divergence

    Calculates the divergence of a vector field

  24. Gradient

    Calculates the gradient of a scalar field

  25. Unit Converter

    Converts a quantity to given target units

  26. Unit Simplifier

    Simplifies a quantity with units

  27. Matrix Creator

    Creates a SymPy matrix from the provided data

  28. Determinant

    Calculates the determinant of a matrix

  29. Matrix Inverse

    Calculates the inverse of a matrix

  30. Eigenvalues

    Calculates the eigenvalues of a matrix

  31. Eigenvectors

    Calculates the eigenvectors of a matrix