Courses / Computer Science I
Calculus

Taylor Series and Approximation

Computer Science I 191 words Free to read

Computers cannot directly evaluate sin⁡x\sin x or exe^x; they use Taylor series to approximate smooth functions with polynomials built from derivatives.

The Taylor series of ff about point aa is:

f(x)=∑n=0∞f(n)(a)n!(x−a)nf(x) = \sum_{n=0}^{\infty} \frac{f^{(n)}(a)}{n!}(x - a)^n

TermWhat it matches
Constant f(a)f(a)Value at aa
Linear f′(a)(x−a)f'(a)(x-a)Slope at aa
QuadraticCurvature at aa

Truncating this gives a Taylor polynomial that hugs the function near aa. Setting a=0a = 0 yields a Maclaurin series, such as ex=1+x+x22!+…e^x = 1 + x + \frac{x^2}{2!} + \dots.

Term by term, matched to a named feature of the curve --- not the

Accuracy and Pitfalls

To compute efficiently, we replace a hard function by an easy polynomial matching it locally. The linear approximation f(x)≈f(a)+f′(a)(x−a)f(x) \approx f(a) + f'(a)(x-a) is the simplest case and underpins numerical algorithms.

FeatureTaylor Polynomial
Best RegionNear aa
Error BehaviorGrows as ∣x−a∣|x - a| increases
Common Pitfall: Expecting a truncated polynomial to work far from aa. More terms extend the valid region, but finite polynomials remain strictly local approximations.

Practise this lesson

Try the questions below, free, answers included. The full set, with its interactive scenes, is in the Tryals app.

11practice questions
2interactive scenes

Calculus