Hello everyone,
I have a question which has more to do with fluid mechanics rather than
the fipy solver itself. I'm trying to solve a set of equations which
contain the continuity equation. The problem is one-dimensional and I'm
using spherical coordinates as well as a coordinate change. After
transformation, the equation looks like this
\[
\frac{\partial c}{\partial t}
- \frac{\partial c}{\partial \xi} \frac{\xi}{R} \frac{dR}{dt}
+ \frac{\partial}{\partial \xi} \left( \frac{c v^*}{R} \right)
+ 2 \frac{c v^*}{\xi R}
= 0
\]
where $\xi$ is the space coordinate, $c$ is the molar density, $R$ is a
function of time only, $v^*$ is the molar average velocity.
Everything can be calculated from other variables of the system, except
for the velocity. Therefore, I need this equation to compute the velocity
$v^*$. It appears in a simple derivative so I thought about declaring this
term in fipy with a convection term. However there are several problems
with this strategy.
- Ideally, the velocity which is a vector face variable should be a
coefficient, not the variable we are solving for.
- There is no diffusion term in this equation which makes it a hyperbolic
equation and as far as I heard this isn't necessarily a good thing.
Then I thought I don't have the strategy, so I read the section of the
manual with the cavity problem which includes the continuity equation. But
there, the velocity can be computed with the momentum equation and is
linked to the pressure with the SIMPLE algorithm. My case is diffrent,
there is no pressure gradient, the velocity is "diffusion induced" if I
may say it like that, it is due to evaporation and diffusion of the
different chemical species in the domain.
Does anyone have any ideas? Jonathan perhaps? Any help would be greatly
appreciated.
Best regards,
Etienne