Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use subdegree instead of superdegree to check cell bendy-ness #295

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions ufl/algorithms/apply_geometry_lowering.py
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ def _reduce_cell_edge_length(self, o, reduction_op):

domain = extract_unique_domain(o)

if domain.ufl_coordinate_element().embedded_superdegree > 1:
if domain.ufl_coordinate_element().embedded_subdegree > 1:
# Don't lower bendy cells, instead leave it to form compiler
warnings.warn("Only know how to compute cell edge lengths of P1 or Q1 cell.")
return o
Expand All @@ -329,7 +329,7 @@ def cell_diameter(self, o):

domain = extract_unique_domain(o)

if domain.ufl_coordinate_element().embedded_superdegree > 1:
if domain.ufl_coordinate_element().embedded_subdegree > 1:
# Don't lower bendy cells, instead leave it to form compiler
warnings.warn("Only know how to compute cell diameter of P1 or Q1 cell.")
return o
Expand Down Expand Up @@ -366,7 +366,7 @@ def _reduce_facet_edge_length(self, o, reduction_op):
if domain.ufl_cell().topological_dimension() < 3:
raise ValueError("Facet edge lengths only make sense for topological dimension >= 3.")

elif domain.ufl_coordinate_element().embedded_superdegree > 1:
elif domain.ufl_coordinate_element().embedded_subdegree > 1:
# Don't lower bendy cells, instead leave it to form compiler
warnings.warn("Only know how to compute facet edge lengths of P1 or Q1 cell.")
return o
Expand Down
Loading