Type a function of x in the f(x) box. The calculator writes its derivative f′(x) as a formula, draws it on the graph beside f, and says in How it was found how it got there. Everything updates as you type.
Any function the site's graphing tools understand can be differentiated: powers and roots, polynomials, fractions, sin, cos, tan and their inverses, ex, ln and log, absolute value, and any combination of them. The formula is given as the rules produce it; sometimes it is correct but not in its shortest form, and a little algebra tidies it.
Reading the two graphs
Demof and f′ together
Step 0 of 4
The blue curve is f and the amber curve is f′. Read them together, at the same x:
Where frises, f′ is above the x-axis; where ffalls, f′ is below it.
Where f has a top or a bottom, f′ is zero: it crosses the axis right below that point.
Where f is steepest, f′ is at its highest or lowest.
The height of the amber curve at x is the slope of the blue curve at x.
What the derivative is
The derivative of f at a point is the slope of the curve there: how fast f(x) changes as x grows. It is defined as a limit of slopes of secant lines,
f′(x)=h→0limhf(x+h)−f(x),
and its value is the slope of the tangent line at that point. For f(x)=2x2 the tangent at x=2 has slope 2 and the tangent at x=−1 has slope −1: in general f′(x)=x. Collecting the slope at every x gives a new function, f′, the derivative function.
Tangent lines to y=2x2: slope 2 at x=2, slope −1 at x=−1.
The rules used
Derivatives are found with a handful of rules, applied again and again:
Constant: the derivative of a number is 0.
Power rule: dxdxn=nxn−1, for any real n; so dxdx=2x1.
Sum and constant multiple: differentiate term by term; numbers in front stay in front.
Product rule: (uv)′=u′v+uv′.
Quotient rule: (vu)′=v2u′v−uv′.
Chain rule: (f(g(x)))′=f′(g(x))g′(x); so dxdsin(3x)=3cos(3x).
With the derivatives of the basic functions below, these rules cover every function you can type.
Turning points and the sign of the derivative
Because f′ is the slope of f, its sign tells where f goes up or down, and its zeros mark the candidates for the highest and lowest points.
For f(x)=4x3−1.5x, the derivative is f′(x)=43x2−1.5, which is zero at x=±2. Left of −2 it is positive (rising), between the two it is negative (falling), and right of 2 positive again. So f has a local top at x=−2 and a local bottom at x=2 — exactly where the picture shows them.
f (blue) has its top and bottom where f′ (dashed amber) is zero.
Derivatives of common functions
dxdsinx=cosx and dxdcosx=−sinx
dxdtanx=cos2x1
dxdex=ex and dxdax=axlna
dxdlnx=x1 and dxdlogax=xlna1
dxdarcsinx=1−x21 and dxdarctanx=1+x21
dxd∣x∣=∣x∣x for x=0
Try each one in the calculator and compare the two curves: ex and its derivative are the same curve, and cos is sin moved a quarter period to the left.
Where the derivative does not exist
A function has no derivative where its graph has no single slope:
A corner: ∣x∣ at x=0 has slope −1 on the left and 1 on the right, so there is no slope at the corner itself. The derivative jumps from −1 to 1.
A vertical tangent: 3x at x=0 becomes vertical; its slope grows without bound.
A break: where f is not defined or jumps, as x1 at 0, there is no derivative either.
The amber curve shows these places as gaps or jumps.
∣x∣ has a corner at 0; its derivative jumps from −1 to 1.
The second derivative
Differentiating f′ again gives the second derivativef′′, which tells how the slope itself changes: where f′′>0 the curve bends upward (it is concave up), and where f′′<0itbendsdownward.Pointswheref''$ changes sign are inflection points.
To get f′′, type the derivative from this calculator back into the f(x) box. In the Graphing Calculator you can draw f, f′ and f′′ at once by writing f(x)=… and then y=f′(x) and y=f′′(x).
Common mistakes
Differentiating a product factor by factor.(x2sinx)′=2xcosx; the product rule gives 2xsinx+x2cosx.
Forgetting the chain rule.(sin3x)′=3cos3x, not cos3x; (ex2)′=2xex2.
Using the power rule on ax.(2x)′=2xln2, not x2x−1; the power rule is for xn with a fixed exponent.
Reading f′ as f. Where the amber curve crosses the axis, f is flat — it is not where f is zero.
Expecting a derivative at a corner.∣x∣ has none at 0.
Related tools
To find the tangent line at one point — its slope and its equation — use the Tangent Line Calculator. To see the derivative together with the rest of a function's behaviour, open it in the Function Explorer. For the limit definition in motion, see the Derivative visualizer.