Function Graph
Plot up to three math functions on one graph with zoom and a value table. Drawn locally on a canvas.
Operators + − * / ^ and parentheses. Functions: sin cos tan asin acos atan exp log sqrt abs. Constants: pi, e. Implicit multiplication works: 2x, 2(x+1). log is the natural logarithm.
Values at integer x
| x | f(x) | g(x) |
|---|---|---|
| -10 | 100 | 0.544 |
| -9 | 81 | -0.4121 |
| -8 | 64 | -0.9894 |
| -7 | 49 | -0.657 |
| -6 | 36 | 0.2794 |
| -5 | 25 | 0.9589 |
| -4 | 16 | 0.7568 |
| -3 | 9 | -0.1411 |
| -2 | 4 | -0.9093 |
| -1 | 1 | -0.8415 |
| 0 | 0 | 0 |
| 1 | 1 | 0.8415 |
| 2 | 4 | 0.9093 |
| 3 | 9 | 0.1411 |
| 4 | 16 | -0.7568 |
| 5 | 25 | -0.9589 |
| 6 | 36 | -0.2794 |
| 7 | 49 | 0.657 |
| 8 | 64 | 0.9894 |
| 9 | 81 | 0.4121 |
| 10 | 100 | -0.544 |
How to use
- Type a formula in the f(x) field, such as x^2, sin(x) or 2x + 1. Use g(x) and h(x) to overlay up to three curves.
- Set the x range and press Redraw. The y range follows automatically from the aspect ratio.
- The table below lists each function's value at every integer x in the range.
Notes
Formulas are interpreted by a dedicated safe parser — eval is never used. Supported functions are sin, cos, tan, asin, acos, atan, exp, log (natural), sqrt and abs, with constants pi and e and implicit multiplication such as 2x. The line breaks where a function is undefined (division by zero, square root of a negative, and so on). The y range is centered on zero automatically, so functions with large values may leave the visible area.
FAQ
- Can I set the y range myself?
- In this version the y range is derived from the x range and the canvas aspect ratio. Adjust the x range to frame the part you want to see.
- Why does tan(x) show near-vertical segments?
- The values jump across its asymptotes. The plotter breaks the line on very large jumps, but some steep segments can remain.