@@ -74,17 +74,21 @@ def __init__(self, ir, symbols, options):
7474 ufl .geometry .CellOrientation ,
7575 ufl .geometry .FacetOrientation }
7676
77- def get (self , t , mt , tabledata , quadrature_rule , access ):
77+ def get (self , mt , tabledata , quadrature_rule , access ):
7878 # Call appropriate handler, depending on the type of t
79- ttype = type (t )
79+
80+ terminal = mt .terminal
81+ ttype = type (terminal )
8082
8183 if ttype in self .do_nothing_set :
8284 return [], []
83- else :
85+ elif ttype in self . call_lookup :
8486 handler = self .call_lookup [ttype ]
85- return handler (t , mt , tabledata , quadrature_rule , access )
87+ return handler (mt , tabledata , quadrature_rule , access )
88+ else :
89+ raise NotImplementedError (f"No handler for terminal type: { ttype } " )
8690
87- def coefficient (self , t , mt , tabledata , quadrature_rule , access ):
91+ def coefficient (self , mt , tabledata , quadrature_rule , access ):
8892 """Return definition code for coefficients."""
8993 # For applying tensor product to coefficients, we need to know if the coefficient
9094 # has a tensor factorisation and if the quadrature rule has a tensor factorisation.
@@ -142,7 +146,7 @@ def coefficient(self, t, mt, tabledata, quadrature_rule, access):
142146
143147 return pre_code , code
144148
145- def _define_coordinate_dofs_lincomb (self , e , mt , tabledata , quadrature_rule , access ):
149+ def _define_coordinate_dofs_lincomb (self , mt , tabledata , quadrature_rule , access ):
146150 """Define x or J as a linear combination of coordinate dofs with given table data."""
147151 # Get properties of domain
148152 domain = ufl .domain .extract_unique_domain (mt .terminal )
@@ -182,7 +186,7 @@ def _define_coordinate_dofs_lincomb(self, e, mt, tabledata, quadrature_rule, acc
182186
183187 return [], code
184188
185- def spatial_coordinate (self , e , mt , tabledata , quadrature_rule , access ):
189+ def spatial_coordinate (self , mt , tabledata , quadrature_rule , access ):
186190 """Return definition code for the physical spatial coordinates.
187191
188192 If physical coordinates are given:
@@ -200,8 +204,8 @@ def spatial_coordinate(self, e, mt, tabledata, quadrature_rule, access):
200204 logging .exception ("FIXME: Jacobian in custom integrals is not implemented." )
201205 return []
202206 else :
203- return self ._define_coordinate_dofs_lincomb (e , mt , tabledata , quadrature_rule , access )
207+ return self ._define_coordinate_dofs_lincomb (mt , tabledata , quadrature_rule , access )
204208
205- def jacobian (self , e , mt , tabledata , quadrature_rule , access ):
209+ def jacobian (self , mt , tabledata , quadrature_rule , access ):
206210 """Return definition code for the Jacobian of x(X)."""
207- return self ._define_coordinate_dofs_lincomb (e , mt , tabledata , quadrature_rule , access )
211+ return self ._define_coordinate_dofs_lincomb (mt , tabledata , quadrature_rule , access )
0 commit comments