This is a simple question whose answer was probably known to Poisson, but I was not able to find it by searching. I need explicit formulas for the Newtonian potential of the unit ball $\mathbb{B}^n$ and the unit sphere $\mathbb{S}^{n-1}$, with *explicit constants*. So I did the computation myself but I still need to check the constants. I thought MO would be a good place for this, since having the precise formulas here could be good as a reference. Feel free to close the question if it is too restricted in scope.

Let $E_2=\frac 1{2\pi}\log|x|$ and $E_n=\frac1{\omega_n(2-n)}|x|^{2-n}$ for $n\ge3$, where $\omega_n$ is the surface of the unit sphere.I denote with $1_{A}$ the characteristic function of the set $A$. Here is what I get for the unit ball ($n\ge3$): \begin{equation} E_{n}*1_{\mathbb{B}^{n}}(x)= \begin{cases} \frac{1}{2(2-n)}+\frac{1}{2n}|x|^{2} &\text{if $ |x|\le1 $,}\\ \frac{1}{n(2-n)}|x|^{2-n} &\text{if $ |x|\ge1 $} \end{cases} \end{equation} \begin{equation} E_{2}*1_{\mathbb{B}^{2}}(x)= \begin{cases} -\frac{1}{4}+\frac{1}{4}|x|^{2} &\text{if $ |x|\le1 $,}\\ \frac{1}{2}\log|x| &\text{if $ |x|\ge1 $.} \end{cases} \end{equation} and for the sphere ($\sigma_{\mathbb{S}^{n-1}}$ is the surface measure of the unit sphere): \begin{equation} E_{n}*\sigma_{\mathbb{S}^{n-1}}(x)= \frac{1}{2-n} \begin{cases} 1 &\text{if $ |x|\le1 $,}\\ |x|^{2-n} &\text{if $ |x|\ge1 $.} \end{cases} \end{equation} \begin{equation} E_{2}*\sigma_{\mathbb{S}^{1}}(x)=(\log|x|)^{+}. \end{equation} Are these formulas correct? of course, a reference where this calculation is done would be enough.