Skip to content

Commit

Permalink
#220 make time_partition deepcopy for enriched_mesh_seq
Browse files Browse the repository at this point in the history
  • Loading branch information
acse-ej321 committed Oct 24, 2024
1 parent 1ae9535 commit 2c9cf5a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion goalie/go_mesh_seq.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"""

from collections.abc import Iterable
from copy import deepcopy

import numpy as np
import ufl
Expand Down Expand Up @@ -61,9 +62,12 @@ def get_enriched_mesh_seq(self, enrichment_method="p", num_enrichments=1):
else:
meshes = self.meshes

# Create copy of time_partition
time_partition = deepcopy(self.time_partition)

# Construct object to hold enriched spaces
enriched_mesh_seq = type(self)(
self.time_partition,
time_partition,
meshes,
get_function_spaces=self._get_function_spaces,
get_initial_condition=self._get_initial_condition,
Expand Down

0 comments on commit 2c9cf5a

Please sign in to comment.