DerivCalc
Learning center

Every derivative rule, explained properly

Six in-depth guides in one place — from what a derivative actually is to the chain rule, implicit differentiation, and the trigonometric family. Every worked example can be opened directly in the calculator to see the steps live.

Guide 1 · Fundamentals

What Is a Derivative? Unlocking Instantaneous Change

We live in a world defined by change. A car accelerates, a company's profit grows, a pathogen spreads, a planet orbits a star. For centuries, mathematics could describe states of being, but it struggled to capture the essence of becoming. The breakthrough came with the invention of calculus and its cornerstone concept: the derivative. It all begins with a simple, everyday experience. When driving, the speedometer doesn't show the average speed for the entire trip; it shows the speed right now. This single reading — this instantaneous rate of change — is the very soul of the derivative. It answers the fundamental question: "How is this system changing at this exact moment?"

The Geometric View: The Slope of a Tangent Line

Geometrically, the derivative of a function \(f(x)\) at a specific point \(x=a\), denoted \(f'(a)\), is the slope of the line tangent to the graph of the function at that exact point. A tangent line is not just any line that touches the curve; it is the unique straight line that best approximates the curve's direction at that location.

A powerful way to visualize this is the "zooming in" analogy. From a distance, a curve's bend is obvious. But as you zoom in closer and closer to any single point, the curve begins to look less curved and more like a straight line. The derivative \(f'(a)\) gives the precise slope of this ideal straight line that the function resembles in its immediate vicinity.

This intuition is formalized by a limit. We begin by drawing a secant line through two nearby points on the curve. As one point slides toward the other, the secant line pivots; in the limit, as the distance between the points shrinks to zero, it settles into the exact position of the tangent line. The derivative is the limit of the slopes of these secant lines.

The Physical View: The Instantaneous Rate of Change

The second face of the derivative is its physical interpretation as an instantaneous rate of change — how a quantity is changing at a particular moment, in contrast to the average rate of change calculated over an interval. The units of a derivative make its meaning concrete: they are always the units of the output divided by the units of the input. If \(H(t)\) gives an object's height in meters as a function of time in seconds, then \(H'(t)\) has units of meters per second.

Analyzing the Anatomy of a Function

With that intuition in place, derivatives let us dissect a function to understand its complete shape — a kind of mathematical autopsy that reveals every peak, valley, and curve with precision.

Finding peaks and valleys. Local maximums are the peaks of hills and local minimums are the bottoms of valleys. At these extreme points, the slope of the tangent line is zero. We locate them by finding the critical points — points where \(f'(x)\) is either zero or undefined.

Understanding curvature. While the first derivative tells us about direction, the second derivative \(f''(x)\) tells us about curvature — the rate of change of the slope. If \(f''(x) > 0\) on an interval, the graph is concave up, curving like a cup; if \(f''(x) < 0\), it is concave down, curving like a frown. A point where the concavity changes is a point of inflection.

Information from…Tells you about the graph of \(f(x)\)…Graphical feature
\(f(x)\)y-value, x- and y-interceptsPosition on the plane
Sign of \(f'(x)\)Where \(f\) is increasing (+) or decreasing (−)Uphill / downhill sections
\(f'(x)=0\) or DNELocation of potential local max/min (critical points)Peaks and valleys
Sign of \(f''(x)\)Where \(f\) is concave up (+) or concave down (−)Curvature (cup or frown)
\(f''(x)=0\) or DNELocation of potential points of inflectionWhere curvature changes

Derivatives in Action: A Cross-Disciplinary Tour

Physics: the mathematics of motion

Velocity is the first derivative of position (\(v(t)=s'(t)\)), and acceleration is the second derivative of position (\(a(t)=v'(t)=s''(t)\)).

Economics: the logic of marginal analysis

In economics, "marginal" means the derivative. Profit is maximized when Marginal Revenue equals Marginal Cost (\(MR = MC\)).

Biology: modeling the dynamics of life

The logistic growth model uses a differential equation to describe how a population changes over time, given the environment's carrying capacity \(K\):

\[\frac{dP}{dt} = rP\left(1 - \frac{P}{K}\right)\]

Computer science: powering modern AI

The gradient descent algorithm, fundamental to machine learning, uses the gradient (a multivariable derivative) to minimize error and "teach" AI models.

From a car's speedometer to the learning algorithm of an artificial intelligence, one mathematical principle connects the trajectory of a planet, the profitability of a company, the growth of a species, and the training of a neural network. The derivative gives us a language to describe not just what is, but what is becoming.

Try it: differentiate x³ − 3x and find its critical points ↑ Back to top
Guide 2 · Core rules

The Product Rule vs. the Quotient Rule

In calculus, we have special rules for finding the derivative of a function. The Product Rule is for when you have two functions multiplied together, and the Quotient Rule is for when one function is divided by another. Let's learn these rules and how they are connected.

The Product Rule: When You Multiply

You use the Product Rule when your problem looks like a multiplication problem — a function made by multiplying two other functions.

The formula

If your function is \(h(x) = f(x)g(x)\), then the derivative is:

\[h'(x) = f'(x)g(x) + f(x)g'(x)\]

A good way to remember it: "Derivative of the first, times the second, plus the first, times the derivative of the second."

Example: differentiating \(y = x^2 e^x\)

  • First function: \(f(x)=x^2\). Its derivative is \(2x\).
  • Second function: \(g(x)=e^x\). Its derivative is \(e^x\).
  • Apply the rule: \(y' = (2x)(e^x) + (x^2)(e^x) = e^x(2x + x^2)\)

The Quotient Rule: When You Divide

You use the Quotient Rule when your problem looks like a fraction — one function divided by another.

The formula

If your function is \(h(x) = \frac{f(x)}{g(x)}\), then the derivative is:

\[h'(x) = \frac{g(x)f'(x) - f(x)g'(x)}{[g(x)]^2}\]

A fun way to remember it: "Low D-High minus High D-Low, all over Low-squared."

Example: differentiating \(y = \frac{e^x}{x}\)

  • High (the top part): \(f(x)=e^x\). Its derivative is \(e^x\).
  • Low (the bottom part): \(g(x)=x\). Its derivative is \(1\).
  • Apply the rule: \(y' = \frac{(x)(e^x) - (e^x)(1)}{x^2} = \frac{e^x(x-1)}{x^2}\)

The Secret Connection

The Quotient Rule isn't a completely new idea. It's actually a shortcut that comes from using the Product Rule and the Chain Rule together. Sometimes a simpler method is to change a division problem into a multiplication problem first.

Expert tip: make it simpler first

It's often easier to rewrite your problem before taking the derivative at all.

  • If you have \(y = \frac{10}{x^2}\), rewrite it as \(y = 10x^{-2}\) and use the simple Power Rule.
  • If you have \(y = \frac{4x^3 - 2x}{x}\), split it into \(y = 4x^2 - 2\) first.

Learning the Product and Quotient rules is a big step in calculus. The best way to master them is not just to memorize the formulas, but to understand when to use them — and to know that sometimes there's an even easier way.

Try it: differentiate x²·eˣ step by step ↑ Back to top
Guide 3 · Core rules

Mastering the Chain Rule

The Chain Rule is one of the most powerful tools in calculus, used to differentiate composite functions — functions nested within one another. It describes how rates of change propagate through a system of dependent variables, like a chain reaction.

The Core Concept: Outside-In Differentiation

A composite function \(h(x) = f(g(x))\) has an "outer function" \(f\) and an "inner function" \(g\). The Chain Rule states that the derivative is the derivative of the outer function (evaluated at the original inner function) multiplied by the derivative of the inner function.

The rule in two notations

Lagrange's notation: \((f(g(x)))' = f'(g(x)) \cdot g'(x)\)

Leibniz's notation: if \(y=f(u)\) and \(u=g(x)\), then \(\frac{dy}{dx} = \frac{dy}{du} \cdot \frac{du}{dx}\)

Example: differentiating \(h(x) = \sin(x^2)\)

  • Outer function \(f(u)=\sin(u)\): derivative is \(\cos(u)\).
  • Inner function \(g(x)=x^2\): derivative is \(2x\).
  • Apply the rule: \(h'(x) = \cos(x^2)\cdot(2x) = 2x\cos(x^2)\)

Advanced Compositions

The rule can be applied recursively for functions with multiple layers.

Nested functions: \(k(x) = \cos^4(7x^2+1)\)

Rewrite as \(k(x) = [\cos(7x^2+1)]^4\). This has three layers:

  1. Outermost (\(u^4\)): \(4[\cos(7x^2+1)]^3\)
  2. Middle (\(\cos(v)\)): \(-\sin(7x^2+1)\)
  3. Innermost (\(7x^2+1\)): \(14x\)

Combine all parts: \(k'(x) = -56x \cos^3(7x^2+1)\sin(7x^2+1)\)

Real-World Applications

  • Related rates: used with time as the variable to find how the rate of change of one quantity affects another (for example, relating a balloon's volume change to its radius change).
  • Machine learning: the Chain Rule is the engine behind "backpropagation," the algorithm used to train artificial neural networks by calculating the gradient of the network's error.
  • Implicit differentiation: the Chain Rule is the justification for why we multiply by \(\frac{dy}{dx}\) when differentiating terms involving \(y\) — see Guide 4.

The Chain Rule is far more than a procedure. It is the essential instrument that allows calculus to move from analyzing static quantities to studying dynamic, interconnected systems — the causal chains that govern processes in science, engineering, and beyond.

Try it: differentiate sin(x²) and watch the chain rule fire ↑ Back to top
Guide 4 · Techniques

Implicit Differentiation, Explained

In calculus, we often work with functions like \(y = x^2\). But what about a circle, \(x^2 + y^2 = 25\)? Solving for \(y\) is messy. Implicit differentiation is the key that unlocks the calculus of curves — not just functions — allowing us to find \(\frac{dy}{dx}\) without ever isolating \(y\).

The Core Technique: A Step-by-Step Guide

The process hinges on one idea: treat \(y\) as a function of \(x\), written \(y(x)\). When we differentiate a term like \(y^2\) with respect to \(x\), we must use the chain rule: \(\frac{d}{dx}(y^2) = 2y \cdot \frac{dy}{dx}\).

The four-step process

  1. Differentiate both sides: apply \(\frac{d}{dx}\) to every term.
  2. Apply differentiation rules: for every term involving \(y\), multiply by \(\frac{dy}{dx}\).
  3. Isolate the \(\frac{dy}{dx}\) terms: use algebra to gather them on one side.
  4. Solve for \(\frac{dy}{dx}\) by factoring and dividing.

Example: differentiating the circle \(x^2 + y^2 = 25\)

Differentiate: \(2x + 2y\frac{dy}{dx} = 0\)

Isolate: \(2y\frac{dy}{dx} = -2x\)

Solve: \(\frac{dy}{dx} = -\frac{x}{y}\)

Higher-Order Implicit Derivatives

We can find the second derivative \(\frac{d^2y}{dx^2}\) by differentiating the first derivative — with one crucial substitution step along the way.

Finding \(\frac{d^2y}{dx^2}\) for the circle

1. First derivative: \(\frac{dy}{dx} = -\frac{x}{y}\)

2. Differentiate again (quotient rule): \(\frac{d^2y}{dx^2} = -\frac{(1)y - x\left(\frac{dy}{dx}\right)}{y^2}\)

3. Substitute \(\frac{dy}{dx}\): \(\frac{d^2y}{dx^2} = -\frac{y - x\left(-\frac{x}{y}\right)}{y^2} = -\frac{y + \frac{x^2}{y}}{y^2}\)

4. Simplify using \(x^2+y^2=25\): \(\frac{d^2y}{dx^2} = -\frac{x^2+y^2}{y^3} = -\frac{25}{y^3}\)

Applications and Related Techniques

Implicit differentiation is crucial for:

  • Finding tangent and normal lines to complex curves.
  • Solving related rates problems, where variables change with respect to time.
  • Logarithmic differentiation, a technique for handling functions like \(y=x^x\) by first taking the natural log of both sides.

Implicit differentiation liberates us from the rigid constraint of explicit functions. By mastering this process — built on careful application of the chain rule — we gain a more powerful lens for analyzing the interconnected, dynamic curves of mathematics.

↑ Back to top
Guide 5 · Beyond the slope

Higher-Order Derivatives

The first derivative answers the question: "How fast is this changing right now?" But that isn't the whole story. Taking the derivative of a derivative — a higher-order derivative — opens up a new dimension of analysis, letting us probe the deeper, more subtle characteristics of a function.

The Mechanics and Notation

A higher-order derivative is the result of applying differentiation multiple times. The second derivative \(f''(x)\) measures the rate of change of the first derivative (the slope). The third derivative \(f'''(x)\) measures the rate of change of the second, and so on.

OrderLagrange notationLeibniz notationNewton's notation (for time \(t\))
1st\(f'(x)\)\(\frac{dy}{dx}\)\(\dot{y}\)
2nd\(f''(x)\)\(\frac{d^2y}{dx^2}\)\(\ddot{y}\)
3rd\(f'''(x)\)\(\frac{d^3y}{dx^3}\)\(\overset{...}{y}\)
n-th\(f^{(n)}(x)\)\(\frac{d^ny}{dx^n}\)(not common)

The Physical Interpretation: The Dynamics of Motion

In kinematics, higher-order derivatives describe an object's motion completely. If position is \(s(t)\):

  • Velocity, \(v(t) = s'(t)\), is the rate of change of position.
  • Acceleration, \(a(t) = s''(t)\), is the rate of change of velocity.
  • Jerk, \(j(t) = s'''(t)\), is the rate of change of acceleration — the "jolt" you feel when acceleration changes suddenly.
  • Even higher derivatives like snap (4th), crackle (5th), and pop (6th) are used in engineering for ultra-smooth motion control.

The Geometric Interpretation: Shaping the Curve

Geometrically, higher-order derivatives describe the shape of a function's graph. The second derivative \(f''(x)\) determines concavity:

  • If \(f''(x) > 0\), the graph is concave up (bends upward, like a cup \(\cup\)).
  • If \(f''(x) < 0\), the graph is concave down (bends downward, like a frown \(\cap\)).

An inflection point is where concavity changes, typically where \(f''(x) = 0\).

The second derivative test

This test classifies critical points (where \(f'(c) = 0\)):

  • If \(f''(c) > 0\), then \(f(c)\) is a local minimum.
  • If \(f''(c) < 0\), then \(f(c)\) is a local maximum.
  • If \(f''(c) = 0\), the test is inconclusive.

The Pinnacle of Approximation: The Taylor Series

The Taylor series uses all of a function's derivatives at a single point \(a\) to build a powerful polynomial approximation:

\[f(x) = \sum_{n=0}^{\infty} \frac{f^{(n)}(a)}{n!}(x-a)^n\]

This expands to:

\[f(x) = f(a) + f'(a)(x-a) + \frac{f''(a)}{2!}(x-a)^2 + \dots\]

Each term adds a layer of accuracy — matching the function's value, slope, concavity, and more, all at that single point.

The journey from the first derivative to higher orders is a journey from a simple description of change to a profoundly nuanced understanding of behavior: the physics of motion, the geometry of curves, and the foundation of the Taylor series, all hidden within every function.

Try it: DerivCalc computes up to the 5th derivative — start with x⁵ ↑ Back to top
Guide 6 · The trig family

Derivatives of Trigonometric Functions

Calculus is the language of change; trigonometry is the language of cycles and oscillation. Where the two intersect, we arrive at the derivatives of trigonometric functions — a set of results that lets us measure the very rhythm of change itself.

The Bedrock: First Principles and Foundational Limits

One critical prerequisite before deriving anything: all angles must be measured in radians. The clean derivative formulas below only hold in radians — in degrees, awkward conversion constants appear everywhere.

The cornerstone limit: \(\lim_{\theta\to 0} \frac{\sin\theta}{\theta} = 1\)

The route to the derivative of sine runs through this limit, proved with a beautiful piece of geometric reasoning: the Squeeze Theorem.

Squeeze Theorem proof sketch

  1. Geometric construction: on a unit circle, take a small angle \(\theta\) and compare three regions — the triangle inside the arc, the circular sector itself, and the larger triangle formed by the tangent line.
  2. Area comparison: the inner triangle has area \(\frac{1}{2}\sin\theta\), the sector has area \(\frac{1}{2}\theta\), and the outer triangle has area \(\frac{1}{2}\tan\theta\).
  3. Establish the inequality: \[\frac{1}{2}\sin\theta < \frac{1}{2}\theta < \frac{1}{2}\tan\theta\]
  4. Algebraic manipulation: dividing through by \(\frac{1}{2}\sin\theta\) and taking reciprocals gives \[\cos\theta < \frac{\sin\theta}{\theta} < 1\]
  5. Apply the Squeeze Theorem: as \(\theta \to 0\), \(\cos\theta \to 1\), so \(\frac{\sin\theta}{\theta}\) is squeezed between two quantities that both approach 1 — and must equal 1 in the limit.

The corollary limit: \(\lim_{\theta\to 0} \frac{\cos\theta - 1}{\theta} = 0\)

Multiplying by the conjugate turns this into a form the cornerstone limit can handle:

\[\lim_{\theta\to 0} \frac{\cos\theta - 1}{\theta} = \lim_{\theta\to 0} \frac{\cos^2\theta - 1}{\theta(\cos\theta + 1)} = \lim_{\theta\to 0}\left(-\frac{\sin\theta}{\theta}\cdot\frac{\sin\theta}{\cos\theta+1}\right) = -1 \cdot \frac{0}{2} = 0\]

Deriving the derivatives of sine and cosine

With both limits established, the limit definition of the derivative and the angle-addition formulas deliver the two foundational results:

\[\frac{d}{dx}(\sin x) = \lim_{h\to 0} \frac{\sin(x+h) - \sin x}{h} = \cos x\] \[\frac{d}{dx}(\cos x) = \lim_{h\to 0} \frac{\cos(x+h) - \cos x}{h} = -\sin x\]

Building the Family: The Remaining Four

Once the derivatives of \(\sin x\) and \(\cos x\) are established, all other trigonometric derivatives follow systematically from the quotient rule (see Guide 2).

Function \(f(x)\)Derivative \(f'(x)\)Chain rule form \(\frac{d}{dx}[f(u)]\)
\(\sin x\)\(\cos x\)\(\cos(u)\cdot u'\)
\(\cos x\)\(-\sin x\)\(-\sin(u)\cdot u'\)
\(\tan x\)\(\sec^2 x\)\(\sec^2(u)\cdot u'\)
\(\cot x\)\(-\csc^2 x\)\(-\csc^2(u)\cdot u'\)
\(\sec x\)\(\sec x\tan x\)\(\sec(u)\tan(u)\cdot u'\)
\(\csc x\)\(-\csc x\cot x\)\(-\csc(u)\cot(u)\cdot u'\)

The Other Side of the Angle: Inverse Trig Derivatives

Inverse trigonometric functions ask, "What angle produced this value?" Their derivatives are found using implicit differentiation (see Guide 4).

Function \(f(x)\)Derivative \(f'(x)\)Domain of \(f(x)\)
\(\arcsin x\)\(\frac{1}{\sqrt{1 - x^2}}\)\([-1, 1]\)
\(\arccos x\)\(-\frac{1}{\sqrt{1 - x^2}}\)\([-1, 1]\)
\(\arctan x\)\(\frac{1}{1 + x^2}\)\((-\infty, \infty)\)
\(\operatorname{arccot} x\)\(-\frac{1}{1 + x^2}\)\((-\infty, \infty)\)
\(\operatorname{arcsec} x\)\(\frac{1}{|x|\sqrt{x^2 - 1}}\)\((-\infty, -1] \cup [1, \infty)\)
\(\operatorname{arccsc} x\)\(-\frac{1}{|x|\sqrt{x^2 - 1}}\)\((-\infty, -1] \cup [1, \infty)\)

From foundational geometric proofs to the oscillating systems of the physical world, the trigonometric derivatives form a tightly interconnected family — each result flowing from two limits, one squeeze, and the rules covered in the guides above. That interconnectedness is a testament to the unifying beauty and utility of mathematics.

Try it: differentiate tan(x) and see the quotient rule derive sec²x ↑ Back to top