From f9ea2eaf21a33476f5968d00410ec205aefb36a6 Mon Sep 17 00:00:00 2001 From: Ralf Hartmann Date: Thu, 20 Jul 2000 11:29:34 +0000 Subject: [PATCH] Fix: Include missing assertions in ::get_function_values (const InputVector &fe_function, ExcIndexRange (selected_dataset, 0, shape_values.size())); Assert (values.size() == n_quadrature_points, ExcWrongVectorSize(values.size(), n_quadrature_points)); + Assert (update_flags & update_values, ExcAccessToUninitializedField()); // get function values of dofs // on this cell @@ -119,6 +120,7 @@ void FEValuesBase::get_function_values (const InputVector &fe_functio for (unsigned i=0;in_components(), ExcWrongNoOfComponents()); + Assert (update_flags & update_values, ExcAccessToUninitializedField()); // get function values of dofs // on this cell @@ -167,6 +169,7 @@ void FEValuesBase::get_function_grads (const InputVector &fe_function, ExcWrongNoOfComponents()); Assert (gradients.size() == n_quadrature_points, ExcWrongVectorSize(gradients.size(), n_quadrature_points)); + Assert (update_flags & update_gradients, ExcAccessToUninitializedField()); // get function values of dofs // on this cell @@ -204,6 +207,7 @@ void FEValuesBase::get_function_grads (const InputVector &fe_ for (unsigned i=0;in_components(), ExcWrongVectorSize(gradients[i].size(), fe->n_components())); + Assert (update_flags & update_gradients, ExcAccessToUninitializedField()); // get function values of dofs // on this cell @@ -256,6 +260,7 @@ void FEValuesBase::get_function_2nd_derivatives (const InputVector &fe ExcWrongNoOfComponents()); Assert (second_derivatives.size() == n_quadrature_points, ExcWrongVectorSize(second_derivatives.size(), n_quadrature_points)); + Assert (update_flags & update_second_derivatives, ExcAccessToUninitializedField()); // get function values of dofs // on this cell diff --git a/deal.II/deal.II/source/numerics/data_out.cc b/deal.II/deal.II/source/numerics/data_out.cc index d9940c5076..7cb4d6fe3c 100644 --- a/deal.II/deal.II/source/numerics/data_out.cc +++ b/deal.II/deal.II/source/numerics/data_out.cc @@ -211,7 +211,7 @@ void DataOut::build_some_patches (Data data) FEValues fe_patch_values(dofs->get_fe(), patch_points, - update_default); + update_values); const unsigned int n_q_points = patch_points.n_quadrature_points; -- 2.39.5