factor

Pack: newton · Endpoint: https://gateway.pipeworx.io/newton/mcp

Factor a polynomial into irreducible factors. Input polynomial (e.g., “x^2-1” or “x^2+3x+2”). Returns factored form.

Parameters

NameTypeRequiredDescription
expressionstringyesPolynomial expression to factor (e.g., “x^2-1”, “x^2+3x+2”)

Example call

Arguments

{
  "expression": "x^2-1"
}

curl

curl -X POST https://gateway.pipeworx.io/newton/mcp \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"factor","arguments":{"expression":"x^2-1"}}}'

TypeScript (@pipeworx/sdk)

import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();

const result = await pipeworx.call('factor', {
  "expression": "x^2-1"
});

More examples

{
  "expression": "x^2+3x+2"
}

Response shape

Always returns: operation, input, result

FieldTypeDescription
operationstringOperation name (factor)
inputstringThe input polynomial expression
resultstring | nullFactored form of the polynomial or null
Full JSON Schema
{
  "type": "object",
  "properties": {
    "operation": {
      "type": "string",
      "description": "Operation name (factor)"
    },
    "input": {
      "type": "string",
      "description": "The input polynomial expression"
    },
    "result": {
      "type": [
        "string",
        "null"
      ],
      "description": "Factored form of the polynomial or null"
    }
  },
  "required": [
    "operation",
    "input",
    "result"
  ]
}

Connect

Add this to your MCP client config, or use one-click install buttons:

{
  "mcpServers": {
    "newton": {
      "url": "https://gateway.pipeworx.io/newton/mcp"
    }
  }
}

See Getting Started for client-specific install steps.

Regenerated from source · build May 9, 2026