Advanced maths

Taylor and Maclaurin approximation calculator

Compare Taylor polynomials for exp, sin, cos and log(1+x), including an analytic truncation bound and SVG overlay.

Your numbers

Calculated on your device. Your inputs aren’t sent to us.

Your result

Ready when you are

Enter your numbers and select Calculate.

Try it, understand it

Explore the result

Change one Taylor assumption at a time and compare the signed error with the separate exact-arithmetic remainder bound.

Worked example comparison
ExampleOutputWhat to notice
Degree four exponential at oneTaylor polynomial approximation2.708333The default polynomial is 65/24, about 2.7083333333.
Degree eight exponential at oneTaylor polynomial approximation2.718279More included terms improve this particular center/target comparison.
Degree four sine at zero centerTaylor polynomial approximation0.833333At x=1, the polynomial is 1−1/6=5/6 because the even-power coefficients vanish.

Check your understanding

Does degree four mean four nonzero terms?

No. Zero derivative coefficients remain zero even when their powers are included.

Is the analytic bound a roundoff bound?

No. It bounds truncation under the stated exact-arithmetic derivative assumptions.

Behind the numbers

How this calculation works

Build the finite polynomial around the chosen center and compare its value with the supported function at the target. A center of zero is a Maclaurin expansion. The analytic Lagrange bound measures truncation in exact arithmetic; it does not include floating-point evaluation error.

THE FORMULATₙ(x) = Σ from k=0 to n of f⁽ᵏ⁾(a)(x−a)ᵏ/k!

A worked example

For exp(x) around zero through degree four at x=1, 1+1+1/2+1/6+1/24 = 65/24 ≈ 2.7083333333. The function value is about 2.7182818285.

Good to know

Four supported real functions only, degree 0–30. Trig inputs are radians. log(1+x) requires center and target above −1, and its infinite series need not converge at a distant target even though the finite polynomial is defined. Near-domain-boundary overflow is rejected; no symbolic arbitrary-function expansion.

A center and a degree define the approximation

A Taylor polynomial matches a function’s derivatives at one chosen center. Moving the center changes the polynomial, even when the target x and degree stay the same. Setting the center to zero gives the familiar Maclaurin case.

Degree is the highest included power, rather than the number of nonzero terms. A degree-four sine expansion at zero still has only x−x³/6 because its even-power coefficients vanish. The coefficient table keeps those zero entries visible.

The polynomial tangent calculator isolates the first-order local prediction. A Taylor approximation calculator adds higher-order terms for its stated supported functions.

Compare approximation error with truncation theory

For exp(x) at x=1 around zero, degree four gives 65/24, about 2.7083333333. Subtracting exp(1) gives about −0.0099484951. A negative signed difference means the polynomial is below the function at this particular target.

The analytic truncation bound uses a bound on the next derivative along the real interval from center to target. It is a theoretical exact-arithmetic bound, not a guarantee about a floating-point implementation. Severe cancellation can add numerical error that the displayed bound does not include.

The logarithm needs an extra convergence distinction

A finite log(1+x) Taylor polynomial can be evaluated at a real target greater than −1 even when that target lies beyond the infinite series’ convergence disk around the center. A large degree does not automatically fix an unsuitable expansion center.

The polynomial tangent calculator shows the degree-one local idea through slope and a finite-offset comparison. This page adds higher derivatives for four supported functions; it does not accept arbitrary symbolic expressions or claim that a sampled overlay proves convergence.

A few questions, answered

Do sine and cosine use degrees?

No. Their arguments, centers and targets are in radians.

Why did degree four add no new sine term?

At center zero, the even-order sine derivatives vanish. Degree four includes that zero coefficient; it does not mean four nonzero terms.

Is the truncation bound the measured error?

No. The signed difference compares two floating-point evaluations; the analytic bound concerns the omitted Taylor remainder in exact arithmetic.

Find your calculator

Start typing to explore the library.