+15 XP

The Derivative is Just a Slope

Most differential equations have no exact formula for their solution. So we cheat — we let a computer crawl forward one tiny step at a time. The whole trick starts with something you already know: a derivative is just a slope.

Instead of the true instantaneous slope, we measure the slope between two nearby points on the curve, a small step Δt apart:

slope ≈ ( y(t + Δt) − y(t) ) / Δt

Rise over run between two points Δt apart. As Δt → 0 this becomes the exact derivative.

Play with the gap. The orange line is the true slope (the tangent). The green line is our two-point approximation. Watch what the size of Δt does to the accuracy:

Δt — the gap between the two pointsΔt = 2.0
012345time, ty(t)
y(t)
exact slope (tangent)
approx slope (secant)
Exact slope: 0.40Approx slope: 0.55Error: 0.15

The orange tangent is the true derivative at t = 1. The green secant connects two points Δt apart — our approximation. Shrink Δt and the secant swings onto the tangent (error → 0). Grow it and they diverge.

The takeaway: a small step gives a great slope estimate; a big step gives a sloppy one. Hold onto that — the entire chapter is a tug-of-war between small steps (accurate) and few steps (fast).