Derivative of x·sin(x)
x·sin(x) is the classic first product-rule problem: two variable factors multiplied, so the product rule is the direct approach.
Step-by-step solution
Both factors depend on x: u = x and v = sin(x). Neither is a constant, so apply the product rule.
(uv)′ = u′v + uv′: differentiate one factor at a time, keeping the other frozen, then add.
u′ = 1 and v′ = cos(x), so f′(x) = 1·sin(x) + x·cos(x) = sin(x) + x cos(x).
Why it works
The two-term answer reflects two separate ways the product can change: the x factor growing while the wave holds still (contributing sin(x)), and the wave moving while x holds still (contributing x·cos(x)). The product rule is exactly this accounting — total change equals the sum of each factor's contribution with the other momentarily frozen.
The graph of x·sin(x) is a sine wave inside an ever-widening envelope of ±x, and the derivative explains its behavior: for large |x| the x·cos(x) term controls the growing slope envelope, so the oscillations get steeper and steeper while the original function is zero at every multiple of π. It's the standard example of oscillation with growing amplitude.
Domain and slopes at the zeros
The product x sin(x) is differentiable for all real x, with the sine argument in radians. At x = kπ, where k is an integer, the function is zero but its derivative is kπ(−1)ᵏ. Thus the nonzero multiples of π are not stationary points merely because the function crosses zero there.
At x = π the slope is −π and the tangent line is y = −π(x − π). At x = 0 both the function and derivative are zero. The product rule produces two terms because both factors change; it does not multiply their derivatives together.
Common mistakes
- Multiplying the derivatives: writing 1·cos(x) = cos(x). The derivative of a product is not the product of derivatives — this is the error the product rule exists to prevent.
- Forgetting one of the two terms, usually the sin(x) from differentiating the plain x.
- Sign confusion after several steps when the problem extends to x·cos(x), whose derivative is cos(x) − x sin(x).
Practice problems
Differentiate x·cos(x)
Answer: cos(x) − x sin(x).
Differentiate x² sin(x)
Answer: 2x sin(x) + x² cos(x).
Differentiate x ex
Answer: ex(1 + x).