HexMathv1.0.4

Taylor series calculator with steps

This Taylor series calculator builds a Taylor or Maclaurin polynomial of the degree you choose. Type the function and the center, or scan the problem. HexMath finds each derivative, evaluates it at the center, divides by the matching factorial and returns the polynomial term by term, with every coefficient worked out.

Loading math input...

What this page covers

  • Taylor polynomials of a chosen degree about any center x=ax = a, and Maclaurin polynomials about 0.
  • Each derivative evaluated at the center and divided by the matching factorial to give the coefficient.
  • The standard series for exe^x, sin⁡x\sin x, cos⁡x\cos x, ln⁡(1+x)\ln(1+x) and 11−x\frac{1}{1-x}, and substitution into them.
  • Not covered here: the radius and interval of convergence of the full series (see the power series calculator).

How to enter the problem

  • Type the function, the center and the degree, such as Taylor polynomial of degree 3 of ln x at x = 1.
  • Scan it. Fit the one problem in the frame.
  • Choose a photo. Several problems in one photo are solved as a list.
  • Then tap Solve.

Worked examples

Example 1: Find the Taylor polynomial of degree 4 of cos x at x = 0.

Problem

Find the Taylor polynomial of degree 4 of cos⁡x\displaystyle \cos x at x=0\displaystyle x = 0.

Answer

Verified

The answer is

1−x22+x4241 - \frac{x^2}{2} + \frac{x^4}{24}

Explanation

  1. Compute the derivatives
    f=cos⁡xf = \cos x, f′=−sin⁡xf' = -\sin x, f′′=−cos⁡xf'' = -\cos x, f′′′=sin⁡xf''' = \sin x, f(4)=cos⁡xf^{(4)} = \cos x.
  2. Evaluate them at 0
    f(0)=1f(0) = 1, f′(0)=0f'(0) = 0, f′′(0)=−1f''(0) = -1, f′′′(0)=0f'''(0) = 0, f(4)(0)=1f^{(4)}(0) = 1.
  3. Write the Taylor formula
    P4(x)=f(0)+f′(0)x+f′′(0)2!x2+f′′′(0)3!x3+f(4)(0)4!x4P_4(x) = f(0) + f'(0)x + \frac{f''(0)}{2!}x^2 + \frac{f'''(0)}{3!}x^3 + \frac{f^{(4)}(0)}{4!}x^4
  4. Substitute
    P4(x)=1+0−x22+0+x424P_4(x) = 1 + 0 - \frac{x^2}{2} + 0 + \frac{x^4}{24}. Only even powers survive because cos⁡\cos is an even function.
  5. Check at a point
    At x=0.5x = 0.5: P4=1−0.125+0.0026=0.8776P_4 = 1 - 0.125 + 0.0026 = 0.8776, and cos⁡0.5=0.8776\cos 0.5 = 0.8776 to four places.

Example 2: Find the Taylor polynomial of degree 3 for ln x centered at x = 1.

Problem

Find the Taylor polynomial of degree 3 for ln⁡x\displaystyle \ln x centered at x=1\displaystyle x = 1.

Answer

Verified

The answer is

(x−1)−(x−1)22+(x−1)33(x-1) - \frac{(x-1)^2}{2} + \frac{(x-1)^3}{3}

Explanation

  1. Differentiate three times
    f=ln⁡xf = \ln x, f′=1xf' = \frac{1}{x}, f′′=−1x2f'' = -\frac{1}{x^2}, f′′′=2x3f''' = \frac{2}{x^3}.
  2. Evaluate at the center 1
    f(1)=0f(1) = 0, f′(1)=1f'(1) = 1, f′′(1)=−1f''(1) = -1, f′′′(1)=2f'''(1) = 2.
  3. Divide by the factorials
    The coefficients are 00, 11, −12-\frac{1}{2} and 26=13\frac{2}{6} = \frac{1}{3}.
  4. Use powers of (x−1)(x - 1)
    The center is 1, so each term uses (x−1)n(x-1)^n rather than xnx^n.

Example 3: Find the Maclaurin polynomial of degree 5 for sin(2x) by substitution.

Problem

Find the Maclaurin polynomial of degree 5 for sin⁡(2x)\displaystyle \sin(2x) by substitution.

Answer

Verified

The answer is

2x−4x33+4x5152x - \frac{4x^3}{3} + \frac{4x^5}{15}

Explanation

  1. Start from the series for sine
    sin⁡u≈u−u36+u5120\sin u \approx u - \frac{u^3}{6} + \frac{u^5}{120} up to degree 5.
  2. Substitute u=2xu = 2x
    2x−(2x)36+(2x)5120=2x−8x36+32x51202x - \frac{(2x)^3}{6} + \frac{(2x)^5}{120} = 2x - \frac{8x^3}{6} + \frac{32x^5}{120}
  3. Simplify the coefficients
    86=43\frac{8}{6} = \frac{4}{3} and 32120=415\frac{32}{120} = \frac{4}{15}.

Common mistakes

  • Leaving out the factorials. For e2xe^{2x} that gives 1+2x+4x2+8x31 + 2x + 4x^2 + 8x^3 instead of 1+2x+2x2+4x331 + 2x + 2x^2 + \frac{4x^3}{3}.
  • Writing powers of xx instead of (x−a)(x - a) when the center is not 0. About x=1x = 1, every term uses (x−1)n(x-1)^n.
  • Counting the degree by the number of terms. The degree 4 polynomial of cos⁡x\cos x has only three nonzero terms, because the odd derivatives of cos⁡x\cos x are 0 at the center.

Checks, assumptions and limits

  • Check numerically near the center. At x=0.1x = 0.1 the example in the solver above gives 1−0.005+0.0000041667≈0.99500421 - 0.005 + 0.0000041667 \approx 0.9950042, and cos⁡(0.1)≈0.9950042\cos(0.1) \approx 0.9950042.
  • The polynomial is an approximation. It is closest near the center and usually drifts away farther out.
  • Angles are in radians. The series for sin⁡x\sin x and cos⁡x\cos x hold only with xx in radians.
  • HexMath can make mistakes. Double check important steps.

Frequently asked questions

A Maclaurin series is a Taylor series centered at x=0x = 0. The method is the same: evaluate the derivatives at the center, divide the nnth one by n!n!, and multiply by (x−a)n(x - a)^n.

As many as the degree asks for. A degree nn polynomial includes every power up to (x−a)n(x - a)^n, even when some of the coefficients are 0.

Yes. Ask a follow-up question in the same thread. A typed follow-up needs sign-in.

Yes. Give the center a, and the polynomial is written in powers of (x − a). A center of 0 gives the Maclaurin polynomial.

Ready to solve your next math problem?

Create a free account for 3 math questions a day in your browser. No card.

Get HexMath on your phone

The same solver and camera scan on iPhone and Android.

Last updated: · HexMath