Graphing Calculator for Calculus

  • Free
  • No sign-up
  • Works on phones
  • Shows the working

2D Visual LabLive coordinate sandbox

See derivatives and integrals take shape

Plot any function, slide a tangent line along the curve, shade the signed area under it, and watch Riemann rectangles converge to the exact integral.

f(x) f′(x) Tangent line Signed area Drag to pan · Ctrl/⌘ + scroll to zoom

This graphing calculator online is built for calculus rather than general algebra. Type a function and it plots \( f(x) \) together with its derivative \( f'(x) \), a tangent line you can slide along the curve, and the shaded signed area between the curve and the x-axis on an interval \([a, b]\). Turn on Riemann rectangles to watch left, right, midpoint or trapezoid sums approach the exact integral.

It’s a quick function grapher for homework, lecture demos or building intuition before an exam. It runs in your browser, works on phones, and is free with no sign-up.

How to use the graphing calculator

  1. Type your function in the f(x) = box. Use ^ for powers, sqrt(), sin(), cos(), ln(), e^(x) and pi. Implicit multiplication works, so 3x and x sin(1/x) are fine. The graph redraws as you type, or tap one of the example chips.
  2. Use the Layers checkboxes to show or hide the derivative (dashed), the tangent line, the area under the curve, and Riemann rectangles.
  3. Drag the Tangent point x₀ slider to move the tangent line. The readout shows \( f(x_0) \), \( f'(x_0) \) and the tangent line’s equation.
  4. Enter Area from a and to b as numbers. The readout gives \( \int_a^b f\,dx \). For Riemann sums, set Rectangles n (1 to 100) and pick a Sampling rule; the readout adds the sum and its error.
  5. Navigate the view: drag to pan, press Ctrl or Cmd while scrolling to zoom, or use the +, −, Fit and Reset buttons. Hover over the graph to read \( x \) and \( f(x) \) at the cursor.

How it works

The lab differentiates your function symbolically and plots \( f'(x) \) as a second curve. The tangent line at \( x_0 \) is

$$y = f(x_0) + f'(x_0)(x - x_0)$$

The area readout is the definite integral, computed numerically. It’s signed: regions above the x-axis are shaded blue and count as positive, regions below are shaded red and count as negative. The Riemann sum with \( n \) subintervals of width \( \Delta x = \frac{b - a}{n} \) is

$$\sum_{i=1}^{n} f(x_i^*)\,\Delta x$$

where \( x_i^* \) is the left endpoint, right endpoint or midpoint of each strip. The trapezoid option joins the endpoints with slanted tops instead.

Worked example

Start with the prefilled \( f(x) = \sin x + \frac{x}{2} \) on \([0, 3]\).

Now try the x^3 - 3x chip. Drag \( x_0 \) to \( -1 \) and \( 1 \): the tangent goes flat, because \( f'(x) = 3x^2 - 3 = 0 \) there. Those are the local maximum \((-1, 2)\) and minimum \((1, -2)\), the critical points. Set \( a = -2 \), \( b = 2 \) and the blue and red regions cancel exactly, so the integral is 0. On \([0, 2]\) it’s \( -2 \), because more of the area lies below the axis.

Visualizing Riemann sums

Enter x^2, set \( a = 0 \), \( b = 2 \), turn on Riemann rectangles, choose Midpoints and set \( n = 4 \). The four strips have width \( 0.5 \) and midpoints \( 0.25, 0.75, 1.25, 1.75 \), so the sum is

$$0.5\left(0.25^2 + 0.75^2 + 1.25^2 + 1.75^2\right) = 2.625$$

The exact area is \( \frac83 \approx 2.6667 \), an error of about \( 0.0417 \). Switch to left endpoints and the sum drops below the true area, since \( x^2 \) is increasing on this interval; right endpoints overshoot. Slide \( n \) up toward 100 and watch every rule converge. The guide to Riemann sums explains why the midpoint rule usually wins, and the Riemann sum calculator adds Simpson’s rule and larger values of \( n \).

Tips

  • Vertical asymptotes. For 1/x the curve is drawn in two pieces, and an interval containing 0 shows “diverges” in the readout.
  • Lost the curve? Press Fit to rescale the y-axis to your function, or Reset to return to the default window.
  • Keyboard control. Click the graph, then use the arrow keys to pan and + or - to zoom.

Related guides

Further reading

FAQ

Can this graphing calculator plot the derivative?

Yes. The derivative is computed symbolically and drawn as a dashed curve, and its formula appears in the readout. Uncheck Derivative f′(x) to hide it.

Can I graph more than one function at once?

No. The lab plots one \( f(x) \) at a time, along with its derivative and tangent line. To compare two curves, switch between them in the input box.

How do I find the area under a curve?

Check Area under curve, enter \( a \) and \( b \), and read the integral in the readout. Remember that it’s signed area; for total area, split the interval where the curve crosses the x-axis.

Is it free to use?

Yes. It’s free, needs no account, and works in any modern browser on desktop or mobile.

Embed this calculator on your website

Teachers, tutors and bloggers are welcome to use this calculator for free. Copy the code below and paste it into any page (in WordPress, use a "Custom HTML" block). The small script makes the calculator grow to fit its answer; if your site removes scripts, it still works at a fixed height. Please keep the credit link.

More calculators

See all calculators