Suppose I have a function $c(x,y,z)$ that describes a scalar field of the concentration of a chemical diffusing from the origin.
Now, suppose I ask the question 'How big a radius $\rho$ should a sphere centered at the origin have to contain $50$% of the field in the domain?'. In other words, this question asks how big a sphere centered at the origin do I need to enclose $50$% of the molecules of the chemical.
Would this question be answered by solving the following for $\rho$?
$$\frac{\int_0^\pi \int_0^{2\pi}\int_0^\rho c(\rho,\theta,\phi)\rho^2 sin(\phi)drd\theta d\phi}{\int_0^\pi \int_0^{2\pi}\int_0^d c(\rho,\theta,\phi)\rho^2 sin(\phi)drd\theta d\phi}=0.5$$ Where the function has been converted to spherical coordinates and this is an integral in spherical coordinates (I hope I recall correctly that $\rho^2sin(\phi)$ is in the spherical coordinates triple integral)?
Any insight is much appreciated. Thanks.
Additional Note: I'm using a concentration function $c(x,y,z)=\frac{E}{4 \pi D \mid\mid(x,y,z)\mid\mid}e^{-\frac{\mid\mid (x,y,z) \mid\mid}{\sqrt{D*t}}}$ where E is the emission rate of the chemical, t the decay time of the molecules and D the diffusivity constant. My problem is that when I ask the question above, if I set up that ratio I see it does NOT depend on the emission rate E, because it cancels out. That seems very odd to me because intuitively, what percentage of the concentration is contained in a sphere of radius $\rho$ should be dependent on the emission rate E. But I'm no scientist.
If $d$ is the extend of the domain, then yes, the integral
$$ f(\rho) = \frac{\int_{r < \rho} {\rm d}^3\mathbf{r}\; c(\mathbf{\mathbf{r}})}{\int_{r < d} {\rm d}^3\mathbf{r}\; c(\mathbf{\mathbf{r}})} \tag{1} $$
will give you the fraction within a sphere of radius $\rho$ relative to the content within a sphere of radius $d$. So in your case, you need to solve $f(\rho) = 0.5$
You're right: in spherical coordinates ${\rm d}^3\mathbf{r} = r^2\sin\theta{\rm d}r {\rm d}\theta{\rm d}\phi$. Moreover, you may want to write $c$ as
$$ c = \frac{E}{4\pi D r} e^{-r/\sqrt{Dt}} $$
When you plug in this in Eq. (1) you get
$$ f(\rho) = \frac{\int_0^\rho {\rm d}r \; r e^{-r/\sqrt{Dt}}}{\int_0^d {\rm d}r \; r e^{-r/\sqrt{Dt}}} = \frac{1-e^{-\frac{\rho}{\sqrt{Dt}}}(1+\rho/\sqrt{Dt} )}{1-e^{-\frac{d}{\sqrt{Dt}}}(1+d/\sqrt{Dt} ) } $$
I actually makes sense that it does not depend on $E$ because is a fraction. If you increase $E$ by a factor of two, the number will increase, but the fraction will not change!