sympy_Identity
Generate an n x n identity matrix for symbolic linear algebra computations.
Instructions
Identity matrix.
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": {
"n": "<n>"
},
"name": "sympy_Identity"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| n | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |
Implementation Reference
- src/mcp_sympy/tools.py:2414-2417 (handler)The tool handler function for 'sympy_Identity'. It is decorated with @mcp.tool(), takes an integer n, and returns a string representation of sympy.Identity(n).
@mcp.tool() def sympy_Identity(n: int) -> str: """Identity matrix.""" return str(sympy.Identity(n)) - src/mcp_sympy/tools.py:2414-2414 (registration)The @mcp.tool() decorator registers this function as an MCP tool with the FastMCP server instance.
@mcp.tool()