Derivative Calculator - Step by Step, Tangent Line, f″(x)

    Step-by-step derivatives with every rule named: product, quotient and chain rule, a simplified f′(x), the second derivative, the value at any point and the tangent line in y = mx + b form.

    Parameters

    Enter data for calculations

    A formula in the variable x

    For the value and the tangent line

    The second one classifies critical points

    Form progress0 / 1 fields

    💡 Fill in all required fields to unlock the calculate button

    An atlas of derivatives, worked out for your function

    The derivative of x2sin(x) is 2x·sin(x) + x2·cos(x), and at x = π/2 its value is 3.141592654, so the tangent line there is y = 3.141592654x - 2.4674011. This derivative calculator differentiates symbolically, the way you would on paper: it names the rule used at every stage (product, quotient, chain, power), simplifies the answer, and, when you give a point, returns f(x₀), f′(x₀), the tangent line in slope-intercept form and, on request, the second derivative.

    18
    standard derivatives in the table below
    8
    differentiation rules the steps are named after
    f′ and f″
    first and second derivative, as formulas and values
    y = mx + b
    tangent line at the point you choose

    Three boxes and the order to read the answer

    1. Function f(x) - a formula in x, such as 3x^4 - 2x + 5, x^2 sin(x) or ln(x^2+1). Use ^ for powers; the multiplication sign can be left out (2x, x sin(x)). Write sin²x as sin^2(x) and put a longer exponent in parentheses: e^(3x).
    2. Point x₀ (optional) - a number or an expression without x, for example 2, -0.5 or pi/4. Use a period for decimals. Leave it empty and you get only the formula of the derivative.
    3. Order of the derivative - first only, or first and second. The second derivative usually settles whether a point with f′(x₀) = 0 is a minimum or a maximum.
    4. Read the result - the dark box holds f′(x) (and f″(x)), the tiles below hold the values at x₀, then the tangent line, the function as the calculator read it, and the list of rules applied, from the outermost operation inward.

    Accepted names: sin, cos, tan, cot, sec, csc, ln, log, exp, sqrt, abs, arcsin, arccos, arctan, arccot, the constants pi and e, and x. Here log means the base-10 logarithm and ln the natural one, as on most US calculators. Angles are in radians.

    What a derivative measures

    The derivative of f at a point x₀ is the limit of the difference quotient [f(x₀ + h) - f(x₀)] / h as h shrinks to zero. Read on a graph, it is the slope of the tangent line at that point. Read as a rate, it is how fast f changes per unit of x right there: if f is position in feet and x is time in seconds, f′ is the velocity in feet per second.

    Nobody evaluates that limit by hand for every new function. A short table of standard derivatives plus a handful of rules takes any formula apart: a sum splits into terms, a product goes to the product rule, a fraction to the quotient rule, a function inside another function to the chain rule. The calculator follows exactly that path and prints each move. For f(x) = x3 - 3x at x₀ = 1 the derivative is 0, so the tangent is the horizontal line y = -2.

    The second derivative is the derivative of the derivative. It tells how the slope itself changes: positive means the graph bends up like a cup (concave up), negative means it bends down (concave down). For 3x4 - 2x + 5 the first derivative is 12x3 - 2 and the second is 36x2; at x₀ = 1 they are worth 10 and 36.

    Table of derivatives: eighteen building blocks

    Every answer the calculator gives is assembled from these entries. The last column is where the formula holds; outside it the function or its derivative is not defined.

    f(x) f′(x) Valid for
    c (a constant)0all x
    xnn·xn-1depends on n
    √x1/(2√x)x > 0
    1/x-1/x2x ≠ 0
    exexall x
    axax·ln aa > 0
    ln x1/xx > 0
    log x (base 10)1/(x·ln 10)x > 0
    sin xcos xall x
    cos x-sin xall x
    tan x1/cos2x = sec2xcos x ≠ 0
    cot x-1/sin2x = -csc2xsin x ≠ 0
    sec xsec x·tan xcos x ≠ 0
    csc x-csc x·cot xsin x ≠ 0
    arcsin x1/√(1 - x2)-1 < x < 1
    arccos x-1/√(1 - x2)-1 < x < 1
    arctan x1/(1 + x2)all x
    arccot x-1/(1 + x2)all x

    The rules, sorted by the shape of the formula

    The step list in the result uses these names. Which rule fires depends only on the outermost operation of the expression; the calculator then works inward. Every example in the right column is the calculator's own output, simplification included.

    Rule Formula Example from the calculator
    Sum and difference(u ± v)′ = u′ ± v′(3x4 - 2x + 5)′ = 12x3 - 2
    Constant multiple(c·u)′ = c·u′(πx2)′ = 2π·x
    Power(un)′ = n·un-1·u′((x2 + 1)3)′ = 6(x2 + 1)2·x
    Product(u·v)′ = u′·v + u·v′(x2sin x)′ = 2x·sin(x) + x2·cos(x)
    Quotient(u/v)′ = (u′·v - u·v′)/v2(x/(x2 + 1))′ = (1 - x2)/(x2 + 1)2
    Chain (composite function)f(g(x))′ = f′(g(x))·g′(x)(sin(x2))′ = 2x·cos(x2)
    Exponential(au)′ = au·ln(a)·u′(2x)′ = 2x·ln(2)
    x in base and exponent(uv)′ = uv·(v′·ln u + v·u′/u)(xx)′ = xx·(ln(x) + 1)

    Six functions run through the calculator

    Rational function at x₀ = 2
    f(x) = (x2 + 1)/(x - 1), second derivative on.
    f(2) = 5, f′(2) = -1, f″(2) = 4.
    Tangent: y = -x + 7.
    Exponential with a chain
    f(x) = e^(3x), x₀ = 0.
    f′(x) = 3e3x, f′(0) = 3.
    Tangent: y = 3x + 1.
    Square root of a sum
    f(x) = sqrt(x^2+16), x₀ = 3.
    f(3) = 5, f′(x) = x/√(x2 + 16), f′(3) = 0.6.
    Tangent: y = 0.6x + 3.2.
    Cubic with a minimum
    f(x) = x^3 - 6x^2 + 9x + 1, x₀ = 3, second derivative on.
    f′(x) = 3x2 - 12x + 9, f′(3) = 0, f″(3) = 6: local minimum, tangent y = 1.
    Inverse tangent
    f(x) = arctan(2x), x₀ = 0.5.
    f′(x) = 2/(1 + 4x2), f′(0.5) = 1.
    Tangent: y = x + 0.2853981634.
    x to the power x
    f(x) = x^x, x₀ = 2.
    f(2) = 4, f′(x) = xx·(ln(x) + 1), f′(2) = 6.772588722.
    Tangent: y = 6.772588722x - 9.545177444.

    Four derivatives that behave unexpectedly

    ex is its own derivative. Up to a constant factor it is the only function with that property, which is why ekx turns up wherever the rate of change is proportional to the amount itself: continuous compounding, radioactive decay, unchecked population growth. For e3x the derivative is simply 3e3x.

    A continuous function can have no derivative. |x| has no gap at 0, yet the difference quotient from the left is -1 and from the right 1. The graph has a corner, and the calculator reports both one-sided values. By contrast |x2| does have a derivative at 0 (it is 0), even though the formula for it gives 0/0 there; the calculator then takes the limit of the difference quotient and says so.

    A vertical tangent is also a missing derivative. The cube root x1/3 at 0 has a tangent line that coincides with the y-axis. The difference quotient grows without bound as h shrinks, so there is no derivative even though the curve looks smooth.

    A zero derivative is not always an extremum. x3 at 0 has f′ = 0 and f″ = 0, and the function keeps increasing straight through. That point is an inflection point with a horizontal tangent, which is why the calculator writes that the second derivative does not decide when f″(x₀) = 0.

    Reading the signs of f′ and f″ at a point

    This is the classification the result text uses after the tangent line. It is the first and second derivative test from a calculus course, applied to the single point you typed.

    At x₀ What it means
    f′(x₀) > 0f is increasing near x₀
    f′(x₀) < 0f is decreasing near x₀
    f′(x₀) = 0 and f″(x₀) > 0local minimum
    f′(x₀) = 0 and f″(x₀) < 0local maximum
    f′(x₀) = 0 and f″(x₀) = 0inconclusive: check the sign of f′ on both sides
    f′(x₀) does not exista corner, a vertical tangent, or no function on one side

    The first two rows assume the derivative is continuous at x₀, which holds for functions built from the table above except at points where the formula for f′ stops making sense. The verdict is about a neighborhood of the point, not about the whole graph: a local minimum can sit well above the lowest value of the function elsewhere.

    Watch the parentheses in exponents. e^2x is read as e2·x, because an exponent without parentheses covers only the number right after ^. Its derivative is the constant e2 ≈ 7.389, not 2e2x. The calculator flags this case under "Function as read"; type e^(2x) if that is what you meant.

    Derivative questions from homework and review sessions

    How do I find the derivative at a point?
    Find the formula for f′(x) and substitute the point. In the calculator, type the function and the point x₀; the tile f′(x₀) holds the value. For f(x) = ln(x2 + 1) at x₀ = 1, f′(x) = 2x/(x2 + 1) and f′(1) = 1.
    How is the tangent line equation built?
    The point-slope form is y = f′(x₀)(x - x₀) + f(x₀). Expanding it gives slope-intercept form y = mx + b with m = f′(x₀) and b = f(x₀) - f′(x₀)·x₀. For sin(x2) at x₀ = √π: f = 0, m = -3.544907702, b = 6.283185307, which is 2π.
    What is the derivative of tan x, and why does the result show 1/cos²(x)?
    The derivative of tan x is sec2x, which is the same function as 1/cos2x. The calculator writes it with cosine because its simplifier works in sin and cos; the step list shows both forms. At x = π/4 the value is 2.
    Is log the natural log here?
    No. log is the base-10 logarithm and ln is the natural one, so (log x)′ = 1/(x·ln 10). At x = 10 that is 0.04342944819, while (ln x)′ at the same point is 0.1.
    Why does my second derivative look longer than the one in the textbook?
    The simplifier combines like terms, cancels common factors of a fraction and collects powers, but it does not factor polynomials. For x/(x2 + 1) the second derivative comes out with (x2 + 1)4 in the denominator, while a textbook would cancel one factor and write 2x(x2 - 3)/(x2 + 1)3. Both are equal; the value at any point is the same, and at x₀ = 0 it is 0.
    Can it do partial or implicit derivatives?
    No. The calculator handles one variable, x, with explicit formulas. Any other letter is reported as unrecognized, so a function of x and y needs another tool. Hyperbolic functions such as sinh are not supported either; write them through exponentials, for example (e^x - e^(-x))/2.

    Related tools

    System of Equations Calculator

    Two or three linear equations solved step by step, with exact fractions and a check - See the calculator

    Definite Integral Calculator

    Value of a definite integral with error estimate, area, average value and Simpson comparison - See the calculator

    Linear Function Calculator

    Slope, intercepts and the equation of a line, the natural next step after a tangent line - See the calculator

    Quadratic Function Calculator

    Vertex, roots and graph data of a parabola, the place where its derivative equals zero - See the calculator

    Logarithm Calculator

    Logarithms in any base, handy when a derivative leaves ln a or ln 10 in the answer - See the calculator

    Powers and Roots Calculator

    Exact powers and roots for checking values such as e2 or the cube root at a point - See the calculator

    Series Convergence Calculator

    Convergence tests for infinite series, the next chapter in most calculus courses - See the calculator

    Laplace Transform Calculator

    Transform pairs that turn derivatives into multiplication by s, used for differential equations - See the calculator

    Similar calculators from this section