Math MCP server to boost LLMs math abilities
Configuration
View docs{
"mcpServers": {
"avanishd-3-math-mcp": {
"command": "uv",
"args": [
"run",
"--with",
"fastmcp",
"--with",
"numpy",
"fastmcp",
"run",
"/absolute/path/Desktop/to/math-mcp-server/src/math_server.py:math_mcp"
]
}
}
}You have a Math MCP Server that performs 64‑bit arithmetic (addition, subtraction, multiplication, division) and matrix multiplication, enabling clients to request precise math computations through the MCP protocol.
To use the Math MCP Server, connect your MCP-enabled client and point it to the local or remote MCP endpoint you run. Your client sends arithmetic or matrix operations to the server, and you receive the computed results in real time. Typical usage involves selecting the math endpoint from your client’s list of MCP servers, choosing the desired operation (add, subtract, multiply, divide, or matrix multiply), and sending the appropriate operands. You can chain multiple operations in a session to perform complex calculations without leaving the MCP environment.
Prerequisites you need before installing the Math MCP Server are:
Install uv on your operating system. Choose the method you prefer below.
# Unix/MacOS
curl -LsSf https://astral.sh/uv/install.sh | sh
```
```
brew install uv
```
```
# Windows
winget install --id=astral-sh.uv -eClone the Math MCP Server repository and synchronize dependencies with uv. You will then be ready to run the server.
git clone https://github.com/avanishd-3/math-mcp.git
cd math-mcp-server
uv syncStart the Math MCP Server using uv with the Fast MCP integration and numpy. Replace the path with your actual project path.
uv run --with fastmcp --with numpy fastmcp run /absolute/path/Desktop/to/math-mcp-server/src/math_server.py:math_mcpPerforms addition of two or more 64-bit numbers and returns the sum.
Subtracts one or more values from a base value, returning the resulting difference.
Multiplies two or more numbers with 64-bit precision and returns the product.
Divides one value by another, returning the quotient with 64-bit precision.
Performs matrix multiplication on matrices using 64-bit floating point precision.