Equation Plotter
Type-in equation plotter (2D and 3D) — parametric, linear, explicit, and implicit equations, with optional sample points and tangent vectors.
Embed syntax
Inside node/facet MDX content, embed the component directly. Inside a page, insert it through the Studio's component picker instead — it configures the same props through a form (or raw JSON if EditorComponentisn't set for this one).
<EquationPlotter
mode="2d"
equations={["x + 2y = 1"]}
title=""
showLegend={true}
legendPosition="right"
/>Live example
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| equations | string[] | ["-2x + y = 0"] (2D) / ["x + 2y + 3z = 5"] (3D) | Equations to plot, one per string, e.g. "y = x^2" or "param2d:x=cos(t),y=sin(t)". |
| mode | "2d" | "3d" | "2d" | Plot dimensionality. |
| title | string | "Equation Plotter" | Card title. |
| showModeSwitch | boolean | true | Show the 2D/3D toggle in the controls bar. |
| xRange2d | [number, number] | [-10, 10] | X-axis range in 2D mode. |
| yRange2d | [number, number] | [-10, 10] | Y-axis range in 2D mode. |
| equalAspect2d | boolean | false | Lock the Y axis to the same scale as X, so true circles look round, not stretched. |
| showSamplePoints | boolean | false | Mark sample points along parametric curves. |
| labelSamplePoints | boolean | false | Label each sample point with its coordinates. |
| sampleParameters | number[] | — | Explicit parameter values to sample, instead of the automatic start/mid/end picks. |
| showLegend | boolean | true | Show the equation legend. |
| legendPosition | "right" | "top" | "right" | Where the legend sits — auto-switches to top on small screens regardless. |
PreviousNext