Context
I have already asked one question regarding charge densities, Diracs, and Heavisides [0]. At the time of writing, that question remains open. More importantly, I still remain unclear regarding how to write charge densities with Diracs, and Heavisides. Here is an example to show that I lack clarity.
This question here revolves around how to define a surface charge. There is a large set up to the problem. Once set up, then comes the discussion of surface charge. I want to solve for the electric potential $V$ inside and outside a conductive ball of radius $R$ with a total charge $Q$. The problem can be solved with Gauss' Law, and it can be solved with spherical harmonics. I will do both.
Gauss' Law
Here, I use Gauss' Law, to find the electric field; and then I use integration and continuity of $V$ at the boundary to solve for $V$. I the potential at infinity as the zero referene. \begin{align*} \mathbf{E} {\left(\mathbf{r}\right)} &= \begin{cases} \mathbf{0},~&\text{for} ~r< R \\\\ \frac{Q}{4\,\pi\,\epsilon_o \,r^2 }\,\mathbf{\hat{r}} ,~&\text{for} ~r> R. \end{cases} \end{align*} \begin{align*} V {\left(\mathbf{r}\right)} &= \begin{cases} \frac{Q}{4\,\pi\,\epsilon_o \,R } ,~&\text{for} ~r\leq R \\\\ \frac{Q}{4\,\pi\,\epsilon_o \,r } ,~&\text{for} ~r> R. \end{cases} \end{align*}
Expansion in Spherical Harmonics
In a nut shell, since this problem has azimuthal symmetry, the solution can be written [1] in terms of Legendre polynomials of degree $\ell$, $P_\ell$, as $$ V(r,\theta,\phi) = \begin{cases} \sum_{\ell=0}^\infty A_\ell\, r^\ell\,P_\ell(\cos\theta), &(r\leq R) \\ \sum_{\ell=0}^\infty \frac{A_\ell\,R^{2\,\ell+1}}{r^{\ell+1}} \,P_\ell(\cos\theta), &(r\geq R) ; \end{cases} $$ where $$ A_\ell = \frac{1}{2\,\varepsilon_o\,R^{\ell-1} }\,\int_0^\pi \sigma(\theta) P_\ell(\cos\theta)\,\sin\theta\,d\theta . $$
Question
(1) What is $\sigma(\theta) $
(2) What am I misunderstanding about how to use Dirac delta distributions and Heaviside step function as I attempt to write charge densities in terms of the same?
Answer to Question 1
One the one hand, I argue, but not with self confidence and only because I know the answer in advance, that surface charge density is invariant with respect to $\theta$ (i.e., $\sigma(\theta) = \sigma_o$). In such case, according to the orthogonality of the Legendre polynomials [2] \begin{align} A_\ell &= \frac{\sigma_o}{2\,\varepsilon_o\,R^{\ell-1} }\,\int_0^\pi P_\ell(\cos\theta)\,\sin\theta\,d\theta . \\ &= \begin{cases} 0 & (\ell\neq 0) \\ \frac{\sigma_o\,R }{ \varepsilon_o }. \end{cases} \end{align} Thus, $$ V(r,\theta,\phi) = \begin{cases} \frac{\sigma_o\,R }{ \varepsilon_o } , &(r\leq R) \\ \frac{\sigma_o\,R }{ \varepsilon_o }\,\frac{ R }{r }, &(r\geq R) ; \end{cases} $$ It appears that for the answer here to be self-consistent with the answer from Gauss' law, that $$ \sigma(\theta) = \frac{Q}{4\,\pi\,R^2}.\tag{1}$$ This seems like a sensible description of the surface charge. Ulitmately, $$ V(r,\theta,\phi) = \begin{cases} \frac{ Q }{ 4\,\pi\,R \,\varepsilon_o } , &(r\leq R) \\ \frac{ Q }{ 4\,\pi \,\varepsilon_o\,r }, &(r\geq R) . \end{cases} $$ Well, that appears to have went well.
One the other hand, I argue that surface charge density varies with respect to $\theta$. In such case, according to the orthogonality of the
I write that \begin{align} Q &= \int_{\mathbb{R}^3} \rho(r,\theta,\phi)\,d\tau \\ &= \int_{\phi=0}^{2\,\pi}\,\int_{\theta=0}^{\pi}\,\int_{r=0}^\infty \rho(r,\theta,\phi)\,r^2\,\sin\theta\,dr\,d\theta\,d\phi. \end{align} Since the charge only exists at $r=R$, I write $\rho(r,\theta,\phi) = \sigma(r,\theta,\phi)\,\delta(r-R)$, then \begin{align} Q &= \int_{\phi=0}^{2\,\pi}\,\int_{\theta=0}^{\pi}\,\int_{r=0}^\infty \sigma( \theta,\phi)\,\delta(r-R)\,r^2\,\sin\theta\,dr\,d\theta\,d\phi. \\ &= \int_{\phi=0}^{2\,\pi}\,\int_{\theta=0}^{\pi} \sigma(\theta,\phi) \, R^2\,\sin\theta\,dr\,d\theta\,d\phi . \end{align} I argue, but not self-convincingly, that since the differential area element, $da$ is $da =R^2\,\sin\theta\,d\theta\,d\phi$ and since the surface charge density should be constant with respect to $da$, that $ \sigma( \theta,\phi) =\sigma_o$. Then, \begin{align} Q &= \int_{\phi=0}^{2\,\pi}\,\int_{\theta=0}^{\pi} \sigma_o \, R^2\,\sin\theta\,dr\,d\theta\,d\phi . \\ &= 4\,\pi \sigma_o \, R^2. \end{align} Again, in oder to be consistent, it seems that $$\sigma = \frac{Q}{4\,\pi\,R^2}. \tag{2}$$ In such case, I will get the same answer as before for $V(r,\theta,\phi)$.
My true question
Is there some way to more formal method to determine how to use Dirac delta distributions and Heavside step functions? Both ways that I performed here are round about. In Equation 1 and Equation 2, I determine the charge density after the fact. I do not like that, as I believe that I will fail to properly apply Dirac delta functions and Heaviside step functions on more complicated surfaces---when I can't use an after-the-fact argument.
Bibliography
[0] Dirac delta, Heaviside step, and volume charge density
[1] Griffiths, "Introdution to Electrodynamics" 2nd Edition p. 142-143.
[2] Wikipedia contributors. "Legendre polynomials." Wikipedia, The Free Encyclopedia. Wikipedia, The Free Encyclopedia, 21 Feb. 2021. Web. 8 Mar. 2021.