Multivariable calculus

Double Integral of exp(y^2) Over a Triangle

The double integral of e to the power y squared over the triangle where x runs from 0 to y and y runs from 0 to 1 equals (e - 1)/2, about 0.8591. This order works because integrating in x first produces a factor of y, which is exactly the substitution factor the integrand needs.

f(x,y)=ey2f(x,y) = e^{y^{2}}
e12\dfrac{e-1}{2}

Numerically 0.859141, confirmed by quadrature on every build.

Integrating in x first manufactures the missing factor

The function ey2e^{y^2} has no elementary antiderivative in yy. That sounds fatal until you notice the integrand does not involve xx at all, so the inner integral is just a length.

0yey2dx=ey2[x]0y=yey2\int_{0}^{y} e^{y^{2}}\,dx = e^{y^{2}}\Big[x\Big]_{0}^{y} = y\,e^{y^{2}}

The width of the triangle at height yy is yy, and that yy is precisely the factor that makes the outer integral a substitution with u=y2u = y^2, du=2ydydu = 2y\,dy.

01yey2dy=[12ey2]01=e120.8591\int_{0}^{1} y\,e^{y^{2}}\,dy = \left[\frac{1}{2}e^{y^{2}}\right]_{0}^{1} = \frac{e - 1}{2} \approx 0.8591

The same region described the other way round

The region is the triangle with vertices (0,0)(0,0), (0,1)(0,1) and (1,1)(1,1), which is the part of the unit square above the line y=xy = x. Slicing it the other way gives an equivalent integral.

01 ⁣ ⁣x1ey2dydx=01 ⁣ ⁣0yey2dxdy=e12\int_{0}^{1}\!\!\int_{x}^{1} e^{y^{2}}\,dy\,dx = \int_{0}^{1}\!\!\int_{0}^{y} e^{y^{2}}\,dx\,dy = \frac{e-1}{2}

The left form is the one exam questions usually hand you, and it is unworkable as written because the inner integral x1ey2dy\int_{x}^{1} e^{y^2}\,dy has no elementary form. Reversing the order is the whole point of the exercise.

  • Sketch the region from the given bounds: xx from 00 to 11, and for each xx, yy from xx up to 11.
  • Read the same region by horizontal slices: yy from 00 to 11, and for each yy, xx from 00 across to yy.
  • Rewrite the integral with the new outer variable outside, then integrate.

The mistake: swapping the bounds without redrawing the region

The error that costs the most marks is mechanically exchanging dydxdy\,dx for dxdydx\,dy while leaving the numbers where they are, producing 01 ⁣x1ey2dxdy\int_{0}^{1}\!\int_{x}^{1} e^{y^2}\,dx\,dy.

That expression is meaningless: the inner integral in xx has a bound xx, so the variable of integration also appears as its own limit, and the outer integral in yy has no yy in its bounds.

A reliable check: after reversing, the outer bounds must both be numbers, and the inner bounds must involve only the outer variable. If either half of that fails, the reversal is wrong.

Frequently asked questions

Why is there no elementary antiderivative for e^(y^2)?

It is a theorem of Liouville that ey2e^{y^2} has no antiderivative expressible in elementary functions. The related ey2dy\int e^{-y^2}\,dy is packaged as the error function for exactly this reason.

Does the answer depend on the integrand having no x in it?

The trick does. Because the integrand is constant in xx, the inner integral is just the slice width yy. If the integrand were xey2x\,e^{y^2}, the inner integral would give y2ey2/2y^2 e^{y^2}/2 instead, which is a harder outer integral.