Logarithmic integral (Green function) I am using a Green function to find the solution of an ODE and I have stuck in finding the solution of the following integral. Could someone please help me with this?
The integral is
$$\int_{0}^{r} d r^{'} \int_{0}^{2 \pi}  \ln\Biggl(\frac{C}{\sqrt{(x-r^{'} \cos{\theta^{'}})^2+(y-r^{'} \sin{\theta^{'}} )^2}} \Biggr)\, d \theta^{'}$$
and $C$ is a positive constant.
 A: We can rewrite  $\ln\Biggl(\frac{C}{\sqrt{(x-r^{'} \cos{\theta^{'}})^2+(y-r^{'} \sin{\theta^{'}} )^2}} \Biggr)=\ln{C}-\frac{1}{2}\ln\left((x-r^{'} \cos{\theta^{'}})^2+(y-r^{'} \sin{\theta^{'}} )^2 \right)=$$\ln{C}-\frac{1}{2}\ln\left(x^2+y^2+r'^2-2xr'cos\theta-2yr'\sin\theta\right)$
If we introduce vector $\vec{a}=(x,y)$, then  $xr'cos\theta+yr'\sin\theta=(\vec{a},\vec{r'})$ at some choice of the direction of $\vec{r'}$.
Because we integrate over $\vec{r'}$ this is up to us to choose the system of coordinates - the final result will not depend on this choice. We can direct the axis $X$ along the vector $\vec{a}$. At this choice the integral of logarithm becomes (accurate to constant factors) $\int_{0}^{r} d r^{'} \int_{0}^{2 \pi}  \ln\Biggl(\frac{1}{\sqrt{(x-r^{'} \cos{\theta^{'}})^2+(y-r^{'} \sin{\theta^{'}} )^2}} \Biggr)\, d \theta^{'}\sim{I}(a)=\int_0^{2\pi}d\phi\int_0^{r}dr\ln(a^2+r'^2-2ar'\cos\phi)$, where $a=\sqrt{x^2+y^2}$
Now we have to consider two cases:

*

*$r<a$
$I(a)=\int_0^{2\pi}d\phi\int_0^{r}dr'\ln\left((a-r'e^{i\phi})(a-r'e^{-i\phi})\right)=$$\int_0^{2\pi}d\phi\int_0^{r}dr'\left(2\ln{a}+\ln(1-\frac{r'}{a}e^{i\phi})+\ln(1-\frac{r'}{a}e^{-i\phi})\right)$
But $\ln(1-\frac{r'}{a}e^{i\phi})=-\frac{r'}{a}e^{i\phi}-\frac{r'^2}{a^2}e^{2i\phi}-...$, and all these terms wanish after integration over $\phi$.
$$I(a)=4\pi{r}\ln{a}$$


*$r>a$
In this case we have to split the integrale into to parts: $I(a)=\int_0^a+\int_a^{r}$
$\int_0^a=4\pi{a}\ln{a}$ (the same calculation as in the case 1.)
$\int_a^{r}=\int_0^{2\pi}d\phi\int_a^{r}dr'\ln(a^2+r'^2-2ar'\cos\phi)=\int_0^{2\pi}d\phi\int_a^{r}dr'\ln\left((r'-ae^{i\phi})(r'-ae^{-i\phi})\right)=$$\int_0^{2\pi}d\phi\int_a^{r}dr'\left(2\ln{r'}+\ln(1-\frac{a}{r'}e^{i\phi})+\ln(1-\frac{a}{r'}e^{-i\phi})\right)$
Two last terms vanish, and we get $2\pi\int_a^{r}dr'{2\ln{r'}}=4\pi(r\ln{r}-r-a\ln{a}+a)$
$$I(a)=4\pi(r\ln{r}-r+a)$$
