---
title: Double Integrals
module: Multiple Integrals and Vector Calculus
moduleNumber: 12
lessonNumber: 1
order: 1201
summary: >
  The double integral extends the definite integral to functions of two
  variables: a limit of Riemann sums that measures signed volume under a
  surface. Fubini's Theorem turns it into two ordinary integrations done one
  after the other, general regions of type I and type II fix the inner limits,
  polar coordinates absorb circular symmetry through the factor r, and the same
  machine computes mass, center of mass, and moments of a lamina.
topics: [Multiple Integrals and Vector Calculus]
draft: false
sources:
  - book: Stewart
    ref: "Ch. 15 — Multiple Integrals; §15.1 Double Integrals over Rectangles, §15.2 Double Integrals over General Regions"
  - book: Stewart
    ref: "§15.3 Double Integrals in Polar Coordinates, §15.4 Applications of Double Integrals"
---

The definite integral $\int_a^b f(x)\,\d x$ answered the area problem: cut $[a,b]$
into strips, sum rectangle areas, take the limit. The double integral answers
the volume problem in exactly the same way, with a rectangle in the plane taking
the place of an interval on the line and a surface taking the place of a curve.
Everything that follows is the single-variable
[definite integral](/calculus/integrals/area-and-the-definite-integral) with one
extra dimension: the same limit computes volume, mass, average value, center of
mass, and moment of inertia of a flat plate of variable density.

## Volume and the double integral

Let $f(x,y)$ be defined on a closed rectangle
$R = [a,b] \times [c,d] = \{(x,y) : a \le x \le b,\ c \le y \le d\}$, and suppose
first that $f(x,y) \ge 0$. The graph $z = f(x,y)$ is a surface, and above $R$ it
caps off a solid $S = \{(x,y,z) : 0 \le z \le f(x,y),\ (x,y) \in R\}$. To measure
the volume of $S$, partition $R$ into subrectangles. Divide $[a,b]$ into $m$
pieces of width $\Delta x = (b-a)/m$ and $[c,d]$ into $n$ pieces of width
$\Delta y = (d-c)/n$; the grid lines cut $R$ into $mn$ subrectangles $R_{ij}$,
each of area $\Delta A = \Delta x\,\Delta y$. Choose a **sample point**
$(x_{ij}^\ast, y_{ij}^\ast)$ in each $R_{ij}$ and raise a column of height
$f(x_{ij}^\ast, y_{ij}^\ast)$ over it. The columns approximate $S$, and their
total volume is a **double Riemann sum**,

$$
V \approx \sum_{i=1}^{m} \sum_{j=1}^{n} f(x_{ij}^\ast, y_{ij}^\ast)\,\Delta A .
$$

$$
% caption: Columns of height $f(x_{ij}^\ast, y_{ij}^\ast)$ over a grid of
% subrectangles of the base $R=[a,b]\times[c,d]$ approximate the solid under the
% surface $z=f(x,y)$; refining the grid drives the double Riemann sum to the
% exact volume.
\begin{tikzpicture}[scale=1.0]
\definecolor{acc}{HTML}{4A6FA5}
% base rectangle in oblique projection
\draw[black] (0,0) -- (5,0) -- (6.4,1.1) -- (1.4,1.1) -- cycle;
% grid lines on base
\foreach \i in {1,2,3,4} {
  \draw[black] (\i*1.0,0) -- ({\i*1.0+1.4},1.1);
}
\foreach \j in {1,2} {
  \draw[black] (\j*0.466,\j*0.366) -- ({5+\j*0.466},\j*0.366);
}
% a few sample columns
\foreach \x/\h in {0.7/1.4, 2.0/2.2, 3.3/1.8, 4.3/1.1} {
  \fill[acc!12] (\x,0) -- ({\x+0.9},0) -- ({\x+0.9},\h) -- (\x,\h) -- cycle;
  \draw[acc, thick] (\x,0) -- ({\x+0.9},0) -- ({\x+0.9},\h) -- (\x,\h) -- cycle;
  \fill[acc!22] (\x,\h) -- ({\x+0.9},\h) -- ({\x+0.9+0.35},{\h+0.27}) -- ({\x+0.35},{\h+0.27}) -- cycle;
  \draw[acc, thick] (\x,\h) -- ({\x+0.9},\h) -- ({\x+0.9+0.35},{\h+0.27}) -- ({\x+0.35},{\h+0.27}) -- cycle;
}
% surface hint
\draw[acc, dashed, thick] (0.45,2.1) .. controls (2.5,3.4) and (4.0,2.6) .. (6.0,2.6);
\node[anchor=west, font=\small] at (6.2,2.7) {graph of $f$};
\node[anchor=north, font=\small] at (3.2,-0.15) {base $R$};
\node[acc, font=\small, anchor=south] at (2.45,2.3) {column height $f$};
\end{tikzpicture}
$$

As $m$ and $n$ grow the columns thin out and the approximation improves. The
limit, when it exists, is the double integral.

> **Definition (Double integral).** The **double integral** of $f$ over the
> rectangle $R$ is
> $$
> \iint\limits_R f(x,y)\,\d A = \lim_{m,n \to \infty} \sum_{i=1}^{m} \sum_{j=1}^{n} f(x_{ij}^\ast, y_{ij}^\ast)\,\Delta A,
> $$
> if the limit exists (the same value for every choice of sample points). When
> $f(x,y) \ge 0$ it equals the volume of the solid under $z = f(x,y)$ and above
> $R$; in general it is a **signed** volume, counting regions below the
> $xy$-plane negatively.

The precise meaning matches the single-variable case: for every
$\varepsilon > 0$ there is an integer $N$ such that the sum is within
$\varepsilon$ of the integral whenever $m, n > N$, for any sample points. A
sufficient condition for existence is that $f$ be continuous on $R$, or bounded
with discontinuities confined to finitely many smooth curves.[^fubini] The
**midpoint rule** is the practical estimate: take each
$(x_{ij}^\ast, y_{ij}^\ast)$ to be the center of $R_{ij}$.

Two facts carry over verbatim from single integrals:

- **Linearity.** $\iint\limits_R (c f + d g)\,\d A = c\iint\limits_R f\,\d A + d\iint\limits_R g\,\d A$.
- **Additivity over regions.** If $R = R_1 \cup R_2$ overlap only on a boundary,
  then $\iint\limits_R f\,\d A = \iint\limits_{R_1} f\,\d A + \iint\limits_{R_2} f\,\d A$.
- **Average value.** The average of $f$ over $R$ is
  $f_{\text{avg}} = \frac{1}{A(R)}\iint\limits_R f\,\d A$, the height of a flat box with
  the same base and the same volume.

## Iterated integrals and Fubini's Theorem

The limit definition is unusable for computation; instead, integrate one
variable at a time. Fix $x$ and integrate $f(x,y)$ over $y$ from $c$ to $d$; the
result $A(x) = \int_c^d f(x,y)\,\d y$ is a function of $x$ alone (a cross-sectional
area). Integrate that over $x$:

$$
\int_a^b \left[ \int_c^d f(x,y)\,\d y \right] \d x = \int_a^b \int_c^d f(x,y)\,\d y\,\d x .
$$

This is an **iterated integral**: work the inner integral first, treating the
outer variable as a constant, then integrate the result. The claim that it
equals the double integral, and that the order does not matter, is Fubini's
Theorem.

> **Theorem (Fubini).** If $f$ is continuous on the rectangle
> $R = [a,b] \times [c,d]$, then
> $$
> \iint\limits_R f(x,y)\,\d A = \int_a^b \int_c^d f(x,y)\,\d y\,\d x = \int_c^d \int_a^b f(x,y)\,\d x\,\d y .
> $$
> More generally the two iterated integrals agree whenever $f$ is bounded on $R$,
> discontinuous only on finitely many smooth curves, and both iterated integrals
> exist.

The geometric reason is Cavalieri's slicing principle: the volume under the
surface is $\int_a^b A(x)\,\d x$ where $A(x)$ is the area of the slice at $x$, and
also $\int_c^d A(y)\,\d y$ slicing the other way. Both recover the same solid.

> **Worked example.** Evaluate $\iint\limits_R (x - 3y^2)\,\d A$ over
> $R = [0,2] \times [1,2]$. Integrate in $y$ first:
>
> $$
> \int_0^2 \int_1^2 (x - 3y^2)\,\d y\,\d x
> = \int_0^2 \Big[\, xy - y^3 \,\Big]_{y=1}^{y=2}\,\d x
> = \int_0^2 (2x - 8) - (x - 1)\,\d x = \int_0^2 (x - 7)\,\d x .
> $$
>
> Then $\int_0^2 (x-7)\,\d x = \big[\tfrac{x^2}{2} - 7x\big]_0^2 = 2 - 14 = -12$. The
> value is negative because $x - 3y^2 < 0$ throughout $R$ (its maximum there is
> $2 - 3 = -1$); the double integral is
> signed volume, not geometric volume. Reversing the order gives the same $-12$, a
> free check whenever the integrand is a manageable polynomial.

When the integrand **separates** as a product $g(x)\,h(y)$ on a rectangle, the
double integral factors into a product of single integrals,

$$
\iint\limits_R g(x)\,h(y)\,\d A = \left( \int_a^b g(x)\,\d x \right)\left( \int_c^d h(y)\,\d y \right),
$$

because the inner integral pulls the constant $g(x)$ out and leaves
$\int_c^d h(y)\,\d y$, itself a constant, to factor out of the outer one.

## General regions

Rectangles are the exception; real regions have curved boundaries. To integrate
over a general region $D$, enclose it in a rectangle $R$, extend $f$ to be zero
outside $D$, and integrate the extension over $R$. Because the extension vanishes off $D$, the
outer limits of integration are the flat sides of $R$ but the **inner** limits
follow the boundary of $D$. Two shapes cover almost everything.

> **Definition (Type I and type II regions).** A region is **type I** if it lies
> between two graphs over an $x$-interval,
> $$
> D = \{(x,y) : a \le x \le b,\ g_1(x) \le y \le g_2(x)\},
> $$
> with $g_1, g_2$ continuous. It is **type II** if it lies between two graphs over
> a $y$-interval,
> $$
> D = \{(x,y) : c \le y \le d,\ h_1(y) \le x \le h_2(y)\}.
> $$

The inner limits are functions; the outer limits are the constants. For type I,
integrate $y$ from the bottom curve to the top curve, then $x$ across the base:

$$
\iint\limits_D f\,\d A = \int_a^b \int_{g_1(x)}^{g_2(x)} f(x,y)\,\d y\,\d x .
$$

For type II, integrate $x$ from the left curve to the right curve, then $y$:

$$
\iint\limits_D f\,\d A = \int_c^d \int_{h_1(y)}^{h_2(y)} f(x,y)\,\d x\,\d y .
$$

$$
% caption: A type I region is swept by a vertical strip running from the bottom
% curve to the top curve; a type II region by a horizontal strip from the left
% curve to the right curve. The strip direction fixes which variable goes inside.
\begin{tikzpicture}[scale=1.0]
\definecolor{acc}{HTML}{4A6FA5}
% --- Type I (left) ---
\begin{scope}
  \fill[acc!10] (0,0.7) .. controls (1.5,1.15) and (2.4,1.35) .. (3.4,1.5)
    -- (3.4,2.55) .. controls (2.4,2.95) and (1.3,2.95) .. (0,2.6) -- cycle;
  \draw[acc, thick] (0,0.7) .. controls (1.5,1.15) and (2.4,1.35) .. (3.4,1.5);
  \draw[acc, thick] (0,2.6) .. controls (1.3,2.95) and (2.4,2.95) .. (3.4,2.55);
  \draw[->, black] (-0.3,0) -- (3.9,0) node[right, font=\small] {$x$};
  \draw[->, black] (0,-0.2) -- (0,3.4) node[above, font=\small] {$y$};
  % vertical strip
  \draw[black, very thick, ->] (1.9,1.25) -- (1.9,2.78);
  \node[font=\small] at (1.55,1.95) {$dy$};
  \node[acc, font=\small, anchor=south] at (2.6,2.9) {$y=g_2(x)$};
  \node[acc, font=\small, anchor=north] at (2.85,1.42) {$y=g_1(x)$};
  \node[font=\small, anchor=north] at (1.9,-0.05) {$a \le x \le b$};
  \node[font=\bfseries, anchor=south] at (1.7,3.15) {type I};
\end{scope}
% --- Type II (right) ---
\begin{scope}[xshift=6.5cm]
  \fill[acc!10] (0.6,0.3) .. controls (0.35,1.4) and (0.4,2.2) .. (0.8,3.1)
    -- (3.0,3.1) .. controls (3.45,2.2) and (3.4,1.2) .. (2.9,0.3) -- cycle;
  \draw[acc, thick] (0.6,0.3) .. controls (0.35,1.4) and (0.4,2.2) .. (0.8,3.1);
  \draw[acc, thick] (2.9,0.3) .. controls (3.4,1.2) and (3.45,2.2) .. (3.0,3.1);
  \draw[->, black] (-0.3,0) -- (3.9,0) node[right, font=\small] {$x$};
  \draw[->, black] (0,-0.2) -- (0,3.4) node[above, font=\small] {$y$};
  % horizontal strip
  \draw[black, very thick, ->] (0.5,1.9) -- (3.32,1.9);
  \node[font=\small] at (1.75,2.2) {$dx$};
  \node[acc, font=\small, anchor=east] at (0.5,0.85) {$x=h_1(y)$};
  \node[acc, font=\small, anchor=west] at (3.25,2.75) {$x=h_2(y)$};
  \node[font=\bfseries, anchor=south] at (1.7,3.15) {type II};
\end{scope}
\end{tikzpicture}
$$

> **Worked example.** Find the volume under $z = x^2 + y^2$ over the triangle $D$
> with vertices $(0,0)$, $(1,0)$, $(1,1)$. As a type I region, $x$ runs from $0$
> to $1$ and, for each $x$, $y$ runs from $0$ (the $x$-axis) up to the line
> $y = x$:
>
> $$
> V = \int_0^1 \int_0^x (x^2 + y^2)\,\d y\,\d x
> = \int_0^1 \left[ x^2 y + \tfrac{y^3}{3} \right]_{0}^{x} \d x
> = \int_0^1 \left( x^3 + \tfrac{x^3}{3} \right) \d x
> = \int_0^1 \tfrac{4}{3} x^3\,\d x = \tfrac{1}{3}.
> $$

### Changing the order of integration

Some inner integrals have no elementary antiderivative in one order but are
routine in the other. The standard example is
$\int_0^1 \int_x^1 \sin(y^2)\,\d y\,\d x$: the inner integral $\int \sin(y^2)\,\d y$
has no closed form. Read off the region — $0 \le x \le 1$ and $x \le y \le 1$, a
triangle — and redescribe it as type II: $0 \le y \le 1$ and $0 \le x \le y$.
Now $y$ is the outer variable and the inner integral is trivial:

$$
\int_0^1 \int_0^y \sin(y^2)\,\d x\,\d y
= \int_0^1 y \sin(y^2)\,\d y
= \left[ -\tfrac{1}{2}\cos(y^2) \right]_0^1 = \tfrac{1}{2}\big(1 - \cos 1\big).
$$

The procedure is fixed: sketch the region from the given limits, then rewrite it
in the other type. Never swap the numbers on the integral signs without redrawing
the region — the inner limits change from curves to constants and back.

## Double integrals in polar coordinates

When the region is a disk, an annulus, or a sector, Cartesian limits carry ugly
square roots. [Polar coordinates](/calculus/parametric-and-polar/polar-coordinates)
$x = r\cos\theta$, $y = r\sin\theta$ describe such regions cleanly. The subtlety
is the area element. A **polar rectangle**
$R = \{(r,\theta) : a \le r \le b,\ \alpha \le \theta \le \beta\}$ splits into
subregions bounded by circles $r = \text{const}$ and rays $\theta = \text{const}$.
A patch between radii $r$ and $r + \Delta r$ and angles $\theta$ and
$\theta + \Delta\theta$ is not a rectangle of area $\Delta r\,\Delta\theta$; it is
a curved wedge whose inner and outer arcs have lengths $r_{\text{in}}\,\Delta\theta$
and $r_{\text{out}}\,\Delta\theta$, so its area is the difference of two
circular-sector areas,

$$
\Delta A = \tfrac{1}{2} r_{\text{out}}^2 \Delta\theta - \tfrac{1}{2} r_{\text{in}}^2 \Delta\theta
= \tfrac{1}{2}(r_{\text{out}} + r_{\text{in}})(r_{\text{out}} - r_{\text{in}})\,\Delta\theta
= r_i^\ast\,\Delta r\,\Delta\theta,
$$

where $r_i^\ast$ is the midpoint radius. In the limit the area element is
$\d A = r\,\d r\,\d\theta$. The extra factor $r$ accounts for the polar change of
variables: a patch far from the origin subtends more area than one near it.

$$
% caption: The polar area element is a curved wedge of sides $dr$ and $r\,d\theta$;
% its area is $r\,dr\,d\theta$, so the factor $r$ must accompany every polar
% double integral.
\begin{tikzpicture}[scale=1.0]
\definecolor{acc}{HTML}{4A6FA5}
\draw[->, black] (0,0) -- (5.2,0) node[right, font=\small] {$x$};
\draw[->, black] (0,0) -- (0,4.0) node[above, font=\small] {$y$};
% arcs
\draw[black] (0,0) ++(28:2.0) arc (28:62:2.0);
\draw[black] (0,0) ++(28:3.0) arc (28:62:3.0);
% rays
\draw[black] (28:1.7) -- (28:3.3);
\draw[black] (62:1.7) -- (62:3.3);
% the wedge fill
\fill[acc!12] (40:2.3) arc (40:52:2.3) -- (52:2.9) arc (52:40:2.9) -- cycle;
\draw[acc, thick] (40:2.3) arc (40:52:2.3) -- (52:2.9) arc (52:40:2.9) -- cycle;
% labels
\draw[<->, black] (43:2.3) -- (43:2.9);
\node[font=\small, anchor=west] at (41:3.15) {$dr$};
\draw[<->, black] (40:2.55) arc (40:52:2.55);
\node[font=\small, anchor=south west] at (53:2.95) {arc length};
% angle marker
\draw[black] (0.9,0) arc (0:40:0.9);
\node[font=\small] at (21:1.25) {angle};
\draw[black] (0,0) -- (40:3.4);
\node[font=\small, anchor=north] at (37:1.7) {$r$};
\end{tikzpicture}
$$

> **Theorem (Change to polar coordinates).** If $f$ is continuous on a polar
> region $R = \{(r,\theta) : \alpha \le \theta \le \beta,\ h_1(\theta) \le r \le h_2(\theta)\}$
> with $0 \le \beta - \alpha \le 2\pi$, then
> $$
> \iint\limits_R f(x,y)\,\d A = \int_\alpha^\beta \int_{h_1(\theta)}^{h_2(\theta)} f(r\cos\theta, r\sin\theta)\,r\,\d r\,\d\theta .
> $$

Three substitutions convert a Cartesian polar-friendly integral: replace $x$ by
$r\cos\theta$, $y$ by $r\sin\theta$, and $\d A$ by $r\,\d r\,\d\theta$, and set limits
that describe the region in $(r,\theta)$. Forgetting the $r$ is the most common
error here.

> **Worked example.** Find the volume under $z = e^{-(x^2+y^2)}$ over the disk of
> radius $R$ centered at the origin. In Cartesian form the integrand has no
> elementary antiderivative; in polar form $x^2 + y^2 = r^2$ and the region is
> $0 \le r \le R$, $0 \le \theta \le 2\pi$:
>
> $$
> V = \int_0^{2\pi} \int_0^{R} e^{-r^2}\,r\,\d r\,\d\theta
> = \int_0^{2\pi} \d\theta \int_0^{R} r e^{-r^2}\,\d r
> = 2\pi \left[ -\tfrac{1}{2} e^{-r^2} \right]_0^{R}
> = \pi\big(1 - e^{-R^2}\big).
> $$

The factor $r$ that polar coordinates supply is what makes the
inner integral elementary; letting $R \to \infty$ gives the value $\pi$, the
route to the Gaussian integral $\int_{-\infty}^\infty e^{-x^2}\,\d x = \sqrt{\pi}$.

## Applications: mass, center of mass, and moments

A double integral computes any quantity that is the sum of a density times an
area element. Let a **lamina** (a thin flat plate) occupy a region $D$ with
surface density $\rho(x,y)$ in mass per unit area. The mass of a small piece near
$(x,y)$ is $\rho(x,y)\,\d A$, and summing over $D$ gives the total.

> **Definition (Mass and moments of a lamina).** For a lamina of density
> $\rho(x,y)$ over a region $D$:
> $$
> m = \iint\limits_D \rho(x,y)\,\d A
> $$
> is the **mass**; the **moments** about the coordinate axes are
> $$
> M_x = \iint\limits_D y\,\rho(x,y)\,\d A, \qquad M_y = \iint\limits_D x\,\rho(x,y)\,\d A;
> $$
> and the **center of mass** is $(\bar{x}, \bar{y})$ with
> $\bar{x} = M_y/m$ and $\bar{y} = M_x/m$.

The center of mass is the balance point: place a support under $(\bar{x},\bar{y})$
and the plate is in equilibrium. Note the cross labeling — the moment about the
$x$-axis weights by $y$, because a mass's tendency to rotate about the $x$-axis
grows with its distance $y$ from that axis.

$$
% caption: The center of mass of a lamina is its balance point, found by dividing
% each axis moment by the total mass; denser regions pull it toward themselves.
\begin{tikzpicture}[scale=1.0]
\definecolor{acc}{HTML}{4A6FA5}
\draw[->, black] (-0.3,0) -- (5.2,0) node[right, font=\small] {$x$};
\draw[->, black] (0,-0.3) -- (0,3.6) node[above, font=\small] {$y$};
% lamina region (a blobby quarter-disk-ish shape), denser to the right
\fill[acc!8] (0.4,0.3) .. controls (2.5,0.0) and (4.3,0.6) .. (4.4,1.8)
  .. controls (4.4,2.9) and (2.0,3.2) .. (0.4,2.4) -- cycle;
\draw[acc, thick] (0.4,0.3) .. controls (2.5,0.0) and (4.3,0.6) .. (4.4,1.8)
  .. controls (4.4,2.9) and (2.0,3.2) .. (0.4,2.4) -- cycle;
% density shading hint (right side denser)
\fill[acc!22] (3.0,0.6) .. controls (4.1,0.8) and (4.4,1.4) .. (4.4,1.8)
  .. controls (4.4,2.4) and (3.7,2.7) .. (3.0,2.6) -- cycle;
\node[font=\small] at (3.95,2.45) {denser};
% center of mass
\fill[black] (2.95,1.55) circle (2.4pt);
\node[font=\small, anchor=south] at (2.6,1.7) {center of mass};
\draw[black, dashed] (2.95,1.55) -- (2.95,0) node[below, font=\small] {$M_y$ over $m$};
\draw[black, dashed] (2.95,1.55) -- (0,1.55) node[left, font=\small] {$M_x$ over $m$};
\node[acc, font=\small] at (1.4,1.4) {density};
\end{tikzpicture}
$$

A related quantity measures resistance to rotation rather than location.

> **Definition (Moment of inertia).** The **moment of inertia** of a lamina about
> an axis is $\iint\limits_D (\text{distance to axis})^2\,\rho\,\d A$. About the coordinate
> axes and the origin,
> $$
> I_x = \iint\limits_D y^2 \rho\,\d A, \quad I_y = \iint\limits_D x^2 \rho\,\d A, \quad I_0 = I_x + I_y = \iint\limits_D (x^2+y^2)\rho\,\d A .
> $$

The polar moment $I_0$ pairs naturally with polar coordinates, since
$x^2 + y^2 = r^2$.

> **Worked example.** The moments of inertia of a homogeneous disk $D$ of radius
> $a$ and constant density $\rho$, centered at the origin. In polar coordinates
> $D$ is $0 \le r \le a$, $0 \le \theta \le 2\pi$, and the polar moment comes out
> at once:
>
> $$
> I_0 = \iint\limits_D (x^2 + y^2)\,\rho\,\d A
> = \rho\int_0^{2\pi}\!\int_0^a r^2\cdot r\,\d r\,\d\theta
> = \rho\,(2\pi)\,\frac{a^4}{4} = \frac{\pi\rho a^4}{2}.
> $$
>
> The disk is symmetric under $x \leftrightarrow y$, so $I_x = I_y$; with
> $I_x + I_y = I_0$ each is half, $I_x = I_y = \tfrac{1}{4}\pi\rho a^4$. Writing the
> mass as $m = \rho\,\pi a^2$ recovers the standard form $I_0 = \tfrac{1}{2}m a^2$.

> **Worked example.** A lamina occupies the quarter-disk $x^2 + y^2 \le 1$,
> $x, y \ge 0$, with density $\rho(x,y) = 1$. In polar form the mass is
> $m = \int_0^{\pi/2}\int_0^1 r\,\d r\,\d\theta = \tfrac{\pi}{4}$, the area, as
> expected. The moment about the $y$-axis is
>
> $$
> M_y = \int_0^{\pi/2} \int_0^1 (r\cos\theta)\,r\,\d r\,\d\theta
> = \int_0^{\pi/2}\cos\theta\,\d\theta \int_0^1 r^2\,\d r
> = 1 \cdot \tfrac{1}{3} = \tfrac{1}{3},
> $$
>
> so $\bar{x} = M_y/m = \tfrac{1/3}{\pi/4} = \tfrac{4}{3\pi} \approx 0.424$, and by
> symmetry $\bar{y} = \tfrac{4}{3\pi}$ as well.

Each quantity is the same double integral $\iint\limits_D (\cdot)\,\d A$ with a different
integrand:

| Integrand | Quantity | Meaning |
| --- | --- | --- |
| $1$ | area of $D$ | flat base |
| $f(x,y)$ | signed volume | solid under $z=f$ |
| $\rho(x,y)$ | mass $m$ | thin plate |
| $x\rho,\ y\rho$ | moments $M_y,\ M_x$ | first moments about axes |
| $x^2\rho,\ y^2\rho$ | inertia $I_y,\ I_x$ | second moments about axes |
| $\frac{1}{A(D)} f$ | average value | mean height |

## Choosing the setup

The technique never changes; only the description of the region does. Three
decisions settle every problem.

- **Coordinate system.** Circular boundaries or an integrand in $x^2 + y^2$
  favor polar; straight boundaries favor Cartesian.
- **Region type.** Sketch $D$. If vertical strips have simple top and bottom
  curves, use type I; if horizontal strips are simpler, use type II. Sometimes
  one order is elementary and the other is impossible.
- **Order of integration.** Even in Cartesian coordinates, reversing the order
  can rescue a non-integrable inner integral — redescribe the region, never just
  the numbers.

| Region | Best coordinates | Typical order |
| --- | --- | --- |
| rectangle | Cartesian | either (separable factors) |
| triangle, region under a curve | Cartesian | type I or II by which strips are simple |
| disk, annulus, sector | polar | $r$ inside, $\theta$ outside |
| integrand $e^{-(x^2+y^2)}$, $\sqrt{x^2+y^2}$ | polar | $r$ inside |

[^fubini]: Stewart, §15.1 — Double Integrals over Rectangles; §15.2 — Double Integrals over General Regions. The existence condition (continuity, or bounded with discontinuities on finitely many smooth curves) and Fubini's Theorem for both orders of integration.
