1

Verify the integral with the aid of residues: $$\int^{\infty}_0\frac{x^2+1}{x^4+1}dx=\frac{\pi}{\sqrt 2}$$

I got:

$f(z)=\frac{z^2+1}{z^4+1}$ and now I must find the residues for $f(z)$ and I got that the poles are: $e^{i\frac{\pi}{4}}$ and $e^{i\frac{3\pi}{4}}$. But I do not know how to finish.

Q.matin
  • 2,835
  • 2
    Those are not the residues but the poles. Your job is to compute the residues at the poles inside some integration contour. – Ron Gordon Apr 06 '13 at 22:59
  • @RonGordon That was an error. I meant poles. – Q.matin Apr 06 '13 at 23:02
  • 2
    Why do you only have 2 poles? What happened to the others? (BTW I know, but I want to see if you do.) – Ron Gordon Apr 06 '13 at 23:08
  • 1
    @RonGordon Good question. I don't have the negative parts of the poles which are, $e^{-i\frac{\pi}{4}}$ and $e^{-i\frac{3\pi}{4}}$, because I want the contour of my integration to lie only in the upper semi circle. Correct? Is that the same answer you were thinking? – Q.matin Apr 06 '13 at 23:13
  • Bingo, that is correct. Now, how do you compute residues of those poles? – Ron Gordon Apr 06 '13 at 23:20
  • @RonGordon Since it is even thus $f(-z)=f(z)$ then the residue will be of the form $$\int_0^\infty f(x) = \frac{1}{2} \int_{-\infty}^\infty f(x) \implies \pi iresidue(f(z))$$ – Q.matin Apr 06 '13 at 23:29

3 Answers3

2

Note that $\int_0^\infty f(x) = \frac{1}{2} \int_{-\infty}^\infty f(x)$. You can use the punctured half-circle contour (like half of a CD, in the upper half plane) to integrate $f(z)$, then apply the residue theorem, note that half of your contour is your integral, and take care of the other half by bounding it.

Like you said, $f(z)$ has poles in your contour at $p_1 = e^{i\pi/4}, p_2 = e^{i3\pi/4}$. It's a fact that these poles are simple, and that's not too hard to show. Hence $f = \frac{p}{q}$ implies that $\text{Res}_{p_i} f = \frac{p(p_i)}{q'(p_i)}$.

Now, call your CD contour $\gamma$ and the residue at $p_i$ as $r_i$. The residue theorem states that $\int_\gamma f = 2\pi i (r_1 + r_2)$. But if you let the circle part of $\gamma$ be $\gamma_C$ then $\int_\gamma f = 2*\int_0^R f + \int_{\gamma_C}f$, and $|\int_{\gamma_C} f| \leq \int_{\gamma_C} |f| \leq len(\gamma_C) * \frac{R^2 + 1}{R^4 + 1} = \frac{R^3 + R}{R^4 + 1} \to 0$ as $R \to \infty$, where $R$ is the radius of $\gamma$. Hence you can ignore the circle part and obtain the result.

Edit: The theorem about rational functions and simple poles. Suppose $f(z) = \frac{p(z)}{q(z)}$ and $f$ has a simple pole at $a$. Then the formula for residues says that $\text{Res}_a f = \lim_{z \to a} (z-a)f(z) = \lim_{z \to a} \frac{p(z)}{\frac{q(z)}{z-a}} = \lim_{z \to a} \frac{p(z)}{\frac{q(z) - (a)}{z-a}} = \frac{p(a)}{q'(a)}$ where I used the fact that $a$ is a pole, which says that $q(a) = 0$.

  • But I already know what you just mentioned. What I am having trouble is applying the residue theorem. – Q.matin Apr 06 '13 at 23:16
  • OK, I'll edit it accordingly. Do you also need help with taking care of the circle part of the contour or with calculating the residues? – Julien Clancy Apr 06 '13 at 23:16
  • Is this enough? Would you like me to source the theorem about simple poles and rational functions? – Julien Clancy Apr 06 '13 at 23:27
  • Julien, how did you get the formula $\text{Res}_{p_i} f = \frac{p(p_i)}{q'(p_i)}$? I just checked my book for it and it doesn't show it anywhere in the section. – Q.matin Apr 06 '13 at 23:27
  • Added. Does this make sense? – Julien Clancy Apr 06 '13 at 23:32
  • Julien, yes it does, thanks! I am going to attempt to try it now with that formula $\text{Res}_{p_i} f = \frac{p(p_i)}{q'(p_i)}$. – Q.matin Apr 06 '13 at 23:35
  • Julien, I got with your help: $$q'(z)=4z^3 \implies \text{Res}{z=e^{i\pi/4}}f(z)=\frac{z^2+1}{4e^{i3\pi/4}}$$ and $$\text{Res}{z=e^{3i\pi/4}}f(z)=\frac{z^2+1}{4e^{i9\pi/4}}$$ then $i\pi \sum \text{Res}f(z)=i\pi[(z^2+1)4e^{-3i\pi/4}+(z^2+1)4e^{-i9\pi/4}]$ and I calculated using cosines and sines but the answer I got was not the one that was given. – Q.matin Apr 06 '13 at 23:43
  • First of all, you need to plug the residues in for $z$ for the top of the rational function. Second, the residue theorem states that the constant in front of the sum must be $2\pi i$, not $\pi i$ (unless you're already dividing by two because you must do so for your final integral, in which case great). I ran this through Mathematica and got the correct result. – Julien Clancy Apr 06 '13 at 23:46
  • Yes, I am already dividing by 2. And alright, I am going to re-attempt it now. – Q.matin Apr 06 '13 at 23:50
2

This answer, which uses residues, says that $$ \frac{\pi}{m}\csc\left(\pi\frac{n+1}{m}\right)=\int_0^\infty\frac{x^n}{1+x^m}\,\mathrm{d}x $$ Using $m=4$ and $n=0$ and $n=2$ yields $$ \begin{align} \int_0^\infty\frac{x^2+1}{z^4+1}\,\mathrm{d}x &=\frac\pi4\csc\left(\frac14\pi\right)+\frac\pi4\csc\left(\frac34\pi\right)\\ &=\frac\pi4\sqrt2+\frac\pi4\sqrt2\\ &=\frac\pi{\sqrt2} \end{align} $$


The Long Way

Using the curve $\gamma$ which runs from $-R$ to $+R$ along the real axis then circles counter-clockwise from $+R$ to $-R$ through the upper half-plane, we get $$ \begin{align} \int_0^\infty\frac{x^2+1}{x^4+1}\,\mathrm{d}x &=\frac12\int_{-\infty}^\infty\frac{x^2+1}{x^4+1}\,\mathrm{d}x\\ &=\frac12\int_\gamma\frac{z^2+1}{z^4+1}\,\mathrm{d}z\\ &=\frac{2\pi i}2\left(\frac{e^{2\pi i/4}+1}{4e^{3\pi i/4}}+\frac{e^{6\pi i/4}+1}{4e^{9\pi i/4}}\right)\\ &=\frac{2\pi i}2\left(\frac{e^{\pi i/4}+e^{-\pi i/4}}{4e^{2\pi i/4}}+\frac{e^{\pi i/4}+e^{-\pi i/4}}{4e^{2\pi i/4}}\right)\\ &=\pi\cos\left(\frac\pi4\right)\\ &=\frac\pi{\sqrt2} \end{align} $$ Since the residue at the singularities inside the contour $z=e^{\pi i/4}$ and $z=e^{3\pi i/4}$ is $\dfrac{z^2+1}{4z^3}$.

robjohn
  • 345,667
  • @RonGordon: I answered that question in generality because there had been many questions asked that could use it. :-) – robjohn Apr 06 '13 at 23:23
  • That is very convenient, I will use this method for future reference. But I would still like to know how to use it the long way. – Q.matin Apr 06 '13 at 23:26
  • Rob, I got when I plugged in the poles: $$i\pi \left[\frac{(i+1)}{2\sqrt2 (i-1)}+\frac{(1-i)}{2\sqrt2 (1+i)}\right]$$ but it isn't right. – Q.matin Apr 07 '13 at 00:19
  • @Q.matin:$\dfrac{i+1}{i-1}=\dfrac{1-i}{1+i}=-i$, so your answer is $\dfrac\pi{\sqrt2}$. – robjohn Apr 07 '13 at 00:23
  • @robjohn Of course it is, thanks a lot ! – Q.matin Apr 07 '13 at 00:25
1

An easy way to get the solution is just to use partial fractions in Calculus. Here is the solution: \begin{eqnarray*} \int_0^\infty\frac{x^2+1}{x^4+1}dx&=&\int_0^\infty\frac{x^2+1}{(x^2+\sqrt{2}x+1)(x^2-\sqrt{2}x+1)}dx\\ &=&\frac{1}{2}\int_0^\infty\frac{1}{x^2+\sqrt{2}x+1}dx+\frac{1}{2}\int_0^\infty\frac{1}{x^2-\sqrt{2}x+1}dx\\ &=&\frac{1}{2}\int_0^\infty\frac{1}{(x+\frac{\sqrt{2}}{2})^2+\frac{1}{2}}dx+\frac{1}{2}\int_0^\infty\frac{1}{(x-\frac{\sqrt{2}}{2})^2+\frac{1}{2}}dx\\ &=&\frac{1}{2}\sqrt{2}\left.\left(\arctan\frac{2x+\sqrt{2}}{\sqrt{2}}+ \arctan\frac{2x-\sqrt{2}}{\sqrt{2}}\right)\right|_{0}^{\infty}\\ &=&\frac{\pi}{\sqrt{2}}. \end{eqnarray*}

xpaul
  • 44,000