Maclaurin series of e to the x

What is the Maclaurin series of f(x)=ex?

Solution

Using ddxex=ex repeatedly, we see that f(n)(x)=ex for all n.

So f(n)(0)=e0=1 for all n. Therefore an=1n! for all n by the Derivative-Coefficient Identity:

ex=1+x1!+x22!+x33!+⋯=∑n=0∞xnn!

Maclaurin series of cos x

Find the Maclaurin series representation of cos⁡x.

Solution

Use the Derivative-Coefficient Identity to solve for the coefficients:

an=f(n)(0)n!
nf(n)(x)f(n)(0)an
0cos⁡x11
1−sin⁡x00
2−cos⁡x−1−1/2
3sin⁡x00
4cos⁡x11/24
5−sin⁡x00
⋮⋮⋮⋮

By studying this pattern, we find the series:

cos⁡x=1−x22!+x44!−x66!+⋯=∑n=0∞(−1)nx2n(2n)!

Maclaurin series from other Maclaurin series

(a) Find the Maclaurin series of sin⁡x using the Maclaurin series of cos⁡x.

(b) Find the Maclaurin series of f(x)=x2e−5x using the Maclaurin series of ex.

(c) Using (b), find the value of f(22)(0).

Solution

(a)

Remember that ddxcos⁡x=−sin⁡x. Let us differentiate the cosine series by terms:

1−x22!+x44!−x66!+⋯≫≫ddx0−2x12!+4x34!−6x56!+⋯≫≫−x11!+x33!−x55!−⋯

Take negative to get:

sin⁡x=x−x33!+x55!−x77!+⋯

(b)

eu=1+u11!+u22!+u33!+⋯

Set u=−5x:

e−5x=1+(−5x)1!+(−5x)22!+(−5x)33!+⋯=∑n=0∞(−1)n5nn!xn

Multiply all terms by x2:

x2e−5x≫≫x2(1+(−5x)1!+(−5x)22!+(−5x)33!+⋯)≫≫x2−5x3+252x4−1253!x5+⋯≫≫∑n=0∞(−1)n5nn!xn+2

(c)

For any series:

f(x)=a0+a1x+a2x2+a3x3+⋯

we have:

f(n)(0)=n!⋅an

We can use this to compute a22. From the series formula:

∑n=0∞(−1)n5nn!xn+2

we see that:

an+2=(−1)n5nn!

Power, NOT term number

The coefficient with an+2 corresponds to the term having xn+2, not necessarily the (n+2)th term of the series.

Therefore:

a22=(−1)2052020!≫≫520120!f(22)(0)=22!⋅a22≫≫520⋅22!20!≫≫520⋅22⋅21

Computing a Taylor series

Find the first five terms of the Taylor series of f(x)=x+1 centered at c=3.

Solution

A Taylor series is just a Maclaurin series centered at a nonzero number.

General format of a Taylor series:

f(x)=a0+a1(x−c)+a2(x−c)2+a3(x−c)3+⋯

The coefficients satisfy f(n)(c)=n!an.

Find the coefficients by computing the derivatives and evaluating at x=3:

f(x)=(x+1)1/2,f(3)=2f′(x)=12(x+1)−1/2,f′(3)=14f′′(x)=−14(x+1)−3/2,f′′(3)=−132f′′′(x)=38(x+1)−5/2,f′′′(3)=3256f(4)(x)=−1516(x+1)−7/2,f(4)(3)=−152048

The first terms of the series:

f(x)=x+1=2+14(x−3)−164(x−3)2+1512(x−3)3−516,384(x−3)4+⋯