Tutorials › Calculus II › Detecting Cyclic Products Before Integrating

Integration Strategy · Tutorial 10 of 998

Detecting Cyclic Products Before Integrating

You will learn to spot when repeated integration by parts returns the original integral, solve the resulting equation, and check when the method applies.

Beginner 9 min read

What You'll Learn

  • Recognize products whose factors repeat after differentiation and integration
  • Set up a cycle of related integrals using integration by parts
  • Solve the resulting equation when its coefficient permits
  • Derive antiderivatives of exponential–sine and exponential–cosine products
  • Check cyclic-integration results by differentiation

When Integration by Parts Comes Back to Its Starting Point

Integration by parts is especially useful when differentiating one factor makes it simpler, while integrating the other factor is manageable. Sometimes, however, the process does not simplify the remaining integral. Instead, it produces another integral of a closely related form. A second application may then bring back the original integral.

This return is not a failure. It creates an equation involving the integral we want. If the coefficient of that integral allows us to isolate it, the cycle gives an efficient solution.

Products of exponentials and sine or cosine are common examples. Differentiating sine and cosine alternates between them, while integrating an exponential preserves its form. The factors therefore keep reappearing in a predictable pattern.

Key idea: Before repeatedly applying integration by parts, look for a cycle: a sequence of related integrals that eventually returns to the original one. Then collect the original integral terms and check whether the resulting equation can be solved.

What Counts as a Cycle?

For this tutorial, a cyclic integration-by-parts pattern is a sequence of integrations by parts in which the remaining integral returns to the starting integral, possibly with a coefficient, plus terms that can be integrated or evaluated directly.

For example, let \(I\) denote an antiderivative of \(e^x\sin x\), and let \(J\) denote an antiderivative of \(e^x\cos x\). The first integration by parts relates \(I\) to \(J\); the next relates \(J\) back to \(I\). The two equations can then be combined to find \(I\).

For indefinite integrals, equations between antiderivatives are understood up to an additive constant. In the calculations below, we choose particular antiderivatives while deriving the formula, then include \(+C\) in the final answer to represent the full family.

A Complete Cycle: Exponential Times Sine

Consider \(I=\int e^x\sin x\,dx\). Choose \(u=\sin x\) and \(dv=e^x\,dx\). Then \(du=\cos x\,dx\) and \(v=e^x\), so integration by parts gives

$$ I=e^x\sin x-\int e^x\cos x\,dx. $$

Set \(J=\int e^x\cos x\,dx\). For \(J\), choose \(u=\cos x\) and \(dv=e^x\,dx\). Then \(du=-\sin x\,dx\) and \(v=e^x\), giving

$$ J=e^x\cos x+\int e^x\sin x\,dx. $$

The last integral is \(I\). Substitute the expression for \(J\) into the equation for \(I\):

$$ \begin{aligned} I &=e^x\sin x-J\\ &=e^x\sin x-\left(e^x\cos x+I\right)\\ &=e^x\sin x-e^x\cos x-I. \end{aligned} $$

Now the original integral appears on both sides. Add \(I\) to each side and divide by \(2\):

$$ 2I=e^x(\sin x-\cos x), \qquad I=\frac{e^x}{2}(\sin x-\cos x)+C. $$

The cycle made the problem solvable because collecting the two copies of \(I\) gave the nonzero coefficient \(2\).

Worked Example: Solve a Cycle for \(\int e^x\sin x\,dx\)

Let \(I=\int e^x\sin x\,dx\) and \(J=\int e^x\cos x\,dx\). The first integration by parts gives

$$ I=e^x\sin x-J. $$

For \(J\), use \(u=\cos x\), \(dv=e^x\,dx\), \(du=-\sin x\,dx\), and \(v=e^x\):

$$ J=e^x\cos x+I. $$

Substitute the second equation into the first, then isolate \(I\):

$$ \begin{aligned} I&=e^x\sin x-(e^x\cos x+I),\\ 2I&=e^x(\sin x-\cos x),\\ I&=\frac{e^x}{2}(\sin x-\cos x)+C. \end{aligned} $$

To check, differentiate the proposed antiderivative. The product rule gives

$$ \begin{aligned} \frac{d}{dx}\left[\frac{e^x}{2}(\sin x-\cos x)\right] &=\frac{e^x}{2}(\sin x-\cos x) +\frac{e^x}{2}(\cos x+\sin x)\\ &=e^x\sin x. \end{aligned} $$

This is the original integrand, so the antiderivative is verified.

Why the Cycle Produces an Equation

The method rests on the integration-by-parts identity, which follows from the product rule. If \(u\) and \(v\) are differentiable, then \((uv)'=u'v+uv'\). Integrating both sides gives \(\int u\,dv=uv-\int v\,du\), with the usual understanding that indefinite antiderivatives are determined up to constants.

In a cycle, this identity is applied to related products. Each application is valid under the usual conditions for integration by parts on the interval in question. Because the differentiated and integrated factors repeat, the resulting equations contain the same unknown integral. Substitution or rearrangement then reduces the cycle to an algebraic equation.

1
Name the unknown integrals.
Use symbols such as \(I\) and \(J\) to keep track of the related integrals.
2
Apply integration by parts.
Choose factors whose derivatives and antiderivatives keep the product structure manageable.
3
Continue until the cycle returns.
Express the new integral in terms of the original one and known terms.
4
Collect and solve.
Move all copies of the unknown integral to one side, then divide only if its coefficient is nonzero.
5
Verify the result.
Differentiate the proposed antiderivative and compare it with the original integrand.

A General Exponential–Trigonometric Formula

The same cycle works for \(e^{ax}\sin(bx)\) and \(e^{ax}\cos(bx)\), where \(a\) and \(b\) are constants and \(a\ne 0\). Define

$$ I_s=\int e^{ax}\sin(bx)\,dx, \qquad I_c=\int e^{ax}\cos(bx)\,dx. $$

In the first integral, take \(u=\sin(bx)\) and \(dv=e^{ax}\,dx\). Then \(du=b\cos(bx)\,dx\) and \(v=e^{ax}/a\). In the second, take \(u=\cos(bx)\) and \(dv=e^{ax}\,dx\). These choices give the pair of equations

$$ I_s=\frac{e^{ax}\sin(bx)}{a}-\frac{b}{a}I_c, \qquad I_c=\frac{e^{ax}\cos(bx)}{a}+\frac{b}{a}I_s. $$

Substituting the second equation into the first yields

$$ \begin{aligned} I_s &=\frac{e^{ax}\sin(bx)}{a} -\frac{b}{a}\left(\frac{e^{ax}\cos(bx)}{a}+\frac{b}{a}I_s\right),\\ \left(1+\frac{b^2}{a^2}\right)I_s &=\frac{e^{ax}\sin(bx)}{a} -\frac{b e^{ax}\cos(bx)}{a^2}. \end{aligned} $$

Since \(1+b^2/a^2=(a^2+b^2)/a^2\), and \(a^2+b^2>0\) when \(a\ne0\), the coefficient is nonzero. Solving gives the formulas below. The cosine formula follows by substituting the expression for \(I_s\) into the equation for \(I_c\).

Result: For constants \(a\ne0\) and \(b\), the cyclic equations can be solved because \(a^2+b^2>0\).
$$ \int e^{ax}\sin(bx)\,dx = \frac{e^{ax}\bigl(a\sin(bx)-b\cos(bx)\bigr)}{a^2+b^2}+C, $$
$$ \int e^{ax}\cos(bx)\,dx = \frac{e^{ax}\bigl(a\cos(bx)+b\sin(bx)\bigr)}{a^2+b^2}+C. $$

The derivation above assumes \(a\ne0\), because it divides by \(a\). If \(a=0\), the integrands reduce to sine or cosine alone, and their elementary antiderivatives can be found directly. The displayed formulas also give the correct expressions when \(a=0\) and \(b\ne0\), but that case does not require a cycle.

Worked Example: Integrate \(e^{2x}\cos(3x)\)

Let \(I=\int e^{2x}\cos(3x)\,dx\) and \(J=\int e^{2x}\sin(3x)\,dx\). For \(I\), take \(u=\cos(3x)\), \(dv=e^{2x}\,dx\). Then \(du=-3\sin(3x)\,dx\) and \(v=e^{2x}/2\), so

$$ I=\frac{e^{2x}\cos(3x)}{2}+\frac{3}{2}J. $$

For \(J\), take \(u=\sin(3x)\), \(dv=e^{2x}\,dx\). Then \(du=3\cos(3x)\,dx\) and \(v=e^{2x}/2\), so

$$ J=\frac{e^{2x}\sin(3x)}{2}-\frac{3}{2}I. $$

Substitute this expression for \(J\) into the equation for \(I\):

$$ \begin{aligned} I &=\frac{e^{2x}\cos(3x)}{2} +\frac{3}{2}\left(\frac{e^{2x}\sin(3x)}{2}-\frac{3}{2}I\right)\\ &=\frac{e^{2x}\cos(3x)}{2} +\frac{3e^{2x}\sin(3x)}{4} -\frac{9}{4}I. \end{aligned} $$

Add \(9I/4\) to both sides, then multiply by \(4/13\):

$$ \frac{13}{4}I =\frac{e^{2x}\bigl(2\cos(3x)+3\sin(3x)\bigr)}{4}, \qquad I=\frac{e^{2x}\bigl(2\cos(3x)+3\sin(3x)\bigr)}{13}+C. $$

For the check, differentiate. The derivative of the numerator product is

$$ \begin{aligned} \frac{d}{dx}\left[e^{2x}\bigl(2\cos(3x)+3\sin(3x)\bigr)\right] &=2e^{2x}\bigl(2\cos(3x)+3\sin(3x)\bigr)\\ &\quad+e^{2x}\bigl(-6\sin(3x)+9\cos(3x)\bigr)\\ &=13e^{2x}\cos(3x). \end{aligned} $$

Dividing by \(13\) gives the original integrand, as required.

Worked Example: Evaluate a Definite Integral Using the Cycle

Evaluate \(\int_0^{\pi/4} e^{2x}\cos(2x)\,dx\). The general formula, with \(a=2\) and \(b=2\), gives the antiderivative

$$ F(x)=\frac{e^{2x}\bigl(2\cos(2x)+2\sin(2x)\bigr)}{2^2+2^2} =\frac{e^{2x}}{4}\bigl(\cos(2x)+\sin(2x)\bigr). $$

At the upper endpoint, \(2x=\pi/2\), so \(\cos(\pi/2)=0\) and \(\sin(\pi/2)=1\). At the lower endpoint, \(\cos(0)=1\) and \(\sin(0)=0\). Therefore

$$ \begin{aligned} \int_0^{\pi/4} e^{2x}\cos(2x)\,dx &=F\left(\frac{\pi}{4}\right)-F(0)\\ &=\frac{e^{\pi/2}}{4}-\frac{1}{4}\\ &=\frac{e^{\pi/2}-1}{4}. \end{aligned} $$

To check the antiderivative, differentiate the expression for \(F\):

$$ F'(x)=\frac{e^{2x}}{4}\left[2\bigl(\cos(2x)+\sin(2x)\bigr)-2\sin(2x)+2\cos(2x)\right] =e^{2x}\cos(2x). $$

The derivative matches the integrand, and the endpoint evaluations use the stated bounds.

When the Cycle Does Not Give a Solution

Not every return to the original integral is useful. Suppose algebra gives \(I=A+\lambda I\), where \(A\) is an expression already known. Rearranging gives \((1-\lambda)I=A\). The cycle determines \(I\) only if \(1-\lambda\ne0\). If \(1-\lambda=0\), the equation either reduces to an identity or signals an inconsistency in the calculation; it does not justify dividing by zero or conclude that the integral has no antiderivative.

In the exponential–sine cycle above, substitution gives a nonzero coefficient because \(a^2+b^2>0\) under the stated condition \(a\ne0\). A useful cycle is therefore more than a visual return: it must produce an equation that can actually be isolated.

A Common Sign Error

The sign in the second integration by parts is easy to lose. For \(J=\int e^x\cos x\,dx\), using \(u=\cos x\) gives \(du=-\sin x\,dx\). Thus

$$ J=e^x\cos x-\int e^x(-\sin x)\,dx =e^x\cos x+I. $$

A common incorrect calculation drops the negative sign in \(du\) and writes \(J=e^x\cos x-I\). Substituting that wrong equation would give \(I=e^x\sin x-e^x\cos x+I\), which cancels \(I\) from both sides and leaves the false claim \(0=e^x(\sin x-\cos x)\). The contradiction is a warning to check the sign of \(du\), not evidence that the method failed. Correcting the sign gives \(J=e^x\cos x+I\), and then \(2I=e^x(\sin x-\cos x)\).

Recognizing When to Try This Method

Look for a product in which one factor has a derivative cycle and the other remains manageable when integrated. Exponentials paired with sine or cosine are a strong signal: the exponential retains its form, and the trigonometric factor alternates between sine and cosine. If the first application creates another integral of the same family, name it and continue only far enough to see whether the original integral returns.

By contrast, when differentiating a factor makes it progressively simpler, repeated integration by parts may reduce the problem rather than create a cycle. The choice of strategy depends on the behavior of the factors and on the algebraic equation the cycle produces. In either case, differentiation of the final antiderivative is a direct check on the result.

Check Your Understanding

Use the cycle structure and the conditions discussed above to answer these questions.

  1. In \(\int e^x\sin x\,dx\), what related integral appears after the first integration by parts?
  2. Why can a returned integral be moved to the other side and solved only when its resulting coefficient is nonzero?
  3. For which condition on \(a\) does the displayed integration-by-parts derivation for \(\int e^{ax}\sin(bx)\,dx\) divide by \(a\)?
  4. What sign should appear in \(\int e^x\cos x\,dx=e^x\cos x+\int e^x\sin x\,dx\), and where does it come from?
  5. How can differentiation check a proposed antiderivative obtained from a cycle?

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