Skip to content

Commit 682c145

Browse files
committed
k
1 parent 8d4d320 commit 682c145

File tree

2 files changed

+11
-17
lines changed

2 files changed

+11
-17
lines changed

ufl/algorithms/apply_restrictions.py

-13
Original file line numberDiff line numberDiff line change
@@ -396,16 +396,3 @@ def make_domain_integral_type_map(integral_data):
396396
else:
397397
domain_integral_type_dict[integration_domain] = integration_type
398398
return domain_integral_type_dict
399-
400-
401-
def apply_restrictions_with_domain_integral_type_map(integral_data):
402-
"""Apply restrictions using domain_integral_type_map."""
403-
new_integrals = []
404-
for integral in integral_data.integrals:
405-
new_integral = apply_restrictions(
406-
integral,
407-
assume_single_integral_type=False,
408-
domain_integral_type_map=integral_data.domain_integral_type_map,
409-
)
410-
new_integrals.append(new_integral)
411-
return new_integrals

ufl/algorithms/compute_form_data.py

+11-4
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@
2525
from ufl.algorithms.apply_integral_scaling import apply_integral_scaling
2626
from ufl.algorithms.apply_restrictions import (
2727
apply_restrictions,
28-
apply_restrictions_with_domain_integral_type_map,
2928
make_domain_integral_type_map,
3029
)
3130
from ufl.algorithms.check_arities import check_form_arity
@@ -499,9 +498,17 @@ def compute_form_data(
499498
""")
500499
for itg_data in self.integral_data:
501500
# Must have split coefficients and removed component/list tensors.
502-
itg_data.domain_integral_type_map = make_domain_integral_type_map(itg_data)
503-
itg_data.integrals = apply_restrictions_with_domain_integral_type_map(itg_data)
504-
501+
domain_integral_type_map = make_domain_integral_type_map(itg_data)
502+
new_integrals = []
503+
for integral in itg_data.integrals:
504+
new_integral = apply_restrictions(
505+
integral,
506+
assume_single_integral_type=False,
507+
domain_integral_type_map=domain_integral_type_map,
508+
)
509+
new_integrals.append(new_integral)
510+
itg_data.domain_integral_type_map = domain_integral_type_map
511+
itg_data.integrals = new_integrals
505512
# --- Checks
506513
_check_elements(self)
507514
_check_facet_geometry(self.integral_data)

0 commit comments

Comments
 (0)