MATHEMATICS · LESSON 04 OF 10
Derivative as a rate
The derivative is the instantaneous rate of change: the limit of average rates, and the slope of the tangent line.
What this lesson explains
Engineering is full of rates: velocity is the rate of change of position, reaction rate is the rate of change of concentration, power is the rate of change of energy. An average rate over an interval is easy to compute, but often we need the rate at one instant. The derivative gives exactly that, and all later calculus (rules, optimization, related rates, approximation) is built on it.
Before you begin
Slope of a line
The slope between (x1, y1) and (x2, y2) is m = y2 − y1 / x2 − x1. The line through (a, b) with slope m is y − b = m(x − a).
Expanding brackets
(a + h)2 = a2 + 2ah + h2 and (a + h)3 = a3 + 3a2h + 3ah2 + h3. After subtracting f(a), every remaining term contains h, so h can be cancelled.
Limits of 0/0 forms
Cancel a common factor that is non-zero for the inputs the limit uses (h ≠ 0), then substitute. See the Limits topic.
The idea, made visible
Start with an average rate of change. Between x = a and x = a + h, the output changes by f(a + h) − f(a) while the input changes by h. Their ratio f(a + h) − f(a) / h is the slope of the secant line through the two points of the graph.
Now shrink the interval. As h → 0 the second point slides along the curve towards the first, and the secant lines approach a limiting line: the tangent line at x = a, the line through (a, f(a)) whose slope is the limit of the secant slopes. Close to a, the tangent follows the direction of the curve. It does not have to stay on one side of the curve or meet it only once: the tangent to y = x³ at the origin is the x-axis, and it crosses the curve there. The limit of the secant slopes is the derivative f′(a). We cannot simply put h = 0, because the quotient would become 0 / 0; that is exactly why a limit is needed.
The derivative has units: output units divided by input units. If s is position in metres and t is time in seconds, s′(t) is in m/s. If C is concentration in mmol/L and t is in minutes, C′(t) is in mmol/(L·min). The sign tells you the direction: f′(a) > 0 means f is increasing at a, f′(a) < 0 means it is decreasing.
Doing this at every point gives a new function, the derivative function f′(x). A function is differentiable at a if this limit exists. A differentiable function is always continuous, but a continuous function need not be differentiable: |x| has a corner at 0, where the slope from the left is −1 and from the right is +1, so no single tangent slope exists.
| h | second point | secant slope (f(1 + h) − f(1))/h |
|---|---|---|
| 1 | (2, 4) | 3 |
| 0.5 | (1.5, 2.25) | 2.5 |
| 0.1 | (1.1, 1.21) | 2.1 |
| 0.01 | (1.01, 1.0201) | 2.01 |
| −0.01 | (0.99, 0.9801) | 1.99 |
| −0.1 | (0.9, 0.81) | 1.9 |
The secant slope equals 2 + h, so it approaches 2 from both sides as h → 0. That limit is f′(1) = 2.
Key terms
- Average rate of change
- Over [a, a + h]: f(a + h) − f(a) / h, the slope of the secant line through (a, f(a)) and (a + h, f(a + h)).
- Derivative at a point
- f′(a) = limh→0 f(a + h) − f(a) / h, provided the limit exists. It is the instantaneous rate of change of f at a and the slope of the tangent line there.
- Tangent line
- The line through (a, f(a)) with slope f′(a): y = f(a) + f′(a)(x − a). It is defined by this slope, not by “touching once”: a tangent line may cross the curve, and may meet it again elsewhere.
- Derivative function
- f′(x) = limh→0 f(x + h) − f(x) / h for each x where the limit exists. Other notations: dy / dx, df / dx, y′.
- Differentiable
- f is differentiable at a if f′(a) exists. Differentiability fails at corners, cusps, vertical tangents and discontinuities.
The formulas and what they mean
| Symbol | Meaning | Unit |
|---|---|---|
| h (or Δx) | a small change in the input | input units |
| Δy = f(a + h) − f(a) | the corresponding change in the output | output units |
| f′(a), dy / dx | derivative (instantaneous rate of change) | output units ÷ input units |
| v = s′(t) | velocity as the derivative of position | m/s if s in m and t in s |
Definition of the derivative
f′(a) = limh→0 f(a + h) − f(a) / h
Conditions and limits: The limit must exist (the same from both sides). If the left and right limits differ, as at a corner, f is not differentiable at a.
Alternative form
f′(a) = limx→a f(x) − f(a) / x − a
Conditions and limits: Equivalent to the first form (put x = a + h).
Tangent line
y = f(a) + f′(a)(x − a)
Conditions and limits: Requires f to be differentiable at a. It uses both the point value f(a) and the slope f′(a).
Differentiable ⇒ continuous
f′(a) exists ⇒ limx→a f(x) = f(a)
Conditions and limits: The converse is false: |x| is continuous at 0 but not differentiable there.
Why it works: Derivative of f(x) = x² from the definition
This is the model for every first-principles calculation.
Difference quotient: (x + h)2 − x2 / h.
Substitute x + h and x into f.
Expand: x2 + 2xh + h2 − x2 / h = 2xh + h2 / h.
The x2 terms cancel; every remaining term contains h.
Cancel h (allowed because h ≠ 0 inside the limit): 2x + h.
This removes the 0/0 form.
Let h → 0: f′(x) = 2x.
2x + h is a polynomial in h, so substitute h = 0.
So the slope of y = x² at x = 1 is 2, at x = 3 is 6, and at x = −2 is −4. The slope changes from point to point, which is why the derivative is a function.
A first worked example
How to find a derivative from the definition, and how to use it
- Write f(a + h) by replacing x with a + h everywhere, then write the quotient f(a + h) − f(a) / h.
- Simplify the numerator (expand, combine fractions, or multiply by a conjugate for roots) until a factor of h appears.
- Cancel h and let h → 0.
- For a tangent line, compute both f(a) (the point) and f′(a) (the slope), then use y = f(a) + f′(a)(x − a).
- State units: output units per input unit. Interpret the sign (increasing or decreasing).
Derivative at a point from the definition
Problem. For f(x) = x2 + 3x, find f′(2) from the definition.
f(2 + h) = (2 + h)2 + 3(2 + h) = 4 + 4h + h2 + 6 + 3h = 10 + 7h + h2.
Replace x by 2 + h and expand.
f(2) = 4 + 6 = 10, so f(2 + h) − f(2) = 7h + h2.
The constant terms cancel.
7h + h2 / h = 7 + h for h ≠ 0.
Cancel the common factor h.
Let h → 0: f′(2) = 7.
Substitute h = 0 in 7 + h.
Result: f′(2) = 7.
What it means: Near x = 2 the output increases about 7 units for each unit increase in x.
A different case
A rate with units
Problem. A concentration is modelled by C(t) = t2 + 3t (mmol/L, t in minutes). Find the rate of change of concentration at t = 2 min.
This is the same function as in the previous example, so C′(2) = 7.
The derivative does not depend on the letters used.
Units: output units ÷ input units = (mmol/L) ÷ min.
Always attach units to a rate.
Result: C′(2) = 7 mmol/(L·min).
What it means: At t = 2 min the concentration is rising at 7 mmol/L per minute. This is an instantaneous rate; the average rate over the first 2 minutes is (C(2) − C(0))/2 = 10/2 = 5 mmol/(L·min).
More worked cases
Each case below uses a different skill. Every step and result is shown.
Equation of a tangent line
Problem. Find the tangent line to f(x) = x2 + 1 at x = 2.
Point: f(2) = 5, so the line passes through (2, 5).
A tangent line needs a point as well as a slope.
Slope: by the same method as for x2, f′(x) = 2x, so f′(2) = 4.
The constant 1 does not change the slope.
y = 5 + 4(x − 2), that is y = 4x − 3.
Point–slope form, then simplify.
Result: y = 4x − 3.
What it means: Check: at x = 2 the line gives 8 − 3 = 5, matching the curve.
Derivative of 1/x from the definition
Problem. Find f′(x) for f(x) = 1 / x, x ≠ 0.
f(x + h) − f(x) / h = 1 / h(1 / x + h − 1 / x).
Write the difference quotient.
Combine the fractions: 1 / x + h − 1 / x = x − (x + h) / x(x + h) = −h / x(x + h).
Use a common denominator.
Divide by h: −1 / x(x + h).
The factor h cancels (h ≠ 0).
Let h → 0: f′(x) = −1 / x2.
Substitute h = 0; valid because x ≠ 0.
Result: f′(x) = −1/x2.
What it means: The slope is negative everywhere: 1/x decreases on each side of 0.
Where a derivative does not exist
Problem. Is f(x) = |x| differentiable at x = 0?
f(0 + h) − f(0) / h = ∣h∣ / h.
Write the difference quotient at 0.
For h > 0 this is 1; for h < 0 it is −1.
Use |h| = h for positive h and |h| = −h for negative h.
The one-sided limits are 1 and −1, so the limit does not exist.
A derivative must have one value from both sides.
Result: |x| is not differentiable at 0 (although it is continuous there).
What it means: The graph has a corner at the origin, so there is no single tangent line.
Velocity, a turning point, and total distance
Problem. A particle moves along a line with position s(t) = t2 − 4t (metres, t in seconds) for 0 ≤ t ≤ 5. Find its velocity, when it turns around, its displacement and the total distance travelled.
v(t) = s′(t) = 2t − 4 m/s.
Velocity is the rate of change of position.
v = 0 at t = 2 s; v < 0 before and v > 0 after.
The particle moves backwards, stops, then moves forwards: t = 2 s is a turning point.
Positions: s(0) = 0, s(2) = −4 m, s(5) = 25 − 20 = 5 m.
Evaluate at the start, the turning time and the end.
Displacement = s(5) − s(0) = 5 m.
Only the start and end positions matter.
Distance = |−4 − 0| + |5 − (−4)| = 4 + 9 = 13 m.
Add the lengths of each one-direction stretch.
Result: v(t) = 2t − 4; turns at t = 2 s; displacement 5 m; total distance 13 m.
What it means: Displacement and distance differ whenever the motion reverses. Using s(5) − s(0) for distance misses the backward stretch.
Common misunderstandings
Misunderstanding: Putting h = 0 immediately in the difference quotient.
Correct idea: That gives 0/0. Simplify and cancel h first, then take the limit.
Misunderstanding: Confusing the average rate with the instantaneous rate.
Correct idea: The average rate uses two points; the derivative is the limit as the interval shrinks to one point.
Misunderstanding: Writing the tangent line as y = f′(a)x.
Correct idea: The line must pass through (a, f(a)): y = f(a) + f′(a)(x − a).
Misunderstanding: Forgetting units.
Correct idea: A derivative is a rate: output units per input unit, for example m/s or mmol/(L·min).
Misunderstanding: “Continuous means differentiable.”
Correct idea: Corners and cusps (|x| at 0) are continuous but have no derivative.
Keep in mind
- f′(a) = limh→0 f(a + h) − f(a) / hDefinition of the derivative
- f′(a) = limx→a f(x) − f(a) / x − aAlternative form
- y = f(a) + f′(a)(x − a)Tangent line
- f′(a) exists ⇒ limx→a f(x) = f(a)Differentiable ⇒ continuous
Scope of this lesson
- Here derivatives are computed from the definition. The faster rules (power, product, quotient, chain) are in the next topic.
- One-variable functions only; partial derivatives belong to later courses.
Next: Differentiation rules. Rules that give derivatives quickly and reliably: power, sum, product, quotient and chain rules, with the derivatives of trigonometric, exponential and logarithmic functions.
Original study text. Sources and credits.