# Math416 Lecture 26

## Continue on Application to evaluating definite integrals

Note: Contour can never go through a singularity.

Recall the semi annulus contour.

Know that $\int_\gamma f(z)dz=0$.

So $\int_A+\int_B+\int_C+\int_D=0$.

From last lecture, we know that $\int_D=0$ and $\int_A+\int_C=2i\int_0^\infty \frac{\sin x}{x}dx$.

### Integrating over $B$

Do $B$, we have $\gamma(t)=\epsilon e^{it}$ for $t\in[0,\pi]$.

$\int_B=-\int_0^\pi f(\epsilon e^{it})\epsilon i e^{it}dt$.

$f(z)=\frac{e^{iz}}{z}=\frac{1}{z}(1+iz-\frac{z^2}{2!}+\cdots)$.

So $z f(z)=1+O(\epsilon)$ and $f(z)=\frac{1}{z}+O(\frac{\epsilon}{z})$.

$$
\begin{aligned}
\int_B&=-\int_0^\pi (\frac{1}{\epsilon}e^{it}+O(1))\epsilon i e^{it}dt\\
&=-i\int_0^\pi 1dt+O(\epsilon)\\
&=-i\pi+O(\epsilon)
\end{aligned}
$$

### Integrating over $D$

#### Method 1: Using estimate

$z=Re^{it}$ for $t\in[0,\pi]$.

$f(z)=\frac{e^{iz}}{z}=\frac{e^{iRe^{it}}}{Re^{it}}$.

$Re^{it}=R(\cos t+i\sin t)$, $iRe^{it}=-R(\sin t-i\cos t)$.

$e^{iRe^{it}}=e^{-R\sin t}e^{iR\cos t}$.

$\max|f(z)|=\max\frac{|e^{iR\cos t}|}{|R e^{it}|}=\frac{1}{R}$.

This only bounds the function $|\int_D|\leq \pi R\frac{1}{R}=\pi$.

This is not a good estimate.

#### Method 2: Hard core integration

$\gamma(t)=Re^{it}$ for $t\in[0,\pi]$.

$$
\begin{aligned}
\int_D&=\int_0^\pi \frac{e^{iRe^{it}}}{R e^{it}}iR e^{it}dt\\
&=i\int_0^\pi e^{iR\cos t}e^{-R\sin t}dt\\
\end{aligned}
$$

Notice that we can use $\frac{2}{\pi}t$ to replace $\sin t$.

$$
\begin{aligned}
\left|\int_D\right|&\leq\int_0^\pi e^{-R\sin t}dt\\
&=2\int_0^{\pi/2} e^{-R\sin t}dt\\
&\leq 2\int_0^{\pi/2} e^{-2Rt/\pi}dt\\
&=-\frac{2\pi}{R}(e^{-\frac{R\pi}{2}t})|_0^{\pi/2}\\
&\leq\frac{\pi}{R}
\end{aligned}
$$

As $R\to\infty$, $\left|\int_D\right|\to 0$.

So $\int_D=0$.

So we have $\int_A+\int_C=2i\int_0^\infty \frac{\sin x}{x}dx=i\pi$.

So $\int_0^\infty \frac{\sin x}{x}dx=\frac{\pi}{2}$.

## Application to evaluate $\int_{-\infty}^\infty \frac{\cos x}{1+x^4}dx$

$f(z)=\frac{e^{iz}}{1+z^4}=\frac{\cos z+i\sin z}{1+z^4}$.

Our desired integral can be evaluated by $\int_{-R}^R f(z)dz$

To evaluate the singularity, $z^4=-1$ has four roots by the De Moivre's theorem.

$z^4=-1=e^{i\pi+2k\pi i}$ for $k=0,1,2,3$.

So $z=e^{i\theta}$ for $\theta=\frac{\pi}{4}+\frac{k\pi}{2}$ for $k=0,1,2,3$.

So the singularities are $z=e^{i\pi/4},e^{i3\pi/4},e^{i5\pi/4},e^{i7\pi/4}$.

Only $z=e^{i\pi/4},e^{i3\pi/4}$ are in the upper half plane.

So we can use the semi-circle contour to evaluate the integral. Name the path as $\gamma$.

$\int_\gamma f(z)dz=2\pi i\left[\operatorname{Res}_{z=e^{i\pi/4}}(f)+\operatorname{Res}_{z=e^{i3\pi/4}}(f)\right]$.

The two poles are simple poles.

$\operatorname{Res}_{z_0}(f)=\lim_{z\to z_0}(z-z_0)f(z)$.

So 

$$
\begin{aligned}
\operatorname{Res}_{z=e^{i\pi/4}}(f)&=\lim_{z\to e^{i\pi/4}}(z-e^{i\pi/4})\frac{e^{iz}}{1+z^4}\\
&=\frac{(z-e^{i\pi/4})e^{iz}}{(z-e^{i\pi/4})(z-e^{i3\pi/4})(z-e^{i5\pi/4})(z-e^{i7\pi/4})}\\
&=\frac{e^{ie^{i\pi/4}}}{(e^{i\pi/4}-e^{i3\pi/4})(e^{i\pi/4}-e^{i5\pi/4})(e^{i\pi/4}-e^{i7\pi/4})}
\end{aligned}
$$

A short cut goes as follows:

We know $p(z)=1+z^4$ has four roots $z_1,z_2,z_3,z_4$.

$$
\lim_{z\to z_0}\frac{(z-z_0)}{p(z)}=\frac{1}{p'(z_0)}
$$

So

$$
\operatorname{Res}_{z=e^{i\pi/4}}(f)=\frac{e^{ie^{i\pi/4}}}{4e^{i3\pi/4}}
$$

Similarly,

$$
\operatorname{Res}_{z=e^{i3\pi/4}}(f)=\frac{e^{ie^{i3\pi/4}}}{4e^{i\pi/4}}
$$

So the sum of the residues is

$$
\begin{aligned}
\operatorname{Res}_{z=e^{i\pi/4}}(f)+\operatorname{Res}_{z=e^{i3\pi/4}}(f)&=\frac{e^{ie^{i\pi/4}}}{4e^{i3\pi/4}}+\frac{e^{ie^{i3\pi/4}}}{4e^{i\pi/4}}\\
&=\frac{e^{\frac{i}{\sqrt{2}}} e^{-\frac{1}{\sqrt{2}}}}{4[-\frac{1}{\sqrt{2}}+i\frac{1}{\sqrt{2}}]}+\frac{e^{-\frac{i}{\sqrt{2}}}-e^{-\frac{1}{\sqrt{2}}}}{4[\frac{1}{\sqrt{2}}+i\frac{1}{\sqrt{2}}]}\\
&=\frac{\pi\sqrt{2}}{2}e^{-\frac{1}{\sqrt{2}}}(\cos\frac{1}{\sqrt{2}}+\sin\frac{1}{\sqrt{2}})
\end{aligned}
$$

SKIP

Review on next lecture.
