You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For the case in which the equation is vector valued, however, $u$ is now a vector and so $\nabla u$ is a second-order tensor, while $[v]$ will be either a scalar or a vector depending on whether jump(v, n) or jump(v) is used, so the inner product is not well-defined any more.
The (one?) correct DG formulation for the vector Poisson equation uses the term
I'm not sure that jump can automagically do the right thing in this case without inspecting the provided expression, which is a recipe for pain.
Perhaps it would be OK, you could traverse the expression to determine if it contains a FacetNormal and then (if no normal is provided) you would return v('+') + v('-') (on the assumption that the sign of the normal fixes up the jump).
The standard Discontinuous Galerkin formulation of the scalar Poisson equation
has terms like
which in UFL is expressed as
and all is well.
For the case in which the equation is vector valued, however,$u$ is now a vector and so $\nabla u$ is a second-order tensor, while $[v]$ will be either a scalar or a vector depending on whether
jump(v, n)
orjump(v)
is used, so the inner product is not well-defined any more.The (one?) correct DG formulation for the vector Poisson equation uses the term
where
I tried implementing this with
but, with the current UFL implementation,
ufl/ufl/operators.py
Lines 441 to 452 in 64c846a
this returns [notice the wrong "-" instead of a "+"]
$$v^+ \otimes n^+ - v^- \otimes n^-.$$
The text was updated successfully, but these errors were encountered: