- What a derivative really means as the gradient of a curve at a point.
- How the formula from first principles is built using a small change hhh.
- How to prove derivatives of linear, quadratic and cubic expressions.
- How to present your working clearly for AS-Level marks.
A straight-line gradient measures how steep a line is. If a line passes through two points, the gradient is
change in ychange in x\frac{\text{change in }y}{\text{change in }x}change in xchange in y
For curves, the steepness changes from point to point, so we need a more careful idea.
Average gradient
The average gradient between two points on a curve is the gradient of the straight line joining those two points. This straight line is called a chord or secant.
Finding an average gradient on a curve
For the curve y=x2y=x^2y=x2, find the average gradient between the points where x=2x=2x=2 and x=5x=5x=5.

-
Find the two yyy-values:
y(2)=22=4y(5)=52=25\begin{aligned}
y(2)&=2^2=4\\
y(5)&=5^2=25
\end{aligned}y(2)y(5)=22=4=52=25
-
Use the gradient formula:
change in ychange in x=25−45−2=213=7\frac{\text{change in }y}{\text{change in }x}
=
\frac{25-4}{5-2}
=
\frac{21}{3}
=
7change in xchange in y=5−225−4=321=7
-
State the result clearly: the average gradient between those two points is 7.
The instantaneous gradient is the gradient at one exact point on a curve. For a curve, this is the gradient of the tangent at that point.
To get it, imagine taking a second point very close to the first point. If the first point has input xxx, let the second point have input x+hx+hx+h, where hhh is a small change in xxx.


The average gradient between these two nearby points is
f(x+h)−f(x)(x+h)−x=f(x+h)−f(x)h\frac{f(x+h)-f(x)}{(x+h)-x}
=
\frac{f(x+h)-f(x)}{h}(x+h)−xf(x+h)−f(x)=hf(x+h)−f(x)
Derivative
The derivative of a function f(x)f(x)f(x), written as f′(x)f'(x)f′(x) or dydx\frac{dy}{dx}dxdy, is the instantaneous gradient of the curve at xxx.
The first principles formula
Differentiating from first principles means using
f′(x)=limh→0f(x+h)−f(x)hf'(x)=\lim_{h\to 0}\frac{f(x+h)-f(x)}{h}f′(x)=h→0limhf(x+h)−f(x)
The symbol limh→0\lim_{h\to 0}limh→0 means “look at what the expression becomes as hhh gets closer and closer to 0”.
Do not put h equal to 0 too early
At the start, the fraction has hhh in the denominator. Substituting h=0h=0h=0 immediately would mean dividing by zero, which is not allowed. You must simplify first, usually by cancelling a factor of hhh.
For most AS-Level first-principles questions, your working follows the same structure:
- Write the first principles formula.
- Substitute the given function into f(x+h)f(x+h)f(x+h) and f(x)f(x)f(x).
- Expand brackets carefully.
- Simplify the numerator.
- Factorise and cancel hhh.
- Let h→0h \to 0h→0.
Proving the derivative of a linear function
Prove from first principles that the derivative of 6x6x6x is 6.
-
Let f(x)=6xf(x)=6xf(x)=6x and write the first principles formula:
f′(x)=limh→0f(x+h)−f(x)hf'(x)=\lim_{h\to 0}\frac{f(x+h)-f(x)}{h}f′(x)=h→0limhf(x+h)−f(x)
-
Find f(x+h)f(x+h)f(x+h) and f(x)f(x)f(x):
f(x+h)=6(x+h)=6x+6hf(x)=6x\begin{aligned}
f(x+h)&=6(x+h)=6x+6h\\
f(x)&=6x
\end{aligned}f(x+h)f(x)=6(x+h)=6x+6h=6x
-
Substitute these into the formula:
f′(x)=limh→0(6x+6h)−6xhf'(x)=\lim_{h\to 0}\frac{(6x+6h)-6x}{h}f′(x)=h→0limh(6x+6h)−6x
-
Simplify the numerator:
f′(x)=limh→06hhf'(x)=\lim_{h\to 0}\frac{6h}{h}f′(x)=h→0limh6h
-
Cancel the common factor hhh:
f′(x)=limh→06f'(x)=\lim_{h\to 0}6f′(x)=h→0lim6
-
Let h→0h \to 0h→0:
f′(x)=6f'(x)=6f′(x)=6
The main challenge in first-principles differentiation is usually not the calculus — it is the algebra.
You must be confident expanding expressions like (x+h)2(x+h)^2(x+h)2 and (x+h)3(x+h)^3(x+h)3.

(x+h)2=x2+2xh+h2(x+h)^2=x^2+2xh+h^2(x+h)2=x2+2xh+h2
(x+h)3=x3+3x2h+3xh2+h3(x+h)^3=x^3+3x^2h+3xh^2+h^3(x+h)3=x3+3x2h+3xh2+h3
Spot the pattern
After subtracting f(x)f(x)f(x), every remaining term should contain a factor of hhh. If it does not, check your expansion or subtraction.
Expanding the key cubic bracket
Expand (x+h)3(x+h)^3(x+h)3 fully.
-
Start by writing the cube as a product:
(x+h)3=(x+h)(x+h)(x+h)(x+h)^3=(x+h)(x+h)(x+h)(x+h)3=(x+h)(x+h)(x+h)
-
First expand two brackets:
(x+h)(x+h)=x2+2xh+h2(x+h)(x+h)=x^2+2xh+h^2(x+h)(x+h)=x2+2xh+h2
-
Multiply by the third bracket:
(x2+2xh+h2)(x+h)(x^2+2xh+h^2)(x+h)(x2+2xh+h2)(x+h)
-
Expand term by term:
x3+x2h+2x2h+2xh2+xh2+h3x^3+x^2h+2x^2h+2xh^2+xh^2+h^3x3+x2h+2x2h+2xh2+xh2+h3
-
Collect like terms:
(x+h)3=x3+3x2h+3xh2+h3(x+h)^3=x^3+3x^2h+3xh^2+h^3(x+h)3=x3+3x2h+3xh2+h3
Now let’s apply the method to a quadratic. This is a common style of proof because the expansion creates terms that need simplifying before hhh can be cancelled.

Proving the derivative of a quadratic
Prove from first principles that the derivative of 3x23x^23x2 is 6x6x6x.
-
Let f(x)=3x2f(x)=3x^2f(x)=3x2 and start with the formula:
f′(x)=limh→0f(x+h)−f(x)hf'(x)=\lim_{h\to 0}\frac{f(x+h)-f(x)}{h}f′(x)=h→0limhf(x+h)−f(x)
-
Work out f(x+h)f(x+h)f(x+h):
f(x+h)=3(x+h)2f(x+h)=3(x+h)^2f(x+h)=3(x+h)2
-
Expand the bracket:
f(x+h)=3(x2+2xh+h2)=3x2+6xh+3h2\begin{aligned}
f(x+h)&=3(x^2+2xh+h^2)\\
&=3x^2+6xh+3h^2
\end{aligned}f(x+h)=3(x2+2xh+h2)=3x2+6xh+3h2
-
Substitute f(x+h)f(x+h)f(x+h) and f(x)=3x2f(x)=3x^2f(x)=3x2 into the formula:
f′(x)=limh→0(3x2+6xh+3h2)−3x2hf'(x)=\lim_{h\to 0}\frac{(3x^2+6xh+3h^2)-3x^2}{h}f′(x)=h→0limh(3x2+6xh+3h2)−3x2
-
Simplify the numerator:
f′(x)=limh→06xh+3h2hf'(x)=\lim_{h\to 0}\frac{6xh+3h^2}{h}f′(x)=h→0limh6xh+3h2
-
Factor out hhh from the numerator:
f′(x)=limh→0h(6x+3h)hf'(x)=\lim_{h\to 0}\frac{h(6x+3h)}{h}f′(x)=h→0limhh(6x+3h)
-
Cancel hhh:
f′(x)=limh→0(6x+3h)f'(x)=\lim_{h\to 0}(6x+3h)f′(x)=h→0lim(6x+3h)
-
Let h→0h \to 0h→0:
f′(x)=6xf'(x)=6xf′(x)=6x
Forgetting to subtract the whole function
If f(x+h)=3x2+6xh+3h2f(x+h)=3x^2+6xh+3h^2f(x+h)=3x2+6xh+3h2, you must subtract all of f(x)f(x)f(x). Write brackets around the expression before subtracting, especially when signs are involved.
Cubic proofs are very similar, but the expansion is longer. The important thing is that after subtracting the original x3x^3x3 term, everything left contains hhh.

Proving the derivative of a cubic
Prove from first principles that the derivative of 4x34x^34x3 is 12x212x^212x2.
-
Let f(x)=4x3f(x)=4x^3f(x)=4x3:
f′(x)=limh→0f(x+h)−f(x)hf'(x)=\lim_{h\to 0}\frac{f(x+h)-f(x)}{h}f′(x)=h→0limhf(x+h)−f(x)
-
Find f(x+h)f(x+h)f(x+h):
f(x+h)=4(x+h)3f(x+h)=4(x+h)^3f(x+h)=4(x+h)3
-
Expand (x+h)3(x+h)^3(x+h)3:
(x+h)3=x3+3x2h+3xh2+h3(x+h)^3=x^3+3x^2h+3xh^2+h^3(x+h)3=x3+3x2h+3xh2+h3
-
Multiply by 4:
f(x+h)=4x3+12x2h+12xh2+4h3f(x+h)=4x^3+12x^2h+12xh^2+4h^3f(x+h)=4x3+12x2h+12xh2+4h3
-
Substitute into the first principles formula:
f′(x)=limh→0(4x3+12x2h+12xh2+4h3)−4x3hf'(x)=\lim_{h\to 0}\frac{(4x^3+12x^2h+12xh^2+4h^3)-4x^3}{h}f′(x)=h→0limh(4x3+12x2h+12xh2+4h3)−4x3
-
Simplify the numerator:
f′(x)=limh→012x2h+12xh2+4h3hf'(x)=\lim_{h\to 0}\frac{12x^2h+12xh^2+4h^3}{h}f′(x)=h→0limh12x2h+12xh2+4h3
-
Factor out hhh:
f′(x)=limh→0h(12x2+12xh+4h2)hf'(x)=\lim_{h\to 0}\frac{h(12x^2+12xh+4h^2)}{h}f′(x)=h→0limhh(12x2+12xh+4h2)
-
Cancel hhh:
f′(x)=limh→0(12x2+12xh+4h2)f'(x)=\lim_{h\to 0}(12x^2+12xh+4h^2)f′(x)=h→0lim(12x2+12xh+4h2)
-
Let h→0h \to 0h→0:
f′(x)=12x2f'(x)=12x^2f′(x)=12x2
A constant multiplier stays attached throughout the proof. If the function is ax3ax^3ax3, where aaa is a constant, then the derivative is 3ax23ax^23ax2.
Constant
A constant is a value that does not change as xxx changes. In an expression like ax3ax^3ax3, the letter aaa represents a fixed number.
Using a constant multiplier
Show from first principles that if f(x)=ax3f(x)=ax^3f(x)=ax3, where aaa is a constant, then f′(x)=3ax2f'(x)=3ax^2f′(x)=3ax2.
-
Start from first principles:
f′(x)=limh→0f(x+h)−f(x)hf'(x)=\lim_{h\to 0}\frac{f(x+h)-f(x)}{h}f′(x)=h→0limhf(x+h)−f(x)
-
Substitute the function:
f′(x)=limh→0a(x+h)3−ax3hf'(x)=\lim_{h\to 0}\frac{a(x+h)^3-ax^3}{h}f′(x)=h→0limha(x+h)3−ax3
-
Expand the cubic bracket:
f′(x)=limh→0a(x3+3x2h+3xh2+h3)−ax3hf'(x)=\lim_{h\to 0}\frac{a(x^3+3x^2h+3xh^2+h^3)-ax^3}{h}f′(x)=h→0limha(x3+3x2h+3xh2+h3)−ax3
-
Multiply out the constant aaa:
f′(x)=limh→0ax3+3ax2h+3axh2+ah3−ax3hf'(x)=\lim_{h\to 0}\frac{ax^3+3ax^2h+3axh^2+ah^3-ax^3}{h}f′(x)=h→0limhax3+3ax2h+3axh2+ah3−ax3
-
Simplify the numerator:
f′(x)=limh→03ax2h+3axh2+ah3hf'(x)=\lim_{h\to 0}\frac{3ax^2h+3axh^2+ah^3}{h}f′(x)=h→0limh3ax2h+3axh2+ah3
-
Factor out hhh:
f′(x)=limh→0h(3ax2+3axh+ah2)hf'(x)=\lim_{h\to 0}\frac{h(3ax^2+3axh+ah^2)}{h}f′(x)=h→0limhh(3ax2+3axh+ah2)
-
Cancel hhh:
f′(x)=limh→0(3ax2+3axh+ah2)f'(x)=\lim_{h\to 0}(3ax^2+3axh+ah^2)f′(x)=h→0lim(3ax2+3axh+ah2)
-
Let h→0h \to 0h→0:
f′(x)=3ax2f'(x)=3ax^2f′(x)=3ax2
You may already know the shortcut:
ddx(xn)=nxn−1\frac{d}{dx}(x^n)=nx^{n-1}dxd(xn)=nxn−1
For example, the derivative of x3x^3x3 is 3x23x^23x2. First principles explains why that shortcut works.
First principles means no shortcut-only solution
If you are asked to prove a derivative from first principles, do not simply quote the power rule. You can use the power rule later to check your answer, but your main solution must use the limit definition.
In the exam
-
Always begin with f′(x)=limh→0f(x+h)−f(x)hf'(x)=\lim_{h\to 0}\frac{f(x+h)-f(x)}{h}f′(x)=limh→0hf(x+h)−f(x) so your method is clear.
-
Put brackets around f(x+h)f(x+h)f(x+h) and f(x)f(x)f(x) before subtracting, then expand carefully.
-
Do not set h=0h=0h=0 until after you have cancelled the factor of hhh in the fraction.
Check yourself
-
Can you explain why f(x+h)−f(x)h\frac{f(x+h)-f(x)}{h}hf(x+h)−f(x) represents a gradient?
-
Why is it wrong to substitute h=0h=0h=0 at the start of the proof?
-
Can you expand (x+h)3(x+h)^3(x+h)3 without looking it up?