Math

io.github.rog0xPublished by GitHub account rog0xv1.0.1Updated Oct 24, 2026

Calculator, units, statistics for AI agents

VerifiedSTDIODesktop onlyDeveloper ToolsData & Analytics

Overview

AI-generated overview

A local MCP server that gives an assistant math tools: safe expression evaluation, unit conversion, statistics, number formatting and percentage calculations.

What you can do
Evaluate arithmetic expressions with functions, constants and named variables, without eval. Convert values across length, weight, temperature, data, time and speed units. Compute statistics on datasets, including mean, median, variance, percentiles and correlation. Format numbers as currency, percentage, scientific notation, binary, octal, hexadecimal or with separators. Run common percentage operations such as tips, discounts, markup and percentage change.
When to use it
Useful when an assistant needs reliable arithmetic, unit or currency-style number formatting, or quick statistics on small datasets instead of doing the math itself. A small, focused addition for everyday calculation tasks.
Requirements
Runs as a local process over stdio, installed from the npm package and built with npm install and npm run build. The README shows launching it with node against the built dist/index.js file in a desktop client configuration. No authentication, environment variables or headers are declared.
Before you install
No credentials, payments or data writes are involved; the tools only compute and return results. Results depend on the tool's own parsing and rounding, so verify important figures. The README's example configuration points at a local file path that must be set correctly.

Installation

In SourceWeft

  1. Open Math in the dashboard and add it to a workspace.
  2. Enable the server for the chats that should use its tools.

Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.

Other MCP clients

Follow the launch instructions in the repository.

README

mcp-math-tools

Math and calculation tools for AI agents, exposed via the Model Context Protocol (MCP).

Tools

calculate

Evaluate math expressions safely (no eval). Supports arithmetic operators (+, -, *, /, ^, %), parentheses, functions (sqrt, abs, floor, ceil, round, log, ln, sin, cos, tan, min, max, pow), constants (pi, e), and named variables.

convert_units

Convert between units across six categories:

  • Length: m, km, cm, mm, mi, yd, ft, in
  • Weight: kg, g, mg, lb, oz, ton
  • Temperature: C, F, K
  • Data: B, KB, MB, GB, TB
  • Time: s, min, h, d, week
  • Speed: m/s, km/h, mph, knots

statistics

Statistical analysis on datasets: mean, median, mode, variance, standard deviation, min, max, range, percentile, correlation between two arrays, and a full summary mode.

format_number

Format numbers as: currency ($1,234.56), percentage, scientific notation, binary, octal, hexadecimal, significant figures, or with thousands separators.

percentage_calc

Common percentage operations: X% of Y, what percent X is of Y, percentage change between two values, tip calculator, discount calculator, and markup calculator.

Installation

bash
npm installnpm run build

Usage with Claude Desktop

Add to your claude_desktop_config.json:

json
{  "mcpServers": {    "math-tools": {      "command": "node",      "args": ["path/to/mcp-math-tools/dist/index.js"]    }  }}

Examples

Calculate: 2 * (3 + 4) ^ 2 returns 98

Convert: 100 from km/h to mph returns 62.137...

Statistics: summary of [1, 2, 3, 4, 5] returns mean, median, mode, variance, etc.

Format: 1234567.89 as currency returns $1,234,567.89

Percentage: 15% tip on 85.50 bill split 3 ways

License

MIT

Source: README.md at commit 18f7312

Tools

0
SourceWeft has not started this package in its sandbox yet, so its tools are not known.

Version history

1
  1. v1.0.1LatestSep 16, 2026

Score

40% of the applicable checks met

How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.

  • Reached in the last 30 days25 pts

    Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.

  • Auth declared10 pts

    Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.

  • Tools listed15 pts

    Answer tools/list without a credential, or ship a package that starts in a sandbox without one.

  • DescriptionRequired15 pts
  • Logo10 pts
  • Documentation15 pts
  • License10 pts

    Declare a license in the repository or the registry entry.