Multivariable calculus

Double Integral of y sin x Under a Cosine Arch

The double integral of y times sin(x) over the region where x runs from 0 to pi/2 and y runs from 0 up to cos(x) equals 1/6, about 0.1667. The inner integral in y gives one half of sin(x) times cos(x) squared, and the substitution u = cos(x) finishes it.

f(x,y)=ysinxf(x,y) = y\sin x
16\dfrac{1}{6}

Numerically 0.166667, confirmed by quadrature on every build.

A type 1 region: y between two functions of x

The region sits between the xx axis below and the curve y=cosxy = \cos x above, for xx from 00 to π/2\pi/2. On a type 1 region the inner variable is yy and its bounds are functions of xx.

DysinxdA=0π/2 ⁣ ⁣0cosxysinxdydx\iint_{D} y \sin x\,dA = \int_{0}^{\pi/2}\!\!\int_{0}^{\cos x} y \sin x\,dy\,dx

Integrate in yy with xx held fixed. Only the yy matters inside; sinx\sin x rides along as a constant.

0cosxysinxdy=sinx[y22]0cosx=sinxcos2x2\int_{0}^{\cos x} y \sin x\,dy = \sin x\left[\frac{y^{2}}{2}\right]_{0}^{\cos x} = \frac{\sin x\cos^{2}x}{2}

Finish with the substitution u = cos x

The outer integral now has sinx\sin x sitting next to a power of cosx\cos x, which is the signature of the substitution u=cosxu = \cos x, du=sinxdxdu = -\sin x\,dx.

120π/2sinxcos2xdx=1210u2(du)=1201u2du=16\frac{1}{2}\int_{0}^{\pi/2} \sin x\cos^{2}x\,dx = \frac{1}{2}\int_{1}^{0} u^{2}\,(-du) = \frac{1}{2}\int_{0}^{1} u^{2}\,du = \frac{1}{6}

Notice the limits changed with the substitution: x=0x = 0 gives u=1u = 1, and x=π/2x = \pi/2 gives u=0u = 0. Flipping them absorbs the minus sign from dudu.

DysinxdA=160.1667\iint_{D} y \sin x\,dA = \frac{1}{6} \approx 0.1667

The mistake: using a constant ceiling instead of the curve

Since cosx\cos x never exceeds 11 on this interval, students sometimes replace the upper bound by the constant 11 and integrate over the rectangle [0,π/2]×[0,1][0,\pi/2]\times[0,1] instead.

0π/2 ⁣ ⁣01ysinxdydx=120π/2sinxdx=12\int_{0}^{\pi/2}\!\!\int_{0}^{1} y \sin x\,dy\,dx = \frac{1}{2}\int_{0}^{\pi/2}\sin x\,dx = \frac{1}{2}

That is 0.50.5 against the true 0.16670.1667, three times too large, because the rectangle includes everything above the cosine curve. The bound cosx\cos x is not an estimate of the region, it is the region's boundary.

The tell that a bound must stay variable: the answer to the inner integral should still contain xx. If your inner integral comes out as a pure number on a type 1 region, you have flattened the boundary.

Frequently asked questions

Could this be set up as a type 2 region instead?

Yes, with yy from 00 to 11 and xx from 00 to arccosy\arccos y, since the curve inverts cleanly on this interval. The arccos\arccos then disappears: the inner integral is y[cosx]0arccosy=y(1y)y\Big[-\cos x\Big]_{0}^{\arccos y} = y(1-y), and 01(yy2)dy=1213=16\int_{0}^{1}\left(y - y^{2}\right)\,dy = \tfrac{1}{2} - \tfrac{1}{3} = \tfrac{1}{6}. It is a clean independent check on the answer.

Why does the answer come out so tidy?

Because the outer integral reduces to 01u2du\int_{0}^{1} u^2\,du after substitution. The trigonometric functions cancel out of the final expression entirely, leaving a rational number.