Power series as functions

Videos

Review Videos

Videos, Math Dr. Bob

Link to original

01 Theory

Theory 1

Given a numerical value for x within the interval of convergence of a power series, the series sum may be considered as the output f(x) of a function f.

Many techniques from algebra and calculus can be applied to such power series functions.

Addition and Subtraction:

f=a0+a1x+a2x2+a3x3+g=b0+b1x+b2x2+b3x3+f+g=(a0+b0)+(a1+b1)x+(a2+b2)x2+

Summation notation:

n=0anxn+n=0bnxn=n=0(an+bn)xn

Scaling:

cf=ca0+(ca1)x+(ca2)x2+

Summation notation:

cn=0anxn=n=0(can)xn

Extra - Multiplication and composition

Multiplication:

fg=(a0+a1x+a2x2+)(b0+b1x+b2x2+)=a0b0+(a0b1+a1b0)x+(a0b2+a1b1+a2b0)x2+

For example, suppose that the geometric power series f(x)=1+x+x2+x3+ converges, so |x|<1. Then we have for its square:

ff=f(x)2=(1+x+x2+)(1+x+x2+)=1+(1+1)x+(1+1+1)x2+=1+2x+3x2+4x3+=n=0(n+1)xn

Composition:

f(x)=1x+x2x3+x4f(2x3)=1+2x3+(2x3)2+=1+2x3+4x6+8x9+

Assume:

f=a0+a1x+a2x2+a3x3+=n=0anxn

Then:

Differentiation:

dfdx=a1+(2a2)x+(3a3)x2+=n=1nanxn1

Antidifferentiation:

f(x)dx=C+a0x+a12x2+a23x3+=C+n=0ann+1xn+1

For example, for the geometric series we have:

f=1+x+x2+x3+x4+dfdx=1+2x+3x2+4x3+5x4+fdx=C+x+12x2+13x3+14x4+

Do the series created with sums, products, derivatives etc., all converge? On what interval?

For the algebraic operations, the resulting power series will converge wherever both of the original series converge.

For calculus operations, the radius is preserved, but the endpoints are not necessarily:

Power series calculus - Radius preserved

If the power series f(x) has radius of convergence R, then the power series f(x) and fdx also have the same radius of convergence R.

Power series calculus - Endpoints not preserved

It is possible that a power series f(x) converges at an endpoint a of its interval of convergence, yet f and fdx do not converge at a.

Extra - Proof of radius for derivative and integral series

Suppose f(x) has radius of convergence R:

|an+1xn+1anxn||an+1an||x|1R|x| as n

Consider now the derivative f and its successive-term ratios:

|(n+1)an+1xnnanxn1|=(n+1n)|an+1an||x|n11R|x|=1R|x|

Consider now the antiderivative fdx and its successive-term ratios:

|(1n+1)anxn+1(1n)an1xn|=(nn+1)|anan1||x|n11R|x|=1R|x|

In both these cases the ratio test provides that the series converges when |x|<R.

Link to original

02 Illustration

Example - Geometric series: algebra meets calculus

Geometric series: algebra meets calculus

Consider the geometric series as a power series functions:

11x=1+x+x2+x3+

Take the derivative of both sides of the function:

ddx(11x)1(1x)2(11x)2

This means f satisfies the identity:

f=f2

Now compute the derivative of the series:

1+x+x2+x3+ddx1+2x+3x2+4x3+

On the other hand, compute the square of the series:

(1+x+x2+x3+)21+2x+3x2+4x3+

So we find that the same relationship holds, namely f=f2, for the closed formula and the series formula for this function.

Link to original

Example - Manipulating geometric series: algebra

Manipulating geometric series: algebra

Find power series that represent the following functions:

(a) 11+x (b) 11+x2 (c) x3x+2 (d) 3x25x

Solution

(a) 11+x

Rewrite in format 11u:

11+x11(x)

Choose u=x. Plug into geometric series:

11u=1+u+u2+u3+11(x)=1+(x)+(x)2+(x)3+1x+x2x3+

Therefore:

11+x=1x+x2x3+=n=0(1)nxn

(b) 11+x2

Rewrite in format 11u:

11+x2=11(x2)

Choose u=x2. Plug into geometric series:

11u=1+u+u2+u3+11(x2)=1+(x2)+(x2)2+(x2)3+1x2+x4x6+

Therefore:

11+x2=1x2+x4x6+=n=0(1)nx2n

(c) x3x+2

Rewrite in format Ax311u:

x3x+2x312+xx312(1+x2)12x311+x212x311(x2)

Choose u=x2. Here Ax3=12x3. Plug into geometric series:

11u=1+u+u2+u3+11(x2)=n=0(x2)n=1+(x2)+(x2)2+(x2)3+n=0(1)n12nxn=112x+14x218x3+

Therefore:

x3x+212x311(x2)12x3(n=0(1)n12nxn)n=0(1)n12n+1xn+3=12x314x4+18x5116x6+

(d) 3x25x

Rewrite in format Ax11u:

3x25x3x125x3x12(15x2)32x1152x

Choose u=52x. Here Ax=32x. Plug into geometric series:

11u=1+u+u2+u3+11(52x)=n=0(52x)n=1+(5x2)+(5x2)2+(5x2)3+n=05n2nxn=1+52x+254x2+1258x3+

Therefore:

3x25x32x1152x32x(n=05n2nxn)n=035n2n+1xn+1=32x+154x2+758x3+37516x4+ Link to original

Example - Manipulating geometric series: calculus

Manipulating geometric series: calculus

Find a power series that represents ln(1+x).

Solution

Differentiate to obtain similarity to geometric sum formula:

ddxln(1+x)11+x11(x)1x+x2x3+x4

Integrate series to find original function:

11(x)dx=1x+x2x3+x4dxln(1+x)=D+x12x2+13x314x4+

Use known point to solve for D:

ln(1+0)=D+0+0+0=Dln(1+x)=x12x2+13x314x4+ Link to original

Example - Recognizing and manipulating geometric series: Part I

Recognizing and manipulating geometric series: Part I

(a) Evaluate n=1(1)n11n. (Hint: consider the series of ln(1x).)

(b) Find a series approximation for ln(2/3).

Solution

(a)

(1) Follow hint, study series of ln(1x):

Notice:

ddxln(1x)=11x(1+x+x2+x3+)

Integrate the series:

11xdx=1xx2dxln(1x)=Cx12x213x3

Solve for C using ln(10)=0 which (plugging above) implies 0=C00 and thus C=0. So:

ln(1x)=x12x213x3=n=11nxn

(2) Relate to the given series:

Notice that xn=(1)n if we set x=1. Also, (1)n=(1)n1. Therefore:

ln(1(1))n=1(1)n11n

So the answer is ln2.


(b) Find a series approximation for ln(2/3):

Observe that ln(2/3)=ln(11/3).

Plug x=1/3 into the series: ln(1x)=xx22x33

ln(11/3)1/3(1/3)22(1/3)331313221333n=11n3n Link to original

Example - Recognizing and manipulating geometric series: Part II

Recognizing and manipulating geometric series: Part II

(a) Find a series representing tan1(x) using differentiation.

(b) Find a series representing dx1+x4.

Solution

(a)

Notice that ddxtan1(x)=11+x2.

What is the series for 11+x2?

Let u=x2:

11+x211u=1+u+u2+1x2+x4x6+x8

Now integrate this by terms:

11+x2dx=1x2+x4x6+x8dxC+xx33+x55x77+

Conclude:

tan1(x)=C+xx33+x55x77+

Plug in 0 to solve for C:

tan1(0)=C+0++0C=0

Final answer:

tan1(x)=xx33+x55x77+

(b)

Rewrite integrand in format of geometric series sum:

11+x411(x4)11u,u=x4

Therefore:

11u=1+u+u2+u3+1x4+x8x12+x16=n=0(1)nx4n

Integrate the series by terms to obtain the answer:

1x4+x8x12+x16dxC+xx55+x99x1313+x1717Link to original

Taylor and Maclaurin series

Videos

Review Videos

Videos, Math Dr. Bob

Link to original

03 Theory

Theory 1

Suppose that we have a power series function:

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

Consider the successive derivatives of f:

f(x)=a0+a1x+a2x2+a3x3+a4x4+f(x)=0+a1+2a2x1+3a3x2+4a4x3+f(x)=0+0+2a2+32a3x1+43a4x2+f(x)=0+0+0+321a3+432a4x1+f(n)(x)=0+0+0+0++n!an+

When these functions are evaluated at x=0, all terms with a positive x-power become zero:

f(0)=a0=a0f(0)=a1=a1f(0)=2a2=2!a2f(0)=32a3=3!a3==f(n)(0)=n(n1)21an=n!an

This last formula is the basis for Taylor and Maclaurin series:

Power series: Derivative-Coefficient Identity

f(n)(0)=n!an

This identity holds for a power series function f(x)=a0+a1x+a2x2+a3x3+ which has a nonzero radius of convergence.

We can apply the identity in both directions:

  • Know f(x)? Calculate an for any n.
  • Know an? Calculate f(n)(0) for large n. (Faster than differentiating.)

Many functions can be ‘expressed’ or ‘represented’ near x=c (i.e. for small enough |xc|) as convergent power series. (This is true for almost all the functions encountered in pre-calculus and calculus.)

Such a power series representation is called a Taylor series. When c=0, the Taylor series is also called the Maclaurin series.

One power series representation we have already studied:

11x=1+x+x2+x3+

Whenever a function has a power series (Taylor or Maclaurin), the Derivative-Coefficient Identity may be applied to calculate the coefficients of that series.

Conversely, sometimes a series can be interpreted as an evaluated power series coming from x=c for some c. If the closed form function format can be obtained for this power series, the total sum of the original series may be discovered by putting x=c in the argument of the function.

Link to original

04 Illustration

Example - Maclaurin series of ex

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=0xnn! Link to original

Example - Maclaurin series of cosx

Maclaurin series of cos x

Find the Maclaurin series representation of cosx.

Solution

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

an=f(n)(0)n!
nf(n)(x)f(n)(0)an
0cosx11
1sinx00
2cosx11/2
3sinx00
4cosx11/24
5sinx00

By studying this pattern, we find the series:

cosx=1x22!+x44!x66!+=n=0(1)nx2n(2n)! Link to original

Maclaurin series from other Maclaurin series

Maclaurin series from other Maclaurin series

(a) Find the Maclaurin series of sinx using the Maclaurin series of cosx.

(b) Find the Maclaurin series of f(x)=x2e5x using the Maclaurin series of ex.

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

Solution

(a)

Remember that ddxcosx=sinx. Let us differentiate the cosine series by terms:

1x22!+x44!x66!+ddx02x12!+4x34!6x56!+x11!+x33!x55!

Take negative to get:

sinx=xx33!+x55!x77!+

(b)

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

Set u=5x:

e5x=1+(5x)1!+(5x)22!+(5x)33!+=n=0(1)n5nn!xn

Multiply all terms by x2:

x2e5xx2(1+(5x)1!+(5x)22!+(5x)33!+)x25x3+252x41253!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!a2252022!20!5202221 Link to original

Computing a Taylor series

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(xc)+a2(xc)2+a3(xc)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(x3)164(x3)2+1512(x3)3516,384(x3)4+Link to original

05 Theory

Theory 2

Study these!

  • Memorize all of these series!
  • Recognize all of these series!
  • Recognize all of these summation formulas!
11x=1+x+x2+=n=0xn,R=1,interval: (1,1)ln(1x)=x1x22x33=n=0xn+1n+1,R=1,interval: [1,1)tan1x=xx33+x55=n=0(1)nx2n+12n+1,R=1,interval: [1,1]ex=1+x1!+x22!+=n=0xnn!,R=cosx=1x22!+x44!=n=0(1)nx2n(2n)!,R=sinx=xx33!+x55!+=n=0(1)nx2n+1(2n+1)!,R=Link to original

Applications of Taylor series

Videos

Review Videos

Videos, Math Dr. Bob

Link to original

06 Theory reminder

Theory 1

Linear approximation is the technique of approximating a specific value of a function, say f(x1), at a point x1 that is close to another point x0 where we know the exact value f(x0). We write Δx for x1x0, and y0=f(x0), and y1=f(x1). Then we write dy=f(x0)Δx and use the fact that:

y1y0+dy=y0+f(x0)Δx

Computing a linear approximation

For example, to approximate the value of 4.01, set f(x)=x, set x0=4 and y0=2, and set x1=4.01 so Δx=0.01.

Then compute: f(x)=12x So f(x0)=1/4.

Finally:

y1y0+f(x0)Δxy12+140.01=2.0025

Now recall the linearization of a function, which is itself another function:

Given a function f(x), the linearization L(x) at the basepoint x=c is the functional form of the tangent line, the line passing through (x0,y0)=(c,f(x)) with slope m=f(c):

y=y0+m(xx0)(point-slope eqn. of line)L(x)=f(c)+f(c)(xc)(linearization fcn.)

The graph of this linearization L(x) is the tangent line to the curve y=f(x) at the point (c,f(c)).

The linearization L(x) may be used as a replacement for f(x) for values of x near c. The closer x is to c, the more accurate the approximation L(x) is for f(x).

Computing a linearization

We set f(x)=x, and we let c=4.

We compute f(c)=2, and f(x)=12x so f(c)=14.

Plug everything in to find L(x):

L(x)=f(c)+f(c)(xc)L(x)=2+14(x4)

Now approximate f(4.01)L(4.01):

L(4.01)=2+14(4.014)=2.0025
Link to original

07 Theory

Theory 2

Taylor polynomials

The Taylor polynomials TN(x) of a function f(x) are the partial sums of the Taylor series of f(x):

TN(x)=i=0Nf(i)(c)i!(xc)i=f(c)+f(c)1!(xc)++f(N)(c)N!(xc)N

These polynomials are generalizations of linearization. Specifically, f(c)=T0(x), and L(x)=T1(x).

The Taylor series Tn(x) is a better approximation of f(x) than Ti(x) for any i<n.

center

center

Facts about Taylor series

The series Tn(x) has the same derivatives as f(x) at the point x=c. This fact can be verified by visual inspection of the series: apply the power rule and chain rule, then plug in x=c and all factors left with (xc) will become zero.

The difference f(x)Tn(x) vanishes to order n at x=c:

f(x)Tn(x)=f(n)(c)n!(xc)n+f(n+1)(c)(n+1)!(xc)n+1+=(xc)n(f(n)(c)n!+f(n+1)(c)(n+1)!(xc)+)

The factor (xc)n drives the whole function to zero with order n as xc.

If we only considered orders up to n, we might say that f(x) and Tn(x) are the same near c.

Link to original

08 Illustration

Taylor polynomial approximations

Taylor polynomial approximations

Let f(x)=sinx and let Tn(x) be the Taylor polynomials expanded around c=0.

By considering the alternating series error bound, find the first n for which Tn(0.02) must have error less than 106.

Solution

Write the Maclaurin series of sinx because we are expanding around c=0:

sinx=xx33!+x55!x77!+=n=0(1)nx2n+1(2n+1)!

This series is alternating when we insert x=0.02, so the AST error bound formula applies (“Next Term Bound”):

|En|an+1

Find smallest n such that an+1106, and then we know:

|En|an+1106|En|106

Plug x=0.02 in the series for sinx:

a2n+1=(0.02)2n+1(2n+1)!

Solve for the first time a2n+1106 by listing the values:

0.0211!=0.02,0.0233!1.33×106,0.0255!2.67×1011,

The first time a2n+1 is below 106 happens when 2n+1=5.

This is NOT the same n as in Tn. That n is the highest power of x allowed.

The sum of prior terms is T4(0.02).

Since T4(x)=T3(x) because there is no x4 term, the final answer is n=3.

Link to original

Taylor polynomials to approximate a definite integral

Taylor polynomials to approximate a definite integral

Approximate 00.3ex2dx using a Taylor polynomial with an error no greater than 105.

Solution

Plug u=x2 into the series of eu:

eu=n=0unn!ex2=n=0(x2)nn!n=0(1)n1n!x2n

Find an antiderivative by terms:

n=0(1)n1n!x2ndxn=0(1)n1n!x2n+12n+1x11!(3)x3+12!(5)x513!(7)x7+

Plug in bounds for definite integral:

00.3n=0(1)n1n!x2n=n=0(1)n1n!x2n+12n+1|00.3n=0(1)n1n!(0.3)2n+12n+10.3(0.3)33+(0.3)510(0.3)742+

Notice alternating series pattern. Apply error bound formula, “Next Term Bound”:

(0.3)5102.43×104,(0.3)7425.21×106

So we can guarantee an error less than 5.21×106 by summing the first terms through (0.3)510:

0.3(0.3)33+(0.3)510=0.291243Link to original