This is a read only copy of the old FEniCS QA forum. Please visit the new QA forum to ask questions

Cannot define DG(0) RestrictedElement on facets

+1 vote

The following code fails:

from dolfin import *
mesh=UnitSquareMesh(5,5)
Q = FunctionSpace(mesh, "DG", 0, restriction="facet")

The error message is, "No point in creating empty RestrictedElement."

I do not understand this error message in this context. Piecewise-constants-on-facets should be a legitimate element, I think. Is this my error, a bug or an unimplemented feature?

asked Jul 23, 2016 by mike125 FEniCS Novice (670 points)

1 Answer

0 votes

Restricting DG0 to facets is rather pointless. The element has no degrees of freedom associated with edges and the element degree of freedom couples all edge traces, so in terms of approximation properties this would result in an awful element. Note that we DON'T have one DOF per edge here as we would have for instance when restricting RT1, which is often referred to as RT0 outside of the FEniCS universe. I guess this is why it is not allowed. There may be internal reasons too... Probably the restriction operator constrains the element DOFs, thus leaves nothing left to work with in your case.

answered Jul 25, 2016 by Christian Waluga FEniCS Expert (12,310 points)
How to generate a mesh of facets of existing mesh.
...