User:Egm6341.s10.Team4.nimaa&m/HW1

= Exercise #6 =

Given
Use following Integration
 * {| style="width:100%" border="0" align="left"

$$ $$
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle f(x)=f(x_0)+\dfrac{x-x_0}{1!}f^1(x_0)+\int\limits_{x_0}^{x} (x-t)f^2(t)\, dt


 * }
 * }

Find
Repeat integration by parts to reveal:
 * {| style="width:100%" border="0" align="left"

$$ $$
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle \dfrac{(x-x_0)^2}{2!}f^2(x_0)+\dfrac{(x-x_0)^3}{3!}f^3(x_0)


 * }
 * }

Solution
For solving this problem we should show that:



I=\int\limits_{x_0}^{x} (x-t)f^2(t)\, dt = \dfrac{(x-x_0)^2}{2!}f^2(x_0)+\dfrac{(x-x_0)^3}{3!}f^3(x_0)+.... $$

From integration by parts; we can define functions u and dv as:



f^2(t)=u; (x-t)dt=dv \rightarrow\ v=\int\limits_{x_0}^{x}(x-t)\, dt = xt-\dfrac{(t^2)}{2} $$



\Rightarrow\ \int\limits_{x_0}^{x} (x-t)f^2(t)\, dt=[(xt-\dfrac{t^2}{2})f^2(t)]-\int\limits_{x_0}^{x}(xt-\dfrac{t^2}{2})f^3(t)\, dt= $$



=\dfrac{x^2}{2}f^2(x)-xx_0f^2(x_0)+\dfrac{x_0^2}{2}f^2(x_0)-\int\limits_{x_0}^{x} (xt-\dfrac{t^2}{2})f^3(t)\, dt $$

Then, by adding and subtracting following term to the integral,



\dfrac{x^2}{2}f^2(x_0) $$

We obtain:



=\dfrac{x^2}{2}f^2(x)-\dfrac{x^2}{2}f^2(x_0)+\dfrac{x^2}{2}f^2(x_0)-\dfrac{2xx_0}{2}f^2(x_0)+\dfrac{x_0^2}{2}f^2(x_0)-\int\limits_{x_0}^{x} (xt-\dfrac{t^2}{2})f^3(t)\, dt= $$



=\dfrac{(x-x_0)^2}{2!}f^2(x_0)+\dfrac{x^2}{2}\int\limits_{x_0}^{x} f^3(t)\, dt-\int\limits_{x_0}^{x} (xt-\dfrac{t^2}{2})f^3(t)\, dt= $$



=\dfrac{(x-x_0)^2}{2!}f^2(x_0)-\int\limits_{x_0}^{x} (\dfrac{x^2}{2}-xt+\dfrac{t^2}{2})f^3(t)\, dt $$

The first term of the expression has already been attained. Now, we should reveal that:



\int\limits_{x_0}^{x} (\dfrac{x^2}{2}-xt+\dfrac{t^2}{2})f^3(t)\, dt=\dfrac{(x-x_0)^3}{3!}f^3(x_0)+.... $$

Again by integration by parts we have:



f^3(t)=u; (\dfrac{x^2}{2}-xt-\dfrac{t^2}{2})dt=dv \rightarrow\ v=\int\limits_{x_0}^{x}(\dfrac{x^2}{2}-xt+\dfrac{t^2}{2})\, dt = (\dfrac{x^2}{2}t-\dfrac{x}{2}t^2+\dfrac{1}{6}t^3) $$



\Rightarrow\ \int\limits_{x_0}^{x} (\dfrac{x^2}{2}-xt+\dfrac{t^2}{2})f^3(t)\, dt=[(\dfrac{x^2}{2}t-\dfrac{x}{2}t^2+\dfrac{t^3}{6})f^3(t)]-\int\limits_{x_0}^{x} (\dfrac{x^2}{2}t-\dfrac{x}{2}t^2+\dfrac{1}{6}t^3)f^4(t)\, dt $$



=\dfrac{x^3}{6}f^3(x)-\dfrac{x^2}{2}x_0f^3(x_0)+\dfrac{xx_0^2}{2}f^3(x_0)-\dfrac{x_0^3}{6}f^3(x_0)-\int\limits_{x_0}^{x} (\dfrac{x^2}{2}t-\dfrac{x}{2}t^2+\dfrac{1}{6}t^3)f^4(t)\, dt $$



=\dfrac{x^3}{6}f^3(x)+\dfrac{(-3x_0x^2+3x_0^2x-x_0^3)}{6=3!}f^3(x_0)-\dfrac{x^3}{6}f^3(x_0)+\dfrac{x^3}{6}f^3(x_0)+....=\dfrac{(x-x_0)^3}{3!}f^3(x_0)+\int\limits_{x_0}^{x} (\dfrac{x^3}{6}-\dfrac{x^2}{2}t+\dfrac{x}{2}t^2+\dfrac{1}{6}t^3)f^4(t)\, dt $$


 * {| style="width:60%" border="0"

$$ \Rightarrow\ f(x)=f(x_0)+\dfrac{x-x_0}{1!}f^1(x_0)+\int\limits_{x_0}^{x} (x-t)f^2(t)\, dt+\dfrac{(x-x_0)^2}{2!}f^2(x_0)+\dfrac{(x-x_0)^3}{3!}f^3(x_0)+.... $$
 * style="width:92%; padding:10px; border:2px solid #8888aa" |
 * style="width:92%; padding:10px; border:2px solid #8888aa" |
 * style= |
 * }

= Exercise #9 =

Given

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

$$ $$
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle \dfrac{e^x}{x}=\dfrac{1}{x}[e^x-1]=:f(x)


 * }
 * }

Find
1) Expand
 * {| style="width:100%" border="0" align="left"

e^x $$ in Taylor series with remainder.
 * $$\displaystyle
 * $$\displaystyle
 * {| style="width:100%" border="0" align="left"

$$
 * 2) Find Taylor series expansion and remainder of f(x).
 * $$\displaystyle
 * $$\displaystyle


 * }
 * }

Solution
Generally, f(x) can be expressed in Taylor series as follows:



f(x)=P_n(x)+R_{n+1}(x) $$



\Rightarrow\sum_{i=0}^n \dfrac{(x-x_0)^n}{n!}f^n(x_0)+\dfrac{(x-x_0)^{n+1}}{(n+1)!}f^{n+1}(\gamma) $$



\gamma\in [0,x] $$



\Rightarrow\ e^x=\sum_{i=0}^n \dfrac{x^n}{n!}f^n(0)+\dfrac{x^{n+1}}{(n+1)!}f^{n+1}(\gamma)=\sum_{i=0}^n \dfrac{x^n}{n!}+\dfrac{x^{n+1}}{(n+1)!}e^\gamma $$

Using the first part will lead us to solve second part:



\Rightarrow\ e^x=1+\sum_{i=1}^n \dfrac{x^n}{n!}+\dfrac{x^{n+1}}{(n+1)!}e^\gamma $$



\Rightarrow\ e^x-1=\sum_{i=1}^n \dfrac{x^n}{n!}+\dfrac{x^{n+1}}{(n+1)!}e^\gamma $$



\Rightarrow\ \dfrac{e^x-1}{x}=\sum_{i=1}^n \dfrac{x^{n-1}}{n!}+\dfrac{x^n}{n+1}e^\gamma $$



\gamma\in[0,x] $$

= Exercise #10 =

Given
Use following Integration
 * {| style="width:100%" border="0" align="left"

$$ $$
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle \int\limits_{a}^{b} \sum_{i=0}^{n=1} l_i(x)f(x_i)\, dx


 * }
 * }

Find
To obtain


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

I=\dfrac{b-a}{2}(f(a)+f(b)). $$ $$
 * $$\displaystyle
 * $$\displaystyle
 * $$\displaystyle


 * }
 * }

Solution
First we expand the summation inside the integral:



I=\int\limits_{a}^{b} \sum_{i=0}^{n=1} l_i(x)f(x_i)\, dx = \int\limits_{a}^{b}[l_0(x)f(x_0)+l_1(x)f(x_1)]\, dx $$

From Lagrange equation we have:



l_i(x)=\prod_{i=1}^{n=1} \dfrac{x-x_j}{x_i-x_j} $$



\Rightarrow\ l_0(x)= \dfrac{x-x_1}{x_0-x_1}; l_1=\dfrac{x-x_0}{x_1-x_0} $$

Trivially,



x_0=a;   x_1=b $$



\Rightarrow\ I= \int\limits_{a}^{b}[\dfrac{x-b}{a-b}f(a)+\dfrac{x-a}{b-a}f(b)]\, dx $$



\dfrac{1}{b-a} \int\limits_{a}^{b}[(b-x)f(a)+(x-a)f(b)]\, dx $$



=\dfrac{1}{b-a} [\int\limits_{a}^{b}(b-x)f(a)\, dx]+[\int\limits_{a}^{b}(x-a)f(b)\, dx] $$

Now, integration can be easily solved in its interval:



=\dfrac{1}{b-a}[f(a)(bx-\dfrac{x^2}{2})+f(b)(\dfrac{x^2}{2}-ax)]=\dfrac{1}{b-a}[f(a)(\dfrac{b^2}{2}-ab+\dfrac{a^2}{2})+f(b)(\dfrac{b^2}{2}-ab+\dfrac{a^2}{2})] $$



=\dfrac{1}{2(b-a)}[f(a)(b-a)^2+f(b)(b-a)^2]=\dfrac{b-a}{2}[f(a)+f(b)] $$