Moving boundary diffusion equation (transformation of coordinates)

In summary, the conversation discusses the implementation of a numerical code for the diffusion equation with moving boundaries in spherical coordinates. After scaling the equations and transforming the coordinates, the result is a modified diffusion equation in Landau coordinates. The conversation also mentions a paper that suggests the final result for the modified equation. The summary also includes a step-by-step guide for changing coordinates and deriving the second partial derivative.
  • #1
babagoslow
13
0
I'm trying to implement a numerical code for the diffusion equation with moving boundaries. I have no problems with the numerical implementation, but with the transformation of coordinates. In spherical coordinates, the diffusion equation is
[itex]\frac{\partial c}{\partial t} = D \left(\frac{2}{r}\frac{\partial c}{\partial r} + \frac{\partial^2 c}{\partial r^2} \right)[/itex].

After scaling these equations with [itex] \phi = c/C_0, \tau = Dt/R_0^2, x = (r-R_0)/R_0 [/itex] I get

[itex] \frac{\partial\phi}{\partial \tau} = \frac{2}{1+x} \frac{\partial\phi}{\partial x} + \frac{\partial^2 \phi}{\partial x^2} [/itex]

Now transform the [itex]x[/itex] coordinate to the Landau (not that Landau) coordinate [itex]\eta(x,\tau)[/itex] defined as

[itex]\eta(x,\tau) = \frac{x - X(\tau)}{X_\infty - X(\tau)}[/itex].

The idea of the transformation is to move the boundary [itex]X(\tau)[/itex], which is variable only in time [itex]\tau[/itex] and keep the length scale [itex]X_\infty[/itex] fixed. This is particularly useful, for instance, in problems involving a gas bubble losing volume by diffusion, where the bubble's radius is variable in time.

There's a paper out there (Fischer, Zinovik and Poulikakos 2009) which suggests that the final result should be

[itex]\frac{\partial \phi}{\partial \tau} = \left[ \frac{2}{(X_\infty - X(\tau))(1+\eta (X_\infty - X(\tau))+ X)} + \frac{1-\eta}{X_\infty - X(\tau)}\frac{dX}{d\tau} \right] \frac{\partial\phi}{\partial\eta} + \frac{1}{(X_\infty - X(\tau))^2} \frac{\partial^2 \phi}{\partial \eta^2}.
[/itex]

However, I have some trouble reproducing this result. Can someone guide me through the change of coordinates? I have problems particularly with the second partial derivative.
 
Physics news on Phys.org
  • #2
babagoslow said:
I'm trying to implement a numerical code for the diffusion equation with moving boundaries. I have no problems with the numerical implementation, but with the transformation of coordinates. In spherical coordinates, the diffusion equation is
[itex]\frac{\partial c}{\partial t} = D \left(\frac{2}{r}\frac{\partial c}{\partial r} + \frac{\partial^2 c}{\partial r^2} \right)[/itex].

After scaling these equations with [itex] \phi = c/C_0, \tau = Dt/R_0^2, x = (r-R_0)/R_0 [/itex] I get

[itex] \frac{\partial\phi}{\partial \tau} = \frac{2}{1+x} \frac{\partial\phi}{\partial x} + \frac{\partial^2 \phi}{\partial x^2} [/itex]

Now transform the [itex]x[/itex] coordinate to the Landau (not that Landau) coordinate [itex]\eta(x,\tau)[/itex] defined as

[itex]\eta(x,\tau) = \frac{x - X(\tau)}{X_\infty - X(\tau)}[/itex].

The idea of the transformation is to move the boundary [itex]X(\tau)[/itex], which is variable only in time [itex]\tau[/itex] and keep the length scale [itex]X_\infty[/itex] fixed. This is particularly useful, for instance, in problems involving a gas bubble losing volume by diffusion, where the bubble's radius is variable in time.

There's a paper out there (Fischer, Zinovik and Poulikakos 2009) which suggests that the final result should be

[itex]\frac{\partial \phi}{\partial \tau} = \left[ \frac{2}{(X_\infty - X(\tau))(1+\eta (X_\infty - X(\tau))+ X)} + \frac{1-\eta}{X_\infty - X(\tau)}\frac{dX}{d\tau} \right] \frac{\partial\phi}{\partial\eta} + \frac{1}{(X_\infty - X(\tau))^2} \frac{\partial^2 \phi}{\partial \eta^2}.
[/itex]

However, I have some trouble reproducing this result. Can someone guide me through the change of coordinates? I have problems particularly with the second partial derivative.

It helps, to avoid confusion, to change to two new independent variables, so let's take [itex](x,\tau) \to (\eta, \sigma)[/itex] with [itex]\sigma(x,\tau) = \tau[/itex].

The chain rule gives
[tex]
\frac{\partial \phi}{\partial x} = \frac{\partial \phi}{\partial \eta} \frac{\partial \eta}{\partial x} + \frac{\partial \phi}{\partial \sigma} \frac{\partial \sigma}{\partial x}
= \frac{1}{X_\infty - X(\sigma)} \frac{\partial \phi}{\partial \eta} \\
\frac{\partial \phi}{\partial \tau} = \frac{\partial \phi}{\partial \eta} \frac{\partial \eta}{\partial \tau} + \frac{\partial \phi}{\partial \sigma} \frac{\partial \sigma}{\partial \tau}
= -\frac{(1- \eta) X'(\sigma)}{X_\infty - X(\sigma)} \frac{\partial \phi}{\partial \eta} + \frac{\partial \phi}{\partial \sigma}
[/tex]
since
[tex]
\frac{\partial \eta}{\partial \tau} = \frac{\partial}{\partial \tau} \left(\frac{x - X(\tau)}{X_\infty - X(\tau)}\right) =
\frac{1}{(X_\infty - X)^2} ((X_\infty - X)(-X') - (x - X)(-X')) \\
= \frac{-X'(\sigma)}{X_\infty - X(\sigma)} \frac{X_\infty - x}{X_\infty - X(\sigma)}
= \frac{-X'(\sigma)}{X_\infty - X(\sigma)}(1-\eta)
[/tex]

For the second derivative,
[tex]
\frac{\partial^2 \phi}{\partial x^2} = \frac{\partial}{\partial x} \frac{\partial \phi}{\partial x}
= \frac{\partial}{\partial x} \left( \frac{1}{X_\infty - X(\sigma)} \frac{\partial \phi}{\partial \eta} \right) \\
= \frac{\partial \eta}{\partial x} \frac{\partial}{\partial \eta} \left( \frac{1}{X_\infty - X(\sigma)} \frac{\partial \phi}{\partial \eta} \right)
+ \frac{\partial \sigma}{\partial x} \frac{\partial}{\partial \sigma} \left( \frac{1}{X_\infty - X(\sigma)} \frac{\partial \phi}{\partial \eta} \right) \\
= \frac{1}{(X_\infty - X(\sigma))^2} \frac{\partial^2 \phi}{\partial \eta^2}
[/tex]

Substitution into the original equation and rearrangement will yield the given result.
 
Last edited:
  • #3
Hi Pasmith, thanks, I understand it now!
 

Related to Moving boundary diffusion equation (transformation of coordinates)

1. What is the moving boundary diffusion equation?

The moving boundary diffusion equation is a mathematical model that describes the diffusion of a substance in a medium where the boundaries of the medium are changing over time. It is commonly used in physics, chemistry, and engineering to analyze diffusion processes in materials such as gases, liquids, and solids.

2. What are the variables in the moving boundary diffusion equation?

The variables in the moving boundary diffusion equation include the concentration of the diffusing substance, the diffusivity of the medium, the distance from the source of diffusion, and the time elapsed. Additional variables may also be included depending on the specific problem being studied.

3. How does the moving boundary diffusion equation differ from the standard diffusion equation?

The main difference between the moving boundary diffusion equation and the standard diffusion equation is that the former takes into account the changing boundaries of the medium, while the latter assumes a fixed boundary. This makes the moving boundary diffusion equation more applicable to real-world situations where boundaries may change over time.

4. What are some applications of the moving boundary diffusion equation?

The moving boundary diffusion equation has a wide range of applications in various fields, including materials science, chemical engineering, and environmental science. Some specific examples include analyzing the diffusion of pollutants in water bodies, predicting the diffusion of drugs in tissues, and understanding the transport of nutrients in biological systems.

5. How are coordinates transformed in the moving boundary diffusion equation?

In the moving boundary diffusion equation, a change of coordinates is often necessary to simplify the mathematical formulation and make it more suitable for solving. This transformation of coordinates can involve converting from Cartesian to polar coordinates, or from an unbounded domain to a bounded one. The specific transformation used depends on the problem being studied.

Similar threads

Replies
3
Views
2K
Replies
17
Views
2K
Replies
1
Views
2K
Replies
8
Views
2K
Replies
2
Views
804
Replies
2
Views
1K
Replies
0
Views
120
Back
Top