Tutorials › Calculus III › Evaluating Triple Integrals over Boxes

Triple Integrals and Solid Regions · Tutorial 602 of 999

Evaluating Triple Integrals over Boxes

Evaluate triple integrals over boxes using successive one-variable antiderivatives, and check each stage of the calculation.

Intermediate 10 min read

What You'll Learn

  • Read the bounds and integration order in an iterated integral.
  • Evaluate continuous functions over boxes by integrating one variable at a time.
  • Keep the remaining variables fixed during each inner integration.
  • Work through polynomial and trigonometric integrands with constant bounds.
  • Check antiderivatives and assess whether a result is plausible.
  • Identify and correct common errors in evaluating iterated integrals.

From a Triple Integral to Three Calculations

A triple integral over a rectangular box can be evaluated by carrying out three ordinary one-variable integrations in succession. At each stage, the variable currently being integrated changes; the other variables are held fixed. Once that integration is complete, its bounds are applied, and the result is integrated with respect to the next variable.

This method is useful for finding the signed accumulation of a function throughout a box. The integrand need not be a product of separate functions of \(x\), \(y\), and \(z\); it may include sums or mixed terms such as \(xy\) or \(\sin(x+y+z)\). What matters here is that the function is continuous on the box, so the rectangular-box version of Fubini’s theorem applies.

Definition: A rectangular box in three-dimensional space is a set of the form \(B=[a,b]\times[c,d]\times[e,f]\), where \(a\le b\), \(c\le d\), and \(e\le f\). An iterated integral over \(B\), in the order \(z\), then \(y\), then \(x\), is written
$$ \int_a^b\int_c^d\int_e^f g(x,y,z)\,dz\,dy\,dx. $$
The innermost integral is evaluated first.

Reading the Bounds and Order

In the displayed integral, \(e\) and \(f\) are the bounds for \(z\), \(c\) and \(d\) are the bounds for \(y\), and \(a\) and \(b\) are the bounds for \(x\). Since these are constant bounds, they do not change as the other coordinates vary. The integration order is indicated by the differentials: \(dz\) first, then \(dy\), then \(dx\).

During the \(z\)-integration, \(x\) and \(y\) are treated as constants. After evaluating at the \(z\)-bounds, the resulting expression may depend on \(x\) and \(y\). The \(y\)-integration then treats \(x\) as constant. Finally, the \(x\)-integration produces a number.

Theorem: If \(g\) is continuous on the rectangular box \(B=[a,b]\times[c,d]\times[e,f]\), Fubini’s theorem identifies its triple integral with the iterated integral. In particular, the order \(dz\,dy\,dx\) gives
$$ \iiint_B g(x,y,z)\,dV = \int_a^b\int_c^d\int_e^f g(x,y,z)\,dz\,dy\,dx. $$
Here \(dV\) denotes volume. The bounds are constant, and continuity on the box is the condition that permits this use of Fubini’s theorem.

In practical evaluation, use the Fundamental Theorem of Calculus at each stage: find an antiderivative with respect to the innermost variable, evaluate it at that variable’s upper and lower bounds, and continue with the remaining integral. The same procedure applies to each outer integration.

Why Successive Integration Works

The connection between the triple integral and the sequence of calculations follows directly from the rectangular-box form of Fubini’s theorem and the one-variable Fundamental Theorem of Calculus. To see the calculation structure, first define the inner integral as a function of the still-unintegrated variables:

$$ H(x,y)=\int_e^f g(x,y,z)\,dz. $$

Fubini’s theorem says that the triple integral equals the double iterated integral of \(H\). The next one-variable integration evaluates \(H\) with respect to \(y\), and the last integrates the resulting function with respect to \(x\). The Fundamental Theorem of Calculus justifies each evaluation: if \(G_z(x,y,z)\) is an antiderivative of \(g\) with respect to \(z\), then

$$ H(x,y)=G(x,y,f)-G(x,y,e). $$

This formula means that the inner integration is complete only after both bounds have been substituted and subtracted. The result is a function of the variables not yet integrated. Applying the same principle to those remaining variables completes the calculation.

1
Integrate in \(z\).
Find an antiderivative with respect to \(z\), keeping \(x\) and \(y\) fixed, and evaluate from \(e\) to \(f\).
2
Integrate in \(y\).
Integrate the expression just obtained with respect to \(y\), keeping \(x\) fixed, and evaluate from \(c\) to \(d\).
3
Integrate in \(x\).
Integrate the remaining function with respect to \(x\), evaluate from \(a\) to \(b\), and state the resulting number.

Worked Polynomial Integrals

Worked Example: A Linear Integrand on the Unit Box

Evaluate \(\iiint_B (x+2y+3z)\,dV\) on \(B=[0,1]\times[0,2]\times[0,1]\), using the order \(dz\,dy\,dx\).

First integrate with respect to \(z\). In this step, \(x\) and \(y\) are constants:

$$ \begin{aligned} \int_0^1 (x+2y+3z)\,dz &=\left[xz+2yz+\frac{3}{2}z^2\right]_0^1\\ &=x+2y+\frac{3}{2}. \end{aligned} $$

For a check, differentiating the antiderivative \(xz+2yz+\frac{3}{2}z^2\) with respect to \(z\) gives \(x+2y+3z\), the original integrand.

Next integrate the result from \(y=0\) to \(y=2\):

$$ \begin{aligned} \int_0^2\left(x+2y+\frac{3}{2}\right)\,dy &=\left[xy+y^2+\frac{3}{2}y\right]_0^2\\ &=2x+4+3\\ &=2x+7. \end{aligned} $$

Differentiating the antiderivative \(xy+y^2+\frac{3}{2}y\) with respect to \(y\) returns \(x+2y+\frac{3}{2}\).

Finally, integrate from \(x=0\) to \(x=1\):

$$ \begin{aligned} \int_0^1(2x+7)\,dx &=\left[x^2+7x\right]_0^1\\ &=1+7\\ &=8. \end{aligned} $$

The derivative of \(x^2+7x\) is \(2x+7\). Thus the triple integral is \(8\). The integrand is nonnegative throughout the box, so a positive result is consistent with its interpretation as accumulated signed volume.

Worked Example: Mixed Terms and Nonzero Bounds

Evaluate the integral of \(xy+yz+z^2\) over \([1,2]\times[0,1]\times[1,2]\), in the order \(dz\,dy\,dx\).

Integrate with respect to \(z\), treating \(x\) and \(y\) as constants:

$$ \begin{aligned} \int_1^2(xy+yz+z^2)\,dz &=\left[xyz+\frac{y}{2}z^2+\frac{1}{3}z^3\right]_1^2\\ &=\left(2xy+2y+\frac{8}{3}\right) -\left(xy+\frac{y}{2}+\frac{1}{3}\right)\\ &=xy+\frac{3y}{2}+\frac{7}{3}. \end{aligned} $$

The displayed antiderivative differentiates with respect to \(z\) to give \(xy+yz+z^2\).

Now integrate with respect to \(y\) from \(0\) to \(1\):

$$ \begin{aligned} \int_0^1\left(xy+\frac{3y}{2}+\frac{7}{3}\right)\,dy &=\left[\frac{x}{2}y^2+\frac{3}{4}y^2+\frac{7}{3}y\right]_0^1\\ &=\frac{x}{2}+\frac{3}{4}+\frac{7}{3}\\ &=\frac{x}{2}+\frac{37}{12}. \end{aligned} $$

Differentiating the antiderivative with respect to \(y\) gives \(xy+\frac{3y}{2}+\frac{7}{3}\), as required.

The last integration uses the bounds \(1\) and \(2\), not \(0\) and \(1\):

$$ \begin{aligned} \int_1^2\left(\frac{x}{2}+\frac{37}{12}\right)\,dx &=\left[\frac{x^2}{4}+\frac{37x}{12}\right]_1^2\\ &=\left(1+\frac{74}{12}\right)-\left(\frac{1}{4}+\frac{37}{12}\right)\\ &=\frac{23}{6}. \end{aligned} $$

The derivative of the final antiderivative is \(\frac{x}{2}+\frac{37}{12}\). The result is positive, consistent with the nonnegative integrand on this box.

Worked Example with an Elementary Function

Worked Example: A Trigonometric Integrand

Evaluate \(\sin(x+y+z)\) over \(B=[0,\frac{\pi}{6}]\times[0,\frac{\pi}{6}]\times[0,\frac{\pi}{6}]\), in the order \(dz\,dy\,dx\).

For the inner integral, an antiderivative with respect to \(z\) is \(-\cos(x+y+z)\), since its derivative with respect to \(z\) is \(\sin(x+y+z)\). Hence

$$ \begin{aligned} \int_0^{\pi/6}\sin(x+y+z)\,dz &=\left[-\cos(x+y+z)\right]_0^{\pi/6}\\ &=\cos(x+y)-\cos\left(x+y+\frac{\pi}{6}\right). \end{aligned} $$

Integrate this result with respect to \(y\). The respective antiderivatives are \(\sin(x+y)\) and \(\sin(x+y+\frac{\pi}{6})\):

$$ \begin{aligned} &\int_0^{\pi/6}\left(\cos(x+y)-\cos\left(x+y+\frac{\pi}{6}\right)\right)\,dy\\ &=\left[\sin(x+y)-\sin\left(x+y+\frac{\pi}{6}\right)\right]_0^{\pi/6}\\ &=2\sin\left(x+\frac{\pi}{6}\right)-\sin x-\sin\left(x+\frac{\pi}{3}\right). \end{aligned} $$

Differentiating the antiderivative in the second line with respect to \(y\) gives the integrand on the first line.

Now integrate from \(x=0\) to \(x=\frac{\pi}{6}\):

$$ \begin{aligned} &\int_0^{\pi/6}\left(2\sin\left(x+\frac{\pi}{6}\right)-\sin x-\sin\left(x+\frac{\pi}{3}\right)\right)\,dx\\ &=2\left(\cos\frac{\pi}{6}-\cos\frac{\pi}{3}\right) -\left(1-\cos\frac{\pi}{6}\right) -\left(\cos\frac{\pi}{3}-\cos\frac{\pi}{2}\right)\\ &=\frac{3\sqrt{3}-5}{2}. \end{aligned} $$

Each term follows by using \(-\cos\) as an antiderivative of the corresponding sine term. As a check on the final value, the integrand is nonnegative throughout the box because \(0\le x+y+z\le\frac{\pi}{2}\). The value is positive, as expected.

A Common Error: Losing a Factor During Integration

One frequent mistake is to integrate a term incorrectly before applying its bounds. For instance, in the first example, after integrating with respect to \(z\), the term \(2y\) must be integrated with respect to \(y\). The incorrect calculation

$$ \int 2y\,dy=2y^2 $$

misses the factor of \(\frac{1}{2}\): differentiating \(2y^2\) gives \(4y\), not \(2y\). If this error is used in the first example, the \(y\)-integration produces \(2x+11\), and the final answer becomes \(12\), rather than \(8\).

The correction is to use the power rule accurately:

$$ \int 2y\,dy=y^2, \qquad \frac{d}{dy}(y^2)=2y. $$

With the correct antiderivative, evaluating from \(y=0\) to \(y=2\) gives \(4\), as used in the worked calculation. Checking by differentiation is a quick way to catch this type of error.

Checks That Improve Reliability

Before accepting a result, verify each antiderivative by differentiating it with respect to the variable being integrated. Also check that every bound is applied to the correct variable, and that each intermediate expression retains any variables not yet integrated. The final result should contain no \(x\), \(y\), or \(z\).

For a continuous nonnegative integrand, the integral over a box must be nonnegative. If the integrand changes sign, the integral is a signed accumulation, so positive and negative contributions can cancel. These observations do not replace the calculation, but they can reveal a sign error or an implausible answer.

Key takeaway: For a continuous integrand on a rectangular box, evaluate the iterated integral from the inside out. At each stage, integrate with respect to the indicated variable, apply its constant bounds, and carry the remaining variables forward until a number remains.

Check Your Understanding

Use the indicated order for each calculation, and check each antiderivative by differentiation.

  1. Evaluate \(\int_0^1\int_0^1\int_0^1 (x+y+z)\,dz\,dy\,dx\).
  2. In \(\int_1^3\int_0^2\int_{-1}^1 g(x,y,z)\,dz\,dy\,dx\), which variable is integrated first, and what are its bounds?
  3. Evaluate \(\int_0^1\int_0^1\int_0^2 z^2\,dz\,dy\,dx\).
  4. Why must the final value of a triple integral over a box be independent of \(x\), \(y\), and \(z\)?
  5. If the integrand is continuous and nonnegative on the box, what can be said about the sign of its triple integral?