# Showing $\nabla \cdot \mathbf A = 0$ using integral formula

In Coulomb gauge the vector potential is chosen so that $$\nabla \cdot \mathbf A = 0$$ and we find $$\nabla^2 \mathbf{A}=-\mu_0 \mathbf j$$ The solution to which is $$\mathbf A(r) = \frac{\mu_0}{4\pi}\int \frac{\mathbf j (r') d \mathbf r'}{|r-r'|}$$ I having having problem to see that why is the $$\nabla \cdot \mathbf A=0$$ in this integral formula. For steady current $$\nabla_{r'} \cdot \mathbf j=0$$ but, On the lhs I am applying the divergence on the field coordinate $$\nabla_r$$. How to show $$\nabla_{r} \cdot \mathbf A=0$$.

• There are a few ways to do it, but the most common is called “integration by parts.” – CR Drost May 27 at 7:11
• is there any transform rule to change $\nabla_r$ to $\nabla_{r'}$ @CRDrost – Galilean May 27 at 7:13
• Not besides “variable substitution” but that is not what you want. But in this special circumstance you have a volume integral, so you can integrate by parts. – CR Drost May 27 at 7:14

\begin{align*} \nabla_r \cdot \mathbf A &= \frac{\mu_0}{4\pi} \int \nabla_{r} \cdot \left (\frac{\mathbf j(\mathbf r')}{|\mathbf r- \mathbf r'|}\right) d\mathbf r' \\ \end{align*} Here $$\nabla_{r}\cdot \mathbf j(\mathbf r')$$ is zero as it is not a function of $$\mathbf r$$. So we are only left with $$\mathbf j (\mathbf r') \cdot \nabla \left( \frac{1}{{|\mathbf r- \mathbf r'|}}\right)$$ in the integrand. Now perform a integration by parts as \begin{align*} \nabla_r \cdot \mathbf A &= \frac{\mu_0}{4\pi} \left[ \left( \mathbf j(\mathbf r') \cdot \frac{1}{{|\mathbf r- \mathbf r'|}} \right)^{\infty}_{-\infty} -\int \nabla_{r'}\cdot \mathbf j(\mathbf r') \frac{1}{{|\mathbf r- \mathbf r'|}} d\mathbf{r'} \right] \end{align*} The first term vanishes as the current is always asumed to be local and in the second term for steady current is $$\nabla_{r'} \cdot \mathbf j(\mathbf r')=0$$ (from continuity equation). So, \begin{align*} \nabla_r \cdot \mathbf A =0 \end{align*}