On Apr 27, 2006, at 1:34 PM, Damm, Edward F. (E. Buddy) wrote:
Sorry, Hope the attached clarifies it. The second to the last
equation is what I am talking about. The stuff before leads up to
it. The term that is not in the original reference, but that I
added per our discussion was the 1/uc.
It's not that you divide by uc; it's that you must factor it out of
the term to determine the coefficient. You have correctly identified
your convection term as
\begin{equation}
\nabla\cdot \left[ M_{c}\cdot u_{c}y_{va}\cdot
\frac{\partial ^{2}G_{m}}{\partial u_{c}\partial \phi }\nabla \phi
\right]
\end{equation}
A convection \nabla\cdot\left[ u_c \vec{v} \right] represents the
field $u_c$ being transported by a velocity field $\vec{v}$. For
FiPy's purposes, the coefficient of the convection term is the
velocity field which, in your expression, is everything *but* $u_c$.
It's not that you need to explicitly divide by $u_c$; you simply need
to factor it out.
Your convection *coefficient* (not equation!!!) is then:
Mc * yva * d2Gmducdphi * phi.getFaceGrad()
However you determine Mc, yva, and d2Gmducdphi, remember that they
must be determined on faces to be consistent with phi.getFaceGrad().