---
tag: 0HFSFVMWQB
kind: definition
name: Taylor polynomial
msc: [41A58]
defines: 0ZZ4RHTR9X
uses: [084NGSTWM7]
sources:
  - url: https://en.wikipedia.org/wiki/Taylor%27s_theorem
    locator: Statement of the theorem
---

## Definition

Let $I$ be an open interval, let $a \in I$, and let $f \colon I \to \mathbb{R}$ be $k$ times differentiable at $a$.
The Taylor polynomial of degree $k$ of $f$ at $a$ is
$$P_k(x) = \sum_{j=0}^{k} \frac{f^{(j)}(a)}{j!} (x - a)^j = f(a) + f'(a)(x - a) + \cdots + \frac{f^{(k)}(a)}{k!} (x - a)^k.$$

## Remarks

It is the unique polynomial $P$ of degree at most $k$ with $P^{(j)}(a) = f^{(j)}(a)$ for $j = 0, \dots, k$, using [[higher derivatives|084NGSTWM7]].
For $k = 1$, its graph is the [[tangent line|01R1HW3Y42]].
The difference $R_k = f - P_k$ is the remainder. [[Taylor's theorem|03QHBVW4TT]] says that it is small near $a$.
Mathlib has `taylorWithinEval` for Taylor polynomials within a set.

## Explanations

### L1 human

The Taylor polynomial copies the value and the first $k$ derivatives of $f$ at $a$.
It is the polynomial that best fits $f$ near $a$.
