User:Egm6341.s10.team3.ynahn81/HW1-7

= (9) Taylor Series Expansion of $$\displaystyle f(x) = \frac{e^{x}-1}{x}=\frac{1}{x}\left[e^{x}-1\right] $$ with Remainder = Ref: Lecture notes [p.7-1]

Problem Statement

 * {| style="width:100%" border="0" align="left"

f(x) = \frac{e^{x}-1}{x}=\frac{1}{x}\left[e^{x}-1\right] $$
 * $$\displaystyle
 * $$\displaystyle
 * }
 * }

(i)Expand $$\displaystyle e^{x} $$ in Taylor series with remainder,
 * {| style="width:100%" border="0" align="left"

R(x) = \frac{(x-0)^{n+1}}{(n+1)!}e^{\xi(x)}. $$
 * $$\displaystyle
 * $$\displaystyle
 * }
 * }

(ii) Find Taylor series expansion and remainder of $$\displaystyle f(x) $$ to get (4) [p.6-3],
 * {| style="width:100%" border="0" align="left"

f(x)-f_{n}(x)=R_{n}(x)=\frac{(x-0)^{n}}{(n+1)!}e^{\xi(x)},\quad \xi\in[0,x]. $$
 * $$\displaystyle
 * $$\displaystyle
 * }
 * }

Solution
First, remember the Taylor series expansion for a function $$\displaystyle f(x) $$ around $$\displaystyle x=x_{0} $$:
 * {| style="width:100%" border="0" align="left"

f(x)=P_{n}(x)+R_{n+1}(x), $$ $$ where
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle (Eq. 1)
 * }
 * }
 * {| style="width:100%" border="0" align="left"

P_{n}(x)=f(x_{0})+\frac{(x-x_{0})}{1!}f^{(1)}(x_{0})+\cdots+\frac{(x-x_{0})^{n}}{n!}f^{(n)}(x_{0}) $$ $$ and
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle (Eq. 2)
 * }
 * }
 * {| style="width:100%" border="0" align="left"

R_{n+1}(x)=\frac{1}{n!}\int_{x_{0}}^{x}(x-t)^{n}f^{(n+1)}(t)dt=\frac{(x-x_{0})^{n+1}}{(n+1)!}f^{(n+1)}(\xi), \quad \xi\in[x_{0},x] $$ $$
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle (Eq. 3)
 * }
 * }

 (i) Expand $$\displaystyle f(x)=e^{x} $$ in Taylor series around $$\displaystyle x=x_{0}=0 $$. Recall that $$\displaystyle \frac{d^{n}}{dx^{n}}\left(e^{x}\right)=e^{x}, \quad n=1, 2, \cdots. $$
 * {| style="width:100%" border="0" align="left"

P_{n}(x)=e^{0}+\frac{(x-0)}{1!}e^{0}+\frac{(x-0)^{2}}{2!}e^{0}+\cdots+\frac{(x-0)^{n}}{n!}e^{0} $$
 * $$\displaystyle
 * $$\displaystyle
 * }
 * {| style="width:100%" border="0" align="left"
 * {| style="width:100%" border="0" align="left"

\Rightarrow P_{n}(x)=1+\frac{x}{1!}+\frac{x^{2}}{2!}+\cdots+\frac{x^{n}}{n!}=\sum_{j=0}^{n}\frac{x^{j}}{j!} $$ $$
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle (Eq. 4)
 * }
 * {| style="width:100%" border="0" align="left"
 * {| style="width:100%" border="0" align="left"

R_{n+1}(x)=\frac{(x-0)^{n+1}}{(n+1)!}e^{\xi}=\frac{x^{n+1}}{(n+1)!}e^{\xi} $$ $$
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle (Eq. 5)
 * }
 * }

Therefore,
 * {| style="width:100%" border="0" align="left"

$$\displaystyle e^{x}=P_{n}(x)+R_{n+1}(x)=\sum_{j=0}^{n}\frac{x^{j}}{j!}+\underbrace{\frac{x^{n+1}}{(n+1)!}e^{\xi}}_{remainder} $$ $$
 * style="width:10%; padding:10px; border:2px solid #8888aa" |
 * style="width:10%; padding:10px; border:2px solid #8888aa" |
 * style = |
 * $$\displaystyle (Eq. 6)
 * }
 * }

 (ii) Expand $$\displaystyle f(x)=\frac{e^{x}-1}{x}=\frac{1}{x}\left[e^{x}-1\right] $$ in Taylor series using Eq.6.
 * {| style="width:100%" border="0" align="left"

\frac{1}{x}\left[e^{x}-1\right]=\frac{1}{x}\left[\cancelto{0}{1}+\frac{x}{1!}+\frac{x^2}{2!}+\cdots+\frac{x^n}{n!}+\frac{x^{n+1}}{(n+1)!}e^{\xi}\cancelto{0}{-1}\right] $$ $$
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle (Eq. 7)
 * }
 * {| style="width:100%" border="0" align="left"
 * {| style="width:100%" border="0" align="left"

\Rightarrow\frac{1}{x}\left[e^{x}-1\right]=\frac{1}{x}\left[\sum_{j=1}^{n}\frac{x^{j}}{j!}+\frac{x^{n+1}}{(n+1)!}e^{\xi}\right] $$ $$
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle (Eq. 8)
 * }
 * {| style="width:100%" border="0" align="left"
 * {| style="width:100%" border="0" align="left"

\Rightarrow\frac{1}{x}\left[e^{x}-1\right]=\frac{1}{x}\sum_{j=1}^{n}\frac{x^{j}}{j!}+\frac{1}{x}\frac{x^{n+1}}{(n+1)!}e^{\xi} $$ $$
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle (Eq. 9)
 * }
 * {| style="width:100%" border="0" align="left"
 * {| style="width:100%" border="0" align="left"

\Rightarrow\frac{1}{x}\left[e^{x}-1\right]=\sum_{j=1}^{n}\frac{x^{j-1}}{j!}+\frac{x^n}{(n+1)!}e^{\xi} $$ $$ Therefore,
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle (Eq. 10)
 * }
 * }
 * {| style="width:100%" border="0" align="left"

f(x)=\underbrace{\sum_{j=1}^{n}\frac{x^{j-1}}{j!}}_{f_{n}(x)=P_{n-1}(x)}+\underbrace{\frac{x^n}{(n+1)!}e^{\xi}}_{R_{n}(x)} $$ $$ Let's move the first term on RHS of Eq.11 to LHS. Then,
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle (Eq. 11)
 * }
 * }
 * {| style="width:100%" border="0" align="left"

$$\displaystyle f(x)-f_{n}(x)=R_{n}(x)=\frac{x^{n}}{(n+1)!}e^{\xi} $$ $$ As Eq.12 shows, our final result is consistent with (4) [p.6-3] of our lecture note.
 * style="width:10%; padding:10px; border:2px solid #8888aa" |
 * style="width:10%; padding:10px; border:2px solid #8888aa" |
 * style = |
 * $$\displaystyle (Eq. 12)
 * }
 * }