Skip to main content
Glama

WritersLogic verifiable AI agents

float-stability

Floating-point stability of an expression over variable ranges — Evaluates a real-valued expression in binary64 (or binary32) on a deterministic grid over the caller's variable ranges and compares each point with a certified arbitrary-precision reference, reporting the decimal digits lost, the worst input, and overflow, underflow or NaN. Recognises and rewrites exp(x)-1, 1-cos(x), log(1+x), sqrt(a)-sqrt(b), a^2-b^2, the quadratic formula, sqrt(x^2+y^2) and log-

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "expression": "<expression>",
      "variables": "<variables>"
    },
    "name": "float-stability"
  }
}

Input Schema

NameRequiredDescriptionDefault
precisionNoArithmetic of the code under test. Default binary64.
variablesYesRange of every free variable.
expressionYesExpression in the declared variables, e.g. 'exp(x) - 1'. Operators + - * / ^ (or **); functions sqrt exp expm1 log log1p log2 log10 sin cos tan atan sinh cosh tanh abs pow hypot min max; constants pi, e.
alternativeNoOptional algebraically equal expression to score on the same grid.
maxDigitsLostNoFail above this many lost digits. Default 4.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

Score is being calculated.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources