Tutorials › Calculus II › Tables for Polynomial-Exponential-Trigonometric Products

Repeated and Tabular Parts · Tutorial 66 of 998

Tables for Polynomial-Exponential-Trigonometric Products

Build and use tabular integration-by-parts tables for polynomial factors multiplied by exponential sines or cosines.

Intermediate 9 min read

What You'll Learn

  • Set up the derivative column for a polynomial and the antiderivative column for an exponential-trigonometric factor.
  • Use the correct alternating signs and diagonal products in a tabular integration-by-parts calculation.
  • Write successive antiderivatives of exponential sines and cosines in a form that works for any polynomial degree.
  • Understand why the table terminates and why its sum gives an antiderivative.
  • Check indefinite and definite answers by differentiation and endpoint evaluation.

Why Combine These Factors in a Table?

A product such as \(x^2e^x\sin x\) contains two different kinds of factors. Differentiating the polynomial repeatedly makes it simpler, and eventually makes it zero. Integrating the exponential-trigonometric factor repeatedly does not make it zero, but its antiderivatives follow a systematic pattern. Tabular integration by parts brings those two patterns together in one finite calculation.

The method is especially useful when the polynomial has degree two or higher: each integration-by-parts step is recorded in the table, so the alternating signs and the final stopping point are visible. It is not a different integration rule. It is a compact way to organize repeated integration by parts.

Successive Antiderivatives of the Exponential-Trigonometric Factor

Let \(a,b\in\mathbb R\), with \(a\) and \(b\) not both zero, and write \(D=a^2+b^2\). Then \(D>0\). For \(g(x)=e^{ax}\sin(bx)\), let \(F_0=g\), and let \(F_j\) denote a \(j\)-fold successive antiderivative, so that \(F_j'=F_{j-1}\) for \(j\geq 1\). For \(g(x)=e^{ax}\cos(bx)\), use \(G_0=g\) and \(G_j'=G_{j-1}\).

Definition: A successive-antiderivative column for \(g\) is the list \(F_1,F_2,\ldots\), where \(F_1'=g\) and \(F_{j+1}'=F_j\). For the cosine factor the corresponding list is \(G_1,G_2,\ldots\). Each entry is an antiderivative of the entry directly above it.

One convenient formula for these columns uses \(z=a+ib\), which is nonzero because \(a,b\) are not both zero. Taking real and imaginary parts gives real-valued functions:

$$ F_j(x)=\operatorname{Im}\!\left(\frac{e^{zx}}{z^j}\right) \quad\text{for }g(x)=e^{ax}\sin(bx), \qquad G_j(x)=\operatorname{Re}\!\left(\frac{e^{zx}}{z^j}\right) \quad\text{for }g(x)=e^{ax}\cos(bx). $$

Indeed, differentiating either expression reduces the exponent \(j\) in the denominator by one, since \(\frac{d}{dx}(e^{zx}/z^j)=e^{zx}/z^{j-1}\). In particular, the first two entries are:

$$ \begin{aligned} F_1(x)&=\frac{e^{ax}}{D}\bigl(a\sin(bx)-b\cos(bx)\bigr),\\ F_2(x)&=\frac{e^{ax}}{D^2}\bigl((a^2-b^2)\sin(bx)-2ab\cos(bx)\bigr),\\[4pt] G_1(x)&=\frac{e^{ax}}{D}\bigl(a\cos(bx)+b\sin(bx)\bigr),\\ G_2(x)&=\frac{e^{ax}}{D^2}\bigl((a^2-b^2)\cos(bx)+2ab\sin(bx)\bigr). \end{aligned} $$

These formulas show why the second column is not just a repeated alternation between sine and cosine: the coefficients change as well. The complex-number expression is a concise way to generate as many successive antiderivatives as the polynomial degree requires.

The Tabular Formula

Let \(P\) be a polynomial of degree \(n\). Its derivative column is \(P,P',P'',\ldots,P^{(n)}\), followed by \(P^{(n+1)}=0\). Pair each polynomial derivative with the next successive antiderivative of \(g\), and alternate the signs, beginning with plus.

Theorem: If \(F_1'=g\) and \(F_{j+1}'=F_j\), then $$ \int P(x)g(x)\,dx = \sum_{k=0}^{n}(-1)^kP^{(k)}(x)F_{k+1}(x)+C. $$ The same formula holds with \(G_j\) in place of \(F_j\) when \(g(x)=e^{ax}\cos(bx)\). Here \(C\) is an arbitrary constant of integration.

In a table, the summands are the diagonal products: \(P F_1\), then \(-P'F_2\), then \(+P''F_3\), and so on. The signs alternate. Stop at the last nonzero polynomial derivative; there is no remainder integral because the next derivative is zero.

Why the Table Works

The tabular formula follows from repeated use of the integration-by-parts identity \(\int u\,dv=uv-\int v\,du\). The following derivation also makes clear why the final term has the sign shown.

1
Start with integration by parts.
Taking \(u=P\) and \(dv=g\,dx\), so \(v=F_1\), gives \(\int Pg\,dx=PF_1-\int P'F_1\,dx\).
2
Apply the same identity to the remaining integral.
Since \(F_2'=F_1\), the remaining integral is \(\int P'F_1\,dx=P'F_2-\int P''F_2\,dx\). Substitution gives \(\int Pg\,dx=PF_1-P'F_2+\int P''F_2\,dx\).
3
Continue until the polynomial derivative vanishes.
At each step, integration by parts adds the next diagonal product and reverses the sign of the remaining integral. After the term involving \(P^{(n)}\), the remainder contains \(P^{(n+1)}=0\), so that integral is zero.

Equivalently, the cancellation can be checked by differentiating the proposed sum. In its derivative, the derivative of \(P^{(k)}\) cancels the term involving \(P^{(k+1)}F_{k+1}\) from the next summand. The only uncancelled term is \(P F_1'=Pg\), because the final polynomial derivative is constant and its next derivative vanishes. Thus the sum really is an antiderivative of \(Pg\).

Worked Example: A Quadratic Times an Exponential Sine

Worked Example: Integrating \(x^2e^x\sin x\)

Find \(\int x^2e^x\sin x\,dx\). Here \(a=b=1\), so \(D=2\). The polynomial derivative column is \(x^2,2x,2,0\). From the successive-antiderivative formulas, the sine column is:

$$ F_1=\frac{e^x(\sin x-\cos x)}{2}, \qquad F_2=-\frac{e^x\cos x}{2}, \qquad F_3=-\frac{e^x(\sin x+\cos x)}{4}. $$

For instance, \(F_2\) follows by substituting \(a=b=1\) in the formula for \(F_2\). The value of \(F_3\) can be obtained from \(\operatorname{Im}(e^{(1+i)x}/(1+i)^3)\), since \((1+i)^{-3}=(-1-i)/4\). The table gives:

$$ \begin{aligned} \int x^2e^x\sin x\,dx &=x^2F_1-2xF_2+2F_3+C\\ &=\frac{x^2e^x(\sin x-\cos x)}{2} +x e^x\cos x -\frac{e^x(\sin x+\cos x)}{2}+C. \end{aligned} $$

To check, set \(A(x)=\frac{x^2}{2}(\sin x-\cos x)+x\cos x-\frac12(\sin x+\cos x)\), so the proposed antiderivative is \(e^xA(x)\). Direct differentiation gives \(A(x)+A'(x)=x^2\sin x\). Therefore its derivative is \(x^2e^x\sin x\), as required.

Worked Example: A Linear Polynomial Times an Exponential Cosine

Worked Example: Integrating \((x+1)e^x\cos(2x)\)

Here \(a=1\), \(b=2\), and \(D=5\). The polynomial column is \(x+1,1,0\). For the cosine factor, the first two entries are:

$$ G_1=\frac{e^x(\cos 2x+2\sin 2x)}{5}, \qquad G_2=\frac{e^x(-3\cos 2x+4\sin 2x)}{25}. $$

The table has just two nonzero polynomial derivatives, so its diagonal sum is:

$$ \begin{aligned} \int (x+1)e^x\cos(2x)\,dx &=(x+1)G_1-G_2+C\\ &=\frac{(x+1)e^x(\cos 2x+2\sin 2x)}{5} +\frac{e^x(3\cos 2x-4\sin 2x)}{25}+C. \end{aligned} $$

For the check, \(G_1'=e^x\cos(2x)\): differentiating its numerator factor gives \[ \frac{d}{dx}\bigl(e^x(\cos 2x+2\sin 2x)\bigr) =e^x\bigl(\cos 2x+2\sin 2x-2\sin 2x+4\cos 2x\bigr) =5e^x\cos 2x. \] Also \(G_2'=G_1\). Consequently, differentiating \((x+1)G_1-G_2\) gives \(G_1+(x+1)e^x\cos(2x)-G_1=(x+1)e^x\cos(2x)\).

Worked Example: Evaluating a Definite Integral from the Table

Worked Example: Evaluating \(\int_0^1 x^2e^x\cos x\,dx\)

Use the cosine column for \(a=b=1\), for which \(D=2\). The required antiderivatives are:

$$ G_1=\frac{e^x(\cos x+\sin x)}{2}, \qquad G_2=\frac{e^x\sin x}{2}, \qquad G_3=\frac{e^x(\sin x-\cos x)}{4}. $$

The polynomial column is \(x^2,2x,2,0\), so an antiderivative is \(H(x)=x^2G_1-2xG_2+2G_3\). Substituting the entries gives:

$$ H(x)=e^x\left( \frac{x^2(\cos x+\sin x)}{2} -x\sin x +\frac{\sin x-\cos x}{2} \right). $$

At \(x=1\), the terms inside the parentheses sum to \(\frac12(\cos 1+\sin 1)-\sin 1+\frac12(\sin 1-\cos 1)=0\), so \(H(1)=0\). At \(x=0\), they sum to \(-\frac12\), so \(H(0)=-\frac12\). Therefore:

$$ \int_0^1 x^2e^x\cos x\,dx =H(1)-H(0)=0-\left(-\frac12\right)=\frac12. $$

As a final check, differentiating \(H=x^2G_1-2xG_2+2G_3\) gives \(2xG_1+x^2G_1'-2G_2-2xG_2'+2G_3'\). Using \(G_1'=e^x\cos x\), \(G_2'=G_1\), and \(G_3'=G_2\), the terms \(2xG_1\), \(-2G_2\), and \(-2xG_1+2G_2\) cancel, leaving \(x^2e^x\cos x\).

Common Pitfall: Losing the Alternating Signs

A frequent error is to use a plus sign for every diagonal product. For example, the incorrect calculation for \(\int x e^x\cos x\,dx\) might be written \(xG_1+G_2\). That sign is wrong: the first integration-by-parts identity is \(\int xg\,dx=xG_1-\int G_1\,dx=xG_1-G_2\).

The correction can be checked directly. Differentiating \(xG_1+G_2\) gives \(G_1+xg+G_1=xg+2G_1\), which is not the integrand. Differentiating the corrected expression \(xG_1-G_2\) gives \(G_1+xg-G_1=xg\). The initial plus sign is followed by a minus sign, then a plus sign, and so forth.

When the Table Is Useful

This table is effective when the polynomial derivative column terminates after a manageable number of rows and the successive antiderivatives of the other factor can be written down reliably. For exponential-sine and exponential-cosine factors, the formulas above supply that antiderivative column. If \(a=b=0\), the displayed formulas do not apply because their denominators vanish; that degenerate case should be handled directly rather than by this table.

For a definite integral, first form the antiderivative from the table, then evaluate it at the upper and lower endpoints and subtract. The table itself does not remove the need to check endpoint values or signs. For an indefinite integral, differentiate the finished expression: the cancellations among neighboring diagonal terms leave exactly the original product.

Check Your Understanding

Use the derivative column, the successive-antiderivative column, and the alternating diagonal products to answer these questions.

  1. For a polynomial of degree four, how many nonzero polynomial entries appear in the derivative column?
  2. What is the first successive antiderivative of \(e^{ax}\cos(bx)\), assuming \(a\) and \(b\) are not both zero?
  3. Why does the final remainder integral vanish when the table is applied to a polynomial of degree \(n\)?
  4. For \(\int x^2g(x)\,dx\), where \(F_1'=g\), \(F_2'=F_1\), and \(F_3'=F_2\), what are the three signed diagonal products?
  5. What differentiation check can detect a sign error in a tabular result?

Test yourself: Calculus II final exam practice

Ready to check what you know? Work a full-length practice final, then open the complete worked solutions.

Want all 1,114 practice problems?

This tutorial covers one topic. Calc Pass covers the full Calculus AB & BC curriculum (the core of Calculus I and II): full review, every practice question, and step-by-step solutions to each one.

QR code to download the Calc Pass app

Get the Calc Pass App

Scan to download and practice on the go, with instant scoring.

Calc Pass Volume 1: 1,114 Practice Questions book cover

Vol. 1: 1,114 Questions

The complete practice question bank, organized by AB & BC topic.

View on Amazon
Calc Pass Volume 2: Solutions Manual book cover

Vol. 2: Solutions Manual

Fully worked solutions to every question in Volume 1.

View on Amazon