Integrals and Legendre Polynomials I was told by a professor that this equality:
$$\frac{1}{2\pi}\int_0^{2\pi}\frac{1}{|r-r(\varphi)|}d\varphi = \frac{1}{r}\sum_0^{\infty} \bigl(\frac{a}{r}\bigr)^n{|P_n(0)|}^2$$
( where:
$a$ is the constant modulo of the vector $r'(\varphi)$ and $P_n(0)$ is the $n$th Legendre Polynomial evaluated in $0$  ).
Is a very well-known fact among physicists and often used as a sort of definition of the Legendre Polynomials.
The problem is that the only Legendre Polynomial definition I know is Rodrigue's one:
$$ P_n(x) = \frac{d^n}{dx^n}(x^2-1)^n$$
How can I prove that these two definitions coincide?
I evaluated the integral by studying the "mean value" of $|r-r(\varphi)|^{-1}$ as a Taylor expansion and I could verify by hand that the first terms really behave as expected, but for obvious reasons I cannot verify all of them...
 A: It's known that the general solution of the Laplace equation $\nabla^2\Phi = 0$ in spherical coordinates with azimutal symmetry is given by:
$$\Phi(r,\theta)=\sum_{l=0}^\infty\left(A_l r^l + B_lr^{-(l+1)}\right)P_l(\cos \theta),$$
where $A_l$ and $B_l$ are given by boundary conditions. We also have that the function $\dfrac{1}{|\mathbf{x}-\mathbf{x'}|}$, where $\mathbf{x'}$ is the location of a charge (or mass) satisfies the Laplace equation. Thus we can write
$$\dfrac{1}{|\mathbf{x}-\mathbf{x'}|}=\sum_{l=0}^\infty\left(A_l r^l + B_lr^{-(l+1)}\right)P_l(\cos \theta)$$
If the points $\mathbf{x}$ and $\mathbf{x'}$lie in the $z$ axis, we have that the LHS is
$$\dfrac{1}{|\mathbf{x}-\mathbf{x'}|}=\frac{1}{|r-r'|},$$
while the RHS is
$$\sum_{l=0}^\infty\left(A_l r^l + B_lr^{-(l+1)}\right),$$
since $P_l(\cos 0)=1$. Expanding $\dfrac{1}{|r-r'|}$ for $r>r'$, we get
$$\dfrac{1}{|\mathbf{x}-\mathbf{x'}|}=\frac{1}{r}\sum_{l=0}^\infty\left(\frac{r'}{r}\right)^l$$
Since the expasion is unique, we get that $A_l=0$, $\forall l$, and $B_l=r'^l$. For $\mathbf{x}$ out of the axis, we just have to multiply each term by $P_l(\cos \theta)$. We get then the expression
$$\dfrac{1}{|\mathbf{x}-\mathbf{x'}|}=\frac{1}{r}\sum_{l=0}^\infty\left(\frac{r'}{r}\right)^lP_l(\cos \gamma),$$
where $\gamma$ is the angle between $\mathbf{x}$ and $\mathbf{x'}$. In you case, since the $\gamma=\dfrac{\pi}{2}$, you find that on the $z$ axis, the potential is given by
$$\Phi(r)=-\frac{GM}{r}\sum_{l=0}^\infty\left(\frac{a}{r}\right)^lP_l(0)$$
A similar procedure yields the result for $r<r'$.
