# Iterated integral

In calculus an iterated integral is the result of applying integrals to a function of more than one variable (for example $f(x,y)$ or $f(x,y,z)$) in a way that each of the integrals considers some of the variables as given constants. For example, the function $f(x,y)$, if $y$ is considered a given parameter can be integrated with respect to $x$, $\int f(x,y)dx$. The result is a function of $y$ and therefore its integral can be considered. If this is done, the result is the iterated integral

$\int\left(\int f(x,y)\,dx\right)\,dy.$

It is key for the notion of iterated integral that this is different, in principle, to the multiple integral

$\iint f(x,y)\,dx\,dy.$

Although in general these two can be different there is a theorem that, under very mild conditions, gives the equality of the two. This is Fubini's theorem.

The alternative notation for iterated integrals

$\int dy \int f(x,y)\,dx$

is also used.

Iterated integrals are computed following the operational order indicated by the parentheses (in the notation that uses them). Starting from the most inner integral outside.

## Examples

### A simple computation

For the iterated integral

$\int\left(\int (x+y) \, dx\right) \, dy$

the integral

$\int (x+y) \, dx = \frac{x^2}{2} + yx$

is computed first and then the result is used to compute the integral with respect to y.

$\int (\frac{x^2}{2} + yx) \, dy = \frac{yx^2}{2} + \frac{xy^2}{2}$

It should be noted, however, that this example omits the constants of integration. After the first integration with respect to x, we would rigorously need to introduce a "constant" function of y. That is, If we were to differentiate this function with respect to x, any terms containing only y would vanish, leaving the original integrand. Similarly for the second integral, we would introduce a "constant" function of x, because we have integrated with respect to y. In this way, indefinite integration does not make very much sense for functions of several variables.

### The order is important

The order in which the integrals are computed is important in iterated integrals, particularly when the integrand is not continuous on the domain of integration. Examples in which the different orders lead to different results are usually for complicated functions as the one that follows.

Let a sequence $0, such that $a_n\rightarrow1$. Let $g_n$ be continuous functions not vanishing in the interval $(a_n,a_{n+1})$ and zero elsewhere, such that $\int_{0}^{1}g_n=1$ for every $n$. Define

$f(x,y)=\sum_{n=0}^\infty (g_n(x)-g_{n+1}(x))g_n(y).$

In the previous sum, at each specific $(x,y)$, at most one term is different from zero. For this function it happens that

$\int_0^1 \left(\int_0^1 f(x,y) \,dy\right)\,dx = 1\neq0 = \int_0^1 \left(\int_0^1 f(x,y)\, dx\right)\,dy$[1]

## References

1. ^ Rudin, W., Real and complex analysis, 1970