Skip to content
πŸ“ˆ

Derivative Calculator

Differentiate polynomials, trig, exponential, and log terms with the rule used for each.

Runs in your browser

Updated

fβ€²(x) =

β€”

    Supports: numbers, x, x^n, sin(x), cos(x), exp(x), ln(x), sqrt(x) β€” added and subtracted.

    The shape of expression it accepts

    Everything is one line of terms added and subtracted. Spaces are deleted, the string splits on plus and minus signs outside parentheses, and each piece is read as an optional signed decimal coefficient followed by a body. That body must be exactly one of x, x^n, sin(x), cos(x), exp(x), ln(x), sqrt(x) or e^x. Asterisks are stripped first, so 2*sin(x) parses even though no multiplication rule exists. Recalculation runs on every keystroke and on Enter.

    A worked example

    The default input 3x^3 - 2x + sin(x) prints 9x^2 βˆ’ 2 + cos(x) under the f prime label, with a typographic minus between terms. The three steps beneath read d/dx [3x^3] = 9x^2 (power rule), d/dx [-2x] = -2 (power rule) and d/dx [sin(x)] = cos(x). A constant alone, say 5, prints 0, and 4x^2 + 3x + 7 prints 8x + 3.

    Which rule each term gets

    Numbers take the constant rule and contribute nothing to the answer line. Powers multiply the coefficient by the exponent and lower the exponent by one, rounded to ten decimal places before printing, and a coefficient of 1 or -1 is left unwritten. The five named functions each have one fixed derivative: cos(x), -sin(x), exp(x), 1/x and 1/(2√x).

    Where it stops

    • A term the reader cannot match stops everything: the answer becomes Cannot parse and the step list empties, with no partial result kept.
    • Products and quotients are out, so x*x and 1/x both fail.
    • No chain rule, so sin(2x) and sin(x)^2 are refused.
    • Like terms are never collected, so 3x^3 - 3x^3 answers 9x^2 βˆ’ 9x^2 rather than 0.
    • A negative exponent such as x^-1 splits at the minus and fails as Cannot parse "x^".

    Questions people ask

    Is this a computer algebra system

    It is a rule table over a sum of simple terms, and the steps show which rule touched each piece.

    Can I get the second derivative

    Not directly, though pasting the printed answer back in works whenever the result is still in an accepted shape.

    Where to go instead

    The Quadratic Equation Solver handles roots, and numeric integration sits in the Simpsons Rule Calculator.