From cfb5ac8b76dfac27fd43bda89aebe4419285a48a Mon Sep 17 00:00:00 2001 From: Guido Kanschat Date: Fri, 12 Oct 2007 16:58:46 +0000 Subject: [PATCH] new UpdateFlags git-svn-id: https://svn.dealii.org/trunk@15304 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/deal.II/include/fe/fe.h | 2 +- deal.II/deal.II/include/fe/fe_update_flags.h | 25 ++++++++++++++++- deal.II/deal.II/include/fe/fe_values.h | 24 ++++++++++++++-- deal.II/deal.II/include/fe/mapping_q1.h | 6 ++-- .../include/numerics/vectors.templates.h | 14 +++++----- deal.II/deal.II/source/dofs/dof_tools.cc | 2 +- .../deal.II/source/fe/fe_dgp_nonparametric.cc | 8 +++--- deal.II/deal.II/source/fe/fe_tools.cc | 10 +++---- deal.II/deal.II/source/fe/fe_values.cc | 2 +- .../deal.II/source/fe/mapping_cartesian.cc | 4 +-- deal.II/deal.II/source/fe/mapping_q1.cc | 10 +++---- deal.II/deal.II/source/numerics/data_out.cc | 2 +- .../source/numerics/data_out_rotation.cc | 2 +- .../numerics/derivative_approximation.cc | 2 +- .../source/numerics/error_estimator.cc | 2 +- deal.II/deal.II/source/numerics/matrices.cc | 28 +++++++++---------- deal.II/doc/news/changes.h | 7 +++++ deal.II/examples/step-12/step-12.cc | 8 +++--- deal.II/examples/step-13/step-13.cc | 2 +- deal.II/examples/step-14/step-14.cc | 8 +++--- deal.II/examples/step-15/step-15.cc | 8 +++--- deal.II/examples/step-16/step-16.cc | 6 ++-- deal.II/examples/step-17/step-17.cc | 4 +-- deal.II/examples/step-18/step-18.cc | 4 +-- deal.II/examples/step-20/step-20.cc | 4 +-- deal.II/examples/step-21/step-21.cc | 8 +++--- deal.II/examples/step-22/step-22.cc | 8 +++--- deal.II/examples/step-25/step-25.cc | 4 +-- deal.II/examples/step-27/step-27.cc | 2 +- deal.II/examples/step-28/step-28.cc | 2 +- deal.II/examples/step-4/step-4.cc | 4 +-- deal.II/examples/step-5/step-5.cc | 2 +- deal.II/examples/step-6/step-6.cc | 2 +- deal.II/examples/step-7/step-7.cc | 4 +-- deal.II/examples/step-8/step-8.cc | 4 +-- deal.II/examples/step-9/step-9.cc | 6 ++-- 36 files changed, 145 insertions(+), 95 deletions(-) diff --git a/deal.II/deal.II/include/fe/fe.h b/deal.II/deal.II/include/fe/fe.h index 12dca24fcc..3289428d07 100644 --- a/deal.II/deal.II/include/fe/fe.h +++ b/deal.II/deal.II/include/fe/fe.h @@ -95,7 +95,7 @@ namespace hp * @code * Quadrature dummy_quadrature (fe.get_unit_support_points()); * FEValues fe_values (mapping, fe, dummy_quadrature, - * update_q_points); + * update_quadrature_points); * fe_values.reinit (cell); * Point& mapped_point = fe_values.quadrature_point (i); * @endcode diff --git a/deal.II/deal.II/include/fe/fe_update_flags.h b/deal.II/deal.II/include/fe/fe_update_flags.h index 51be7bd88f..0d60c43819 100644 --- a/deal.II/deal.II/include/fe/fe_update_flags.h +++ b/deal.II/deal.II/include/fe/fe_update_flags.h @@ -127,7 +127,7 @@ enum UpdateFlags * points transformed into real * cell coordinates. */ - update_q_points = 0x0010, + update_quadrature_points = 0x0010, //! Transformed quadrature weights /** * Compute the quadrature @@ -212,6 +212,29 @@ enum UpdateFlags * H_div subspaces like RT and ABF. */ update_cell_JxW_values = 0x2000, + /** + * Update the location of the + * mapped generalized support + * points of the element. + */ + update_support_points = 0x4000, + /** + * Update the Jacobian of the + * mapping in generalized + * support points. + */ + update_support_jacobians = 0x8000, + /** + * Update the inverse Jacobian + * of the mapping in + * generalized support points. + */ + update_support_inverse_jacobians = 0x10000, + /** + * @deprecated Update + * quadrature points + */ + update_q_points = update_quadrature_points, /** * @deprecated Update second * derivatives. diff --git a/deal.II/deal.II/include/fe/fe_values.h b/deal.II/deal.II/include/fe/fe_values.h index 02296098a9..45d814b666 100644 --- a/deal.II/deal.II/include/fe/fe_values.h +++ b/deal.II/deal.II/include/fe/fe_values.h @@ -233,6 +233,26 @@ class FEValuesData */ std::vector > boundary_forms; + /** + * Array of the mapped support + * points, filled by Mapping. + */ + std::vector > support_points; + + /** + * Array of the Jacobian of the + * mapping in the support points, + * filled by Mapping. + */ + HessianVector support_jacobians; + + /** + * Array of the inverse Jacobian of the + * mapping in the support points, + * filled by Mapping. + */ + HessianVector support_inverse_jacobians; + /** * Indicate the first row which a * given shape function occupies @@ -2765,7 +2785,7 @@ inline const std::vector > & FEValuesBase::get_quadrature_points () const { - Assert (this->update_flags & update_q_points, ExcAccessToUninitializedField()); + Assert (this->update_flags & update_quadrature_points, ExcAccessToUninitializedField()); return this->quadrature_points; } @@ -2787,7 +2807,7 @@ inline const Point & FEValuesBase::quadrature_point (const unsigned int i) const { - Assert (this->update_flags & update_q_points, ExcAccessToUninitializedField()); + Assert (this->update_flags & update_quadrature_points, ExcAccessToUninitializedField()); Assert (iquadrature_points.size(), ExcIndexRange(i, 0, this->quadrature_points.size())); return this->quadrature_points[i]; diff --git a/deal.II/deal.II/include/fe/mapping_q1.h b/deal.II/deal.II/include/fe/mapping_q1.h index 875f355a0c..1c8dbf7cfd 100644 --- a/deal.II/deal.II/include/fe/mapping_q1.h +++ b/deal.II/deal.II/include/fe/mapping_q1.h @@ -125,7 +125,7 @@ class MappingQ1 : public Mapping * * Description of effects: *
    - *
  • if @p update_q_points + *
  • if @p update_quadrature_points * is required, the output will * contain * @p update_transformation_values. This @@ -156,7 +156,7 @@ class MappingQ1 : public Mapping * Description of effects if * @p flags contains: *
      - *
    • update_q_points is + *
    • update_quadrature_points is * copied to the output to * compute the quadrature points * on the real cell. @@ -291,7 +291,7 @@ class MappingQ1 : public Mapping std::vector > covariant; /** - * Tensors of covariant + * Tensors of contravariant * transformation at each of * the quadrature points. The * contravariant matrix is diff --git a/deal.II/deal.II/include/numerics/vectors.templates.h b/deal.II/deal.II/include/numerics/vectors.templates.h index f41a1d13b6..804cb2d158 100644 --- a/deal.II/deal.II/include/numerics/vectors.templates.h +++ b/deal.II/deal.II/include/numerics/vectors.templates.h @@ -174,7 +174,7 @@ void VectorTools::interpolate (const Mapping &mapping, hp::MappingCollection mapping_collection (mapping); hp::FEValues fe_values (mapping_collection, - fe, support_quadrature, update_q_points); + fe, support_quadrature, update_quadrature_points); for (; cell!=endc; ++cell) { @@ -516,7 +516,7 @@ void VectorTools::create_right_hand_side (const Mapping &mapping, rhs_vector = 0; UpdateFlags update_flags = UpdateFlags(update_values | - update_q_points | + update_quadrature_points | update_JxW_values); FEValues fe_values (mapping, fe, quadrature, update_flags); @@ -641,7 +641,7 @@ void VectorTools::create_right_hand_side (const hp::MappingCollection &m rhs_vector = 0; UpdateFlags update_flags = UpdateFlags(update_values | - update_q_points | + update_quadrature_points | update_JxW_values); hp::FEValues x_fe_values (mapping, fe, quadrature, update_flags); @@ -877,7 +877,7 @@ VectorTools::create_boundary_right_hand_side (const Mapping &mapping, rhs_vector = 0; UpdateFlags update_flags = UpdateFlags(update_values | - update_q_points | + update_quadrature_points | update_JxW_values); FEFaceValues fe_values (mapping, fe, quadrature, update_flags); @@ -1033,7 +1033,7 @@ VectorTools::create_boundary_right_hand_side (const hp::MappingCollection rhs_vector = 0; UpdateFlags update_flags = UpdateFlags(update_values | - update_q_points | + update_quadrature_points | update_JxW_values); hp::FEFaceValues x_fe_values (mapping, fe, quadrature, update_flags); @@ -1433,7 +1433,7 @@ interpolate_boundary_values (const Mapping &mapping, } Quadrature aux_quad (unit_support_points); - FEFaceValues fe_values (mapping, fe, aux_quad, update_q_points); + FEFaceValues fe_values (mapping, fe, aux_quad, update_quadrature_points); //TODO[?] End of inefficient code // get indices, physical location and @@ -1829,7 +1829,7 @@ namespace internal break; } - UpdateFlags update_flags = UpdateFlags (update_q_points | + UpdateFlags update_flags = UpdateFlags (update_quadrature_points | update_JxW_values); switch (norm) { diff --git a/deal.II/deal.II/source/dofs/dof_tools.cc b/deal.II/deal.II/source/dofs/dof_tools.cc index 7941d4a141..93a330a899 100644 --- a/deal.II/deal.II/source/dofs/dof_tools.cc +++ b/deal.II/deal.II/source/dofs/dof_tools.cc @@ -4845,7 +4845,7 @@ DoFTools::map_dofs_to_support_points (const Mapping &mapping, // by the used constructor. Quadrature q_dummy(dof_handler.get_fe().get_unit_support_points()); FEValues fe_values (mapping, dof_handler.get_fe(), - q_dummy, update_q_points); + q_dummy, update_quadrature_points); typename DoFHandler::active_cell_iterator cell = dof_handler.begin_active(), endc = dof_handler.end(); diff --git a/deal.II/deal.II/source/fe/fe_dgp_nonparametric.cc b/deal.II/deal.II/source/fe/fe_dgp_nonparametric.cc index ce7e2266f3..f36d8ae490 100644 --- a/deal.II/deal.II/source/fe/fe_dgp_nonparametric.cc +++ b/deal.II/deal.II/source/fe/fe_dgp_nonparametric.cc @@ -213,7 +213,7 @@ FE_DGPNonparametric::update_each (const UpdateFlags flags) const UpdateFlags out = flags; if (flags & (update_values | update_gradients | update_hessians)) - out |= update_q_points ; + out |= update_quadrature_points ; return out; } @@ -285,7 +285,7 @@ FE_DGPNonparametric::fill_fe_values ( InternalData &fe_data = dynamic_cast (fedata); const UpdateFlags flags(fe_data.current_update_flags()); - Assert (flags & update_q_points, ExcInternalError()); + Assert (flags & update_quadrature_points, ExcInternalError()); const unsigned int n_q_points = data.quadrature_points.size(); @@ -326,7 +326,7 @@ FE_DGPNonparametric::fill_fe_face_values ( InternalData &fe_data = dynamic_cast (fedata); const UpdateFlags flags(fe_data.update_once | fe_data.update_each); - Assert (flags & update_q_points, ExcInternalError()); + Assert (flags & update_quadrature_points, ExcInternalError()); const unsigned int n_q_points = data.quadrature_points.size(); @@ -368,7 +368,7 @@ FE_DGPNonparametric::fill_fe_subface_values ( InternalData &fe_data = dynamic_cast (fedata); const UpdateFlags flags(fe_data.update_once | fe_data.update_each); - Assert (flags & update_q_points, ExcInternalError()); + Assert (flags & update_quadrature_points, ExcInternalError()); const unsigned int n_q_points = data.quadrature_points.size(); diff --git a/deal.II/deal.II/source/fe/fe_tools.cc b/deal.II/deal.II/source/fe/fe_tools.cc index 668b0b1ed4..f3f21ea26d 100644 --- a/deal.II/deal.II/source/fe/fe_tools.cc +++ b/deal.II/deal.II/source/fe/fe_tools.cc @@ -485,7 +485,7 @@ void FETools::get_projection_matrix (const FiniteElement &fe1, QGauss quadrature(degree+1); // Set up FEValues. - const UpdateFlags flags = update_values | update_q_points | update_JxW_values; + const UpdateFlags flags = update_values | update_quadrature_points | update_JxW_values; FEValues val1 (fe1, quadrature, update_values); val1.reinit (tr.begin_active()); FEValues val2 (fe2, quadrature, flags); @@ -609,7 +609,7 @@ FETools::compute_embedding_matrices(const FiniteElement& fe, const unsigned int nq = q_fine.n_quadrature_points; FEValues fine (mapping, fe, q_fine, - update_q_points | update_JxW_values | update_values); + update_quadrature_points | update_JxW_values | update_values); // We search for the polynomial on // the small cell, being equal to @@ -781,7 +781,7 @@ FETools::compute_face_embedding_matrices(const FiniteElement& fe, Assert (k == fe.dofs_per_face, ExcInternalError()); FEValues fine (mapping, fe, q_fine, - update_q_points | update_JxW_values | update_values); + update_quadrature_points | update_JxW_values | update_values); // We search for the polynomial on // the small cell, being equal to @@ -888,9 +888,9 @@ FETools::compute_projection_matrices(const FiniteElement& fe, const unsigned int nq = q_fine.n_quadrature_points; FEValues coarse (mapping, fe, q_fine, - update_q_points | update_JxW_values | update_values); + update_quadrature_points | update_JxW_values | update_values); FEValues fine (mapping, fe, q_fine, - update_q_points | update_JxW_values | update_values); + update_quadrature_points | update_JxW_values | update_values); typename Triangulation::cell_iterator coarse_cell = tr.begin(0); diff --git a/deal.II/deal.II/source/fe/fe_values.cc b/deal.II/deal.II/source/fe/fe_values.cc index 20ce6c9488..ea1be93b8e 100644 --- a/deal.II/deal.II/source/fe/fe_values.cc +++ b/deal.II/deal.II/source/fe/fe_values.cc @@ -302,7 +302,7 @@ FEValuesData::initialize (const unsigned int n_quadrature_points, this->shape_hessians.resize (n_nonzero_shape_components, std::vector > (n_quadrature_points)); - if (flags & update_q_points) + if (flags & update_quadrature_points) this->quadrature_points.resize(n_quadrature_points); if (flags & update_JxW_values) diff --git a/deal.II/deal.II/source/fe/mapping_cartesian.cc b/deal.II/deal.II/source/fe/mapping_cartesian.cc index 5a114c3bc5..be00a08b44 100644 --- a/deal.II/deal.II/source/fe/mapping_cartesian.cc +++ b/deal.II/deal.II/source/fe/mapping_cartesian.cc @@ -2,7 +2,7 @@ // $Id$ // Version: $Name$ // -// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006 by the deal.II authors +// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007 by the deal.II authors // // This file is subject to QPL and may not be distributed // without copyright and license information. Please refer @@ -193,7 +193,7 @@ MappingCartesian::compute_fill (const typename Triangulation::cell_ite // is obtained simply by scaling // unit coordinates with lengths in // each direction - if (update_flags & update_q_points) + if (update_flags & update_quadrature_points) { const typename QProjector::DataSetDescriptor offset = (face_no == invalid_face_number diff --git a/deal.II/deal.II/source/fe/mapping_q1.cc b/deal.II/deal.II/source/fe/mapping_q1.cc index 991f94258a..180a2847d0 100644 --- a/deal.II/deal.II/source/fe/mapping_q1.cc +++ b/deal.II/deal.II/source/fe/mapping_q1.cc @@ -2,7 +2,7 @@ // $Id$ // Version: $Name$ // -// Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006 by the deal.II authors +// Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 by the deal.II authors // // This file is subject to QPL and may not be distributed // without copyright and license information. Please refer @@ -224,7 +224,7 @@ MappingQ1::update_once (const UpdateFlags in) const | update_transformation_gradients)); // Shape function values - if (in & update_q_points) + if (in & update_quadrature_points) out |= update_transformation_values; // Shape function gradients @@ -246,7 +246,7 @@ MappingQ1::update_each (const UpdateFlags in) const { // Select flags of concern for the // transformation. - UpdateFlags out = UpdateFlags(in & (update_q_points + UpdateFlags out = UpdateFlags(in & (update_quadrature_points | update_covariant_transformation | update_contravariant_transformation | update_JxW_values @@ -465,7 +465,7 @@ MappingQ1::compute_fill (const typename Triangulation::cell_iterator & { const UpdateFlags update_flags(data.current_update_flags()); - if (update_flags & update_q_points) + if (update_flags & update_quadrature_points) { Assert (quadrature_points.size() == n_q_points, ExcDimensionMismatch(quadrature_points.size(), n_q_points)); @@ -517,7 +517,7 @@ MappingQ1::compute_fill (const typename Triangulation::cell_iterator & } // first compute quadrature points - if (update_flags & update_q_points) + if (update_flags & update_quadrature_points) for (unsigned int point=0; point::build_some_patches (Data &data) const hp::FECollection fe_collection(this->dofs->get_fe()); const hp::MappingCollection mapping_collection(*(data.mapping)); - UpdateFlags update_flags=update_values | update_q_points; + UpdateFlags update_flags=update_values | update_quadrature_points; for (unsigned int i=0; idof_data.size(); ++i) if (this->dof_data[i]->postprocessor) update_flags |= this->dof_data[i]->postprocessor->get_needed_update_flags(); diff --git a/deal.II/deal.II/source/numerics/data_out_rotation.cc b/deal.II/deal.II/source/numerics/data_out_rotation.cc index 8522216cfa..9c0bc192bc 100644 --- a/deal.II/deal.II/source/numerics/data_out_rotation.cc +++ b/deal.II/deal.II/source/numerics/data_out_rotation.cc @@ -64,7 +64,7 @@ void DataOutRotation::build_some_patches (Data &data) const hp::QCollection q_collection (patch_points); const hp::FECollection fe_collection(this->dofs->get_fe()); - UpdateFlags update_flags=update_values | update_q_points; + UpdateFlags update_flags=update_values | update_quadrature_points; for (unsigned int i=0; idof_data.size(); ++i) if (this->dof_data[i]->postprocessor) update_flags |= this->dof_data[i]->postprocessor->get_needed_update_flags(); diff --git a/deal.II/deal.II/source/numerics/derivative_approximation.cc b/deal.II/deal.II/source/numerics/derivative_approximation.cc index b18073592f..eb7ae49d6f 100644 --- a/deal.II/deal.II/source/numerics/derivative_approximation.cc +++ b/deal.II/deal.II/source/numerics/derivative_approximation.cc @@ -726,7 +726,7 @@ approximate_cell (const Mapping &mapping, hp::FEValues x_fe_midpoint_value (mapping_collection, fe_collection, q_collection, DerivativeDescription::update_flags | - update_q_points); + update_quadrature_points); // matrix Y=sum_i y_i y_i^T Tensor<2,dim> Y; diff --git a/deal.II/deal.II/source/numerics/error_estimator.cc b/deal.II/deal.II/source/numerics/error_estimator.cc index 8db67f5a86..5dec7d989a 100644 --- a/deal.II/deal.II/source/numerics/error_estimator.cc +++ b/deal.II/deal.II/source/numerics/error_estimator.cc @@ -680,7 +680,7 @@ estimate_some (const hp::MappingCollection &mapping, update_JxW_values | ((!neumann_bc.empty() || (coefficients != 0)) ? - update_q_points : 0) | + update_quadrature_points : 0) | update_normal_vectors)); hp::FEFaceValues fe_face_values_neighbor (mapping, fe, diff --git a/deal.II/deal.II/source/numerics/matrices.cc b/deal.II/deal.II/source/numerics/matrices.cc index 8c2fc1d32f..0a413667fe 100644 --- a/deal.II/deal.II/source/numerics/matrices.cc +++ b/deal.II/deal.II/source/numerics/matrices.cc @@ -119,7 +119,7 @@ void MatrixCreator::create_mass_matrix_1 (const Mapping &mapping, { UpdateFlags update_flags = UpdateFlags(update_values | update_JxW_values); if (coefficient != 0) - update_flags = UpdateFlags (update_flags | update_q_points); + update_flags = UpdateFlags (update_flags | update_quadrature_points); FEValues fe_values (mapping, dof.get_fe(), q, update_flags); @@ -370,10 +370,10 @@ MatrixCreator::create_mass_matrix_2 (const Mapping &mapping, Threads::ThreadMutex &mutex) { UpdateFlags update_flags = UpdateFlags(update_values | - update_q_points | + update_quadrature_points | update_JxW_values); if (coefficient != 0) - update_flags = UpdateFlags (update_flags | update_q_points); + update_flags = UpdateFlags (update_flags | update_quadrature_points); FEValues fe_values (mapping, dof.get_fe(), q, update_flags); @@ -564,7 +564,7 @@ MatrixCreator::create_mass_matrix_1 (const hp::MappingCollection &map UpdateFlags update_flags = UpdateFlags(update_values | update_JxW_values); if (coefficient != 0) - update_flags = UpdateFlags (update_flags | update_q_points); + update_flags = UpdateFlags (update_flags | update_quadrature_points); hp::FEValues x_fe_values (mapping, dof.get_fe(), q, update_flags); @@ -755,10 +755,10 @@ MatrixCreator::create_mass_matrix_2 (const hp::MappingCollection &map Threads::ThreadMutex &mutex) { UpdateFlags update_flags = UpdateFlags(update_values | - update_q_points | + update_quadrature_points | update_JxW_values); if (coefficient != 0) - update_flags = UpdateFlags (update_flags | update_q_points); + update_flags = UpdateFlags (update_flags | update_quadrature_points); hp::FEValues x_fe_values (mapping, dof.get_fe(), q, update_flags); @@ -1030,7 +1030,7 @@ create_boundary_mass_matrix_1 (const Mapping &mapping, UpdateFlags update_flags = UpdateFlags (update_values | update_JxW_values | - update_q_points); + update_quadrature_points); FEFaceValues fe_values (mapping, fe, q, update_flags); // two variables for the coefficient, @@ -1404,7 +1404,7 @@ create_boundary_mass_matrix_1 (const hp::MappingCollection &mapping, UpdateFlags update_flags = UpdateFlags (update_values | update_JxW_values | - update_q_points); + update_quadrature_points); hp::FEFaceValues x_fe_values (mapping, fe_collection, q, update_flags); // two variables for the coefficient, @@ -1802,7 +1802,7 @@ void MatrixCreator::create_laplace_matrix_1 (const Mapping &mapping, UpdateFlags update_flags = UpdateFlags(update_JxW_values | update_gradients); if (coefficient != 0) - update_flags = UpdateFlags (update_flags | update_q_points); + update_flags = UpdateFlags (update_flags | update_quadrature_points); FEValues fe_values (mapping, dof.get_fe(), q, update_flags); @@ -1987,10 +1987,10 @@ MatrixCreator::create_laplace_matrix_2 (const Mapping &mapping, { UpdateFlags update_flags = UpdateFlags(update_values | update_gradients | - update_q_points | + update_quadrature_points | update_JxW_values); if (coefficient != 0) - update_flags = UpdateFlags (update_flags | update_q_points); + update_flags = UpdateFlags (update_flags | update_quadrature_points); FEValues fe_values (mapping, dof.get_fe(), q, update_flags); @@ -2184,7 +2184,7 @@ MatrixCreator::create_laplace_matrix_1 (const hp::MappingCollection & UpdateFlags update_flags = UpdateFlags(update_gradients | update_JxW_values); if (coefficient != 0) - update_flags = UpdateFlags (update_flags | update_q_points); + update_flags = UpdateFlags (update_flags | update_quadrature_points); hp::FEValues x_fe_values (mapping, dof.get_fe(), q, update_flags); @@ -2376,10 +2376,10 @@ MatrixCreator::create_laplace_matrix_2 (const hp::MappingCollection & { UpdateFlags update_flags = UpdateFlags(update_values | update_gradients | - update_q_points | + update_quadrature_points | update_JxW_values); if (coefficient != 0) - update_flags = UpdateFlags (update_flags | update_q_points); + update_flags = UpdateFlags (update_flags | update_quadrature_points); hp::FEValues x_fe_values (mapping, dof.get_fe(), q, update_flags); diff --git a/deal.II/doc/news/changes.h b/deal.II/doc/news/changes.h index 2f43dbb3ec..5d4b13d83f 100644 --- a/deal.II/doc/news/changes.h +++ b/deal.II/doc/news/changes.h @@ -114,6 +114,13 @@ inconvenience this causes.
        +
      1. Improved: UpdateFlags::update_q_points has been renamed to + UpdateFlags::update_quadrature_points. Additional update flags for support + points have been added without functionality, yet. +
        + (GK 2007/10/12) +

      2. +
      3. Improved: The number of blocks of an FESystem was properly defined and the constructors changed accordingly. At least non of the test programs noticed the change.
        diff --git a/deal.II/examples/step-12/step-12.cc b/deal.II/examples/step-12/step-12.cc index b0fb0ed238..d0cfed4547 100644 --- a/deal.II/examples/step-12/step-12.cc +++ b/deal.II/examples/step-12/step-12.cc @@ -746,14 +746,14 @@ void DGMethod::assemble_system1 () // FEFaceValues objects. const UpdateFlags update_flags = update_values | update_gradients - | update_q_points + | update_quadrature_points | update_JxW_values; // Note, that on faces we do not // need gradients but we need // normal vectors. const UpdateFlags face_update_flags = update_values - | update_q_points + | update_quadrature_points | update_JxW_values | update_normal_vectors; @@ -1213,11 +1213,11 @@ void DGMethod::assemble_system2 () const UpdateFlags update_flags = update_values | update_gradients - | update_q_points + | update_quadrature_points | update_JxW_values; const UpdateFlags face_update_flags = update_values - | update_q_points + | update_quadrature_points | update_JxW_values | update_normal_vectors; diff --git a/deal.II/examples/step-13/step-13.cc b/deal.II/examples/step-13/step-13.cc index 7a32650851..645fb3e8e1 100644 --- a/deal.II/examples/step-13/step-13.cc +++ b/deal.II/examples/step-13/step-13.cc @@ -1580,7 +1580,7 @@ namespace LaplaceSolver assemble_rhs (Vector &rhs) const { FEValues fe_values (*this->fe, *this->quadrature, - update_values | update_q_points | + update_values | update_quadrature_points | update_JxW_values); const unsigned int dofs_per_cell = this->fe->dofs_per_cell; diff --git a/deal.II/examples/step-14/step-14.cc b/deal.II/examples/step-14/step-14.cc index 1db22c5051..34ac79d870 100644 --- a/deal.II/examples/step-14/step-14.cc +++ b/deal.II/examples/step-14/step-14.cc @@ -232,7 +232,7 @@ namespace Evaluation QTrapez vertex_quadrature; FEValues fe_values (dof_handler.get_fe(), vertex_quadrature, - update_gradients | update_q_points); + update_gradients | update_quadrature_points); std::vector > solution_gradients (vertex_quadrature.n_quadrature_points); @@ -933,7 +933,7 @@ namespace LaplaceSolver assemble_rhs (Vector &rhs) const { FEValues fe_values (*this->fe, *this->quadrature, - update_values | update_q_points | + update_values | update_quadrature_points | update_JxW_values); const unsigned int dofs_per_cell = this->fe->dofs_per_cell; @@ -2031,7 +2031,7 @@ namespace DualFunctional QGauss quadrature(4); FEValues fe_values (dof_handler.get_fe(), quadrature, update_gradients | - update_q_points | + update_quadrature_points | update_JxW_values); const unsigned int n_q_points = fe_values.n_quadrature_points; const unsigned int dofs_per_cell = dof_handler.get_fe().dofs_per_cell; @@ -2544,7 +2544,7 @@ namespace LaplaceSolver fe_values (fe, quadrature, update_values | update_hessians | - update_q_points | + update_quadrature_points | update_JxW_values), right_hand_side (&right_hand_side) { diff --git a/deal.II/examples/step-15/step-15.cc b/deal.II/examples/step-15/step-15.cc index 374ab1229a..93420d8c9d 100644 --- a/deal.II/examples/step-15/step-15.cc +++ b/deal.II/examples/step-15/step-15.cc @@ -400,7 +400,7 @@ void MinimizationProblem::assemble_step () // quadrature point in real space for the // $x-u^3$ terms; to get these from the // FEValues object, we need to pass it - // the update_q_points flag. + // the update_quadrature_points flag. // // It is a simple calculation to figure out // that for linear elements, the integrals @@ -411,7 +411,7 @@ void MinimizationProblem::assemble_step () QGauss quadrature_formula(4); FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); // Next, here are the usual two convenience // variables, followed by declarations for @@ -879,7 +879,7 @@ void MinimizationProblem<1>::refine_grid () FEValues fe_values (fe, quadrature, update_values | update_gradients | update_hessians | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); // The error indicator formula presented in // the introduction requires us to compute @@ -1254,7 +1254,7 @@ MinimizationProblem::energy (const DoFHandler &dof_handler, QGauss quadrature_formula(4); FEValues fe_values (dof_handler.get_fe(), quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); const unsigned int n_q_points = quadrature_formula.n_quadrature_points; diff --git a/deal.II/examples/step-16/step-16.cc b/deal.II/examples/step-16/step-16.cc index 13d3f35407..dd49e26a3a 100644 --- a/deal.II/examples/step-16/step-16.cc +++ b/deal.II/examples/step-16/step-16.cc @@ -4,7 +4,7 @@ /* $Id$ */ /* Version: $Name$ */ /* */ -/* Copyright (C) 2003, 2004, 2005, 2006 by the deal.II authors */ +/* Copyright (C) 2003, 2004, 2005, 2006, 2007 by the deal.II authors */ /* */ /* This file is subject to QPL and may not be distributed */ /* without copyright and license information. Please refer */ @@ -195,7 +195,7 @@ void LaplaceProblem::assemble_system () FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); const unsigned int dofs_per_cell = fe.dofs_per_cell; const unsigned int n_q_points = quadrature_formula.n_quadrature_points; @@ -300,7 +300,7 @@ void LaplaceProblem::assemble_multigrid () FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); const unsigned int dofs_per_cell = fe.dofs_per_cell; const unsigned int n_q_points = quadrature_formula.n_quadrature_points; diff --git a/deal.II/examples/step-17/step-17.cc b/deal.II/examples/step-17/step-17.cc index f4a2851605..b27ed8c262 100644 --- a/deal.II/examples/step-17/step-17.cc +++ b/deal.II/examples/step-17/step-17.cc @@ -4,7 +4,7 @@ /* $Id$ */ /* Version: $Name$ */ /* */ -/* Copyright (C) 2000, 2004, 2005, 2006 by the deal.II authors */ +/* Copyright (C) 2000, 2004, 2005, 2006, 2007 by the deal.II authors */ /* */ /* This file is subject to QPL and may not be distributed */ /* without copyright and license information. Please refer */ @@ -515,7 +515,7 @@ void ElasticProblem::assemble_system () QGauss quadrature_formula(2); FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); const unsigned int dofs_per_cell = fe.dofs_per_cell; const unsigned int n_q_points = quadrature_formula.n_quadrature_points; diff --git a/deal.II/examples/step-18/step-18.cc b/deal.II/examples/step-18/step-18.cc index 900b75ef3d..803cb04065 100644 --- a/deal.II/examples/step-18/step-18.cc +++ b/deal.II/examples/step-18/step-18.cc @@ -4,7 +4,7 @@ /* $Id$ */ /* Version: $Name$ */ /* */ -/* Copyright (C) 2000, 2004, 2005, 2006 by the deal.II authors */ +/* Copyright (C) 2000, 2004, 2005, 2006, 2007 by the deal.II authors */ /* */ /* This file is subject to QPL and may not be distributed */ /* without copyright and license information. Please refer */ @@ -1482,7 +1482,7 @@ namespace QuasiStaticElasticity FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); const unsigned int dofs_per_cell = fe.dofs_per_cell; const unsigned int n_q_points = quadrature_formula.n_quadrature_points; diff --git a/deal.II/examples/step-20/step-20.cc b/deal.II/examples/step-20/step-20.cc index 4dbb7c923e..68a274fd73 100644 --- a/deal.II/examples/step-20/step-20.cc +++ b/deal.II/examples/step-20/step-20.cc @@ -610,10 +610,10 @@ void MixedLaplaceProblem::assemble_system () FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); FEFaceValues fe_face_values (fe, face_quadrature_formula, update_values | update_normal_vectors | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); const unsigned int dofs_per_cell = fe.dofs_per_cell; const unsigned int n_q_points = quadrature_formula.n_quadrature_points; diff --git a/deal.II/examples/step-21/step-21.cc b/deal.II/examples/step-21/step-21.cc index a009908aa1..46cdeca903 100644 --- a/deal.II/examples/step-21/step-21.cc +++ b/deal.II/examples/step-21/step-21.cc @@ -829,10 +829,10 @@ void TwoPhaseFlowProblem::assemble_system () FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); FEFaceValues fe_face_values (fe, face_quadrature_formula, update_values | update_normal_vectors | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); const unsigned int dofs_per_cell = fe.dofs_per_cell; @@ -1000,10 +1000,10 @@ void TwoPhaseFlowProblem::assemble_rhs_S () QGauss face_quadrature_formula(degree+2); FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); FEFaceValues fe_face_values (fe, face_quadrature_formula, update_values | update_normal_vectors | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); FEFaceValues fe_face_values_neighbor (fe, face_quadrature_formula, update_values); diff --git a/deal.II/examples/step-22/step-22.cc b/deal.II/examples/step-22/step-22.cc index ce86ff9b19..1490fdba2d 100644 --- a/deal.II/examples/step-22/step-22.cc +++ b/deal.II/examples/step-22/step-22.cc @@ -480,10 +480,10 @@ void BoussinesqFlowProblem::assemble_system () FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); FEFaceValues fe_face_values (fe, face_quadrature_formula, update_values | update_normal_vectors | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); const unsigned int dofs_per_cell = fe.dofs_per_cell; @@ -614,10 +614,10 @@ void BoussinesqFlowProblem::assemble_rhs_T () QGauss face_quadrature_formula(degree+2); FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); FEFaceValues fe_face_values (fe, face_quadrature_formula, update_values | update_normal_vectors | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); FEFaceValues fe_face_values_neighbor (fe, face_quadrature_formula, update_values); diff --git a/deal.II/examples/step-25/step-25.cc b/deal.II/examples/step-25/step-25.cc index a2da7cbb2a..fc6dbe019a 100644 --- a/deal.II/examples/step-25/step-25.cc +++ b/deal.II/examples/step-25/step-25.cc @@ -503,7 +503,7 @@ void SineGordonProblem::compute_nl_term (const Vector &old_data, FEValues fe_values (fe, quadrature_formula, update_values | update_JxW_values | - update_q_points); + update_quadrature_points); const unsigned int dofs_per_cell = fe.dofs_per_cell; const unsigned int n_q_points = quadrature_formula.n_quadrature_points; @@ -576,7 +576,7 @@ void SineGordonProblem::compute_nl_matrix (const Vector &old_data, { QGauss quadrature_formula (3); FEValues fe_values (fe, quadrature_formula, - update_values | update_JxW_values | update_q_points); + update_values | update_JxW_values | update_quadrature_points); const unsigned int dofs_per_cell = fe.dofs_per_cell; const unsigned int n_q_points = quadrature_formula.n_quadrature_points; diff --git a/deal.II/examples/step-27/step-27.cc b/deal.II/examples/step-27/step-27.cc index 6a10ae239e..40737884bf 100644 --- a/deal.II/examples/step-27/step-27.cc +++ b/deal.II/examples/step-27/step-27.cc @@ -307,7 +307,7 @@ void LaplaceProblem::assemble_system () hp::FEValues hp_fe_values (fe_collection, quadrature_collection, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); const RightHandSide rhs_function; diff --git a/deal.II/examples/step-28/step-28.cc b/deal.II/examples/step-28/step-28.cc index fc57e23b93..e633dc9037 100644 --- a/deal.II/examples/step-28/step-28.cc +++ b/deal.II/examples/step-28/step-28.cc @@ -1018,7 +1018,7 @@ void EnergyGroup::assemble_ingroup_rhs (const Function &extraneous_sou const unsigned int n_q_points = quadrature_formula.n_quadrature_points; FEValues fe_values (fe, quadrature_formula, - update_values | update_q_points | + update_values | update_quadrature_points | update_JxW_values); Vector cell_rhs (dofs_per_cell); diff --git a/deal.II/examples/step-4/step-4.cc b/deal.II/examples/step-4/step-4.cc index 26407dac70..ec31942f14 100644 --- a/deal.II/examples/step-4/step-4.cc +++ b/deal.II/examples/step-4/step-4.cc @@ -414,10 +414,10 @@ void LaplaceProblem::assemble_system () // object, as well as the quadrature // weights, JxW). We can tell the // FEValues object to do for us by also - // giving it the update_q_points flag: + // giving it the update_quadrature_points flag: FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); // We then again define a few // abbreviations. The values of these diff --git a/deal.II/examples/step-5/step-5.cc b/deal.II/examples/step-5/step-5.cc index 125c2fe335..9a1fd3530c 100644 --- a/deal.II/examples/step-5/step-5.cc +++ b/deal.II/examples/step-5/step-5.cc @@ -437,7 +437,7 @@ void LaplaceProblem::assemble_system () FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); const unsigned int dofs_per_cell = fe.dofs_per_cell; const unsigned int n_q_points = quadrature_formula.n_quadrature_points; diff --git a/deal.II/examples/step-6/step-6.cc b/deal.II/examples/step-6/step-6.cc index 57c0c62abf..e7b88c8c87 100644 --- a/deal.II/examples/step-6/step-6.cc +++ b/deal.II/examples/step-6/step-6.cc @@ -552,7 +552,7 @@ void LaplaceProblem::assemble_system () FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); const unsigned int dofs_per_cell = fe.dofs_per_cell; const unsigned int n_q_points = quadrature_formula.n_quadrature_points; diff --git a/deal.II/examples/step-7/step-7.cc b/deal.II/examples/step-7/step-7.cc index cd247c5913..0fd500b68f 100644 --- a/deal.II/examples/step-7/step-7.cc +++ b/deal.II/examples/step-7/step-7.cc @@ -869,10 +869,10 @@ void HelmholtzProblem::assemble_system () // FEFaceValues: FEValues fe_values (*fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); FEFaceValues fe_face_values (*fe, face_quadrature_formula, - update_values | update_q_points | + update_values | update_quadrature_points | update_normal_vectors | update_JxW_values); // Then we need some objects diff --git a/deal.II/examples/step-8/step-8.cc b/deal.II/examples/step-8/step-8.cc index b117c92f7a..8b875fccd7 100644 --- a/deal.II/examples/step-8/step-8.cc +++ b/deal.II/examples/step-8/step-8.cc @@ -4,7 +4,7 @@ /* $Id$ */ /* Version: $Name$ */ /* */ -/* Copyright (C) 2000, 2001, 2002, 2003, 2004, 2006 by the deal.II authors */ +/* Copyright (C) 2000, 2001, 2002, 2003, 2004, 2006, 2007 by the deal.II authors */ /* */ /* This file is subject to QPL and may not be distributed */ /* without copyright and license information. Please refer */ @@ -541,7 +541,7 @@ void ElasticProblem::assemble_system () FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); const unsigned int dofs_per_cell = fe.dofs_per_cell; const unsigned int n_q_points = quadrature_formula.n_quadrature_points; diff --git a/deal.II/examples/step-9/step-9.cc b/deal.II/examples/step-9/step-9.cc index 09ea490998..18060472ce 100644 --- a/deal.II/examples/step-9/step-9.cc +++ b/deal.II/examples/step-9/step-9.cc @@ -985,9 +985,9 @@ assemble_system_interval (const typename DoFHandler::active_cell_iterator & // vectors to the cells. FEValues fe_values (fe, quadrature_formula, update_values | update_gradients | - update_q_points | update_JxW_values); + update_quadrature_points | update_JxW_values); FEFaceValues fe_face_values (fe, face_quadrature_formula, - update_values | update_q_points | + update_values | update_quadrature_points | update_JxW_values | update_normal_vectors); // Then we define some @@ -1590,7 +1590,7 @@ GradientEstimation::estimate_interval (const DoFHandler &dof_handler, QMidpoint midpoint_rule; FEValues fe_midpoint_value (dof_handler.get_fe(), midpoint_rule, - update_values | update_q_points); + update_values | update_quadrature_points); // Then we need space foe the // tensor Y, which is the sum -- 2.39.5