Skip to main content
Glama
agmonetti

mathmethods-mcp

by agmonetti

interpolation_lagrange

Constructs the Lagrange interpolating polynomial from provided y-values or a generating function, evaluates it at an optional x, and returns the polynomial, degree, and error bounds.

Instructions

Build the Lagrange interpolating polynomial through a set of points.

Provide either the point values puntos_y or the generating function func_str evaluated at puntos_x.

Args: puntos_x: Distinct abscissas of the interpolation points. x_eval: Optional x where the polynomial is evaluated. func_str: Optional generating function f(x) for the y values. puntos_y: Optional y values matching puntos_x one-to-one. precision: Rounding digits.

Returns: Dict with the polynomial, its degree, the points table and error bounds when func_str is provided.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
x_evalNo
func_strNo
puntos_xYes
puntos_yNo
precisionNo

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/agmonetti/mathmethods-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server