next up previous
Next: About this document ... Up: lab_template Previous: lab_template

Subsections


Taylor Polynomials

Purpose

The purpose of this lab is to use Maple to introduce you to the concept of radius of convergence of power series and Taylor series.

Getting Started

To assist you, there is a worksheet associated with this lab that contains examples similar to some of the exercises. You can access this worksheet by typing in the search field (mag nifying glass next to start menu):

\\storage.wpi.edu\academics\math\calclab\MA1023\Powseries_start_A19.mw

Background

The general form of the Taylor polynomial approximation of order $n$ to $f(x)$ is given by the following

Theorem 1   Suppose that $f(x)$ is a smooth function in some open interval containing $x=a$. Then the $n$th degree Taylor polynomial of the function $f(x)$ at the point $x=a$ is given by

\begin{displaymath}P_n(x,a) = f(a) + f'(a)(x-a) + \frac{f''(a)}{2}(x-a)^2 + \cdots
+ \frac{f^{(n)}(a)}{n!} (x-a)^n\end{displaymath}

which can be written more compactly with summation notation.

\begin{displaymath}P_n(x,a) = \sum_{k=0}^{n} \frac{f^{(k)}(a)}{k!} (x-a)^k \end{displaymath}

The notation $f^{(k)}(a)$ is used in the definition to stand for the value of the $k$-th derivative of $f$ at $x=a$. That is, $f^{(1)}(a) = f'(a)$, $f^{(3)}(a) = f'''(a)$, and so on. By convention, $f^{(0)}(a) =
f(a)$. Note that $a$ is fixed and so the derivatives $f^{(k)}(a)$ are just numbers. That is, a Taylor polynomial has the form

\begin{displaymath}\sum_{k=0}^{n} a_k (x-a)^k \end{displaymath}

which you should recognize as a power series that has been truncated.

The Ratio Test

The Ratio Test for convergence of a series can be thought of as a measurement of how fast the series is increasing or decreasing. This can be found by looking at the ratio $\displaystyle \frac{a_{n+1}}{an}$ as $n \rightarrow \infty$.

Given the series $\displaystyle \sum_{n=0}^{\infty} a_n$, suppose that

\begin{displaymath}\lim_{n \rightarrow \infty} \vert\frac{a_{n+1}}{a_n}\vert=L \end{displaymath}

Then

  1. the series converges if $L < 1$,
  2. the series diverges if $L>1$,
  3. the test is inconclusive if $L=1$.

Radius or Interval of Convergence

The radius of convergence of a series can usually be found by using the ratio test:

\begin{displaymath}\lim_{n \rightarrow \infty} \frac{a_{n+1}}{a_n}=L \end{displaymath}

Next, you would need to solve for the interval of $x$ values such that $\vert L\vert<1$. This, however, does not account for convergence or divergence at the endpoints of the interval. Those would need to be tested individually.

Maple Commands

The general term $a_n$ for a series $\displaystyle \sum_{n=0}^{\infty} a_n$ can be defined in Maple as a function of $n$ and the ratio test can be performed as follows:
> a := n-> (1/2)^n
> limit(a(n+1)/a(n),n=infinity)
The same commands can be used to determine the radius of convergence of a power series where you would then need to solve for the values of x that would make the absolute value of the limit less than 1.
> a := n-> x^n
> L:= limit(a(n+1)/a(n),n=infinity)
> solve(abs(L)<1,x)
This approach can also be used to determine the interval that a Taylor series converges to the function that it is approximating. However, you must first identify the general term of the series as shown below.
> f := x-> cos(x)
> taylor(f(x),x=0,10)
> a:= n-> (-1)^n(2x)^n/(2n)!
> seq(a(n),n=0..5)
> L:= simplify(limit(a(n+1)/a(n),n=infinity))
> solve(abs(L)<1,x)

Exercises

  1. Use the ratio test to determine if each of the given series converges or diverges.
    a)

    \begin{displaymath}\sum_{n=1}^{\infty} \frac{(2^n)n!}{(n^2)!} \end{displaymath}

    b)

    \begin{displaymath}\sum_{n=1}^{\infty} \frac{3^n n!}{n^n}
\end{displaymath}

    c)

    \begin{displaymath}\sum_{n=1}^{\infty} 2^n(1-\frac{1}{n})^{n^2}
\end{displaymath}

  2. Use the ratio test to find the interval of convergence for each of the following series. When necessary, be sure to explain whether or not to include the endpoints of the interval.
    a)

    \begin{displaymath}\sum_{n=1}^{\infty} \frac{(-1)^n}{3^n}(x+2)^n \end{displaymath}

    b)

    \begin{displaymath}\sum_{n=1}^{\infty} n^n x^n \end{displaymath}

  3. Find the Taylor/power series for each function listed below about $x=0$. Write the general term of the series and define it as $a_n$ in Maple (Use the seq command to check that the terms match the terms of the series. Then, use the ratio test to determine the interval of $x$ values over which the Taylor series converges to the given function.

    1. \begin{displaymath}\frac{1}{1-4x} \end{displaymath}


    2. \begin{displaymath}3^x \end{displaymath}


    3. \begin{displaymath}\sin(x) \end{displaymath}


    4. \begin{displaymath}\ln(x+1) \end{displaymath}

  4. Recall the function, $\displaystyle f(x) = \frac{1}{5+2x}$, from last week's lab. Use the procedure from the last exercise to verify your interval of convergence.


next up previous
Next: About this document ... Up: lab_template Previous: lab_template
Dina J. Solitro-Rassias
2019-09-27