Skip to content

Commit

Permalink
remove entity_dof_counts (as it is never used)
Browse files Browse the repository at this point in the history
  • Loading branch information
mscroggs committed Jun 21, 2021
1 parent 5fcac2d commit e2d6831
Showing 1 changed file with 0 additions and 41 deletions.
41 changes: 0 additions & 41 deletions ffcx/element_interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,11 +138,6 @@ def value_shape(self):
"""Get the value shape of the element."""
raise NotImplementedError

@property
def entity_dof_counts(self):
"""Get the number of DOFs associated with each entity."""
raise NotImplementedError

@property
def entity_dof_numbers(self):
"""Get the DOF numbers associated with each entity."""
Expand Down Expand Up @@ -231,15 +226,9 @@ def value_shape(self):
"""Get the value shape of the element."""
return self.element.value_shape

@property
def entity_dof_counts(self):
"""Get the number of DOFs associated with each entity."""
return self.element.entity_dof_counts

@property
def entity_dof_numbers(self):
"""Get the DOF numbers associated with each entity."""
# TODO: move this to basix, then remove this wrapper class
return self.element.entity_dofs

@property
Expand Down Expand Up @@ -403,13 +392,6 @@ def value_shape(self):
"""Get the value shape of the element."""
return (sum(e.value_size for e in self.sub_elements), )

@property
def entity_dof_counts(self):
"""Get the number of DOFs associated with each entity."""
data = [e.entity_dof_counts for e in self.sub_elements]
return [[sum(d[tdim][entity_n] for d in data) for entity_n, _ in enumerate(entities)]
for tdim, entities in enumerate(data[0])]

@property
def entity_dof_numbers(self):
"""Get the DOF numbers associated with each entity."""
Expand Down Expand Up @@ -519,11 +501,6 @@ def value_shape(self):
"""Get the value shape of the element."""
return (self.value_size, )

@property
def entity_dof_counts(self):
"""Get the number of DOFs associated with each entity."""
return [[j * self.block_size for j in i] for i in self.sub_element.entity_dof_counts]

@property
def entity_dof_numbers(self):
"""Get the DOF numbers associated with each entity."""
Expand Down Expand Up @@ -617,24 +594,6 @@ def value_shape(self):
"""Get the value shape of the element."""
return [1]

@property
def entity_dof_counts(self):
"""Get the number of DOFs associated with each entity."""
dofs = []
tdim = self._ufl_element.cell().topological_dimension()

if tdim >= 1:
dofs += [[0] * self._ufl_element.cell().num_vertices()]

if tdim >= 2:
dofs += [[0] * self._ufl_element.cell().num_edges()]

if tdim >= 3:
dofs += [[0] * self._ufl_element.cell().num_facets()]

dofs += [[self.dim]]
return dofs

@property
def entity_dof_numbers(self):
"""Get the DOF numbers associated with each entity."""
Expand Down

0 comments on commit e2d6831

Please sign in to comment.