# Is it possible to solve the equation for the diffusion of gas through a sphere analytically by applying e.g. "combination of variables"?

In the case of diffusion through a thin film it is possible to combine the variables in the following way: $\sigma = \frac{x}{\sqrt{4Dt}}$

where

• $x$=length
• $D$=diffusion coefficient
• $t$=time
• $\sigma$=a function of x and t

Thereby, x and t is substituted by the single variable sigma

Is there a similar expression for a sphere?

E. L. Cussler discribes in detail how to solve the equation for a thin film by applying "combination of variables".

• Good, but still unclear. You can combine (say, multiply) any variable with any other variable. What is the significance of this particular combination? Feb 19, 2018 at 20:24
• @Sigils while not off topic here, you might get a better answer on Physics SE.
– Tyberius
Feb 19, 2018 at 20:25
• Are you looking for a solution which gives you for example in how much time a sphere of sugar will dissolve in water by only diffusion? Feb 19, 2018 at 22:19

Given the diffusion equation

$D(\frac{d^2y}{dr^2}+(\frac{2}{r})\frac{dy}{dr})=\frac{dy}{dt}$

You can put in

$y=z/r$

And then

$\frac{dy}{dr}=(\frac{1}{r})(\frac{dz}{dr}-\frac{z}{r})$

$\frac{d^2y}{dr^2}=(\frac{1}{r})(\frac{d^2z}{dr^2}-(\frac{2}{r})\frac{dz}{dr}+\frac{2z}{r^2})$

$\frac{dy}{dt}=(\frac{1}{r})\frac{dz}{dt}$

Plug these into your diffusion equation and a lot of terms cancel leaving the same equation you would have in rectangular coordinates:

$D\frac{d^2z}{dr^2}=\frac{dz}{dt}$

So you then use the same combination of variables as in the rectangular case except you put $z=ry$ as your dependent variable.

• Then I get a result of the type: z(sigma) = C1+erf(sigma) * C2 Which leads to an equation of the following type with respect to c: c(r,t) = (C1 + erf(x/(sqrt(4Dt))) * C2)/(r) Is this correct? Feb 20, 2018 at 18:18
• Your boundary conditions on $z$ will not be analogous to those on $y$ in the rectangular case. You can reduce your problem to one independent variable but you might get different functional forms depending on the form of the boundary conditions for $z$. So treat that carefully. Also remember to use $r$ for your coordinate throughout. Feb 20, 2018 at 19:04

Yes. Let's improve the wording here: that is not just an expression, it's the definition of a dimensionless variable that eases the understanding of the solution of the transient diffusion is a semi-infinite medium. Because there is no clear characteristic length as in a finite diffusion path problem, Buckingham π theorem will tell us the two dimensionless quantities we need are $$\Pi_1 = \frac{z}{\sqrt{D t}}$$ (Or any function of it, like squaring it or dividing it by 4, such as your $\sigma$)

And $$\Pi_2 = \frac{y-y_{A\infty}}{y_{As} - y_{A\infty}}$$

With $s$ being the surface index and $\infty$ indicating a position "at infinity" (often we use $y_{A\infty} = 0$).

Then we conclude $\Pi_2 =\textrm{function}(\Pi_1)$. This particular function can found by solving Fick's second law with the appropriate boundary and initial conditions. In the most common case, it yields a Gauss error function.

Had we be initially interested in a sphere instead of a planar surface, the only major difference would be the use of spherical coordinates instead of a Cartesian frame, which would result in a different functional solution. But the problem of defining the dimensionless variables would be the same, given we assume perfect angular symmetry. The $z$ position would just be substituted by a radial position $r$.