Visual Tools
Calculators
Tables
Mathematical Keyboard
Converters
Other Tools

Area Between Curves Calculator

How to use
  1. Type the two functions in the f(x)f(x) and g(x)g(x) boxes, for example x2x^2 and x+2x + 2. Learn more about finding the area
  2. Type the interval in From a and To b. To find the area enclosed by the two curves, use the points where they meet as aa and bb; the calculator lists those points.
  3. Read the area under Area. The region between the curves is shaded, and the meeting points are marked. Learn more about reading the answer
  4. Change either function or either limit and the area follows at once.

Area between curves
Area
∫−12∣f(x)−g(x)∣dx≈4.5\displaystyle \int_{-1}^{2} \left| f(x) - g(x) \right| dx \approx 4.5
The curves meet at
x=−1,x=2\displaystyle x = -1,\quad x = 2
How it was found

Between x=−1x = -1 and x=2x = 2, the area enclosed by f(x)=x+2f(x) = x+2 and g(x)=x2g(x) = {x}^{2} is the integral of the gap between them, ∣f(x)−g(x)∣|f(x) - g(x)|.

The curves cross at x=−1x = -1, x=2x = 2, so the upper curve changes there; the absolute value takes care of that.

Worked out numerically: 4.54.5.

Drawn by the tool
g(x)=x2g\left(x\right)={x}^{2}read-only
f(x)=x+2f\left(x\right)=x+2
g(x)=x2g\left(x\right)={x}^{2}


Finding the area

DemoArea enclosed by two curves
Step 0 of 4
Type two functions and an interval. The calculator shades the region between the two curves from x=ax = a to x=bx = b, gives its area, and lists every point between aa and bb where the curves meet.

For the area enclosed by two curves, the interval runs from one meeting point to the next: for x+2x + 2 and x2x^2 they meet at x=−1x = -1 and x=2x = 2, and the enclosed area is 4.54.5.

Reading the answer

DemoWhen the curves cross
Step 0 of 4
The Area box gives

∫ab∣f(x)−g(x)∣ dx,\int_a^b |f(x) - g(x)|\,dx,


the size of the shaded region, always positive. Under it, The curves meet at lists the meeting points inside the interval, and How it was found explains the steps.

When the curves cross inside the interval, the upper curve changes. The calculator takes care of that: every piece of the region counts as positive area, whichever curve is on top.

The area between two curves

Where ff lies above gg, the vertical distance between them at xx is f(x)−g(x)f(x) - g(x). Adding up thin strips of that height across the interval gives the area between the curves:

A=∫ab(f(x)−g(x)) dxwhen f(x)≥g(x) on [a,b].A = \int_a^b \big(f(x) - g(x)\big)\,dx \quad\text{when } f(x) \ge g(x) \text{ on } [a, b].


For f(x)=x+2f(x) = x + 2 and g(x)=x2g(x) = x^2 between their meeting points −1-1 and 22:

A=∫−12(x+2−x2) dx=[x22+2x−x33]−12=103+76=4.5.A = \int_{-1}^{2} (x + 2 - x^2)\,dx = \left[\frac{x^2}{2} + 2x - \frac{x^3}{3}\right]_{-1}^{2} = \frac{10}{3} + \frac{7}{6} = 4.5.
The region enclosed by y=x+2y = x + 2 and y=x2y = x^2 has area 4.54.5.

Finding where the curves meet

The meeting points are the solutions of f(x)=g(x)f(x) = g(x), or equally the roots of f(x)−g(x)f(x) - g(x). For x+2=x2x + 2 = x^2: x2−x−2=0x^2 - x - 2 = 0, so (x−2)(x+1)=0(x - 2)(x + 1) = 0 and x=−1x = -1 or x=2x = 2.

These points matter twice: they are the limits of the enclosed region, and they are where the upper curve can change. The calculator finds them numerically and lists those between aa and bb.

When the curves cross inside the interval

If the curves cross between aa and bb, the plain integral ∫ab(f−g) dx\int_a^b (f - g)\,dx adds the piece where ff is on top and subtracts the piece where gg is on top. To get the true area, split the interval at each crossing and take each piece as positive — or integrate ∣f−g∣|f - g|, which does the same in one step.

For x3x^3 and xx on [−1,1][-1, 1]: ∫−11(x3−x) dx=0\int_{-1}^{1} (x^3 - x)\,dx = 0, but the area is ∫−10(x3−x) dx+∫01(x−x3) dx=14+14=12\int_{-1}^{0}(x^3 - x)\,dx + \int_{0}^{1}(x - x^3)\,dx = \frac{1}{4} + \frac{1}{4} = \frac{1}{2}.
x3x^3 and xx swap places at 00; both pieces count, total 12\frac{1}{2}.

Curves that are easier sideways

Some regions are simpler to cut into horizontal strips. The region between x=y2x = y^2 and the line y=x−2y = x - 2 has a different top curve on different stretches when sliced vertically, but sliced horizontally it is one piece: the line is always on the right. With xx in terms of yy,

A=∫−12((y+2)−y2) dy=4.5.A = \int_{-1}^{2} \big((y + 2) - y^2\big)\,dy = 4.5.


The calculator works with functions of xx; for sideways regions, set up the integral in yy by hand, or draw both curves in the Graphing Calculator to see the region.
The region between x=y2x = y^2 and y=x−2y = x - 2, meeting at (1,−1)(1, -1) and (4,2)(4, 2).

Common mistakes

  • Subtracting in the wrong order. ∫(g−f)\int (g - f) where gg is below gives a negative number; area is never negative.
  • Ignoring a crossing. If the curves cross inside [a,b][a, b], one integral of f−gf - g lets the pieces cancel.
  • Using the wrong limits. For the enclosed area, the limits are the meeting points, not the edges of the picture.
  • Integrating each curve separately and adding. The area between is the difference of the two, not their sum.