About the Taylor Series Calculator
A Taylor polynomial replaces a complicated function with a simple polynomial that matches it closely near a chosen point. Calculators use the idea to evaluate and , physicists use it whenever they say "for small angles, ", and engineers use it to linearise systems that would otherwise be impossible to analyse. It is one of the most practical ideas in all of calculus.
This calculator builds the polynomial exactly as the formula prescribes. It differentiates your function repeatedly with the symbolic derivative engine, evaluates each derivative at the center, divides by the matching factorial and assembles the terms. Coefficients are kept exact whenever they are rational or simple multiples of constants like , or , so you see rather than .
Give an x-value and the calculator also evaluates the polynomial there, compares it with the actual function value and reports the error, so you can see how good the approximation is. The polynomial is verified by checking that its error shrinks at the rate Taylor's theorem predicts, and functions that cannot be expanded at the chosen center are refused with an explanation.
What is a Taylor series?
The Taylor series of a function about a point is the infinite sum . Each term is built from one derivative of at the single point . When the series is usually called a Maclaurin series, after Colin Maclaurin, who used this special case extensively.
Stopping the sum after the term gives the Taylor polynomial of order , written . It is the unique polynomial of degree at most whose value and first derivatives at agree with those of . Matching more derivatives means matching the shape of the curve more closely, which is why higher orders generally give better approximations near the center.
For many functions the full series equals the function on an interval around . The series for , and converge for every real ; the series for about 1 converges only for . Outside that interval the polynomial still exists, but adding more terms no longer helps, and the approximation can get dramatically worse instead of better. Knowing where a series converges is therefore just as important as knowing its coefficients.
How to use the Taylor Series Calculator
- Type the function of x, for example e^x, sin(x), log(x) for the natural logarithm or sqrt(x).
- Enter the center a. Use 0 for a Maclaurin polynomial; values such as 1, 4 or pi/4 also work.
- Choose the order n, a whole number from 0 to 12.
- Optionally enter an x-value to compare the polynomial's approximation with the true value.
- Press Find Taylor polynomial to see the derivative table, the coefficients and the finished polynomial.
Formulas
Taylor polynomial of order n
Lagrange remainder
Exponential
Sine and cosine
Geometric series
Worked example: eˣ about 0, order 4, at x = 1
The worked example below is computed live for about with order 4, approximated at . Every derivative of is , and , so the coefficients are simply . The polynomial is .
At this gives , while the true value is , an error of about 0.00995. The next term, , is roughly 0.0083, which shows why the error is that size: what is left over is dominated by the first term you left out.
The solution below is generated by the same engine that powers the calculator above.
Final answer
How we read your problem
Find the Taylor polynomial of order 4 for f(x) = e^x centred at x = 0.
Step-by-step solution
Taylor polynomial of order 4 about x = 0 (a Maclaurin polynomial)
Differentiate and evaluate at the center
Continue differentiating
Divide each value by k! and assemble the polynomial
Approximate f(1) with the polynomial
Formulas used
Taylor polynomial
Each coefficient is the k-th derivative at the center divided by k!, so the polynomial matches f and its first 4 derivatives at x = 0. Near the center it approximates f with an error of order (x − a)^5.
Verification
- Checked: the error f(a + h) − Tₙ(a + h) shrinks like h^5 (h = 0.1 → 8.47e-8, h = 0.05 → 2.63e-9).
Detailed explanation
Where the coefficients come from
Suppose a polynomial is to match at . Setting kills every term except , so . Differentiating once and setting leaves . Differentiating twice leaves , and in general .
That is the whole derivation, and it explains the factorials: they undo the constants that pile up when is differentiated times. The calculator displays this as a table of and for each , which is the same table you would build by hand.
Patterns in the standard series
For about 0 the derivatives cycle through , which at 0 take the values . Every even-power coefficient is zero, and the order-7 polynomial is . Cosine gives the even powers instead: to order 4 it is .
For about 1 the th derivative is , so the coefficients are and the series is . Recognising these patterns lets you write down many series without computing derivatives at all, and substitute into them, for example replacing with in the series for .
How accurate is the approximation?
Taylor's theorem bounds the error. The remainder equals for some between and . Two things make it small: being close to the center, so is tiny, and the factorial in the denominator, which eventually beats any power.
The square root example shows the first effect. The order-3 polynomial for about 4 is . At it gives about 2.024845703 against the true 2.024845673, an error near , because is already very small.
Far from the center the picture changes. For , the polynomials match well at but are useless at , because the series only converges for . At the order-5 polynomial gives 63 while the function equals , an error of 64 that grows with every extra term. The calculator's error report makes this visible: try the same function and order at a near point and a far point and compare.
Choosing the center
Pick a center where the function and its derivatives are easy to evaluate and that lies close to where you need the approximation. Expanding about 4 is natural because exactly. Expanding about 0 is impossible because the function is undefined there, and expanding about 0 fails because it has no derivative at that point; the calculator explains such cases instead of producing a meaningless polynomial.
Taylor polynomials in practice
The small-angle approximation is simply the order-1 Maclaurin polynomial of sine, and it is accurate to better than 1% for angles below about 14 degrees. A pendulum's period formula, the paraxial approximation in optics and the linear spring law all come from keeping only the first one or two terms of a Taylor expansion.
Taylor polynomials also turn hard problems into easy ones. A limit such as becomes obvious once is replaced by , and an integral with no elementary antiderivative, like , can be approximated by integrating a polynomial term by term.
Common mistakes
- Forgetting to divide each derivative by .
- Writing powers of instead of when the center is not zero.
- Evaluating derivatives at instead of at the center .
- Assuming more terms always improve the approximation, even outside the interval of convergence.
- Confusing order with the number of nonzero terms; to order 7 has only four terms.
- Using degrees in trigonometric series, which are valid only for angles in radians.
Tips
- Choose the center close to the x-values you care about.
- Memorise the series for , , and ; many others follow by substitution.
- Estimate the error with the first omitted term when the series alternates.
- Check as a quick sanity test of your polynomial.
- Use order 1 to get the tangent line, the simplest linear approximation.
- Compare two orders at the same x-value; if the answers barely change, the approximation has settled.
- Graph the function and its polynomial together to see exactly where the match starts to fail.
Frequently asked questions
What is the difference between a Taylor and a Maclaurin series?
A Maclaurin series is a Taylor series centred at 0. Enter a = 0 for a Maclaurin polynomial; any other center gives a general Taylor polynomial in powers of (x − a).
What order should I choose?
Use the order your problem asks for. Otherwise, low orders such as 2 to 4 show the idea, and higher orders give better accuracy close to the center. The calculator allows orders from 0 to 12.
Why are some powers missing from my polynomial?
Their coefficients are zero. Odd functions such as sin x have only odd powers about 0, and even functions such as cos x have only even powers. Zero terms are left out of the final polynomial.
How do I enter the natural logarithm?
Type log(x); the calculator reads log as the natural logarithm ln. Remember that ln x cannot be expanded about 0, so use a center such as a = 1.
What does the error value tell me?
It is the difference between the true function value and the polynomial's value at your chosen x. Small errors mean the polynomial is a good stand-in for the function there.
Why does the calculator refuse to expand some functions?
A Taylor polynomial needs the function and its derivatives to exist at the center. If one of them is undefined, as for |x| or √x at 0, the calculator reports which derivative fails and suggests choosing another center.
Can the center be an irrational number like π/4?
Yes. Enter pi/4 or similar. Coefficients are shown exactly when they match simple multiples of constants such as √2, and otherwise as decimals marked with ≈.
Is the order-1 Taylor polynomial the tangent line?
Yes. T₁(x) = f(a) + f′(a)(x − a) is exactly the tangent line at x = a, also called the linear approximation or linearisation of f.
How is a Taylor polynomial different from a Taylor series?
A Taylor polynomial stops after a finite number of terms and is an approximation. A Taylor series continues forever and, inside its interval of convergence, equals the function exactly. This calculator builds the polynomial of the order you choose.
Build your Taylor polynomial
Enter a function, a center and an order above to get every derivative, the exact coefficients and the approximation error.