Skip to content

Commit

Permalink
refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
pbrubeck committed Nov 1, 2023
1 parent f35b8fc commit 19d9536
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 2 additions & 2 deletions FIAT/barycentric_interpolation.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ def __init__(self, ref_el, pts):
def get_num_members(self, n):
return len(self.nodes)

def make_dmats(self, degree):
return [numpy.transpose(self.dmat)]
def get_dmats(self, degree):
return [self.dmat.T]

def tabulate(self, n, pts):
assert n == len(self.nodes)-1
Expand Down
6 changes: 4 additions & 2 deletions FIAT/expansions.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,8 @@ def recurrence(dim, n, factors, phi, dfactors=None, dphi=None):
raise ValueError("Invalid number of spatial dimensions")

f1, f2, f3, f4 = factors
f5 = f4 ** 2
if dfactors is not None:
df1, df2, df3, df4 = dfactors
df5 = 2 * f4 * df4

# p = 1
icur = idx(0)
Expand All @@ -71,6 +69,10 @@ def recurrence(dim, n, factors, phi, dfactors=None, dphi=None):
if dim < 2:
return

f5 = f4 ** 2
if dfactors is not None:
df5 = 2 * f4 * df4

for p in range(n):
# q = 1
icur = idx(p, 0)
Expand Down

0 comments on commit 19d9536

Please sign in to comment.