Differentiation: Chapter 03

The Product Rule

Why you cannot just multiply derivatives: the correct formula, a proof from first principles, 12 fully worked exercises, and a 10-question quiz.

✦ Full Proof ✦ 12 Exercises ✦ Poly · Trig ✦ Poly · Exp ✦ Triple Products ✦ 10-Question Quiz
Share this page

§ 01What Is the Product Rule?

The product rule answers a simple but surprisingly tricky question: how do you differentiate two functions that are multiplied together?

In calculus, we often encounter functions like y = x³ · sin x or y = eˣ · ln x, two separate functions sitting side by side, multiplied. Instinct might suggest: just differentiate each one and multiply the results. That instinct is wrong, and understanding why it is wrong will help the correct formula stick.

Consider f(x) = x² and g(x) = x³. Their product is f · g = x⁵, whose derivative is 5x⁴. Now try multiplying the individual derivatives: f′ = 2x and g′ = 3x², so f′ · g′ = 2x · 3x² = 6x³. That is clearly not 5x⁴. The rule "multiply the derivatives" fails because multiplication interacts with limits in a more complex way than addition does.

The sum rule works term by term: d/dx[f + g] = f′ + g′. But the product rule is different, it produces a sum of two cross terms, not a single product.

The Product Rule
If   y = u · v   then   dy/dx = u′v + uv′

In words: differentiate the first function and multiply by the second, then add the first function multiplied by the derivative of the second. This is sometimes remembered as "d-first times second, plus first times d-second."

§ 02Proof from First Principles

The product rule is not handed down from authority, it can be derived from the fundamental limit definition of the derivative. Here is the full argument.

We want to find the derivative of h(x) = u(x) · v(x). Using the limit definition:

Derivation — Product Rule from the Limit Definition

Write the definition of h′(x) using the limit:

h′(x) = lim[h→0]   [u(x+h)v(x+h) − u(x)v(x)] ÷ h We are applying the standard derivative definition h(x) = u(x)v(x), so h(x+Δx) = u(x+h)·v(x+h).

Add and subtract the term u(x) · v(x+h) inside the numerator. This is the key algebraic trick, we are adding zero (since we add and subtract the same thing), but it breaks the expression into two useful pieces:

= lim[h→0]   [u(x+h)v(x+h) − u(x)v(x+h) + u(x)v(x+h) − u(x)v(x)] ÷ h Check: the +u(x)v(x+h) and −u(x)v(x+h) cancel each other out, so the numerator is unchanged.

Group the numerator into two separate fractions, the first involving changes in u, the second involving changes in v:

= lim[h→0]   v(x+h) · [u(x+h) − u(x)] ÷ h   +   lim[h→0]   u(x) · [v(x+h) − v(x)] ÷ h

Evaluate each limit separately as h → 0:

[u(x+h) − u(x)] ÷ h   →   u′(x)   (by definition of the derivative) [v(x+h) − v(x)] ÷ h   →   v′(x)   (by definition of the derivative) v(x+h)   →   v(x)   (since v is continuous, as h → 0 the argument converges) We need u and v to be differentiable — and differentiable functions are automatically continuous.

Assemble the result:

h′(x) = v(x) · u′(x) + u(x) · v′(x) = u′v + uv′   ✓ This is the product rule. The proof shows exactly why there are two terms — one from the change in u, one from the change in v.

This proof is worth understanding, not just memorising. The "add and subtract a middle term" trick is one of the most useful manoeuvres in mathematical analysis: you will see it again in many different proofs.

§ 03How to Apply the Product Rule — Step by Step

The product rule is mechanical once you establish a clear routine. Follow these four steps every time.

Worked example — x² · sin x
y = x² · sin x

Step 1:   u = x²,   v = sin x
Step 2:   u′ = 2x,   v′ = cos x
Step 3:   dy/dx = u′v + uv′
      = 2x · sin x + x² · cos x
Step 4:   Factorise x:
      = x(2 sin x + x cos x)

Notation Choices

You may see the product rule written in several equivalent ways. All of the following mean exactly the same thing:

Get comfortable with all of them, since textbooks and lecturers vary in which form they prefer.

The Triple Product Extension

When three functions are multiplied together, say y = u · v · w, the product rule extends naturally. You can either group (uv) as a single unit and apply the two-function rule, or use the direct generalisation:

Triple Product Rule
If   y = u · v · w   then:
dy/dx = u′vw + uv′w + uvw′

The pattern is clear: each term differentiates exactly one factor while leaving the other two untouched. There are three such terms because there are three factors, each getting "its turn" to be differentiated.

✦ When to Simplify Before Differentiating Sometimes what looks like a product rule problem can be simplified first to avoid it altogether. For example, y = x(x + 3) looks like a product, but expanding gives y = x² + 3x, which is just two power rule terms. If expanding is quick, do it — it often saves time and reduces errors. Use the product rule when expanding would make things messier, such as y = x⁵ · (x⁴ + 3x² − 7), where expanding and then differentiating term by term requires much more work.

§ 04Common Mistakes

Most errors with the product rule fall into three categories. Recognise them now so you do not repeat them in an exam.

⚠ Mistake 1 — Multiplying the Derivatives Directly
Wrong:   d/dx[x² · sin x] = 2x · cos x

Why it's wrong: This differentiates each function and multiplies the results. But as the counterexample with x² and x³ showed, this does not give the correct derivative of their product.

Correct:   d/dx[x² · sin x] = 2x · sin x + x² · cos x   ✓

The product rule always produces a sum of two terms, not a single product.
⚠ Mistake 2 — Confusing Product Rule with Chain Rule
Wrong:   Applying the product rule to sin(x²)

Why it's wrong: sin(x²) is a composite function — x² is inside the sine function. It is not a product. The product rule applies when two functions are being multiplied. When one function is nested inside another, you need the chain rule instead.

How to tell the difference: If you can write it as f(x) · g(x) — two separate functions side by side — it is a product. If there is a function inside another function, it is a composition.
⚠ Mistake 3 — Forgetting to Differentiate One Factor
Wrong:   d/dx[x³ · eˣ] = 3x² · eˣ   (kept eˣ but never found its derivative separately and added it)

Why it's wrong: The formula requires both combinations: u′v AND uv′. Leaving out one term gives an incomplete answer.

Correct:   d/dx[x³ · eˣ] = 3x² · eˣ + x³ · eˣ = x²eˣ(3 + x)   ✓
⚠ Mistake 4 — Dropping the Chain Rule When v is a Composite Function
Wrong:   d/dx[x · (2x+1)³] — writing v′ = 3(2x+1)² without multiplying by the inner derivative 2

Why it's wrong: When one of your factors is itself a composite function — like (2x+1)³ — you must use the chain rule to find its derivative. Here, v′ = 3(2x+1)² · 2 = 6(2x+1)².

Rule of thumb: Before writing down v′, always ask yourself — is v a simple function, or is there something inside something? If inside, chain rule applies.

§ 05Standard Derivatives You Need to Know

The product rule only moves you forward if you already know the derivatives of the individual functions. These are the ones that appear most often.

Standard derivatives — commit these to memory
d/dx[xⁿ]    = nxⁿ⁻¹
d/dx[eˣ]    = eˣ
d/dx[aˣ]    = aˣ ln a  (a is a positive constant)
d/dx[ln x]   = 1/x
d/dx[sin x]   = cos x
d/dx[cos x]   = −sin x  (note the minus sign)
d/dx[tan x]   = sec²x
d/dx[sec x]   = sec x tan x
d/dx[cosec x] = −cosec x cot x
d/dx[cot x]   = −cosec²x

If you are unsure about the derivative of a trig function, visit the Trig Derivatives page for the full derivations. If you need the chain rule applied to composite versions of these (like sin(3x) or e^(x²)), see the Chain Rule page.

§ 06Worked Exercises — 12 Problems

Work through each problem yourself before revealing the solution. Every step is explained in plain English: nothing is skipped.

Exercises completed: 0 of 12

Group A — Polynomial × Trigonometric (Exercises 1 – 3)

Exercise 1 — Polynomial × Sine
Find dy/dx when   y = x⁴ · sin x
  1. Recognise the structure: two different functions multiplied together. This calls for the product rule. The two factors are x⁴ (a polynomial) and sin x (a trigonometric function). Neither can be simplified into the other, so there is no shortcut.
  2. Label the two factors as u and v: u = x⁴   v = sin x
  3. Differentiate u using the power rule, bring down the exponent 4, reduce the power by 1: u′ = 4x³
  4. Differentiate v, the derivative of sin x is cos x (a standard result): v′ = cos x
  5. Apply the product rule formula dy/dx = u′v + uv′. Substitute the four values: dy/dx = 4x³ · sin x + x⁴ · cos x
  6. Check whether any factorisation is possible. Both terms share a factor of x³: dy/dx = x³(4 sin x + x cos x) Answer: dy/dx = x³(4 sin x + x cos x)
Exercise 2 — Polynomial × Cosine (with Negative Derivative)
Find f′(x) when   f(x) = (3x² − 1) · cos x
  1. Two functions multiplied → product rule. Label them: u = 3x² − 1   v = cos x
  2. Differentiate u term by term. The constant −1 has derivative 0: u′ = d/dx[3x²] + d/dx[−1] = 6x + 0 = 6x
  3. Differentiate v, the derivative of cos x is −sin x. The minus sign is important and must not be dropped: v′ = −sin x Many students write v′ = sin x here. That is wrong. The derivative of cosine is negative sine.
  4. Apply the product rule: f′(x) = u′v + uv′. Substitute in: f′(x) = 6x · cos x + (3x² − 1) · (−sin x)
  5. Distribute the negative sign from the second term: f′(x) = 6x cos x − (3x² − 1) sin x You can leave the second term in brackets like this, or expand: 6x cos x − 3x² sin x + sin x. Both forms are correct.
  6. There is no further factorisation that simplifies things. The final answer is: Answer: f′(x) = 6x cos x − (3x² − 1) sin x
Exercise 3 — Linear × Tangent
Find dy/dx when   y = (x + 2) · tan x
  1. Two functions multiplied → product rule. Label them: u = x + 2   v = tan x
  2. Differentiate u. The derivative of x is 1 and the derivative of 2 (a constant) is 0: u′ = 1
  3. Differentiate v. The derivative of tan x is sec²x, a standard result from the quotient rule applied to sin x / cos x: v′ = sec²x If you haven't memorised d/dx[tan x] = sec²x yet, it is derived on the Trig Derivatives page.
  4. Apply the product rule: dy/dx = u′v + uv′: dy/dx = 1 · tan x + (x + 2) · sec²x
  5. Simplify: the first term needs no changes since 1 · tan x = tan x: dy/dx = tan x + (x + 2) sec²x Answer: dy/dx = tan x + (x + 2) sec²x

Group B — Polynomial × Exponential (Exercises 4 – 6)

Exercise 4 — Quadratic × eˣ
Find dy/dx when   y = (x² − 3x) · eˣ
  1. Two functions multiplied → product rule. Label: u = x² − 3x   v = eˣ
  2. Differentiate u term by term: u′ = d/dx[x²] + d/dx[−3x] = 2x − 3
  3. Differentiate v. The exponential function eˣ is its own derivative: this is one of the most remarkable facts in calculus: v′ = eˣ
  4. Apply the product rule: dy/dx = u′v + uv′: dy/dx = (2x − 3) · eˣ + (x² − 3x) · eˣ
  5. Both terms share a common factor of eˣ. Factorise it out: dy/dx = eˣ[(2x − 3) + (x² − 3x)]
  6. Collect like terms inside the bracket: 2x − 3 + x² − 3x = x² − x − 3: dy/dx = eˣ(x² − x − 3) Answer: dy/dx = eˣ(x² − x − 3)
Exercise 5 — Linear × eˣ (with Repeated IBP Connection)
Find dy/dx when   y = (2x + 5) · eˣ
  1. Two functions multiplied → product rule. Label: u = 2x + 5   v = eˣ
  2. Differentiate u. The derivative of 2x is 2; the derivative of 5 (constant) is 0: u′ = 2
  3. Differentiate v. Again, eˣ is its own derivative: v′ = eˣ
  4. Apply the product rule: dy/dx = u′v + uv′: dy/dx = 2 · eˣ + (2x + 5) · eˣ
  5. Factorise the common factor eˣ: dy/dx = eˣ[2 + (2x + 5)]
  6. Simplify inside the bracket: 2 + 2x + 5 = 2x + 7: dy/dx = eˣ(2x + 7) Observe the pattern: for y = (ax + b)eˣ, the derivative is always eˣ(ax + b + a). The bracket shifts up by a, which is the coefficient of x. This is a useful pattern to recognise when checking your work. Answer: dy/dx = eˣ(2x + 7)
Exercise 6 — Polynomial × aˣ
Find dy/dx when   y = x² · 2ˣ
  1. Two functions multiplied → product rule. Label: u = x²   v = 2ˣ
  2. Differentiate u using the power rule: u′ = 2x
  3. Differentiate v. This is a general exponential function aˣ with base a = 2. Its derivative uses the formula d/dx[aˣ] = aˣ ln a: v′ = 2ˣ · ln 2 The ln 2 factor arises because when the base is not e, differentiating pulls down a natural logarithm of the base. When the base is e, ln e = 1 and that factor disappears, which is why d/dx[eˣ] = eˣ · 1 = eˣ.
  4. Apply the product rule: dy/dx = u′v + uv′: dy/dx = 2x · 2ˣ + x² · 2ˣ ln 2
  5. Factorise the common factor of x · 2ˣ: dy/dx = x · 2ˣ (2 + x ln 2) Answer: dy/dx = x · 2ˣ(2 + x ln 2)

Group C — Polynomial × Logarithm (Exercises 7 – 8)

Exercise 7 — Quadratic × ln x
Find dy/dx when   y = x³ · ln x
  1. Two functions multiplied → product rule. Label: u = x³   v = ln x
  2. Differentiate u with the power rule: u′ = 3x²
  3. Differentiate v. The derivative of the natural logarithm is 1/x: one of the most important standard results: v′ = 1/x This result comes from inverting d/dx[eˣ] = eˣ. If y = ln x then x = eʸ, differentiating implicitly gives 1 = eʸ · dy/dx, so dy/dx = 1/eʸ = 1/x.
  4. Apply the product rule: dy/dx = u′v + uv′: dy/dx = 3x² · ln x + x³ · (1/x)
  5. Simplify the second term: x³ · (1/x) = x³/x = x²: dy/dx = 3x² ln x + x²
  6. Factorise x² from both terms: dy/dx = x²(3 ln x + 1) Answer: dy/dx = x²(3 ln x + 1)
Exercise 8 — √x × ln x
Find dy/dx when   y = √x · ln x   (write √x = x½ first)
  1. Rewrite √x as a fractional exponent to make differentiation straightforward: y = x^(1/2) · ln x
  2. Two functions multiplied → product rule. Label: u = x^(1/2)   v = ln x
  3. Differentiate u using the power rule: bring down 1/2, subtract 1 from the exponent: u′ = (1/2) · x^(1/2 − 1) = (1/2) · x^(−1/2) = 1 ÷ (2√x)
  4. Differentiate v: v′ = 1/x
  5. Apply the product rule: dy/dx = u′v + uv′: dy/dx = [1 ÷ (2√x)] · ln x + x^(1/2) · (1/x)
  6. Simplify the second term: x^(1/2) · (1/x) = x^(1/2) · x^(−1) = x^(−1/2) = 1/√x: dy/dx = ln x ÷ (2√x) + 1/√x
  7. Both terms have a denominator of 2√x if we write 1/√x as 2/(2√x). Place both over the common denominator: dy/dx = ln x ÷ (2√x) + 2 ÷ (2√x) dy/dx = (ln x + 2) ÷ (2√x) Answer: dy/dx = (ln x + 2) ÷ (2√x)

Group D — Product Rule with Chain Rule (Exercises 9 – 12)

Exercise 9 — Product Rule + Chain Rule (Polynomial × Composite Power)
Find dy/dx when   y = x³ · (4x − 1)⁵
  1. Outer structure: two functions multiplied → product rule. Label: u = x³   v = (4x − 1)⁵
  2. Differentiate u with the power rule (straightforward): u′ = 3x²
  3. Differentiate v: this requires the chain rule, because (4x − 1) is a function sitting inside a power of 5. First identify the inner and outer functions: Outer function: something⁵   Inner function: 4x − 1
  4. Apply chain rule to v: differentiate outer (bring down 5, reduce power), then multiply by inner derivative: Outer derivative: 5(4x − 1)⁴ Inner derivative: d/dx[4x − 1] = 4 v′ = 5(4x − 1)⁴ · 4 = 20(4x − 1)⁴
  5. Now apply the product rule: dy/dx = u′v + uv′: dy/dx = 3x² · (4x − 1)⁵ + x³ · 20(4x − 1)⁴
  6. Look for common factors. Both terms contain x² and (4x − 1)⁴: dy/dx = x²(4x − 1)⁴ [3(4x − 1) + 20x]
  7. Expand inside the bracket: 3(4x − 1) + 20x = 12x − 3 + 20x = 32x − 3: dy/dx = x²(4x − 1)⁴(32x − 3) Answer: dy/dx = x²(4x − 1)⁴(32x − 3)
Exercise 10 — Product Rule + Chain Rule (Poly × Composite Trig)
Find dy/dx when   y = x² · sin(3x)
  1. Outer structure: two functions multiplied → product rule. Label: u = x²   v = sin(3x)
  2. Differentiate u: u′ = 2x
  3. Differentiate v: sin(3x) is a composite function: 3x sits inside the sine. The chain rule is needed here. Outer function: sin(something) (derivative is cos(something). Inner function: 3x) derivative is 3.
  4. Apply chain rule: differentiate the outer (keeping the inside unchanged), then multiply by the inner derivative: v′ = cos(3x) · 3 = 3 cos(3x)
  5. Now apply the product rule: dy/dx = u′v + uv′: dy/dx = 2x · sin(3x) + x² · 3 cos(3x)
  6. Reorder the second term conventionally (coefficient before variable): dy/dx = 2x sin(3x) + 3x² cos(3x)
  7. Factorise the common factor of x: dy/dx = x[2 sin(3x) + 3x cos(3x)] Answer: dy/dx = x[2 sin(3x) + 3x cos(3x)]
Exercise 11 — Product Rule + Chain Rule (Poly × Composite Exponential)
Find dy/dx when   y = (x + 1) · e^(x²)
  1. Two functions multiplied → product rule. Label: u = x + 1   v = e^(x²)
  2. Differentiate u. The derivative of x is 1 and the derivative of 1 (constant) is 0: u′ = 1
  3. Differentiate v: this requires the chain rule. The inner function is x² sitting inside the exponential e^(something): Outer function: e^(something), derivative is e^(something) (exponential is its own derivative). Inner function: x², derivative is 2x.
  4. Apply chain rule: outer derivative × inner derivative: v′ = e^(x²) · 2x = 2x e^(x²)
  5. Now apply the product rule: dy/dx = u′v + uv′: dy/dx = 1 · e^(x²) + (x + 1) · 2x e^(x²)
  6. Factorise the common factor e^(x²): dy/dx = e^(x²)[1 + 2x(x + 1)]
  7. Expand inside the bracket: 1 + 2x(x + 1) = 1 + 2x² + 2x: dy/dx = e^(x²)(2x² + 2x + 1) Answer: dy/dx = e^(x²)(2x² + 2x + 1)
Exercise 12 — Triple Product Rule
Find dy/dx when   y = x · eˣ · sin x
  1. Three functions are all multiplied together. We use the triple product rule: dy/dx = u′vw + uv′w + uvw′. Label: u = x   v = eˣ   w = sin x Alternatively you could group (x · eˣ) as a single unit and apply the two-function product rule twice. Both methods give the same answer. We will use the direct triple product rule here.
  2. Differentiate each factor individually: u′ = d/dx[x] = 1 v′ = d/dx[eˣ] = eˣ w′ = d/dx[sin x] = cos x
  3. Write out all three terms of the triple product rule, each differentiating exactly one factor: Term 1: u′vw, differentiate u, keep v and w unchanged. u′vw = 1 · eˣ · sin x = eˣ sin x Term 2: uv′w: keep u, differentiate v, keep w unchanged. uv′w = x · eˣ · sin x = xeˣ sin x Term 3: uvw′: keep u and v, differentiate w. uvw′ = x · eˣ · cos x = xeˣ cos x
  4. Add all three terms: dy/dx = eˣ sin x + xeˣ sin x + xeˣ cos x
  5. Factorise eˣ from all three terms: dy/dx = eˣ(sin x + x sin x + x cos x)
  6. Factorise further, the last two terms inside the bracket share a factor of x: dy/dx = eˣ[sin x + x(sin x + cos x)] Answer: dy/dx = eˣ[sin x + x(sin x + cos x)]

§ 0710-Question Quiz

Test your understanding. Select your answer and hit Submit Quiz to see your score with feedback on every question.

Product Rule — Test Yourself

Question 1

What does the product rule state for y = u · v?

  • dy/dx = u′ · v′
  • dy/dx = u′v + uv′
  • dy/dx = u′v − uv′
  • dy/dx = (u + v)′
Question 2

Find d/dx[x² · eˣ].

  • 2xeˣ
  • x²eˣ
  • eˣ(x² + 2x)
  • 2x + eˣ
Question 3

Find d/dx[x · ln x].

  • ln x
  • 1/x
  • ln x + 1
  • x/ln x
Question 4

Why can you NOT compute d/dx[f · g] simply as f′ · g′?

  • You can, that is the correct rule
  • Multiplication does not distribute through limits the same way addition does
  • It only works when f and g are polynomials
  • Because the product rule requires integration
Question 5

Find d/dx[sin x · cos x].

  • −sin²x + cos²x   (i.e. cos 2x)
  • −sin x · cos x
  • cos²x
  • sin x + cos x
Question 6

For y = u · v · w, the triple product rule gives dy/dx = ?

  • u′v′w′
  • u′vw + uv′w + uvw′
  • (u + v + w)′
  • u′vw + uv′w
Question 7

Find d/dx[x³ · (2x + 1)²] at x = 0.

  • 0
  • 1
  • 3
  • 6
Question 8

Which step in differentiating y = x · sin(x²) requires the chain rule?

  • Differentiating x
  • Differentiating sin(x²)
  • The product rule itself
  • Neither: only the power rule is needed
Question 9

Find d/dx[eˣ · sin x].

  • eˣ cos x
  • eˣ(sin x − cos x)
  • eˣ(sin x + cos x)
  • eˣ sin x · eˣ cos x
Question 10

Which of these is the fully factorised form of d/dx[x² · eˣ]?

  • xeˣ(x + 2)
  • eˣ(x² + 2x)
  • x²eˣ + 2xeˣ
  • 2xeˣ
❧     ❧     ❧

Cookie Settings