Skip to content

Commit 9c8ac56

Browse files
committed
API changes from: FEniCS/dolfinx#3500
1 parent b6318c4 commit 9c8ac56

3 files changed

Lines changed: 5 additions & 6 deletions

File tree

cpp/PeriodicConstraint.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,8 @@ dolfinx_mpc::mpc_data<T> _create_periodic_condition(
6565
parents_glob[i] = parents_glob[i] * bs + parent_rems[i];
6666
return parents_glob;
6767
};
68-
if (const std::size_t value_size = V.value_size() / V.element()->block_size();
68+
if (const std::size_t value_size
69+
= V.element()->reference_value_size() / V.element()->block_size();
6970
value_size > 1)
7071
throw std::runtime_error(
7172
"Periodic conditions for vector valued spaces are not "

cpp/mpc_helpers.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -231,10 +231,7 @@ create_extended_functionspace(const dolfinx::fem::FunctionSpace<U>& V,
231231
old_dofmap.element_dof_layout(), new_index_map, old_dofmap.bs(),
232232
std::move(flattened_dofmap), old_dofmap.bs());
233233

234-
return dolfinx::fem::FunctionSpace(
235-
V.mesh(), element, new_dofmap,
236-
dolfinx::fem::compute_value_shape(element, V.mesh()->topology()->dim(),
237-
V.mesh()->geometry().dim()));
234+
return dolfinx::fem::FunctionSpace(V.mesh(), element, new_dofmap);
238235
}
239236

240237
} // namespace dolfinx_mpc

cpp/utils.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1026,7 +1026,8 @@ evaluate_basis_functions(const dolfinx::fem::FunctionSpace<U>& V,
10261026

10271027
assert(basis_shape[2]
10281028
== std::size_t(element->space_dimension() / bs_element));
1029-
assert(basis_shape[3] == std::size_t(V.value_size() / bs_element));
1029+
assert(basis_shape[3]
1030+
== std::size_t(element->reference_value_size() / bs_element));
10301031
std::array<std::size_t, 3> reference_shape
10311032
= {basis_shape[1], basis_shape[2], basis_shape[3]};
10321033
std::vector<U> output_basis(std::reduce(

0 commit comments

Comments
 (0)