Open Calculator

Derivative Calculator

Symbolic derivatives with every rule shown step by step.

How the derivative calculator works

The calculator parses your expression into a tree, then applies the standard differentiation rules from the top down. Every rule it uses is recorded, so the steps read like a worked solution: the outer rule first, then the derivatives of the pieces, then a final simplification that merges like terms and folds constants exactly (fractions stay fractions, so d/dx of x/3 is 1/3, not 0.3333).

Worked example: d/dx of x^3 + sin(2x)

The top of the tree is a sum, so the sum rule splits the problem into d/dx[x^3] and d/dx[sin(2x)]. The first piece is the power rule: bring the exponent down and lower it by one, giving 3x^2. The second piece is a sine of an inner expression, so the chain rule applies: the derivative of sin is cos, evaluated at the inner expression, times the derivative of the inner expression. d/dx[2x] is 2 by the constant multiple rule, so the piece becomes 2cos(2x). Adding the pieces gives 3x^2 + 2cos(2x), which is exactly what the calculator shows with the default input.

Derivative rules table

RuleStatementExample
Constantd/dx [c] = 0d/dx [7] = 0
Powerd/dx [x^n] = n x^(n-1)d/dx [x^3] = 3x^2
Constant multipled/dx [c f] = c f'd/dx [5x^2] = 10x
Sum(f + g)' = f' + g'd/dx [x^2 + x] = 2x + 1
Product(f g)' = f' g + f g'd/dx [x e^x] = e^x + x e^x
Quotient(f / g)' = (f' g - f g') / g^2d/dx [x / (x + 1)] = 1 / (x + 1)^2
Chainf(g(x))' = f'(g(x)) g'(x)d/dx [sin(2x)] = 2cos(2x)
Exponentiald/dx [e^x] = e^x, d/dx [a^x] = a^x ln ad/dx [2^x] = 2^x ln 2
Logarithmd/dx [ln x] = 1 / xd/dx [ln(x^2 + 1)] = 2x / (x^2 + 1)

Derivatives of common functions

f(x)f'(x)f(x)f'(x)
sin xcos xasin x1 / sqrt(1 - x^2)
cos x-sin xacos x-1 / sqrt(1 - x^2)
tan xsec^2 xatan x1 / (1 + x^2)
sec xsec x tan xsinh xcosh x
csc x-csc x cot xcosh xsinh x
cot x-csc^2 xtanh x1 - tanh^2 x
sqrt x1 / (2 sqrt x)log x (base 10)1 / (x ln 10)
|x|sign(x)log2 x1 / (x ln 2)

Reading the steps

Each step shows the expression being differentiated on the left, written as d/dx[...], and the rule's output on the right. Pieces that still need differentiating appear as d/dx[...] placeholders, and later steps resolve them. The last step, labelled Simplify, collects everything into the final answer. If you set a higher order, the trace repeats once per derivative, each round starting from the simplified result of the previous one.

Higher derivatives and when they vanish

Differentiating a polynomial lowers its degree by one, so the (n+1)-th derivative of a degree-n polynomial is 0. Exponentials never vanish: every derivative of e^(2x) is a multiple of e^(2x). Sine and cosine cycle with period four: the fourth derivative of sin x is sin x again. The calculator makes these patterns easy to check by setting the order field.

Limitations

The calculator differentiates with respect to one variable and treats every other letter as a constant, which is what you want for partial derivatives of simple expressions. It does not differentiate min, max, or piecewise definitions, and the derivative of |x| is reported as sign(x), which is undefined at 0. Where a derivative is defined almost everywhere (floor, ceiling, round), the calculator returns 0.

Frequently asked questions

What is a derivative?

The derivative of a function measures how fast its output changes as the input changes. Geometrically it is the slope of the tangent line at each point; physically it is an instantaneous rate such as velocity.

How does the calculator know which rule to use?

It walks the expression tree: sums use the sum rule, products the product rule, quotients the quotient rule, powers the power rule, and any function of a non-trivial inner expression triggers the chain rule. Each application is listed in the steps.

Can it find the second or third derivative?

Yes. Set the order field to 2, 3, or up to 10. The calculator differentiates, simplifies, and repeats, showing the rules for each round.

What notation does it accept?

Type expressions the way you would on paper: x^3, 2x, sin(2x), e^x, ln(x), sqrt(x), and implicit multiplication such as x sin(x). Use pi and e for the constants. The variable can be any single letter.

Why does the answer look different from my textbook?

The calculator returns one canonical simplified form, with constants first and like terms merged. Forms such as 2x(x+1) and 2x^2 + 2x are equal; expand or factor by hand if you need a specific layout.

Does it handle x^x or other variable exponents?

Yes. When both the base and the exponent contain the variable it rewrites a^b as e^(b ln a) and applies the chain rule, giving x^x (ln x + 1) for x^x.

Related calculators