Skip to content

Commit 65406dd

Browse files
committed
k
1 parent d66f3f8 commit 65406dd

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
@@ -503,9 +502,17 @@ def compute_form_data(
503502
""")
504503
for itg_data in self.integral_data:
505504
# Must have split coefficients and removed component/list tensors.
506-
itg_data.domain_integral_type_map = make_domain_integral_type_map(itg_data)
507-
itg_data.integrals = apply_restrictions_with_domain_integral_type_map(itg_data)
508-
505+
domain_integral_type_map = make_domain_integral_type_map(itg_data)
506+
new_integrals = []
507+
for integral in itg_data.integrals:
508+
new_integral = apply_restrictions(
509+
integral,
510+
assume_single_integral_type=False,
511+
domain_integral_type_map=domain_integral_type_map,
512+
)
513+
new_integrals.append(new_integral)
514+
itg_data.domain_integral_type_map = domain_integral_type_map
515+
itg_data.integrals = new_integrals
509516
# --- Checks
510517
_check_elements(self)
511518
_check_facet_geometry(self.integral_data)

0 commit comments

Comments
 (0)