Skip to content
Toolcroft

Math Calculators

Derivative Calculator - Symbolic Differentiation

Calculate the derivative of any polynomial, trigonometric, exponential, or logarithmic expression. Supports chain rule, product rule, and quotient rule with step-by-step output.

Use: +, −, *, /, ^ | Functions: sin, cos, tan, exp, ln, sqrt | Press Enter or click d/dx

Quick examples:

Input f(x)

x^3 − 4x^2 + 2x − 1

Derivative f′(x)

3x^2 − 4·2x + 2

Loading chart…
f(x) and f′(x)
xf(x)f′(x)
-5.0000-125.000075.0000
-3.8889-58.813445.3704
-2.7778-21.433523.1481
-1.6667-4.62968.3333
-0.5556-0.17150.9259
0.55560.17150.9259
1.66674.62968.3333
2.777821.433523.1481
3.888958.813445.3704
5.0000125.000075.0000

Syntax reference

x^2 to x²2*x to 2xsin(x), cos(x)tan(x)exp(x) to eˣln(x)sqrt(x) to √xa/b to quotientf(g(x)) to chain

What is differentiation?

Differentiation is the process of finding the derivative of a function. The derivative f′(x) gives the instantaneous rate of change of f at any point x; geometrically, the slope of the tangent line to the curve y = f(x). Derivatives are used to find maxima and minima, analyze motion, model growth and decay, and solve optimization problems.

Core differentiation rules

  • Constant rule: d/dx[c] = 0
  • Power rule: d/dx[xⁿ] = nxⁿ⁻¹
  • Sum / difference rule: (f ± g)′ = f′ ± g′
  • Product rule: (fg)′ = f′g + fg′
  • Quotient rule: (f/g)′ = (f′g − fg′) / g²
  • Chain rule: (f∘g)′ = f′(g(x)) · g′(x)

Common derivatives

  • d/dx[sin x] = cos x
  • d/dx[cos x] = −sin x
  • d/dx[tan x] = sec²x = 1/cos²x
  • d/dx[eˣ] = eˣ
  • d/dx[ln x] = 1/x
  • d/dx[√x] = 1/(2√x)

How the calculator works

This tool parses your expression into an abstract syntax tree (AST) using a recursive descent parser, then applies the differentiation rules symbolically, exactly as you would by hand. The resulting expression tree is simplified and printed back as a readable string. All computation happens entirely in your browser.