Function Graph Plotter
Plot mathematical functions interactively on a canvas with a safe recursive descent parser. Supports multiple functions, zoom/pan, intercepts, and local extrema.
このツールについて
Graph any mathematical function without installing software or using a paid service. Enter an expression like sin(x), x^2 + 2*x - 1, or 1/x and it appears instantly on an interactive canvas. The expression evaluator uses a hand-written recursive descent parser — no eval() is ever called, so there is no script injection risk. The parser handles: the four arithmetic operators +, -, *, /; exponentiation with ^ or **; unary minus; grouping parentheses; and the built-in math functions sin, cos, tan, asin, acos, atan, sinh, cosh, tanh, sqrt, cbrt, abs, log (base-10), ln (natural log), exp, floor, ceil, round, and sign. Constants pi (π) and e are recognized. Plot multiple functions simultaneously — each gets its own color, a toggle to show/hide it, and can be removed independently. Drag the canvas to pan, and scroll or pinch to zoom in and out; the axis labels update accordingly. Set the x range manually or let the plotter auto-scale. Y range can be set manually or auto-fitted. Toggle grid lines and axis labels. For each function the tool numerically finds: x-intercepts (zeros), the y-intercept, and local minima and maxima within the visible range — displayed as annotated dots on the graph and listed in the sidebar.
使い方
- 1 Type a function expression in the input field (e.g. sin(x), x^3 - 3*x, 1/(1+exp(-x))).
- 2 Press Enter or click 'Add Function' to plot it — each function gets a different color.
- 3 Scroll to zoom in/out; drag the canvas to pan.
- 4 Adjust the x range manually using the min/max inputs, or click 'Auto Fit Y' to rescale the y axis.
- 5 Toggle 'Show Grid', 'Show Axes', and 'Show Annotations' to customize the display.
- 6 Click the eye icon next to a function to hide/show it, or the trash icon to remove it.