Numerical Methods for Engineers · Problem type

Central differences for f′ and f″

Use this for “f(0.9) = 2.4596, f(1) = 2.7183 and f(1.1) = 3.0042. Estimate f′(1) and f″(1).”

Chart

f(s) = 2.718 + 2.723s + 1.36s2−2−1012301234567Distance from x, sfΔs = 1Δy = 2.723(−0.1, 2.46)(0, 2.718)(0.1, 3.004)
Tangent at s = 0: slope f′(0) = 2.723, y = 2.723s + 2.718
Ringed: the nodes (−0.1, 2.46), (0, 2.718), (0.1, 3.004)
This is an example. Type your own values to start a new problem.
f′
≈
−
2
×
=
f(x)
Value at the point
example
f″
Second derivative
calculated

Formulas

f′
=
(
f
(x
+
h
)
−
(
f
(x
−
h
)))
÷
(2
×
h
)
2.723
=
3.0042 − 2.4596
2 × 0.1
f″
=
(
f
(x
+
h
)
−
2
×
f
(x)
+
f
(x
−
h
))
÷
h
2
2.72
=
(3.0042
−
2
×
2.7183
+
2.4596)
÷
0.1
2

Assumptions

•
The three points are evenly spaced, h apart, with x in the middle.
•
Both formulas are second order: halving h cuts the error about 4 times.
•
A very small h loses digits to rounding, since nearly equal values are subtracted.

Step-by-step

WE KNOW
h = 0.1, f(x − h) = 2.4596, f(x) = 2.7183, f(x + h) = 3.0042
FIND
first derivative (f′), second derivative (f″)
Step 1 · Find first derivative (f′)
Use f′ = (f(x + h) − (f(x − h))) ÷ (2 × h)
The
slope
of
the
line
through
the
two
outer
points,
which
are
2
h
apart.
f′
=
3.0042 − 2.4596
2 × 0.1
f′
=
0.5446
0.2
f′ = 2.723
Step 2 · Find second derivative (f″)
Use f″ = (f(x + h) − 2 × f(x) + f(x − h)) ÷ h²
The
change
in
slope
from
the
left
half-step
to
the
right
one,
over
h
.
f″
=
(3.0042
−
2
×
2.7183
+
2.4596)
÷
0.1
2
f″
=
3.0042 − 5.4366 + 2.4596
0.1
2
f″
=
0.0272
0.1
2
f″
=
0.0272
0.01
f″ = 2.72
Check
Put the numbers back in. Both sides should match.
2.723
=
3.0042 − 2.4596
2 × 0.1
✓
2.72
=
(3.0042
−
2
×
2.7183
+
2.4596)
÷
0.1
2
✓
Topic check
See what you know: 5 questions on this topic
New questions each time. Pass to mark it complete.

Related lessons

© 2026 SME. All rights reserved.