# Integral of rational function with cosine hyperbolic function using rectangle contour

$$\int^{\infty}_{-\infty} \frac{1}{(5 \pi^2 + 8 \pi y + 16y^2) }\frac{\cosh\left(y+\frac{\pi}{4} \right)}{\cosh^3(y)}dy=\frac{2}{\pi^3}\left(\pi \cosh\left(\frac{\pi}{4} \right)-4\sinh\left( \frac{\pi}{4}\right) \right)$$

$$\textit{proof}$$

Consider
$$f(z) = \frac{\sinh(z)}{z \sinh^3(z-\pi/4)}$$

If we integrate around a contour of height $\pi$ and stretch it to infinity we get

By taking $T \to \infty$

$$\color{red}{\int^{i\pi/2+\infty}_{-i\pi/2+\infty}f(x)\,dx}+\color{blue}{\int^{i\pi/2-\infty}_{i\pi/2+\infty}f(x)\,dx}+\\\color{red}{\int^{-i\pi/2-\infty}_{i\pi/2-\infty}f(x)\,dx}+ \color{blue}{\int^{-i\pi/2+\infty}_{-i\pi/2-\infty}f(x)\,dx} = 2\pi i \mathrm{Res}(f,\frac{\pi}{4})$$

Consider

$$\color{blue}{\int^{-i\pi/2+\infty}_{-i\pi/2-\infty}\frac{\sinh(x)}{x \sinh^3(x-\pi/4)}\,dx}$$

Let $x = -\pi/2i+\pi/4+y$

$$-\int^{\infty}_{-\infty}\frac{1}{-i\pi/2+\pi/4+y}\frac{\cosh(\pi/4+y)}{ \cosh^3(y)}\,dy$$
———-
Similarly we have for

$$\color{blue}{\int^{i\pi/2-\infty}_{i\pi/2+\infty}\frac{\sinh(x)}{x \sinh^3(x-\pi/4)}\,dx}$$

By letting $x =i\pi/2+\pi/4+ y$

$$\int^{\infty}_{-\infty}\frac{1}{i\pi/2+\pi/4+y}\frac{\cosh(\pi/4+y)}{ \cosh^3(y)}\,dy$$
———-
The other integrals go to 0 hence

$$-16 \pi i\int^{\infty}_{-\infty} \frac{1}{(5 \pi^2 + 8 \pi y + 16y^2) }\frac{\cosh\left(y+\frac{\pi}{4} \right)}{\cosh^3(y)}dy =2\pi i \mathrm{Res}(f,\frac{\pi}{4})$$

Calculating the residue we have

$$-16 \pi i\int^{\infty}_{-\infty} \frac{1}{(5 \pi^2 + 8 \pi y + 16y^2) }\frac{\cosh\left(y+\frac{\pi}{4} \right)}{\cosh^3(y)}dy = 2\pi i\frac{-(16 (π \cosh(π/4) – 4 \sinh(π/4))}{π^3}$$

Which reduces to our result

$$\int^{\infty}_{-\infty} \frac{1}{(5 \pi^2 + 8 \pi y + 16y^2) }\frac{\cosh\left(y+\frac{\pi}{4} \right)}{\cosh^3(y)}dy=\frac{2}{\pi^3}\left(\pi \cosh\left(\frac{\pi}{4} \right)-4\sinh\left( \frac{\pi}{4}\right) \right)$$

This entry was posted in Contour Integration and tagged , , , , . Bookmark the permalink.