Tutorials › Calculus I › Applying Product and Chain Rules Together

Product, Quotient, and Chain Rules · Tutorial 468 of 1495

Applying Product and Chain Rules Together

Combine the Product Rule with the Chain Rule inside a factor, then factor out common powers to get a compact derivative.

Intermediate 10 min read

What You'll Learn

  • Identify the outer structure of an expression as a product.
  • Apply the Chain Rule to each composite factor.
  • Factor common powers to simplify the derivative.
  • Find horizontal tangents from the factored form.
  • Detect the standard errors: missing inner derivatives and mis-sorted rules.

Two Rules, One Expression

Real functions rarely arrive in a form that needs just one differentiation rule. The expression \(x^2(x+1)^4\) is a product of \(x^2\) and \((x+1)^4\), and the second factor is itself a composite, a fourth power of the inner function \(x+1\). Differentiating it requires the Product Rule at the outer level and the Chain Rule inside one of the factors. The skill is not in either rule alone but in deciding which rule applies where. Always look at the last operation performed in the expression: that tells you which rule to apply first.

For \(x^2(x+1)^4\), the last operation is multiplication, so the Product Rule comes first. Inside it, the factor \((x+1)^4\) is a power of a function, so the Chain Rule handles that derivative.

Combined Procedure: To differentiate \(f(x)=A(x)\,B(x)\) where \(A\) or \(B\) is a composite function: (1) apply the Product Rule, \(f'=A'B+AB'\); (2) compute each factor's derivative, using the Chain Rule for composite factors; (3) factor out common powers and simplify.

Worked Example: A Power Times a Power of a Linear Function

Differentiate \(f(x)=x^2(x+1)^4\).

Let \(A=x^2\) and \(B=(x+1)^4\). Then \(A'=2x\), and by the Chain Rule \(B'=4(x+1)^3\cdot1\). The Product Rule gives

$$ f'(x)=2x(x+1)^4+x^2\cdot4(x+1)^3. $$

Both terms contain \(2x\) and \((x+1)^3\). Factoring them out,

$$ f'(x)=2x(x+1)^3\bigl[(x+1)+2x\bigr]=2x(x+1)^3(3x+1). $$

Check at \(x=1\): the factored form gives \(2\cdot1\cdot8\cdot4=64\). The unfactored form gives \(2\cdot16+1\cdot4\cdot8=32+32=64\). A difference quotient of \(f\) near \(1\) also gives about \(64\).

Horizontal tangents: \(f'(x)=0\) when \(x=0\), \(x=-1\) or \(x=-\tfrac13\). At \(x=-1\), \(f(-1)=1\cdot0=0\), so the graph touches the \(x\)-axis there. At \(x=0\) it also touches the \(x\)-axis.

Worked Example: Two Composite Factors

Differentiate \(g(x)=(2x-1)^3(x^2+3)^2\).

Both factors are composite. For \(A=(2x-1)^3\), the Chain Rule gives \(A'=3(2x-1)^2\cdot2=6(2x-1)^2\). For \(B=(x^2+3)^2\), \(B'=2(x^2+3)\cdot2x=4x(x^2+3)\). Then

$$ g'(x)=6(2x-1)^2(x^2+3)^2+(2x-1)^3\cdot4x(x^2+3). $$

The common factor is \(2(2x-1)^2(x^2+3)\). Factoring it out,

$$ g'(x)=2(2x-1)^2(x^2+3)\bigl[3(x^2+3)+2x(2x-1)\bigr]=2(2x-1)^2(x^2+3)\bigl(7x^2-2x+9\bigr). $$

Check at \(x=1\): the factored form gives \(2(1)^2(4)(14)=112\). The unfactored form gives \(6\cdot1\cdot16+1\cdot4\cdot4=96+16=112\). They agree.

Worked Example: A Radical Factor

Differentiate \(h(x)=x\sqrt{1-x^2}\) for \(-1<x<1\).

Write \(\sqrt{1-x^2}=(1-x^2)^{1/2}\). Its derivative is \(\tfrac12(1-x^2)^{-1/2}(-2x)=-\dfrac{x}{\sqrt{1-x^2}}\). By the Product Rule,

$$ h'(x)=\sqrt{1-x^2}+x\cdot\left(-\frac{x}{\sqrt{1-x^2}}\right)=\frac{(1-x^2)-x^2}{\sqrt{1-x^2}}=\frac{1-2x^2}{\sqrt{1-x^2}}. $$

The derivative is zero when \(x=\pm\tfrac{1}{\sqrt2}\), where \(h\) has a local maximum value \(\tfrac12\) at \(x=\tfrac1{\sqrt2}\).

Check at \(x=\tfrac12\): \(h'(\tfrac12)=\dfrac{1-\tfrac12}{\sqrt{3}/2}=\dfrac{1}{\sqrt3}\approx0.5774\), and a difference quotient near \(x=0.5\) agrees.

Worked Example: An Exponential Factor

Differentiate \(k(x)=x\,e^{-x^2}\).

The derivative of \(e^{-x^2}\) is \(e^{-x^2}\cdot(-2x)\) by the Chain Rule. So

$$ k'(x)=e^{-x^2}+x\bigl(-2x\,e^{-x^2}\bigr)=e^{-x^2}(1-2x^2). $$

At \(x=0.7\), \(k'(0.7)=e^{-0.49}(1-0.98)=0.6126\times0.02\approx0.0123\), nearly zero because \(0.7\) is close to the critical point \(x=\tfrac1{\sqrt2}\approx0.7071\).

Common Mistakes

Forgetting the inner derivative. For \(g\), writing \(\dfrac{d}{dx}(2x-1)^3=3(2x-1)^2\) omits the factor \(2\). At \(x=1\) this error would change the first term from \(6\cdot16=96\) to \(48\) and give a wrong total. The Chain Rule requires multiplying by the derivative of the inside every time.

Differentiating a product factor by factor. It is false that \((AB)'=A'B'\). For \(f=x^2(x+1)^4\), \(A'B'=2x\cdot4(x+1)^3\), which at \(x=1\) equals \(64\) here by coincidence, but at \(x=2\) it gives \(4\cdot108=432\) while the true derivative is \(2\cdot2\cdot27\cdot7=756\).

Over-expanding. It is usually a mistake to multiply out \(x^2(x+1)^4\) before differentiating. The factored derivative \(2x(x+1)^3(3x+1)\) is compact and shows the zeros immediately. Expansion produces a degree-six polynomial that is harder to analyze.

Tangent Lines from the Combined Rule

One reason to simplify the derivative is that it makes applications easy. For \(f(x)=x^2(x+1)^4\), we found \(f'(x)=2x(x+1)^3(3x+1)\). To write the tangent line at \(x=1\), compute \(f(1)=1\cdot16=16\) and \(f'(1)=64\). The tangent line is \(y=16+64(x-1)=64x-48\).

Check the quality of the approximation: at \(x=1.01\) the line predicts \(16.64\), while the function value is \(16.650488\). At \(x=1.1\) the line predicts \(22.4\), while \(f(1.1)=23.532201\). The line is accurate very close to \(1\) and drifts away as \(x\) moves farther, exactly as a tangent line should.

Worked Example: A Trigonometric Factor

Differentiate \(p(x)=x^2\sin(3x)\).

The derivative of \(\sin(3x)\) is \(3\cos(3x)\) by the Chain Rule. The Product Rule gives

$$ p'(x)=2x\sin(3x)+3x^2\cos(3x)=x\bigl[2\sin(3x)+3x\cos(3x)\bigr]. $$

Check at \(x=1\): \(p'(1)=2\sin 3+3\cos 3\approx-2.68774\). A numerical derivative of \(p\) at \(1\) gives -2.68774, which matches.

A Decision Guide

When an expression combines operations, choose the rule by looking at the outermost operation. The table summarizes the pattern used in the examples above.

ExpressionOutermost operationFirst ruleInner rule needed
x²(x+1)⁴productProduct RuleChain Rule on (x+1)⁴
(2x−1)³(x²+3)²productProduct RuleChain Rule on both factors
x√(1−x²)productProduct RuleChain Rule on the radical
x e^(−x²)productProduct RuleChain Rule on the exponential
(x²(x+1))⁴fourth powerChain RuleProduct Rule on the inside

The last row shows the reverse nesting. For \(\bigl(x^2(x+1)\bigr)^4\), the outermost operation is the fourth power, so the Chain Rule comes first and the Product Rule is used for the derivative of the inside. The same two rules appear, but in the opposite order, which is why reading the expression from the outside in is the safest habit.

Factoring Strategy

After the Product Rule, each term contains the factors from the original expression raised to powers one lower or equal to the originals. The common factor to extract is the lowest power of each repeated base. In \(2x(x+1)^4+4x^2(x+1)^3\), the base \(x\) appears with powers \(1\) and \(2\), so factor \(x^1\); the base \(x+1\) appears with powers \(4\) and \(3\), so factor \((x+1)^3\); and the numerical factors \(2\) and \(4\) share the factor \(2\). The remaining bracket, \((x+1)+2x\), is a simple linear expression. Factoring this way makes the zeros of the derivative visible at a glance.

Worked Example: Three Factors

Differentiate \(q(x)=x(x-1)^2(x+2)^3\).

With three factors, take the derivative of one factor at a time and keep the other two unchanged:

$$ q'(x)=(x-1)^2(x+2)^3+2x(x-1)(x+2)^3+3x(x-1)^2(x+2)^2. $$

The common part is \((x-1)(x+2)^2\). Factoring it out,

$$ q'(x)=(x-1)(x+2)^2\bigl[(x-1)(x+2)+2x(x+2)+3x(x-1)\bigr]=(x-1)(x+2)^2\bigl(6x^2+2x-2\bigr). $$

Check at \(x=1\): the factored form is \(0\) because of the factor \(x-1\). In the unfactored form, the first and third terms each contain \((x-1)\) and vanish, and the second term is \(2\cdot1\cdot0\cdot27=0\). Both give zero. At \(x=2\), the factored form is \(1\cdot16\cdot(24+4-2)=416\).

The rule behind this result extends to any number of factors: the derivative of a product is the sum, over the factors, of the derivative of that factor times all the others.

Where This Fits in the Course

This tutorial belongs to the module “Product, Quotient, and Chain Rules”. The tutorial just before it is “Quotients with Composite Numerators and Denominators,” and the one that follows is “Products of Composite Functions.”

Practice Problems with Answers

Try each problem before reading the answer. Each answer below was verified by differentiation or by evaluating a difference quotient or integral numerically.

  1. Differentiate \(x^3(2x+5)^2\) and simplify.
    Answer. \(x^2(2x+5)\bigl[3(2x+5)+4x\bigr]=x^2(2x+5)(10x+15)=5x^2(2x+5)(2x+3)\).
  2. Differentiate \((x-1)^2(x+2)^3\) and simplify.
    Answer. \((x-1)(x+2)^2\bigl[2(x+2)+3(x-1)\bigr]=(x-1)(x+2)^2(5x+1)\).
  3. Differentiate \(x^2\sqrt{x^2+1}\).
    Answer. \(2x\sqrt{x^2+1}+\dfrac{x^3}{\sqrt{x^2+1}}=\dfrac{x(3x^2+2)}{\sqrt{x^2+1}}\).
  4. Where does \(x(x-3)^2\) have horizontal tangents?
    Answer. \(f'=(x-3)^2+2x(x-3)=(x-3)(3x-3)\), so at \(x=1\) and \(x=3\).

Check Your Understanding

Work these without looking back.

  1. Differentiate \(x^4(3x-2)^5\) and factor the result.
  2. Differentiate \((x^2+1)^3(x-2)^2\).
  3. Which rule is applied first for \(x\sqrt{x+1}\)? Differentiate it.
  4. Find the critical points of \(x^2(x-4)^2\).
  5. Explain why \((AB)'=A'B'\) is false using \(A=B=x\).

Test yourself: Calculus I 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