Skip to content

FiPy or Clawpack for advection-diffusion like equation in non-rectangular domain #1086

Answered by guyer
cgadal asked this question in Q&A
Discussion options

You must be logged in to vote

Remaining questions:

  • I am unsure about how to discretize the third term of the equation. It does not seem to fall into any of the typical categories, so should I deal with it as a source term ?

I would be inclined to approach the third term by writing

$$ -\frac{\partial}{\partial x}\left[\hat{\imath} F_x \phi \left(1 - \phi\right)\right] -\frac{\partial}{\partial z}\left[\hat{k} F_z \phi \left(1 - \phi\right)\right] = -\nabla\cdot\left[\vec{F} \phi \left(1 - \phi\right)\right] $$

and then representing that as

F = ...
Fvec = [0, F]
eq = ... + ConvectionTerm(coeff=Fvec * (1 - phi), var=phi) == ...
  • I am unsure about how to represent those boundary conditions, but it seems to me they ma…

Replies: 2 comments 6 replies

Comment options

You must be logged in to vote
2 replies
@cgadal
Comment options

@cgadal
Comment options

Answer selected by cgadal
Comment options

You must be logged in to vote
4 replies
@cgadal
Comment options

@guyer
Comment options

@cgadal
Comment options

@guyer
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants