calculate_series
Compute Taylor, Laurent, or Fourier series expansions to approximate functions near a point, enabling linearization and perturbation analysis.
Instructions
Calculate series expansion of an expression.
═══════════════════════════════════════════════════════════════════════
🆕 NOT AVAILABLE IN SYMPY-MCP!
═══════════════════════════════════════════════════════════════════════
Use cases:
- Approximate functions near a point
- Linearization (order=1)
- Small-signal analysis
- Perturbation methods
Args:
expression: The expression to expand
variable: The expansion variable
point: The expansion point (default: "0" for Maclaurin series)
order: Number of terms (default: 6)
series_type: Type of series
- "taylor": Taylor/Maclaurin series (default)
- "laurent": Laurent series (for singularities)
- "fourier": Fourier series (periodic functions)
Returns:
Series expansion with LaTeX
Examples:
# Maclaurin series of sin(x)
calculate_series("sin(x)", "x", "0", order=5)
→ {"result": "x - x**3/6 + x**5/120", ...}
# Taylor series around x=1
calculate_series("ln(x)", "x", "1", order=4)
→ {"result": "-1 + x - (x-1)**2/2 + ...", ...}
# Linearization (first-order approximation)
calculate_series("exp(-E/(R*T))", "T", "T0", order=1)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| order | No | ||
| point | No | 0 | |
| variable | Yes | ||
| expression | Yes | ||
| series_type | No | taylor |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||