plot
Plot a mathematical function as an SVG graph showing the curve with axes, grid, and labels. Enter any expression like sin(x) or x^2 - 3x + 1 to visualize it.
Instructions
Plot a mathematical function as an SVG graph. Returns an image showing the function curve with axes, grid, and labels.
Examples:
plot sin(x) from -2pi to 2pi
plot x^2 - 3*x + 1 from -5 to 5
plot exp(-x^2) (Gaussian curve)
plot 1/x with asymptote detection
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | No | Chart title (optional) | |
| width | No | Image width in pixels (default: 600) | |
| x_max | No | Maximum x value (default: 10) | |
| x_min | No | Minimum x value (default: -10) | |
| y_max | No | Maximum y value (auto-detected if omitted) | |
| y_min | No | Minimum y value (auto-detected if omitted) | |
| height | No | Image height in pixels (default: 400) | |
| variable | No | Variable name (default: "x") | |
| expression | Yes | Mathematical expression to plot (e.g., "sin(x)", "x^2 - 3*x + 1") |