Skip to content

Commit

Permalink
Merged in taylor (pull request #26)
Browse files Browse the repository at this point in the history
enable Taylor elements in UFL.
  • Loading branch information
colinjcotter committed Aug 17, 2015
2 parents 9eeeb70 + 2ff6e67 commit 00cf21a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 4 additions & 1 deletion test/test_elements.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ def test_scalar_galerkin():
element = FiniteElement(family, cell, p)
assert element.value_shape() == ()
assert element == eval(repr(element))

for p in range(1, 10):
for family in ("TDG", "Discontinuous Taylor"):
element = FiniteElement(family, interval, p)
assert element.value_shape() == ()

def test_vector_galerkin():
for cell in all_cells:
Expand Down
1 change: 1 addition & 0 deletions ufl/finiteelement/elementlist.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ def show_elements():
register_element("Lagrange", "CG", 0, H1, "identity", (1, None), any_cell + ("OuterProductCell",)) # "P", "Q"
register_element("Brezzi-Douglas-Marini", "BDM", 1, HDiv, "contravariant Piola", (1, None), simplices[1:]) # "BDMF" (2d), "N2F" (3d)
register_element("Discontinuous Lagrange", "DG", 0, L2, "identity", (0, None), any_cell + ("OuterProductCell",)) # "DP", "DQ"
register_element("Discontinuous Taylor", "TDG", 0, L2, "identity", (0, None), ("interval",))
register_element("Nedelec 1st kind H(curl)", "N1curl", 1, HCurl, "covariant Piola", (1, None), simplices[1:]) # "RTE" (2d), "N1E" (3d)
register_element("Nedelec 2nd kind H(curl)", "N2curl", 1, HCurl, "covariant Piola", (1, None), simplices[1:]) # "BDME" (2d), "N2E" (3d)
register_element("Raviart-Thomas", "RT", 1, HDiv, "contravariant Piola", (1, None), simplices[1:]) # "RTF" (2d), "N1F" (3d)
Expand Down

0 comments on commit 00cf21a

Please sign in to comment.