Lesson 8: The Product Rule
The Product Rule
Example 1: Motivating the Product Rule
Suppose \(f(x) = 3x^3(5x^2 + 7x)\). Find \(f'(x)\).
Solution (by expanding first):
First, expand the product:
\[f(x) = 3x^3(5x^2 + 7x) = 15x^5 + 21x^4\]Then, take the derivative:
\[f'(x) = 75x^4 + 84x^3\]Why We Need the Product Rule
What happens if we take the derivative of each factor and multiply them together?
Warning: The derivative of a product is NOT the product of the derivatives!
If we incorrectly tried to find the derivative by taking \(f'(x) = 9x^2(10x + 7)\), we would get \(90x^3 + 63x^2\), which is wrong.
\[\frac{d}{dx}[f(x)g(x)] \neq \left[\frac{d}{dx}f(x)\right]\left[\frac{d}{dx}g(x)\right]\]The Product Rule: Using the limit definition of a derivative (and some cleverness), we can show that
\[\frac{d}{dx}[f(x)g(x)] = \left[\frac{d}{dx}f(x)\right]g(x) + \left[\frac{d}{dx}g(x)\right]f(x)\]Or more simply: \((fg)' = f'g + g'f\)
Proof of the Product Rule
Proof: We will use the limit definition of the derivative along with some algebraic manipulation.
Starting with the definition:
\[\frac{d}{dx}(f(x)g(x)) = \lim_{h \to 0} \frac{f(x+h)g(x+h) - f(x)g(x)}{h}\]The key insight is to add and subtract \(f(x+h)g(x)\) in the numerator (adding zero in a clever way):
\[\lim_{h \to 0} \frac{f(x+h)g(x+h) - f(x)g(x)}{h}=\lim_{h \to 0} \frac{f(x+h)g(x+h) - f(x+h)g(x) + f(x+h)g(x) - f(x)g(x)}{h}\]Rearranging and factoring, we get that:
\[\frac{d}{dx}(f(x)g(x)) =\lim_{h \to 0} \frac{f(x+h)g(x+h) - f(x+h)g(x)}{h} + \lim_{h \to 0} \frac{f(x+h)g(x) - f(x)g(x)}{h}\]Factoring out common terms:
\[\frac{d}{dx}(f(x)g(x)) = \lim_{h \to 0} f(x+h) \left[\frac{g(x+h) - g(x)}{h}\right] + \lim_{h \to 0} g(x) \left[\frac{f(x+h) - f(x)}{h}\right]\]Using limit properties:
\[\frac{d}{dx}(f(x)g(x)) = \lim_{h \to 0} f(x+h) \cdot \lim_{h \to 0} \left[\frac{g(x+h) - g(x)}{h}\right] + g(x) \cdot \lim_{h \to 0} \left[\frac{f(x+h) - f(x)}{h}\right]\]Recognizing the derivative definition:
\[\frac{d}{dx}(f(x)g(x)) = f(x) \cdot g'(x) + g(x) \cdot f'(x)\]Therefore:
\[\frac{d}{dx}[f(x)g(x)] = f(x)g'(x) + g(x)f'(x)\]Examples
Example 1 (revisited): Using the Product Rule
Suppose \(y = 3x^3(5x^2 + 7x)\). Find \(y'\) using the product rule.
Solution:
Let \(f(x) = 3x^3\) and \(g(x) = 5x^2 + 7x\). Then:
\[f'(x) = 9x^2\] \[g'(x) = 10x + 7\]Using the product rule \(y' = f'(x)g(x) + g'(x)f(x)\):
\[\begin{align} y' &= 9x^2(5x^2 + 7x) + (10x + 7)(3x^3)\\ &= 45x^4 + 63x^3 + 30x^4 + 21x^3\\ &= 75x^4 + 84x^3\end{align}\]This matches our result from expanding first!
Example 2: Product Rule with Exponential and Trigonometric Functions
Find the derivative of \(y = 3e^x\cos(x)\) at \(x = \pi\).
Solution:
Let \(f(x) = 3e^x\) and \(g(x) = \cos(x)\). Then:
\[f'(x) = 3e^x\] \[g'(x) = -\sin(x)\]Using the product rule:
\[\begin{align}y' &= f'(x)g(x) + g'(x)f(x)\\ &= 3e^x\cos(x) + (-\sin(x))(3e^x)\\ &= 3e^x\cos(x) - 3e^x\sin(x)\\ &= 3e^x(\cos(x) - \sin(x))\end{align}\]Now, evaluate at \(x = \pi\):
\[y'(\pi) = 3e^\pi(\cos(\pi) - \sin(\pi)) = 3e^\pi(-1 - 0) = -3e^\pi\]Practice Problems
Practice Problem 1: Finding Horizontal Tangent Lines
Find the \(x\)-values at which \(y = 6x^8e^x\) has a horizontal tangent line.
Solution:
A horizontal tangent line occurs where the derivative equals zero. Let \(f(x) = 6x^8\) and \(g(x) = e^x\). Then:
\[f'(x) = 48x^7\] \[g'(x) = e^x\]Using the product rule:
\[\begin{align}y' &= f'(x)g(x) + g'(x)f(x)\\ &= 48x^7e^x + e^x \cdot 6x^8\\ &= 48x^7e^x + 6x^8e^x\\ &= 6x^7e^x(8 + x)\end{align}\]Set the derivative equal to zero and solve:
\[6x^7e^x(8 + x) = 0\]Since \(e^x\) is never zero, we need:
\[6x^7(8 + x) = 0\]This gives us:
\[x = 0 \quad \text{or} \quad x = -8\]The function has horizontal tangent lines at \(x = 0\) and \(x = -8\).
Practice Problem 2: Equation of a Tangent Line
Find the equation of the tangent line to the curve of \(y = 7x\sin(x)\) at \(x = \pi\).
Solution:
Let \(f(x) = 7x\) and \(g(x) = \sin(x)\). Then:
\[f'(x) = 7\] \[g'(x) = \cos(x)\]Using the product rule:
\[\begin{align} y' &= f'(x)g(x) + g'(x)f(x)\\ &=7\sin(x) + \cos(x) \cdot 7x\\ &= 7\sin(x) + 7x\cos(x)\end{align}\]The slope of the tangent line at \(x = \pi\) is:
\[y'(\pi) = 7\sin(\pi) + 7\pi\cos(\pi) = 7\cdot 0 + 7\pi\cdot -1 = -7\pi\]The point on the curve at \(x = \pi\) is:
\[y(\pi) = 7\pi\sin(\pi) = 7\pi\cdot 0 = 0\]So, a point on the tangent line is \((\pi, 0)\).
Using the point-slope form, namely \(y - y_1 = m(x - x_1)\):
\[y - 0 = -7\pi(x - \pi)\] \[y = -7\pi x + 7\pi^2\]