From 2604b9194d3ccd3156125e0bda500e825eaf0cb7 Mon Sep 17 00:00:00 2001 From: Emma Cinatl Date: Wed, 18 Apr 2018 17:22:14 -0400 Subject: [PATCH] Add missing assert in do_integrate_difference Check number of components of exact_solution. --- include/deal.II/numerics/vector_tools.templates.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/include/deal.II/numerics/vector_tools.templates.h b/include/deal.II/numerics/vector_tools.templates.h index 6ac4f7d380..08954d19af 100644 --- a/include/deal.II/numerics/vector_tools.templates.h +++ b/include/deal.II/numerics/vector_tools.templates.h @@ -7245,7 +7245,10 @@ namespace VectorTools // on, if necessary, so have a read-write version of it: double exponent = exponent_1; - const unsigned int n_components = dof.get_fe(0).n_components(); + const unsigned int n_components = dof.get_fe(0).n_components(); + + Assert (exact_solution.n_components==n_components, + ExcDimensionMismatch(exact_solution.n_components, n_components)); if (weight!=nullptr) { -- 2.39.5