๐Ÿงฎ Brain Teaser

Integral of x2sinโก(x)x^2 \sin(x)

Problem

Compute: โˆซx2sinโก(x)โ€‰dx\int x^2 \sin(x) \, dx


Field

Integration / Calculus

Why It's Interesting

A clean integration-by-parts problem that requires applying IBP twice. The bookkeeping is a small exercise in itself, and the final answer has a satisfying compact form. It's a staple of integration bees and a good test of fluency with the tabular method.

Key Idea / Trick

Integration by parts: โˆซuโ€‰dv=uvโˆ’โˆซvโ€‰du\int u \, dv = uv - \int v \, du.

Take u=x2u = x^2, dv=sinโก(x)โ€‰dxdv = \sin(x)\,dx. Differentiate uu and integrate dvdv repeatedly until the polynomial factor vanishes (requires 2 rounds). The tabular method organizes this cleanly.

Difficulty

1 / 5

Tags

Integration, Integration by parts, Tabular method, Trigonometric integrals

Integration by partsTabular methodTrigonometric integrals

Integral of x2sinโก(x)x^2 \sin(x) โ€” Answer

Answer

โˆซx2sinโก(x)โ€‰dx=2xsinโก(x)โˆ’(x2โˆ’2)cosโก(x)+C\int x^2 \sin(x)\, dx = 2x\sin(x) - (x^2 - 2)\cos(x) + C


Solution via Tabular Method

Set up the table: differentiate the polynomial column until it hits 0, integrate the trig column, alternate signs +,โˆ’,+,โ€ฆ+, -, +, \ldots

| Sign | Differentiate | Integrate | |------|--------------|-----------| | ++ | x2x^2 | sinโก(x)\sin(x) | | โˆ’- | 2x2x | โˆ’cosโก(x)-\cos(x) | | ++ | 22 | โˆ’sinโก(x)-\sin(x) | | โˆ’- | 00 | cosโก(x)\cos(x) |

Multiply diagonally (each row's sign ร— left entry ร— right entry of next row) and sum:

=(+)(x2)(โˆ’cosโกx)+(โˆ’)(2x)(โˆ’sinโกx)+(+)(2)(cosโกx)= (+)(x^2)(-\cos x) + (-)(2x)(-\sin x) + (+)(2)(\cos x) =โˆ’x2cosโก(x)+2xsinโก(x)+2cosโก(x)+C= -x^2\cos(x) + 2x\sin(x) + 2\cos(x) + C

Factoring: =2xsinโก(x)โˆ’(x2โˆ’2)cosโก(x)+C= 2x\sin(x) - (x^2 - 2)\cos(x) + C


Verification

Differentiate the answer: ddx[2xsinโกxโˆ’(x2โˆ’2)cosโกx]\frac{d}{dx}\left[2x\sin x - (x^2-2)\cos x\right] =2sinโกx+2xcosโกxโˆ’2xcosโกx+(x2โˆ’2)sinโกx= 2\sin x + 2x\cos x - 2x\cos x + (x^2-2)\sin x =2sinโกx+(x2โˆ’2)sinโกx=x2sinโกxโœ“= 2\sin x + (x^2-2)\sin x = x^2 \sin x \checkmark

Type: IntegrationEdit on GitHub โ†—