Techniques of Integration

☰ Contents

Differentiation follows rules that always work. Integration has no single procedure, so it is learned as a set of techniques, and the skill is reading the shape of the integrand and recognizing which technique it calls for.

What is integration?

Integration asks the reverse of differentiation: which function has this derivative? That function is an antiderivative, and every answer can be checked by differentiating it. For a power of x, add one to the power and divide by the new power, so 6x² integrates to 2x³ + C, because 6 ÷ 3 = 2. The rule undoes the power rule exactly: differentiating 2x³ brings down the 3, which cancels the division, and lowers the power back to 2. A constant factor stays outside, and a sum is integrated term by term, so 4x + 3 gives 2x² + 3x + C, where + C covers any constant that differentiated away. Only x⁻¹ breaks the rule, since the new power would be 0; 1/x integrates to ln|x| + C instead. Differentiating 2x³ + C gives back 6x², since 3 × 2 = 6 and the C disappears. See The antiderivative.

xyC = −1F′(1) = 2x = 2−2−112−2246

the tangent at x = 1 has gradient 2x = 2 for every C: shifting F up or down changes F, never F′, so ∫ 2x dx is the whole family x² + C

Slide the curve up and down and watch the tangent's gradient

3x32
first, put one back on the power
Differentiating took one off the power, so going back puts one on. Full lesson: The Antiderivative

x³ integrates to x⁴/4 by the same rule. See Integrating powers.

x
The rule fails only at n = −1, where dividing by n+1 would divide by zero. Full lesson: Integrating Powers

Now you

integrate it

Integrate 40x^4

integrate it

Integrate 20x^4

Why is there always a + C?

Differentiating removes any constant term, so integration cannot tell which constant was there, and + C stands for all of them. The functions x², x² + 7 and x² − 100 all differentiate to 2x, so the integral of 2x is the family x² + C, one parallel curve per value of C. Shifting a curve up or down never tilts it, so every member has the same gradient at the same x. One extra fact picks out a single curve: through (2, 9), 9 = 4 + C, so C = 5 and the function is x² + 5. In a differential equation that fact is the initial condition. A definite integral needs no C, because it cancels in F(b) − F(a). Substituting x = 2 into x² + 5 gives 4 + 5 = 9, the required height, and the gradient there is 2 × 2 = 4.

xy(1, 3)C = −2y(1) = 1 + C = −1−2−112−4−2246

y(1) = 1 + C = −1, not 3: this member of the family misses the point, so the initial condition rules it out

Drag C until the curve passes through (1, 3)

xy
f'(x) = 2x integrates to x² + C — a whole family of curves, one per C. Full lesson: Finding the Constant of Integration

See Finding the constant of integration.

subtract the 1
C = 3
Substitute the point in: 4 = 1² + C, so C = 3. Full lesson: Finding the Constant of Integration

What does the integral sign actually say?

The sign ∫ is a stretched S, for sum, and ∫ f(x) dx means: add up thin slivers of height f(x) and width dx. The function f(x) is the integrand, and the numbers at the bottom and top are the limits of integration, where the adding starts and stops. The integral of 3 from x = 1 to x = 5 adds slivers of height 3 across a width of 4, since 5 − 1 = 4, so it totals 3 × 4 = 12, a rectangle's area. The notation records how the answer is built: height times width, summed, with the widths shrunk until the sum is exact. The dx names the variable being summed, which matters when other letters appear: integrating with dx holds any y constant. With no limits, the sign asks for an antiderivative plus a constant, not a number. The antiderivative 3x gives 15 − 3 = 12 as well. See Reading the integral sign.

xyf(x) = 1.44Δx = 0.3x = 1.2f(x)·Δx = 1.44 × 0.3 = 0.432∫₀² x² dx = 8/3

the sign ∫ is an S for sum: each sliver is height f(x) × width Δx = 0.432, and the integral adds them across the interval

Narrow the sliver to dx = 0.01

xy
One sliver is f(x) dx: height f(x), times a width dx too small to see. Full lesson: Reading the Integral Sign

dx has a meaning of its own. dy/dx began as a rise over a run, and the pieces can be separated: if y = x², then dy = 2x dx. Substitution depends on this. See Differentials.

each side is a tiny amount
dy = 2x dx
Treat the pieces separately: if y = x², the tiny rise dy is 2x times dx. Full lesson: Differentials

Why does an integral measure area?

A definite integral is the limit of a sum of rectangles: slice the region into strips of width Δx, treat each as a rectangle of height f(x), and add the areas f(x) Δx. For y = x from 0 to 2, four strips of width 1/2 with right-edge heights give (1/2 + 1 + 3/2 + 2) × 1/2 = 5/2, over the true area, 2. The fundamental theorem skips the strips: the area from a to b is F(b) − F(a) for any antiderivative F, because the area up to x grows at the rate f(x). A total area needs one more step, since regions below the axis count as negative: split at each crossing and add the sizes. For y = x − 1 from 0 to 2, the integral is 0, but the area is 1/2 + 1/2 = 1. The triangle under y = x has area 1/2 × 2 × 2 = 2, matching x²/2 at 2. See The definite integral.

12xyn = 4leftrightmidpoint

n = 4, so the error is 1.083

Increase n until the Riemann sum converges on the exact area

Slice the region into rectangles and add them. The total is close, but visibly coarse. Full lesson: The Definite Integral

Each height can be read at the left edge, the right edge or the middle of its strip. On a rising curve the left sum underestimates and the right sum overestimates. In sigma notation the sum is Σ f(xᵢ) Δx from i = 1 to n; let n run to infinity and Σ becomes ∫ and Δx becomes dx. See Left, right and midpoint Riemann sums and The Riemann sum in sigma notation.

f risingthe left edge is the short side of each stripleft sum under, right sum over
On a rising curve every left rectangle falls short, so the left sum underestimates. Full lesson: Left, Right and Midpoint Riemann Sums

Let A(x) be the area under the curve up to x. Increase x a little and the area grows by a thin strip of height f(x), so A differentiates to f. See The fundamental theorem of calculus.

xy
That growth is a thin strip of height f(x), so the area function differentiates to f. Full lesson: The Fundamental Theorem of Calculus

Area below the axis counts as negative. The arch of sin x from 0 to π has integral 2, from π to 2π the integral is −2, and over the whole cycle it is 0. For the total area, split at the crossings and add the sizes: 2 + 2 = 4. See Area below the axis.

xy
Integrate over the whole cycle and the two halves cancel to 0 — the integral is a signed count. Full lesson: Area Below the Axis

Swapping the limits changes the sign, a constant factor comes outside, and a to b plus b to c joins into a to c. See Properties of the definite integral.

Now you

xy

∫ 2x dx from 0 to 4

xy

∫ 2x dx from 0 to 5

How do you integrate a function inside another function?

Substitution is the chain rule read backwards: when an integral contains the derivative of an inside function as a factor, name the inside u, replace every x, and integrate in u. For the integral of 3x²(x³ + 2)⁴, let u = x³ + 2, so du = 3x² dx and the integral becomes ∫ u⁴ du = u⁵/5 + C, which is (x³ + 2)⁵/5 + C. The factor 3x² is absorbed exactly by du, leaving a plain power. A definite integral changes one step: convert the limits to u and never return to x. From x = 0 to 1, u runs from 2 to 3, so the integral is (3⁵ − 2⁵)/5, and 243 − 32 = 211, giving 211/5. The right u is usually the expression inside a bracket or under a root, and it leaves no x behind. Differentiating (x³ + 2)⁵/5 by the chain rule restores the factor 3x². See Integration by substitution.

xu = x²00.511.5201234Δx = 0.2Δu = 0.52Δu / Δx = 2.6 · 2x = 2.4

du = 2x dx: the u-line stretches the interval by 2x = 2.4, which is why ∫ 2x cos(x²) dx becomes ∫ cos u du with the 2x used up

Slide the interval to where du and dx have the same length

  1. Choose u, usually the expression inside the bracket or under the root.
  2. Find du/dx, and write dx in terms of du.
  3. Replace every x. If one is left over, u was the wrong choice.
  4. Integrate in u, then write the x expression back. For a definite integral, convert the limits instead.

∫ 2x(x² + 1)⁵ dx: 2x is the derivative of x² + 1, so let u = x² + 1 and du = 2x dx. The integral becomes ∫ u⁵ du = u⁶/6 + C = (x² + 1)⁶/6 + C.

u’s own derivative, as a differential
du = 2x dxan ordinary power in u
u was only ever a name
Replace 2x dx with du, integrate the power, then write x² + 1 back in place of u. Full lesson: Integration by Substitution

When the inside is linear, ax + b, its derivative is the constant a and there is a shortcut: integrate as if the inside were plain x, then divide by a. ∫ cos 3x dx = (1/3) sin 3x + C. A curved inside has a derivative that changes with x, so the shortcut does not apply. See Integrating f(ax + b).

the usual answer, divided by a
The rule: integrate as if the inside were plain x, then divide by its coefficient a. Full lesson: Integrating f(ax + b)

Now you

what does this come to?

∫ e^(5x) dx

what does this come to?

∫ cos 2x dx

How do you integrate a product?

Integration by parts is the product rule read backwards: ∫ u dv = uv − ∫ v du. Choose u as the factor that simplifies when differentiated. For ∫ x cos x dx, let u = x and dv = cos x dx, so du = dx and v = sin x, and the integral is x sin x − ∫ sin x dx, which is x sin x + cos x + C. The formula is the product rule for uv, integrated and rearranged. The new integral must be easier, which is why a polynomial against eˣ, sin x or cos x is u: differentiating lowers its power. A higher power needs more rounds, so x² eˣ takes two and gives (x² − 2x + 2)eˣ + C. From 0 to π the first answer gives (0 − 1) − (0 + 1) = −2, and differentiating x sin x + cos x returns x cos x. See Integration by parts.

uv∫u dv = 3.89∫v du = 1.94uv = 5.83

the area under the curve is ∫v du and the area to its left is ∫u dv; together they are the box uv, which is ∫u dv = uv − ∫v du

Drag the corner and try to make the two areas fail to fill the box

(uv)′ = u′v + uv'take u′v to the other sideuv' = (uv)′ − u′vintegrate both sides; dv is v′ dx, du is u′ dx
Integrate the product rule and rearrange: your integral swaps for a different one. Full lesson: Integration by Parts
choose uit only helps if the new integral is easierthe part that simplifies
It only helps if the new integral is easier, so choose u as the part that simplifies. Full lesson: Integration by Parts

∫ x eˣ dx: let u = x and dv = eˣ dx, so du = dx and v = eˣ. Then ∫ x eˣ dx = x eˣ − ∫ eˣ dx = x eˣ − eˣ + C. If the new integral is harder than the old one, swap the choice of u.

∫ x³ ln x dx∫ x eˣ dx∫ x cos x dx∫ x³ ln x dxu = ln x, dv = x³ dxu = x³, dv = ln x dxuv − ∫ v du =x³(x ln x − x) − ∫ 3x²(x ln x − x) dxa harder integral

u = x³ leaves uv − ∫ v du with a harder integral than the original — the power went up or the awkward factor stayed — so swap u and dv

Choose the u that leaves a simpler integral

∫ ln x dx is done by parts with u = ln x and dv = 1 dx. ∫ eˣ sin x dx returns to itself after two rounds; treat the original integral as an unknown and solve for it.

Now you

what does this come to?

For ∫ x eˣ dx, the best choice of u is

what does this come to?

∫ x eˣ dx =

How do you integrate trigonometric functions?

Integration reverses differentiation, so cos x integrates to sin x + C, and sin x to −cos x + C, since cos x differentiates to −sin x. Reversing other standard results gives sec²x → tan x and sec x tan x → sec x. With the angle in radians, the area under cos x from 0 to π/2 is sin(π/2) − sin 0, which is 1 − 0 = 1. The minus sign on the cosine is the part most often lost. The results need radians because only there does sin x differentiate to exactly cos x; in degrees each would carry a factor of 180/π. Powers and products change the method. sin²x is not a standard derivative, so rewrite it with a double angle identity first, and sin x cos x becomes (sin 2x)/2, which integrates to −(cos 2x)/4 + C. Differentiating −cos x + C returns sin x, the integrand, with the C gone.

½yπ/2π3π/22π1y = cos²xX/2 = 1.1 · sin 2X / 4 = −0.238 · ∫ = 0.862

cos²x = ½ + ½ cos 2x: the ½ integrates to X/2 and the wave to sin 2X / 4 = −0.238, so the green and red pieces do not yet cancel

Drag the limit to where the wave cancels

sin xcos x−sin x−cos x
Walk the ring backwards to integrate, and that is where the minus sign comes from. Full lesson: Integrating Trigonometric Functions

sin²x is not the derivative of any standard function, so rewrite it with the double angle formula: sin²x = (1 − cos 2x)/2, and ∫ sin²x dx = x/2 − (sin 2x)/4 + C. cos²x = (1 + cos 2x)/2 integrates the same way. The identities are in radians and trigonometric identities; see Integrating sin² and cos².

the double angle formula for cosine
rearranged for the square
The double angle formula rearranges: sin²x = (1 − cos 2x) / 2 — the square is gone. Full lesson: Integrating sin² and cos²

tan x is sin x over cos x, and the numerator is minus the derivative of the denominator, so ∫ tan x dx = −ln|cos x| + C = ln|sec x| + C. See Integrating sec²x, sec x tan x and tan x.

the numerator is minus the derivative of the denominator
sin x = −(cos x)′f′ over f, with one minus−ln|cos x| + c
tan x itself is sin over cos — an f' over f logarithm that carries one minus sign. Full lesson: Integrating sec²x, sec x tan x and tan x

How do you integrate exponentials, logarithms and fractions?

eˣ is its own derivative, so ∫ eˣ dx = eˣ + C, and e^(2x) integrates to e^(2x)/2 + C. Since ln x differentiates to 1/x, the integral of 1/x is ln|x| + C; the modulus keeps it defined for negative x. The logarithm fills the gap the power rule leaves, because raising the power −1 by one would mean dividing by 0. A fraction whose top is the derivative of its bottom integrates to the log of the bottom, since the chain rule makes f'(x)/f(x) the derivative of ln f(x). So 3x²/(x³ + 1) integrates to ln|x³ + 1| + C. A bottom that factors is split into partial fractions first. Stretching explains why ln 4 − ln 2 = ln 2: the strip under 1/x from 2 to 4 is the strip from 1 to 2 made twice as wide and half as tall, and 2 × 1/2 = 1. See Integrating exponentials and logarithms.

x11ab = 3a = 1.5b = 2ln a = 0.405ln b = 0.693ln ab = 1.099y = 1/x

the region from a to ab is the region from 1 to b stretched a times wider and squashed a times shorter — the same area — so area(1 → ab) = area(1 → a) + area(1 → b)

Set a and b so that ab = 6, and compare the three areas

x
But ln x differentiates to 1 over x, so it fills exactly that gap. Full lesson: Integrating Exponentials and Logarithms

Differentiating ln f(x) by the chain rule gives f'(x)/f(x). Read backwards: when the numerator is the derivative of the denominator, the integral is ln of the denominator. ∫ 2x/(x² + 1) dx = ln(x² + 1) + C, because 2x is the derivative of x² + 1. Differentiate the denominator first and check whether the numerator matches. See Integrals of f' over f.

the numerator must be exactly the derivative of the denominator
ln|f(x)| + c
Read backwards: when the numerator is the derivative of the denominator, the integral is ln of the denominator. Full lesson: Integrals of f′ over f

When the denominator factors instead, split into partial fractions. Write 1/((x − 1)(x + 1)) as A/(x − 1) + B/(x + 1), clear the denominators, then substitute x = 1 to find A and x = −1 to find B. Each piece is a constant over a linear bracket, so each integrates to a logarithm. A repeated factor needs one fraction for each power; a quadratic that will not factor keeps a numerator Ax + B. See Integration by partial fractions.

each piece is a log
½ ln|x−1| − ½ ln|x+1| + c
Each piece is a constant over a linear bracket, so each integrates to a logarithm. Full lesson: Integration by Partial Fractions

Now you

check the numerator against the denominator

∫ 3x² / (x³ + 5) dx

top ÷ bottom dx
when is this a log?

The pattern needs the numerator to be

Which integrals give inverse functions?

Two derivatives from the rules of differentiation, read in reverse, give inverse trigonometric answers. Since tan⁻¹x differentiates to 1/(1 + x²), 1/(1 + x²) integrates to tan⁻¹x, and since sin⁻¹x differentiates to 1/√(1 − x²), 1/√(1 − x²) integrates to sin⁻¹x. The area under 1/(1 + x²) from 0 to 1 is the angle whose tangent is 1, π/4. With a² in place of the 1, the answers become (1/a) tan⁻¹(x/a) and sin⁻¹(x/a), so 1/(9 + x²) gives (1/3) tan⁻¹(x/3) + C, as 9 = 3 × 3. Substituting x = tan θ explains it: 1 + x² becomes sec²θ, which cancels dx = sec²θ dθ. Without the root, 1/(1 − x²) needs partial fractions instead. Differentiating (1/3) tan⁻¹(x/3) gives two factors of 1/3, and (1/3) × (1/3) = 1/9 turns the result into 1/(9 + x²); see Integrals that give tan⁻¹ and sin⁻¹.

θ = 45°adjacent = a cos θ = √(a² − x²) = 3.54x = a sin θ = 3.54a = 5

x = a sin θ names the opposite side, so √(a² − x²) is the adjacent side a cos θ, here 3.54

Swing θ until the adjacent side is 3

xy
The shaded area from 0 to 1 is π/4 — the angle whose tangent is 1. Full lesson: Integrals That Give tan⁻¹ and sin⁻¹

When √(a² − x²) appears with no factor of x beside it, substitute x = a sin θ. Then a² − x² = a² cos²θ, the root becomes a cos θ, and dx = a cos θ dθ. A minus inside takes sine; a plus takes tangent. See Choosing a trigonometric substitution.

because 1 + tan²θ = sec²θ
The sign inside decides the substitution: a minus takes sine, a plus takes tangent. Full lesson: Choosing a Trigonometric Substitution

A plus under the root gives a hyperbolic answer: 1/√(x² + 1) integrates to arsinh x, and 1/√(x² − 1) to arcosh x. Both are logarithms, so either form is correct. See Integrals that give arsinh and arcosh.

a minus inside gives inverse sine
a plus inside gives inverse sinh
The sign inside the root decides the family: a minus is circular, a plus is hyperbolic. Full lesson: Integrals That Give arsinh and arcosh

How do you choose?

Read the shape of the integrand first and ask, in order: is it a standard result or a power? Is the top the derivative of the bottom, giving a logarithm? Is an inside function's derivative present, calling for substitution? Is it a product of unrelated families, such as x and eˣ, calling for parts? Is it a fraction whose bottom factors, calling for partial fractions? Is it sin²x or cos²x, calling for a double angle identity? So x/(x² + 4) passes the second test up to a factor of 2 and integrates to (1/2) ln(x² + 4) + C. The early tests are quicker, and one integrand can pass several: x e^(x²) looks like a product, but substitution finishes it in a line. Some, such as e^(−x²), pass none, and a numerical method takes over. Differentiating the log gives 2x over the bottom, and 1/2 × 2 = 1 leaves x/(x² + 4).

∫ x e^(x²) dx∫ x eˣ dx∫ 2x/(x²+1) dxtop = (bottom)′ ?ln of the bottominner derivative outside?substitutiontwo families multiplied?by parts∫ x e^(x²) dx

ask in order: top = derivative of the bottom? inner derivative present? product of two families?

Drag each integral to the question it answers yes to

What you seeWhat to try
Inner function with its derivative presentSubstitution
Bracket or root with a linear insideLinear substitution
Product of two unrelated functionsBy parts
Numerator is the derivative of the denominatorLogarithm directly
Rational function, denominator factorsPartial fractions
sin² or cos²Double angle identity
1 + x² or 1 − x² in the denominator or under a rootInverse trigonometric
Root of a squared difference or sumTrigonometric or hyperbolic substitution

The mistakes worth naming

xx sin x(−x cos x)′ = −cos x + x sin xx = 1: x sin x = 0.84 · (−x cos x)′ = 0.3gap: −cos x = −0.54π/2π3π/22π−44

differentiating the false answer leaves an extra −cos x = −0.54: x cannot be taken outside ∫ x sin x dx, because it varies across the slivers

Find the one place the false answer happens to agree

The rules being reversed are in the rules of differentiation, their uses in applications of integration and polar curves, and the limits behind the definition in limits and continuity.

Your turn

Three to try — tap what you get.

∫ 2x dx

∫ cos x dx

∫ from 0 to 1 of 3x² dx

Questions and answers

Why do you add + C when integrating?
Because differentiation destroys constants, so integration cannot recover them. The functions x squared, x squared plus 7 and x squared minus 100 all have the same derivative, 2x, so integrating 2x gives a whole family of curves differing only by a vertical shift. The + C stands for that unknown shift, and it is only fixed when the question supplies a point the curve passes through.
What is integration by substitution?
It is the chain rule run backwards. Choose an inner expression, call it u, and rewrite the whole integral in terms of u — including converting dx into du, which is the step that makes it work. The substitution succeeds when the derivative of your chosen u is already present as a factor in the integral, and it fails when it is not.
When do you use integration by parts?
When the integrand is a product of two unrelated functions, such as x times e to the x, or x times sin x. It is the product rule reversed, and it trades your integral for a different one, so the whole art is choosing which factor to differentiate. Pick the one that gets simpler when differentiated, since a polynomial eventually reduces to a constant and the new integral becomes easy.
What does the fundamental theorem of calculus say?
That differentiation and integration are inverse operations, and therefore that an area can be found by antidifferentiating. To get the area under a curve between two points, find any antiderivative, evaluate it at both ends and subtract. There is no obvious reason why reversing a gradient calculation should measure an area, and the theorem is the proof that it does.
How do you integrate sin squared x?
Use the double angle identity to remove the square first: sin squared x equals one half of one minus cos 2x. That converts a squared function, which has no direct integral, into a constant plus a plain cosine, which integrates immediately to give x over 2 minus sin 2x over 4. Squares of sine and cosine are always handled this way, and the same identity handles cos squared x.
How do you know which integration technique to use?
Read the shape of the integrand. A function inside another function with its derivative present suggests substitution; a product of unrelated functions suggests parts; a fraction whose top is the derivative of its bottom gives a logarithm; a rational function with a factorable denominator suggests partial fractions; and a root of a squared difference suggests a trigonometric substitution. Recognizing the shape is most of the work.
Mr. Chalk