Math Playground
Calculus

Taylor series

Approximate any nice function with a polynomial — add more terms, get closer.

Your calculator doesn't *know* sin(0.7). It looks up a polynomial — a Taylor series — and does a few multiplications. Polynomials approximate every nice function in the universe, given enough terms.

Any 'nice' function can be approximated near a point by a polynomial — a Taylor series. The more terms you add, the better the fit.

Where you'll meet this

Numerical algorithms, physics approximations (small-angle sin θ ≈ θ), AI gradient methods, signal processing, GPU shader maths — all rely on Taylor expansions instead of exact functions.

computingphysicsML
Taylor series at x = 0

Famous Taylor series (around 0)

  • = 1 + x + x²/2! + x³/3! + … (everywhere)
  • sin x = x − x³/3! + x⁵/5! − … (everywhere)
  • cos x = 1 − x²/2! + x⁴/4! − … (everywhere)
  • 1/(1−x) = 1 + x + x² + x³ + … (only when |x| < 1)
Try it

Approximate eˣ near 0

1 + x + x²/2 + x³/6 + x⁴/24 + … (works for any x; converges everywhere)

Your turn

Use the first three terms of cos x to estimate cos(0.1).

Watch out

Taylor series only converge for some functions over their full domain. 1/(1−x) blows up at x = 1, and the series only works for |x| < 1. Always check the radius of convergence.

Recap
  • Taylor series = polynomial approximation built from a function's derivatives.
  • Closer to the centre point and more terms = better fit.
  • Many physical formulas are *just* the first term or two of a Taylor expansion (e.g. small-angle sin θ ≈ θ).