central-difference formula
Approximating a derivative from one point ahead and one point behind, straddling x symmetrically -- one order of accuracy better than using either side alone.
The central-difference formula approximates f'(x) by D(h)=\dfrac{f(x+h)-f(x-h)}{2h}, the slope of the secant line through (x-h,f(x-h)) and (x+h,f(x+h)). Its truncation error is O(h^2) -- one order better than the one-sided forward- or backward-difference formulas -- because the symmetric expansion cancels the h^1 error term exactly (ch.05 sec.3).
Examples
For f(x)=x^2 at x=1, h=0.1: \dfrac{f(1.1)-f(0.9)}{0.2}=\dfrac{1.21-0.81}{0.2}=2, exactly matching f'(1)=2 -- no error at all, since x^2's own error term vanishes identically.
Point table
Graph settings
Calculator