Skip to content

Unit 6: Integration and Accumulation of Change

AP Calc cheatsheet

Open ↗

Loading…

Integration begins with a simple idea: if a region is too curved to measure with one familiar geometry formula, approximate it with many simple shapes. A Riemann sum approximates accumulated change by cutting an interval into small pieces and adding rectangle areas.

Suppose we want the signed area under f(x)f(x) on [a,b][a,b]. Divide the interval into nn subintervals of equal width

Δx=b−an.\Delta x = \frac{b-a}{n}.

Choose one sample point xi∗x_i^* in each subinterval. The rectangle on that subinterval has height f(xi∗)f(x_i^*) and width Δx\Delta x, so the total approximation is

∑i=1nf(xi∗)Δx.\sum_{i=1}^n f(x_i^*)\Delta x.

The sample point determines the type of Riemann sum. There are three types of rectangular Riemann sums: left Riemann sums, right Riemann sums, and midpoint Riemann sums.

1224xf(x)Left1224xf(x)Right1224xf(x)Midpoint

A left Riemann sum uses the left endpoint of each subinterval. On an increasing function, left sums usually underestimate because each rectangle uses the smaller height from its interval.

Example. Approximate ∫02x2 dx\int_0^2 x^2\,dx with a left Riemann sum using n=4n=4.

The width is

Δx=2−04=0.5.\Delta x=\frac{2-0}{4}=0.5.

The left endpoints are 0,0.5,1,1.50,0.5,1,1.5, so

L4=0.5[f(0)+f(0.5)+f(1)+f(1.5)].L_4=0.5\left[f(0)+f(0.5)+f(1)+f(1.5)\right].

Since f(x)=x2f(x)=x^2,

L4=0.5(0+0.25+1+2.25)=1.75.L_4=0.5(0+0.25+1+2.25)=1.75.

A right Riemann sum uses the right endpoint of each subinterval. On an increasing function, right sums usually overestimate because each rectangle uses the larger height from its interval.

Example. Approximate ∫02x2 dx\int_0^2 x^2\,dx with a right Riemann sum using n=4n=4.

The right endpoints are 0.5,1,1.5,20.5,1,1.5,2, so

R4=0.5[f(0.5)+f(1)+f(1.5)+f(2)].R_4=0.5\left[f(0.5)+f(1)+f(1.5)+f(2)\right].

Evaluate:

R4=0.5(0.25+1+2.25+4)=3.75.R_4=0.5(0.25+1+2.25+4)=3.75.

A midpoint Riemann sum uses the center of each subinterval. Midpoint sums often give a better estimate than left or right sums with the same number of intervals because the rectangle height is chosen from the middle.

Example. Approximate ∫02x2 dx\int_0^2 x^2\,dx with a midpoint Riemann sum using n=4n=4.

The subintervals are [0,0.5][0,0.5], [0.5,1][0.5,1], [1,1.5][1,1.5], and [1.5,2][1.5,2]. Their midpoints are 0.25,0.75,1.25,1.750.25,0.75,1.25,1.75. Thus

M4=0.5[f(0.25)+f(0.75)+f(1.25)+f(1.75)].M_4=0.5\left[f(0.25)+f(0.75)+f(1.25)+f(1.75)\right].

Compute:

M4=0.5(0.0625+0.5625+1.5625+3.0625)=2.625.M_4=0.5(0.0625+0.5625+1.5625+3.0625)=2.625.

The trapezoidal rule uses trapezoids instead of rectangles. On each subinterval, connect the two endpoint heights with a straight segment. The area of one trapezoid is

12(width)(left height+right height).\frac{1}{2}(\text{width})(\text{left height}+\text{right height}).

For equal spacing Δx\Delta x,

∫abf(x) dx≈Δx2[y0+2y1+2y2+⋯+2yn−1+yn].\int_a^b f(x)\,dx \approx \frac{\Delta x}{2} \left[y_0+2y_1+2y_2+\cdots+2y_{n-1}+y_n\right].

Example. Approximate ∫02x2 dx\int_0^2 x^2\,dx with the trapezoidal rule using n=4n=4.

The nodes are 0,0.5,1,1.5,20,0.5,1,1.5,2, and the heights are

0,0.25,1,2.25,4.0,\quad 0.25,\quad 1,\quad 2.25,\quad 4.

So

T4=0.52[0+2(0.25)+2(1)+2(2.25)+4].T_4=\frac{0.5}{2}\left[0+2(0.25)+2(1)+2(2.25)+4\right].

This gives

T4=0.25(11)=2.75.T_4=0.25(11)=2.75.
0:511:521234trapezoidsusebothendpointsxf(x)

With table data, the width of each subinterval matters. Equal spacing is convenient, but AP tables often use unequal intervals.

For left and right sums, multiply each function value by the width of its interval. For trapezoids, each interval contributes

12(width)(left height+right height).\frac{1}{2}(\text{width})(\text{left height}+\text{right height}).

If the function is increasing, a left sum underestimates and a right sum overestimates. If the function is decreasing, the reverse is true. Concavity controls whether trapezoids or midpoints tend to overestimate or underestimate.

Example. A car’s velocity is measured in miles per hour:

t (hours)0134v(t) (mph)20355042\begin{array}{c|cccc} t\text{ (hours)} & 0 & 1 & 3 & 4 \\\hline v(t)\text{ (mph)} & 20 & 35 & 50 & 42 \end{array}

Approximate the distance traveled from t=0t=0 to t=4t=4 using a left Riemann sum.

The intervals have widths 11, 22, and 11. A left sum uses the left endpoint velocity on each interval:

20(1)+35(2)+50(1)=20+70+50=140.20(1)+35(2)+50(1)=20+70+50=140.

The car traveled approximately 140140 miles. The units work because

miles per hour⋅hours=miles.\text{miles per hour}\cdot\text{hours}=\text{miles}.

Although Riemann sums are a great way to approximate the area under the curve, you always end of over- or underestimating the actual area. One way to fix this is to shrink the width of the rectangles used to an infinitesimally small value dxdx (basically 00) so that the height of each rectangle represents the actual height. We define a function called the definite integral to model this limit.

Definition. The definite integral of ff from aa to bb is the limit of Riemann sums:

∫abf(x) dx=lim⁡n→∞∑i=1nf(xi∗)Δx,\int_a^b f(x)\,dx = \lim_{n\to\infty}\sum_{i=1}^{n} f(x_i^*)\Delta x,

as the width of the largest subinterval approaches 00, assuming this limit exists. f(x)f(x) is called the integrand, and dxdx is “integrating with respect to xx”. aa and bb are the bounds of integration, with aa being the bottom bound and bb being the top bound.

A key property of the definite integral is

∫abf(x) dx=−∫baf(x) dx.\int_a^b f(x)\,dx = -\int_b^a f(x)\,dx.

This is because we usually define the definite integral using singed area (talked about right after this), meaning that the direction of the area matters. We usually take right and above as positive, meaning that integrating from right to left or integrating under the xx-axis results in a negative area.

For bounds ordered from left to right, the definite integral gives signed area:

  • area above the xx-axis contributes positively,
  • area below the xx-axis contributes negatively.

Geometric area is always nonnegative, meaning that you add up the magnitudes of all of the areas.


The definite integral is defined as a limiting area process, but computing a limit of Riemann sums every time would be painful. The Fundamental Theorem of Calculus gives the shortcut: if you can find an antiderivative, then a definite integral can be evaluated by subtracting endpoint values.

The theorem also explains why derivatives and integrals are inverse processes. Derivatives measure instantaneous change; integrals add up accumulated change.

Theorem (Fundamental Theorem of Calculus). If for some functions F(x)F(x) and f(x)f(x), F′(x)=f(x)F'(x)=f(x), then

∫abf(x) dx=F(b)−F(a).\int_a^b f(x)\,dx = F(b)-F(a).

Also, if

g(x)=∫axf(t) dt,g(x) = \int_a^x f(t)\,dt,

then

g′(x)=f(x)g'(x) = f(x)

when ff is continuous.

Proof (Fundamental Theorem of Calculus). Let

G(x)=∫axf(t) dt.G(x)=\int_a^x f(t)\,dt.

To find G′(x)G'(x), use the derivative definition:

G′(x)=lim⁡h→0G(x+h)−G(x)h.G'(x)=\lim_{h\to0}\frac{G(x+h)-G(x)}{h}.

Substitute the definition of GG:

G(x+h)−G(x)=∫ax+hf(t) dt−∫axf(t) dt=∫xx+hf(t) dt.G(x+h)-G(x) = \int_a^{x+h}f(t)\,dt-\int_a^x f(t)\,dt = \int_x^{x+h}f(t)\,dt.

Thus

G′(x)=lim⁡h→01h∫xx+hf(t) dt.G'(x)=\lim_{h\to0}\frac{1}{h}\int_x^{x+h}f(t)\,dt.

If ff is continuous, then on a very small interval from xx to x+hx+h, the average value of ff approaches f(x)f(x). Therefore

G′(x)=f(x).G'(x)=f(x).

Now suppose F′(x)=f(x)F'(x)=f(x). Since G′(x)=f(x)G'(x)=f(x) too, the functions FF and GG differ only by a constant. Using total change,

∫abf(x) dx=G(b)−G(a)=F(b)−F(a).\int_a^b f(x)\,dx=G(b)-G(a)=F(b)-F(a).

Before using the Fundamental Theorem of Calculus, you need an antiderivative. These are the most common reverse rules:

∫xn dx=xn+1n+1+C,n≠−1\int x^n\,dx=\frac{x^{n+1}}{n+1}+C,\qquad n\ne -1 ∫ex dx=ex+C\int e^x\,dx=e^x+C ∫ax dx=axln⁡a+C,a>0, a≠1\int a^x\,dx=\frac{a^x}{\ln a}+C,\qquad a>0,\ a\ne1 ∫1x dx=ln⁡∣x∣+C\int \frac{1}{x}\,dx=\ln\lvert x\rvert+C ∫cos⁡x dx=sin⁡x+C,∫sin⁡x dx=−cos⁡x+C\int \cos x\,dx=\sin x+C,\qquad \int \sin x\,dx=-\cos x+C

Always check an antiderivative by differentiating it back to the integrand.

Example. Evaluate ∫03x2 dx\displaystyle\int_0^3 x^2\,dx.

Find an antiderivative of the integrand:

F(x)=x33,F′(x)=x2.F(x) = \frac{x^3}{3}, \qquad F'(x) = x^2.

Now apply ∫abf(x) dx=F(b)−F(a)\int_a^b f(x)\,dx = F(b)-F(a):

∫03x2 dx=333−033=273−0=9.\int_0^3 x^2\,dx = \frac{3^3}{3} - \frac{0^3}{3} = \frac{27}{3} - 0 = 9.

So the definite integral equals 99.

An integral adds up tiny pieces. If f(x)f(x) is a rate, then

f(x) dxf(x)\,dx

represents a tiny amount of accumulated change caused by that rate. Adding all of those tiny pieces from aa to bb gives

∫abf(x) dx.\int_a^b f(x)\,dx.

This is why the units of a definite integral are

(units of f)(units of x).(\text{units of }f)(\text{units of }x).

For example, if r(t)r(t) is measured in gallons per minute and tt is measured in minutes, then

∫abr(t) dt\int_a^b r(t)\,dt

is measured in gallons. The integral does not give a rate anymore; it gives the accumulated amount caused by that rate over the interval.

To solve a definite integral using the Fundamental Theorem:

Example. Evaluate

∫14(3x2−2x) dx.\int_1^4 \left(3x^2-2x\right)\,dx.

An antiderivative is

F(x)=x3−x2.F(x)=x^3-x^2.

Apply the Fundamental Theorem:

∫14(3x2−2x) dx=F(4)−F(1).\int_1^4 \left(3x^2-2x\right)\,dx = F(4)-F(1).

Compute:

F(4)=43−42=64−16=48,F(4)=4^3-4^2=64-16=48,

and

F(1)=13−12=0.F(1)=1^3-1^2=0.

Therefore

∫14(3x2−2x) dx=48.\int_1^4 \left(3x^2-2x\right)\,dx=48.

If

G(x)=∫u(x)v(x)f(t) dt,G(x) = \int_{u(x)}^{v(x)} f(t)\,dt,

then

G′(x)=f(v(x))v′(x)−f(u(x))u′(x).G'(x) = f(v(x))v'(x) - f(u(x))u'(x).

This is can be thought of as the chain rule for FTC.

Proof (Chain rule form of FTC). Define

A(x)=∫axf(t) dt.A(x)=\int_a^x f(t)\,dt.

By the Fundamental Theorem,

A′(x)=f(x).A'(x)=f(x).

If the upper limit is v(x)v(x), then

∫av(x)f(t) dt=A(v(x)).\int_a^{v(x)}f(t)\,dt=A(v(x)).

Differentiate using the chain rule:

ddxA(v(x))=A′(v(x))v′(x)=f(v(x))v′(x).\frac{d}{dx}A(v(x))=A'(v(x))v'(x)=f(v(x))v'(x).

For a lower limit u(x)u(x), rewrite

∫u(x)v(x)f(t) dt=∫av(x)f(t) dt−∫au(x)f(t) dt.\int_{u(x)}^{v(x)}f(t)\,dt = \int_a^{v(x)}f(t)\,dt-\int_a^{u(x)}f(t)\,dt.

Differentiate both pieces:

ddx∫u(x)v(x)f(t) dt=f(v(x))v′(x)−f(u(x))u′(x).\frac{d}{dx}\int_{u(x)}^{v(x)}f(t)\,dt =f(v(x))v'(x)-f(u(x))u'(x).

Example. Find ddx∫0x2cos⁡t dt.\displaystyle\frac{d}{dx}\int_0^{x^2}\cos t\,dt.

Here the upper limit is v(x)=x2v(x)=x^2 and the lower limit is the constant 00. By the chain-rule form of the Fundamental Theorem, evaluate the integrand at the upper limit and multiply by its derivative:

v′(x)=2x.v'(x) = 2x.

Therefore

ddx∫0x2cos⁡t dt=cos⁡ ⁣(x2)⋅2x=2xcos⁡ ⁣(x2).\frac{d}{dx}\int_0^{x^2}\cos t\,dt = \cos\!\bigl(x^2\bigr)\cdot 2x = 2x\cos\!\bigl(x^2\bigr).

The lower limit contributes nothing because its derivative is zero.


Antiderivatives and the indefinite integral

Section titled “Antiderivatives and the indefinite integral”

Definition. An antiderivative of ff is any function FF such that

F′(x)=f(x).F'(x) = f(x).

However, antiderivatives are more commonly known as indefinite integrals. Another way to represent the antiderivative is using the integral sign:

F(x)=∫f(x)dx.F(x) = \int f(x) dx.

Note that antiderivatives have no bounds. Instead of finding a value, the antiderivative finds a function whose derivative calculates to the original function.

This is the key difference:

  • A definite integral has bounds and returns a number.
  • An indefinite integral has no bounds and returns a family of functions.

For indefinite integrals, you always have to add a constant of integration +C+C. The +C+C is necessary because derivatives lose constant information. For example,

ddx(x2)=2x,ddx(x2+5)=2x,ddx(x2−11)=2x.\frac{d}{dx}(x^2)=2x, \qquad \frac{d}{dx}(x^2+5)=2x, \qquad \frac{d}{dx}(x^2-11)=2x.

So when reversing the derivative of 2x2x, all of those possibilities must be included:

∫2x dx=x2+C.\int 2x\,dx=x^2+C.

Example. Compute ∫(3x2+4x) dx.\displaystyle\int \bigl(3x^2+4x\bigr)\,dx.

Apply the reverse power rule to each term, raising the exponent by one and dividing:

∫3x2 dx=x3,∫4x dx=2x2.\int 3x^2\,dx = x^3, \qquad \int 4x\,dx = 2x^2.

Combining the pieces and adding the constant of integration gives

∫(3x2+4x) dx=x3+2x2+C.\int \bigl(3x^2+4x\bigr)\,dx = x^3 + 2x^2 + C.

The +C+C is required because every constant has derivative zero, so the antiderivative is only determined up to a constant.


Before integrating, check the form of the integrand and the bounds. They can suggest a substitution, a symmetry, or another way to simplify the calculation.

Symmetry can make some definite integrals much faster, especially on intervals of the form [−a,a][-a,a].

  • An even function satisfies f(−x)=f(x)f(-x)=f(x). Its graph is symmetric across the yy-axis.
  • An odd function satisfies f(−x)=−f(x)f(-x)=-f(x). Its graph is symmetric about the origin.

On a symmetric interval,

∫−aaf(x) dx=2∫0af(x) dx\int_{-a}^{a} f(x)\,dx=2\int_0^a f(x)\,dx

for even functions, and

∫−aaf(x) dx=0\int_{-a}^{a} f(x)\,dx=0

for odd functions.

Example. Evaluate

∫−33(x2+1) dx\int_{-3}^{3}(x^2+1)\,dx

using symmetry.

The function x2+1x^2+1 is even, so

∫−33(x2+1) dx=2∫03(x2+1) dx.\int_{-3}^{3}(x^2+1)\,dx = 2\int_0^3(x^2+1)\,dx.

Example. Evaluate

∫−4π4πsin⁡3xcos⁡4x dx.\int_{-4\pi}^{4\pi}\sin^3{x}\cos^4{x}\,dx.

The function sin⁡3xcos⁡4x\sin^3{x}\cos^4{x} is odd because

sin⁡3(−x)cos⁡4(−x)=−sin⁡3xcos⁡4x.\sin^3(-x)\cos^4(-x)=-\sin^3{x}\cos^4{x}.

If you don’t see why, make sure to brush up on your trig rules. Since the interval is symmetric,

∫−4π4πsin⁡3xcos⁡4x dx=0.\int_{-4\pi}^{4\pi}\sin^3{x}\cos^4{x}\,dx=0.

King’s rule and Queen’s rule are symmetry shortcuts for definite integrals. King’s rule says that

∫abf(x) dx=∫abf(a+b−x) dx.\int_a^b f(x)\,dx = \int_a^b f(a+b-x)\,dx.

This comes from the substitution u=a+b−xu=a+b-x. It reflects the input across the midpoint of the interval. The most common move is to write the integral once normally, write it again using King’s rule, and then add the two versions.

Queen’s rule is a related way to split an interval in half:

∫02af(x) dx=∫0a[f(x)+f(2a−x)] dx.\int_0^{2a} f(x)\,dx = \int_0^a \left[f(x)+f(2a-x)\right]\,dx.

This is useful when the whole interval has symmetry around x=ax=a, but adding the two mirrored pieces is easier than working on the full interval. Both rules are relatively easy to prove, and it is left to the reader to prove.

Example. Evaluate

I=∫0π/2sin⁡xsin⁡x+cos⁡x dx.I=\int_0^{\pi/2}\frac{\sin x}{\sin x+\cos x}\,dx.

Here a=0a=0 and b=π2b=\frac{\pi}{2}, so King’s rule uses

x↦π2−x.x\mapsto \frac{\pi}{2}-x.

Then

I=∫0π/2sin⁡(π2−x)sin⁡(π2−x)+cos⁡(π2−x) dx.I = \int_0^{\pi/2} \frac{\sin\left(\frac{\pi}{2}-x\right)} {\sin\left(\frac{\pi}{2}-x\right)+\cos\left(\frac{\pi}{2}-x\right)} \,dx.

Use sin⁡(π2−x)=cos⁡x\sin\left(\frac{\pi}{2}-x\right)=\cos x and cos⁡(π2−x)=sin⁡x\cos\left(\frac{\pi}{2}-x\right)=\sin x:

I=∫0π/2cos⁡xsin⁡x+cos⁡x dx.I = \int_0^{\pi/2}\frac{\cos x}{\sin x+\cos x}\,dx.

Add this to the original integral:

2I=∫0π/2sin⁡x+cos⁡xsin⁡x+cos⁡x dx=∫0π/21 dx=π2.2I = \int_0^{\pi/2} \frac{\sin x+\cos x}{\sin x+\cos x}\,dx = \int_0^{\pi/2}1\,dx = \frac{\pi}{2}.

Therefore

I=π4.I=\frac{\pi}{4}.

Example. Evaluate

I=∫0πxsin⁡x1+cos⁡2x dx.I=\int_0^\pi \frac{x\sin x}{1+\cos^2 x}\,dx.

The interval [0,π][0,\pi] has midpoint π2\frac{\pi}{2}, so write it in Queen’s-rule form with 2a=π2a=\pi:

I=∫0π/2[xsin⁡x1+cos⁡2x+(π−x)sin⁡(π−x)1+cos⁡2(π−x)] dx.I = \int_0^{\pi/2} \left[ \frac{x\sin x}{1+\cos^2 x} + \frac{(\pi-x)\sin(\pi-x)}{1+\cos^2(\pi-x)} \right]\,dx.

Use

sin⁡(π−x)=sin⁡x,cos⁡(π−x)=−cos⁡x.\sin(\pi-x)=\sin x, \qquad \cos(\pi-x)=-\cos x.

Since cos⁡2(π−x)=cos⁡2x\cos^2(\pi-x)=\cos^2x, the integrand becomes

xsin⁡x1+cos⁡2x+(π−x)sin⁡x1+cos⁡2x=πsin⁡x1+cos⁡2x.\frac{x\sin x}{1+\cos^2 x} + \frac{(\pi-x)\sin x}{1+\cos^2x} = \frac{\pi\sin x}{1+\cos^2x}.

So

I=π∫0π/2sin⁡x1+cos⁡2x dx.I = \pi\int_0^{\pi/2}\frac{\sin x}{1+\cos^2x}\,dx.

Use u=cos⁡xu=\cos x, so du=−sin⁡x dxdu=-\sin x\,dx. The bounds change from x=0x=0 to u=1u=1 and from x=π2x=\frac{\pi}{2} to u=0u=0:

I=π∫10−11+u2 du=π∫0111+u2 du.I = \pi\int_1^0\frac{-1}{1+u^2}\,du = \pi\int_0^1\frac{1}{1+u^2}\,du.

Therefore

I=π[arctan⁡u]01=π⋅π4=π24.I = \pi\left[\arctan u\right]_0^1 = \pi\cdot\frac{\pi}{4} = \frac{\pi^2}{4}.

If part of the integrand is the derivative of another part, let

u=g(x),du=g′(x) dx.u = g(x), \qquad du = g'(x)\,dx.

Then

∫f(g(x))g′(x) dx=∫f(u) du.\int f(g(x))g'(x)\,dx = \int f(u)\,du.

Example. Compute ∫2x(x2+1)3 dx.\displaystyle\int 2x\bigl(x^2+1\bigr)^3\,dx.

The factor 2x2x is the derivative of x2+1x^2+1, which suggests the substitution

u=x2+1,du=2x dx.u = x^2+1, \qquad du = 2x\,dx.

Rewriting the integral in terms of uu removes the 2x dx2x\,dx cleanly:

∫2x(x2+1)3 dx=∫u3 du=u44+C.\int 2x\bigl(x^2+1\bigr)^3\,dx = \int u^3\,du = \frac{u^4}{4} + C.

Substituting back u=x2+1u = x^2+1 gives

∫2x(x2+1)3 dx=(x2+1)44+C.\int 2x\bigl(x^2+1\bigr)^3\,dx = \frac{\bigl(x^2+1\bigr)^4}{4} + C.

For definite integrals, there are two clean options:

  • change the bounds into uu-bounds and never return to xx,
  • or find an antiderivative in terms of xx and use the original bounds.

Changing the bounds often keeps the work cleaner.

Example. Compute

∫022x(x2+1)3 dx.\int_0^2 2x(x^2+1)^3\,dx.

Use

u=x2+1,du=2x dx.u=x^2+1, \qquad du=2x\,dx.

Now change the bounds. When x=0x=0,

u=02+1=1.u=0^2+1=1.

When x=2x=2,

u=22+1=5.u=2^2+1=5.

So

∫022x(x2+1)3 dx=∫15u3 du.\int_0^2 2x(x^2+1)^3\,dx = \int_1^5 u^3\,du.

Evaluate:

∫15u3 du=[u44]15=54−144=6244=156.\int_1^5 u^3\,du = \left[\frac{u^4}{4}\right]_1^5 = \frac{5^4-1^4}{4} = \frac{624}{4} =156.

Roots, long division, and completing the square

Section titled “Roots, long division, and completing the square”

Before using a heavier technique, simplify the integrand:

  • Roots may become powers, such as x=x1/2\sqrt{x}=x^{1/2}.
  • Improper rational functions should use polynomial long division first.
  • Quadratic denominators may need completing the square.

Example. Compute

∫x2+1x+1 dx.\int \frac{x^2+1}{x+1}\,dx.

The numerator degree is larger than the denominator degree, so divide:

x2+1x+1=x−1+2x+1.\frac{x^2+1}{x+1}=x-1+\frac{2}{x+1}.

Now integrate term by term:

∫x2+1x+1 dx=∫(x−1+2x+1) dx.\int \frac{x^2+1}{x+1}\,dx = \int\left(x-1+\frac{2}{x+1}\right)\,dx.

Therefore

∫x2+1x+1 dx=x22−x+2ln⁡∣x+1∣+C.\int \frac{x^2+1}{x+1}\,dx = \frac{x^2}{2}-x+2\ln\lvert x+1\rvert+C.

Example. Compute

∫1x2+4x+8 dx.\int \frac{1}{x^2+4x+8}\,dx.

Complete the square in the denominator:

x2+4x+8=(x+2)2+4.x^2+4x+8=(x+2)^2+4.

So

∫1x2+4x+8 dx=∫1(x+2)2+22 dx.\int \frac{1}{x^2+4x+8}\,dx = \int \frac{1}{(x+2)^2+2^2}\,dx.

Use the inverse tangent pattern:

∫1u2+a2 du=1aarctan⁡(ua)+C.\int \frac{1}{u^2+a^2}\,du=\frac{1}{a}\arctan\left(\frac{u}{a}\right)+C.

With u=x+2u=x+2 and a=2a=2,

∫1x2+4x+8 dx=12arctan⁡(x+22)+C.\int \frac{1}{x^2+4x+8}\,dx = \frac12\arctan\left(\frac{x+2}{2}\right)+C.

Integrals involving powers of sine and cosine usually depend on whether one power is odd.

Example. Compute

∫sin⁡3xcos⁡2x dx.\int \sin^3 x\cos^2 x\,dx.

Because the sine power is odd, save one sine factor:

sin⁡3x=sin⁡2xsin⁡x.\sin^3x=\sin^2x\sin x.

Use sin⁡2x=1−cos⁡2x\sin^2x=1-\cos^2x:

∫sin⁡3xcos⁡2x dx=∫(1−cos⁡2x)cos⁡2xsin⁡x dx.\int \sin^3x\cos^2x\,dx = \int (1-\cos^2x)\cos^2x\sin x\,dx.

Let

u=cos⁡x,du=−sin⁡x dx.u=\cos x, \qquad du=-\sin x\,dx.

Then

∫(1−cos⁡2x)cos⁡2xsin⁡x dx=−∫(1−u2)u2 du.\int (1-\cos^2x)\cos^2x\sin x\,dx = -\int (1-u^2)u^2\,du.

Integrate:

−∫(u2−u4) du=−u33+u55+C.-\int (u^2-u^4)\,du =-\frac{u^3}{3}+\frac{u^5}{5}+C.

Substitute back:

∫sin⁡3xcos⁡2x dx=−cos⁡3x3+cos⁡5x5+C.\int \sin^3x\cos^2x\,dx =-\frac{\cos^3x}{3}+\frac{\cos^5x}{5}+C.

Trig substitution is useful when radicals contain expressions matching Pythagorean identities.

ExpressionSubstitutionIdentity used
a2−x2\sqrt{a^2-x^2}x=asin⁡θx=a\sin\theta1−sin⁡2θ=cos⁡2θ1-\sin^2\theta=\cos^2\theta
a2+x2\sqrt{a^2+x^2}x=atan⁡θx=a\tan\theta1+tan⁡2θ=sec⁡2θ1+\tan^2\theta=\sec^2\theta
x2−a2\sqrt{x^2-a^2}x=asec⁡θx=a\sec\thetasec⁡2θ−1=tan⁡2θ\sec^2\theta-1=\tan^2\theta

This technique should be immediately used when you see something that resembles Pythagorean theorem, like square roots with x2x^2 in them.

Example. Compute

∫14−x2 dx.\int \frac{1}{\sqrt{4-x^2}}\,dx.

The radical matches a2−x2\sqrt{a^2-x^2} with a=2a=2, so use

x=2sin⁡θ,dx=2cos⁡θ dθ.x=2\sin\theta, \qquad dx=2\cos\theta\,d\theta.

Then

4−x2=4−4sin⁡2θ=4cos⁡2θ=2cos⁡θ\sqrt{4-x^2} = \sqrt{4-4\sin^2\theta} = \sqrt{4\cos^2\theta} =2\cos\theta

on the usual substitution interval. The integral becomes

∫2cos⁡θ2cos⁡θ dθ=∫1 dθ=θ+C.\int \frac{2\cos\theta}{2\cos\theta}\,d\theta = \int 1\,d\theta =\theta+C.

Since x=2sin⁡θx=2\sin\theta,

θ=arcsin⁡(x2).\theta=\arcsin\left(\frac{x}{2}\right).

Therefore

∫14−x2 dx=arcsin⁡(x2)+C.\int \frac{1}{\sqrt{4-x^2}}\,dx = \arcsin\left(\frac{x}{2}\right)+C.

Integration by parts comes from the product rule:

∫u dv=uv−∫v du.\int u\,dv=uv-\int v\,du.

It is useful for products such as polynomial times exponential, polynomial times trig, or logarithmic functions.

For example, in

∫xex dx,\int x e^x\,dx,

choose u=xu=x and dv=ex dxdv=e^x\,dx. Then du=dxdu=dx and v=exv=e^x, so

∫xex dx=xex−∫ex dx=xex−ex+C.\int x e^x\,dx=xe^x-\int e^x\,dx=xe^x-e^x+C.

Example. Compute

∫xln⁡x dx.\int x\ln x\,dx.

By LIATE, choose

u=ln⁡x,dv=x dx.u=\ln x, \qquad dv=x\,dx.

Then

du=1x dx,v=x22.du=\frac{1}{x}\,dx, \qquad v=\frac{x^2}{2}.

Apply integration by parts:

∫xln⁡x dx=x22ln⁡x−∫x22⋅1x dx.\int x\ln x\,dx =\frac{x^2}{2}\ln x-\int \frac{x^2}{2}\cdot\frac{1}{x}\,dx.

Simplify the remaining integral:

=x22ln⁡x−12∫x dx=x22ln⁡x−x24+C.=\frac{x^2}{2}\ln x-\frac12\int x\,dx =\frac{x^2}{2}\ln x-\frac{x^2}{4}+C.

The tabular method is a faster way to organize repeated integration by parts when one factor eventually differentiates to 00, such as a polynomial.

It is best for integrals of the form

∫(polynomial)(easy-to-integrate function) dx.\int (\text{polynomial})(\text{easy-to-integrate function})\,dx.

Make two columns:

  1. differentiate the polynomial until it becomes 00,
  2. integrate the other factor the same number of times.

Then multiply along the diagonals and alternate signs +,−,+,−,…+,-,+,-,\dots. This is the same integration by parts formula repeated several times, just organized in a table.

Example. Use the tabular method to compute

∫x2ex dx.\int x^2e^x\,dx.

Differentiate x2x^2 repeatedly and integrate exe^x repeatedly:

signDI+x2ex−2xex+2ex−0ex\begin{array}{c|c|c} \text{sign} & D & I \\\hline + & x^2 & e^x \\ - & 2x & e^x \\ + & 2 & e^x \\ - & 0 & e^x \end{array}

Multiply diagonally with alternating signs:

∫x2ex dx=x2ex−2xex+2ex+C.\int x^2e^x\,dx = x^2e^x-2xe^x+2e^x+C.

Factor if desired:

∫x2ex dx=ex(x2−2x+2)+C.\int x^2e^x\,dx=e^x(x^2-2x+2)+C.

Partial fractions break a rational function into simpler rational pieces. Before using them, make sure the numerator degree is smaller than the denominator degree. If not, divide first.

For a denominator like

(x−a)(x−b),(x-a)(x-b),

write

P(x)(x−a)(x−b)=Ax−a+Bx−b.\frac{P(x)}{(x-a)(x-b)} =\frac{A}{x-a}+\frac{B}{x-b}.

Then solve for the constants and integrate each term. For more details, you can look at Unit 13 of AP Precalculus for a reminder of how to solve partial fractions.

Example. Compute

∫5x+1x2−x−2 dx.\int \frac{5x+1}{x^2-x-2}\,dx.

Factor the denominator:

x2−x−2=(x−2)(x+1).x^2-x-2=(x-2)(x+1).

Set up partial fractions:

5x+1(x−2)(x+1)=Ax−2+Bx+1.\frac{5x+1}{(x-2)(x+1)} = \frac{A}{x-2}+\frac{B}{x+1}.

Multiply through by (x−2)(x+1)(x-2)(x+1):

5x+1=A(x+1)+B(x−2).5x+1=A(x+1)+B(x-2).

Use convenient values. If x=2x=2, then

11=3A⟹A=113.11=3A \quad\Longrightarrow\quad A=\frac{11}{3}.

If x=−1x=-1, then

−4=−3B⟹B=43.-4=-3B \quad\Longrightarrow\quad B=\frac{4}{3}.

Therefore

∫5x+1x2−x−2 dx=∫(11/3x−2+4/3x+1) dx.\int \frac{5x+1}{x^2-x-2}\,dx = \int\left(\frac{11/3}{x-2}+\frac{4/3}{x+1}\right)\,dx.

So

∫5x+1x2−x−2 dx=113ln⁡∣x−2∣+43ln⁡∣x+1∣+C.\int \frac{5x+1}{x^2-x-2}\,dx = \frac{11}{3}\ln\lvert x-2\rvert+\frac{4}{3}\ln\lvert x+1\rvert+C.

Definition. An improper integral is a definite integral where ordinary endpoint evaluation does not make sense. This happens in two main ways:

  • the interval is infinite, such as [1,∞)[1,\infty),
  • the integrand becomes unbounded, such as 1/x1/x near x=0x=0.

Improper integrals are not evaluated by simply plugging in infinity or plugging in a vertical asymptote. They must be rewritten as limits.

For an infinite interval,

∫1∞1x2 dx=lim⁡b→∞∫1b1x2 dx.\int_1^\infty \frac{1}{x^2}\,dx =\lim_{b\to\infty}\int_1^b\frac{1}{x^2}\,dx.

For an infinite discontinuity inside the interval, split at the discontinuity. For example,

∫011x dx=lim⁡a→0+∫a11x dx.\int_0^1 \frac{1}{\sqrt{x}}\,dx = \lim_{a\to0^+}\int_a^1 \frac{1}{\sqrt{x}}\,dx.

The integral converges if the limit is finite and diverges otherwise. If an improper integral has two problematic endpoints or an interior discontinuity, every required limit must converge.

Convergence means the limiting accumulated value is finite. Divergence means the accumulated value does not settle to a finite number.

Example. Evaluate ∫1∞1x2 dx.\displaystyle\int_1^\infty \frac{1}{x^2}\,dx.

Because the interval is infinite, rewrite the integral as a limit with a finite upper endpoint bb:

∫1∞1x2 dx=lim⁡b→∞∫1bx−2 dx.\int_1^\infty \frac{1}{x^2}\,dx =\lim_{b\to\infty}\int_1^b x^{-2}\,dx.

Compute the inner integral using ∫x−2 dx=−x−1\int x^{-2}\,dx=-x^{-1}:

∫1bx−2 dx=[−1x]1b=−1b+1=1−1b.\int_1^b x^{-2}\,dx =\left[-\frac1x\right]_1^b =-\frac1b+1 =1-\frac1b.

Now take the limit:

lim⁡b→∞(1−1b)=1.\lim_{b\to\infty}\left(1-\frac1b\right)=1.

The limit is finite, so the improper integral converges and its value is 11.


Integration questions usually ask you to connect a rate, an amount, and an interval. The central idea is:

new amount=initial amount+accumulated change.\text{new amount}=\text{initial amount}+\text{accumulated change}.

So if A′(t)=r(t)A'(t)=r(t), then

A(b)=A(a)+∫abr(t) dt.A(b)=A(a)+\int_a^b r(t)\,dt.