MCP Calculate Server

by 611711Dark
Verified

hybrid server

The server is able to function both locally and remotely, depending on the configuration or use case.

Integrations

  • Utilized as the server framework to expose SymPy's mathematical computation capabilities through an API accessible via the MCP protocol.

  • Offers matrix operations including inversion and eigenvalue/eigenvector calculations through SymPy's Matrix implementation.

  • Provides access to SymPy's symbolic computation capabilities including basic operations, algebraic manipulations, calculus, equation solving, matrix operations, series expansion, and special functions.

MCP 計算サーバー

MCP プロトコルと SymPy ライブラリに基づく数学計算サービスで、強力な記号計算機能を提供します。

主な特徴

  • 基本演算:加算、減算、乗算、除算、累乗
  • 代数演算:式の展開、因数分解、簡略化
  • 微積分:微分、積分(定積分・不定積分)、極限計算
  • 方程式の解法:代数方程式、連立方程式
  • 行列演算:行列の逆行列、固有値/固有ベクトルの計算
  • 級数展開:テイラー級数展開
  • 特殊関数:三角関数、対数関数、指数関数

使用例

# Basic operations "2 + 3*5" → 17 # Algebraic operations "expand((x + 1)**2)" → x² + 2x + 1 "factor(x**2 - 2*x - 15)" → (x - 5)(x + 3) # Calculus "diff(sin(x), x)" → cos(x) "integrate(exp(x), (x, 0, 1))" → E - 1 "limit(tan(x)/x, x, 0)" → 1 # Equation solving "solve(x**2 - 4, x)" → [-2, 2] "solve([x**2 + y**2 - 1, x + y - 1], [x, y])" → [(0, 1), (1, 0)] # Matrix operations "Matrix([[1, 2], [3, 4]]).inv()" → [[-2, 1], [3/2, -1/2]] "Matrix([[1, 2, 3], [4, 5, 6]]).eigenvals()" → {9/2 - sqrt(33)/2: 1, 9/2 + sqrt(33)/2: 1}

インストール

Smithery経由でインストール

Smithery経由で Claude Desktop 用の Calculate Server を自動的にインストールするには:

npx -y @smithery/cli install @611711Dark/mcp_sympy_calculate_server --client claude

ローカルインストール

  1. リポジトリのクローン:
    git clone https://github.com/611711Dark/mcp-calculate-server.git cd mcp-calculate-server
  2. 仮想環境を作成し、依存関係をインストールします。
    uv venv source .venv/bin/activate uv pip install -e .
  3. 構成:
    "calculate_expression1": { "isActive": false, "command": "uv", "args": [ "run", "--directory", "/path/to/mcp_calculate_server", "server.py" ], }

APIの使用

数式文字列を渡して MCP プロトコル経由でcalculate_expressionツールを呼び出し、計算結果を返します。

依存関係

  • mcp>=1.5.0
  • sympy>=1.13.3
  • ファストAPI>=0.95.0
  • uvicorn>=0.21.0

ライセンス

このプロジェクトはMITライセンスの下でライセンスされています。LICENSEファイルをご覧ください。

中国語版

You must be authenticated.

A
security – no known vulnerabilities
A
license - permissive license
A
quality - confirmed to work

MCP プロトコルを通じて、基本的な算術、代数、微積分、方程式の解法、行列演算などの記号計算を実行できる数学計算サービス。

  1. Key Features
    1. Usage Examples
      1. Installation
        1. Installing via Smithery
        2. Local Installation
      2. API Usage
        1. Dependencies
          1. License
            ID: 4ls84tw6lt