Skip to content

Commit 0642f55

Browse files
committed
has_pointwise_dual_basis
1 parent 4072e63 commit 0642f55

1 file changed

Lines changed: 6 additions & 5 deletions

File tree

finat/finiteelementbase.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -285,15 +285,16 @@ def mapping(self):
285285
'''Appropriate mapping from the reference cell to a physical cell for
286286
all basis functions of the finite element.'''
287287

288-
def is_lagrange(self):
289-
'''Returns whether finat_element.dual_basis consists only of point
290-
evaluation dofs.'''
288+
@cached_property
289+
def has_pointwise_dual_basis(self):
290+
'''Returns whether this element's dual basis consists of point
291+
evaluation functionals.'''
291292
try:
292293
Q, ps = self.dual_basis
293294
except NotImplementedError:
294295
return False
295-
# Inspect the weight matrix
296-
# Lagrange elements have gem.Delta as the only terminal nodes
296+
# Check whether the weight matrix is a product of identity matrices
297+
# A pointwise dual basis has gem.Delta as the only terminal node
297298
children = [Q]
298299
while children:
299300
nodes = []

0 commit comments

Comments
 (0)