Taylor Series

TagsMATH 115

Taylor Series

Definition 🐧

A taylor series is an approximation of a function by capturing its nnο»Ώ derivatives. We can express a taylor approximation by the following:

f(x)β‰ˆa+b(xβˆ’x0)+c(xβˆ’x0)2f(x) \approx a + b(x-x_0) + c(x - x_0)^2

Derivation of coefficients πŸš€

We know that a=f(x0)a = f(x_0)ο»Ώ and we know from derivatives that b=f’(x0)b = f’(x_0)ο»Ώ. Let’s try to derive ccο»Ώ.

You can do this inductively for any number of terms. Just solve for that coefficient, and compute the limit as xβ†’x0x β†’ x_0ο»Ώ using L’hopital’s rule. The factorial in the term comes from the repeated differentiation of (xβˆ’x0)n(x - x_0)^nο»Ώ.

Taylor’s Theorem πŸš€

Theorem: A function can be expressed exactly in terms of its taylor expression as

f(x)=f(N)(c)N!(xβˆ’x0)n+1+βˆ‘n=0Nβˆ’1f(n)(x0)n!(xβˆ’x0)nf(x) = \frac{f^{(N)}(c)}{N!}(x - x_0)^{n+1} + \sum_{n=0}^{N-1} \frac{f^{(n)}(x_0)}{n!}(x - x_0)^n

So the second term is just the taylor approximation with NNο»Ώ terms, but this first term is actually quite magical. It tells us that we can make up the difference with just the next term, but you evalutate the f(N)f^{(N)}ο»Ώat some c∈(x0,x)c \in (x_0, x)ο»Ώ. Of course, this ccο»Ώ depends a lot on what xxο»Ώ is; you won’t get a perfect function just by adding another term with a singular value. We can also call this first term the remainder.