Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

This question already has an answer here:

How would we evaluate the below integral by methods of complex analysis?

$$\int_{0}^{1} \frac{\ln(x+1)}{x^2+1} \mathrm{dx}$$

I asked the question a while ago, but at that time I didn't specify this requirement.
Now, I'm only interested in a complex way. Thanks !!!

Sis.

share|cite|improve this question

marked as duplicate by Alex M., G. Sassatelli, RecklessReckoner, Shailesh, quid Jul 10 at 0:32

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

    
Hmmm, or I should use the fact that $x^2+1=(x-i)(x+i)$ and then $\frac{1}{x^2+1}= \frac{1}{2 x} (\frac{1}{x-i}+\frac{1}{x+i})$ – user 1618033 Feb 14 '13 at 8:26
    
This problem is a special case of the more general problem – Mhenni Benghorbal Feb 14 '13 at 18:06
up vote 9 down vote accepted

We have $$ \int_0^1 \frac{\ln(1+x)}{x^2+1}dx= \left[\begin{array}{l} t=\frac{1}{x} \\ dt=-\frac{1}{x^2}dx \end{array}\right]=\int_1^\infty \frac{\ln(t+1)-\ln{t}}{1+t^2}dt= \left[\begin{array}{l} u=t-1 \\ du=dt \end{array}\right] = \int_0^\infty \frac{\ln(u+2)-\ln(u+1)}{1+(u+1)^2}du. $$

I am quite confident that this integral can be handled with a keyhole contour in much a similar way as this integral. If you want me to do more details, just comment, and I will update when I have the time.


EDIT: Continued the argument. Please notify me about misprints or other errors. I will show how to compute $$\int_0^\infty \frac{\ln(x+2)}{1+(x+1)^2}dx$$ (the other one is solved analogously).

Keyhole contour

We now consider the integral $$\int_C \frac{\log^2(z+2)}{1+(z+1)^2}dz,$$ where $C$ is the keyhole contour above. Note the choice of logarithm! It is imperative that we take $0<\arg{z}<2\pi$ for the logarithms (or $2\pi n<\arg{z}<2\pi (n+1)$ for some $n\in\mathbb{Z}$).

The integrand has poles at $z=-1\pm i$, and by Cauchy's integral formula, we get $$ \int_C \frac{\log^2(z+2)}{1+(z+1)^2}dz= \int_C \frac{\log^2(z+2)}{(z+1+i)(z+1-i)}dz= 2\pi i\left(\frac{\log^2(1-i)}{-2i}+ \frac{\log^2(1+i)}{2i}\right)= \pi(\log^2(1+i)-\log^2(1-i))= \pi\left(\left(\ln\sqrt{2}+\frac{i\pi}{4}\right)^2-\left(\ln\sqrt{2}+\frac{7i\pi}{4}\right)^2\right)= \frac{6\pi^3-3i\pi^2\ln{2}}{2} .$$

The integral along $\gamma$ goes to zero as the inner radius goes to zero, and the integral along $\Gamma$ goes to zeros as $R\rightarrow\infty$ (this can be shown using the ML-inequality).

Therefore, in the limit we only get contributions from the straight parts, so $$ \int_0^R\frac{\log^2(x+i\varepsilon+1)}{(1+x+i\varepsilon)^2+1}dx+ \int_R^0\frac{\log^2(x-i\varepsilon+1)}{(1+x-i\varepsilon)^2+1}dx\rightarrow \frac{6\pi^3-3i\pi^2\ln{2}}{2}. $$ But we also have $$ \int_0^R\frac{\log^2(x+i\varepsilon+2)}{(1+x+i\varepsilon)^2+1}dx+ \int_R^0\frac{\log^2(x-i\varepsilon+2)}{(1+x-i\varepsilon)^2+1}dx\rightarrow \int_0^\infty\frac{\ln^2(x+2)-\left(\ln(x+2)+2i\pi\right)^2}{(1+x)^2+1}dx= \int_0^\infty\frac{4\pi^2-4i\pi\ln(x+2)}{(1+x)^2+1}dx, $$ so $$\int_0^\infty\frac{4\pi^2-4i\pi\ln(x+2)}{(1+x)^2+1}dx=\frac{6\pi^3-3i\pi^2\ln{2}}{2}.$$ By considering the imaginary part, we get that $$\int_0^\infty \frac{\ln(x+2)}{(x+1)^2+1}dx=\frac{3\pi\ln{2}}{8}.$$

It is possible to compute $$\int_0^\infty \frac{\ln(x+1)}{(x+1)^2+1}dx$$ analogously, and then take the difference in order to find the value of the original integral.

share|cite|improve this answer
    
I'd appreciate if you might add more details. Thanks. (+1) – user 1618033 Feb 14 '13 at 9:33
    
I will continue the argument when time allows, then. – Mårten W Feb 14 '13 at 12:50
    
Sure, no problem. There is no hurry for me. – user 1618033 Feb 14 '13 at 12:52
    
I would really be interested to see if this works. I have a contour integral, but only after a pretty difficult substitution. – robjohn Feb 14 '13 at 17:46
    
@MårtenW: thank you for your work! It'll be a good lesson to me in terms of complex analysis. – user 1618033 Feb 15 '13 at 17:52

Well, there is a method which is not that complex.

$$\int_0^1 \frac{\log(1+x)}{1+x^2}dx$$

$$\int_0^1 \left(\int_0^x \frac{1}{1+y}dy\right)\frac{1}{1+x^2}dx$$

$$\int_0^1 \int_0^x \frac{1}{1+y}dy\frac{1}{1+x^2}dx$$

Make a change of variables $y=ux$ in the inner integral:

$$\tag 1 \int_0^1 \int_0^1 \frac{x}{1+ux}\frac{1}{1+x^2}dudx$$

Partial fractions:

$${x \over {1 + xu}}{1 \over {1 + {x^2}}} = {1 \over {1 + {u^2}}}{x \over {1 + {x^2}}} + {u \over {1 + {u^2}}}{1 \over {1 + {x^2}}} - {u \over {1 + {u^2}}}{1 \over {1 + xu}}$$

Now, integrating the first two terms, which account to the same$^1$, gives that you integral is

$$\mathcal I=\frac \pi 4\log 2-\int_0^1\int_0^1 \frac u {1+u^2}\frac{1}{1+xu}dxdu$$

The latter integral is just our original integral, due to symmetry, as you see in $(1)$

This means that $$\mathcal I =\frac \pi 8 \log 2$$

as desired. You can see a simlar integral solved here with the very same method.

$1$: symmetry, once again.

share|cite|improve this answer
    
Chris, I hope you enjoy this method. – Pedro Tamaroff Feb 14 '13 at 16:12
2  
Nicely done! (+1) – robjohn Feb 14 '13 at 16:15
    
@PeterTamaroff: nice solution. (+1) – user 1618033 Feb 14 '13 at 17:04
    
I think your fractions-decomposition is slightly incorrect, and it should be:${x \over {1 + xu}}{1 \over {1 + {x^2}}} = {1 \over {1 + {u^2}}}{x \over {1 + {x^2}}} + {u \over {1 + {u^2}}}{1 \over {1 + {x^2}}} - {u \over {1 + {u^2}}}{1 \over {1 + xu}}$ – awllower Feb 15 '13 at 3:31
    
@awllower You're right. I forgot the $x$ on the right hand side. Thank you. – Pedro Tamaroff Feb 15 '13 at 3:34

Here is a real method, and since $\mathbb{R}\subset\mathbb{C}\dots$ $$ \begin{align} \int_0^1\frac{\log(1+x)}{1+x^2}\mathrm{d}x &=\int_0^{\pi/4}\log(1+\tan(u))\,\mathrm{d}u\\ &=\int_0^{\pi/4}\Big(\log(\cos(u)+\sin(u))-\log(\cos(u))\Big)\,\mathrm{d}u\\ &=\int_0^{\pi/4}\Big(\log(\sqrt2\cos(\pi/4-u))-\log(\cos(u))\Big)\,\mathrm{d}u\\ &=\int_0^{\pi/4}\Big(\log(\sqrt2)+\log(\cos(\pi/4-u))-\log(\cos(u))\Big)\,\mathrm{d}u\\ &=\frac\pi8\log(2)\tag{1} \end{align} $$


Another method, avoiding all trig substitutions, and using contour integration

Suppose that $$ (1+x)(1+y)=2\tag{2} $$ That is, $$ x=\frac{1-y}{1+y}\quad\text{and}\quad\frac{\mathrm{d}x}{1+x^2}=-\frac{\mathrm{d}y}{1+y^2}\tag{3} $$ Furthermore, $(2)$ implies $$ \log\left(\frac{1+x}{\sqrt2}\right)=-\log\left(\frac{1+y}{\sqrt2}\right)\tag{4} $$ Substituting, using $(3)$ and $(4)$, remembering to flip the limits of integration, yields $$ \int_0^1\log\left(\frac{1+x}{\sqrt2}\right)\frac{\mathrm{d}x}{1+x^2}=-\int_0^1\log\left(\frac{1+y}{\sqrt2}\right)\frac{\mathrm{d}y}{1+y^2}\tag{5} $$ Noting that the left and right sides of $(5)$ are equal yet opposite, we see that both are $0$. Unraveling yields $$ \begin{align} \int_0^1\frac{\log(1+x)}{1+x^2}\mathrm{d}x &=\int_0^1\frac{\log(\sqrt2)}{1+x^2}\mathrm{d}x\tag{6} \end{align} $$ To evaluate $(6)$ note that the substitution $x\mapsto\frac1x$ yields $$ \int_0^1\frac{\mathrm{d}x}{1+x^2}=\int_1^\infty\frac{\mathrm{d}x}{1+x^2}\tag{7} $$ and since $\frac1{1+x^2}$ is even we get $$ \int_0^1\frac{\mathrm{d}x}{1+x^2}=\frac14\int_{-\infty}^\infty\frac{\mathrm{d}x}{1+x^2}\tag{8} $$ Let $\gamma$ be the contour following the real line on $[-R,R]$ and circling back counterclockwise in the upper half-plane along $|z|=R$, we get $$ \int_{-\infty}^\infty\frac{\mathrm{d}x}{1+x^2}=\int_\gamma\frac{\mathrm{d}z}{1+z^2}\tag{9} $$ There is one singularity in the upper half-plane at $z=i$ with residue $\frac1{2i}$ which means the value of the integral along $\gamma$ is $2\pi i\cdot\frac1{2i}=\pi$. Using $(6)$, $(8)$, and $(9)$, this yields $$ \begin{align} \int_0^1\frac{\log(1+x)}{1+x^2}\mathrm{d}x &=\int_0^1\frac{\log(\sqrt2)}{1+x^2}\mathrm{d}x\\ &=\log(\sqrt2)\cdot\frac14\int_{-\infty}^\infty\frac1{1+x^2}\mathrm{d}x\\ &=\log(\sqrt2)\cdot\frac14\cdot\pi\\ &=\frac\pi8\log(2)\tag{10} \end{align} $$

share|cite|improve this answer
    
Thanks (+1). However, I'd be more interested in a complex method. :-) – user 1618033 Feb 14 '13 at 14:42
    
Sorry, I hadn't looked at your link to see that you already got an answer to this integral. – robjohn Feb 14 '13 at 14:47
    
Would the downvoter care to comment? – robjohn Feb 14 '13 at 15:28
1  
"...and since $\Bbb R\subset \Bbb C$" +1 – Pedro Tamaroff Feb 14 '13 at 15:49
    
See my answer! ${}{}$ – Pedro Tamaroff Feb 14 '13 at 16:05

Not the answer you're looking for? Browse other questions tagged or ask your own question.