From: hartmann Date: Mon, 26 Mar 2001 16:03:17 +0000 (+0000) Subject: Need to collect flags twice, see example in doc. X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ced256765c3df89b1ff9fe7a076357a0e5599461;p=dealii-svn.git Need to collect flags twice, see example in doc. git-svn-id: https://svn.dealii.org/trunk@4293 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/deal.II/source/fe/fe_values.cc b/deal.II/deal.II/source/fe/fe_values.cc index 091f6ff4cd..5dc087bc7c 100644 --- a/deal.II/deal.II/source/fe/fe_values.cc +++ b/deal.II/deal.II/source/fe/fe_values.cc @@ -635,6 +635,29 @@ FEFaceValues::FEFaceValues (const Mapping &mapping, mapping_data = mapping.get_face_data(flags, quadrature); fe_data = fe.get_face_data(flags, mapping, quadrature); + // The get_face_data functions + // might have added an update flag. + // Therefore collect all flags + // again. + // + // E.g. if update_JxW_values is set + // the update_boundary_forms flag + // is added within the + // Mapping::get_face_data function. + // If also update_normal_vectors is + // set this update_boundary_forms + // flag was already set by the + // update_once or update_each + // function resulting in no change + // in flags below, but if + // update_normal_vectors is not set + // this actually makes a + // difference. + flags |= mapping_data->update_once + | mapping_data->update_each + | fe_data->update_once + | fe_data->update_each; + // set up objects within this class FEValuesData::initialize(n_quadrature_points, dofs_per_cell, @@ -673,7 +696,30 @@ FEFaceValues::FEFaceValues (const FiniteElement &fe, // calls to reinit mapping_data = mapping->get_face_data(flags, quadrature); fe_data = fe.get_face_data(flags, *mapping, quadrature); - + + // The get_face_data functions + // might have added an update flag. + // Therefore collect all flags + // again. + // + // E.g. if update_JxW_values is set + // the update_boundary_forms flag + // is added within the + // Mapping::get_face_data function. + // If also update_normal_vectors is + // set this update_boundary_forms + // flag was already set by the + // update_once or update_each + // function resulting in no change + // in flags below, but if + // update_normal_vectors is not set + // this actually makes a + // difference. + flags |= mapping_data->update_once + | mapping_data->update_each + | fe_data->update_once + | fe_data->update_each; + // set up objects within this class FEValuesData::initialize(n_quadrature_points, dofs_per_cell, @@ -752,6 +798,30 @@ FESubfaceValues::FESubfaceValues (const Mapping &mapping, mapping_data = mapping.get_subface_data(flags, quadrature); fe_data = fe.get_subface_data(flags, mapping, quadrature); + + // The get_face_data functions + // might have added an update flag. + // Therefore collect all flags + // again. + // + // E.g. if update_JxW_values is set + // the update_boundary_forms flag + // is added within the + // Mapping::get_face_data function. + // If also update_normal_vectors is + // set this update_boundary_forms + // flag was already set by the + // update_once or update_each + // function resulting in no change + // in flags below, but if + // update_normal_vectors is not set + // this actually makes a + // difference. + flags |= mapping_data->update_once + | mapping_data->update_each + | fe_data->update_once + | fe_data->update_each; + // set up objects within this class FEValuesData::initialize(n_quadrature_points, dofs_per_cell, @@ -791,6 +861,29 @@ FESubfaceValues::FESubfaceValues (const FiniteElement &fe, // calls to reinit mapping_data = mapping->get_subface_data(flags, quadrature); fe_data = fe.get_subface_data(flags, *mapping, quadrature); + + // The get_face_data functions + // might have added an update flag. + // Therefore collect all flags + // again. + // + // E.g. if update_JxW_values is set + // the update_boundary_forms flag + // is added within the + // Mapping::get_face_data function. + // If also update_normal_vectors is + // set this update_boundary_forms + // flag was already set by the + // update_once or update_each + // function resulting in no change + // in flags below, but if + // update_normal_vectors is not set + // this actually makes a + // difference. + flags |= mapping_data->update_once + | mapping_data->update_each + | fe_data->update_once + | fe_data->update_each; // set up objects within this class FEValuesData::initialize(n_quadrature_points,