]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Introduce the flag update_values for consistency with the other update flags.
authorwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 21 Dec 1999 14:17:34 +0000 (14:17 +0000)
committerwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 21 Dec 1999 14:17:34 +0000 (14:17 +0000)
git-svn-id: https://svn.dealii.org/trunk@2103 0785d39b-7218-0410-832d-ea1e28bc413d

23 files changed:
deal.II/deal.II/Attic/examples/convergence/convergence.cc
deal.II/deal.II/Attic/examples/error-estimation/error-estimation.cc
deal.II/deal.II/Attic/examples/multigrid/multigrid.cc
deal.II/deal.II/Attic/examples/nonlinear/fixed-point-iteration/nonlinear.cc
deal.II/deal.II/Attic/examples/poisson/problem.cc
deal.II/deal.II/Attic/examples/step-by-step/step-3/step-3.cc
deal.II/deal.II/include/fe/fe_update_flags.h
deal.II/deal.II/include/fe/fe_values.h
deal.II/deal.II/source/fe/fe_values.cc
deal.II/deal.II/source/numerics/data_io.cc
deal.II/deal.II/source/numerics/data_out_stack.cc
deal.II/deal.II/source/numerics/matrices.cc
deal.II/deal.II/source/numerics/vectors.cc
deal.II/doc/tutorial/chapter-1.elements/rhs.html
deal.II/examples/step-3/step-3.cc
tests/big-tests/convergence/convergence.cc
tests/big-tests/error-estimation/error-estimation.cc
tests/big-tests/multigrid/multigrid.cc
tests/big-tests/nonlinear/fixed-point-iteration/nonlinear.cc
tests/big-tests/poisson/problem.cc
tests/deal.II/wave-test-3.cc
tests/fe/show_shapes.cc
tests/fe/show_transform.cc

index 3b09adeaede28c0dc740b7be14abc0d891415d51..d972b01fbdd6168f9c5044221d5768af777f1cec 100644 (file)
@@ -335,8 +335,8 @@ int PoissonProblem<dim>::run (const unsigned int level) {
   n_dofs.push_back (dof->n_dofs());
 
   cout << "    Assembling matrices..." << endl;
-  UpdateFlags update_flags = UpdateFlags(update_q_points  | update_gradients |
-                                        update_JxW_values);
+  UpdateFlags update_flags = UpdateFlags(update_values | update_q_points  |
+                                        update_gradients | update_JxW_values);
   
   ProblemBase<dim>::FunctionMap dirichlet_bc;
   dirichlet_bc[0] = boundary_values;
index 2aa1b4e5dac9403e9b901f82a8ca4a6dadbfb1b5..bde0cea6a562cf6e2cfb51b3f915d147d9908b72 100644 (file)
@@ -484,8 +484,8 @@ void PoissonProblem<dim>::run (ParameterHandler &prm) {
       n_dofs.push_back (dof->n_dofs());
 
       cout << "    Assembling matrices..." << endl;
-      UpdateFlags update_flags = UpdateFlags(update_q_points  | update_gradients |
-                                            update_JxW_values);
+      UpdateFlags update_flags = UpdateFlags(update_values | update_q_points  |
+                                            update_gradients | update_JxW_values);
   
       ProblemBase<dim>::FunctionMap dirichlet_bc;
       dirichlet_bc[0] = solution_function;
index 2341d34c145b8364f18777a952b42139fab02101..bdc538b84a5f06c0f14df3d70e02724b7653d558 100644 (file)
@@ -503,8 +503,8 @@ int PoissonProblem<dim>::run (const unsigned int level) {
   n_dofs.push_back (dof->DoFHandler<dim>::n_dofs());
 
   cout << "    Assembling matrices..." << endl;
-  UpdateFlags update_flags = UpdateFlags(update_q_points  | update_gradients |
-                                        update_JxW_values);
+  UpdateFlags update_flags = UpdateFlags(update_values | update_q_points  |
+                                        update_gradients | update_JxW_values);
   
   map<unsigned char,const Function<dim>*> dirichlet_bc;
   dirichlet_bc[0] = boundary_values;
index ea02510cb5781db7c641bc71ac9d6518729d4599..30155302fa831eb2d86ea51a5a7b0a523199de0d 100644 (file)
@@ -199,8 +199,8 @@ void NonlinearProblem<dim>::run () {
          cout << "    Nonlinear step " << nonlinear_step << endl;
          cout << "        Assembling matrices..." << endl;
          assemble (equation, quadrature, fe,
-                   UpdateFlags(update_gradients | update_JxW_values |
-                               update_q_points),
+                   UpdateFlags(update_values | update_gradients |
+                               update_JxW_values | update_q_points),
                    dirichlet_bc);
          
          cout << "        Solving..." << endl;
index f867e12661815429a2c0079a5e82073d0ff47f1b..309a056b64fdb9b71e022ff842ad9e28c367c123 100644 (file)
@@ -589,8 +589,8 @@ void PoissonProblem<dim>::run (ParameterHandler &prm) {
   ProblemBase<dim>::FunctionMap dirichlet_bc;
   dirichlet_bc[0] = boundary_values;
   assemble (equation, quadrature,
-           UpdateFlags(update_gradients | update_JxW_values |
-                       update_q_points),
+           UpdateFlags(update_values | update_gradients |
+                       update_JxW_values | update_q_points),
            dirichlet_bc);
 
   cout << "    Solving..." << endl;
index 25178f6044f4bb578b0132a0ed25f9c70c96e96f..0e0403cabfacb9d70d3a0576656708e859582801 100644 (file)
@@ -336,8 +336,10 @@ void LaplaceProblem::assemble_system ()
                                   // transformations from the unit
                                   // cell to the real cells. The
                                   // values of the shape functions
-                                  // are always computed, so we don't
-                                  // have to list them. The
+                                  // computed by specifying
+                                  // update_values; the gradients are
+                                  // done alike, using
+                                  // update_gradients. The
                                   // determinants of the Jacobians
                                   // and the weights are always used
                                   // together, so only the products
@@ -346,7 +348,8 @@ void LaplaceProblem::assemble_system ()
                                   // we also need them, we have to
                                   // list them as well:
   FEValues<2> fe_values (fe, quadrature_formula, 
-                        UpdateFlags(update_gradients |
+                        UpdateFlags(update_values    |
+                                    update_gradients |
                                     update_JxW_values));
 
                                   // For use further down below, we
index 793211f6992445f60b81300a2ed8d5132a3716ca..4c2ec388ce3ea3dcb76fd18eb60dd4a1d1280da7 100644 (file)
@@ -21,28 +21,44 @@ enum UpdateFlags {
                                        * Default: update nothing.
                                        */
       update_default  = 0,
+                                      /**
+                                       * Compute the values of the
+                                       * shape functions at the
+                                       * quadrature points on the
+                                       * real space cell. For the
+                                       * usual Lagrange elements,
+                                       * these values are equal to
+                                       * the values of the shape
+                                       * functions at the quadrature
+                                       * points on the unit cell, but
+                                       * they are different for more
+                                       * complicated elements, such
+                                       * as BDM or Raviart-Thomas
+                                       * elements.
+                                       */
+      update_values = 1,
                                       /**
                                        * Compute quadrature points in real
                                        * space (not on unit cell).
                                        */
-      update_q_points = 1,
+      update_q_points = 2,
                                       /**
                                        * Transform gradients on unit cell to
                                        * gradients on real cell.
                                        */
-      update_gradients = 2,
+      update_gradients = 4,
                                       /**
                                        * Compute jacobian matrices of the
                                        * transform between unit and real cell
                                        * in the evaluation points.
                                        */
-      update_jacobians = 4,
+      update_jacobians = 8,
                                       /**
                                        * Compute the JxW values (Jacobian
                                        * determinant at the quadrature point
                                        * times the weight of this point).
                                        */
-      update_JxW_values = 8,
+      update_JxW_values = 16,
                                       /**
                                        * Compute the points on the real cell
                                        * on which the trial functions are
@@ -53,7 +69,7 @@ enum UpdateFlags {
                                        * in an error, since support points are
                                        * not useful in that case.
                                        */
-      update_support_points = 16,
+      update_support_points = 32,
                                       /**
                                        * Update the outward normal vectors
                                        * to the face relative to this cell.
@@ -65,13 +81,13 @@ enum UpdateFlags {
                                        * an error, since normal vectors are
                                        * not useful in that case.
                                        */
-      update_normal_vectors = 32,
+      update_normal_vectors = 64,
 
                                       /**
                                        * Update the second derivatives of the
                                        * shape functions on the real cell.
                                        */
-      update_second_derivatives = 64
+      update_second_derivatives = 128
 };
 
 
index db369ffef5c45aa35c450330322abd254da95f48..1bae229f3782fa7e8f3ab5f9dce4f6becba2c8c1 100644 (file)
@@ -1227,6 +1227,7 @@ template <int dim>
 inline
 const FullMatrix<double> & FEValuesBase<dim>::get_shape_values () const
 {
+  Assert (update_flags & update_values, ExcAccessToUninitializedField());
   Assert (selected_dataset<shape_values.size(),
          ExcIndexRange (selected_dataset, 0, shape_values.size()));
   return shape_values[selected_dataset];
index ba61fe7923142619fed40cd36540daa1b07d9cad..7bd312b2e598654e517952cb7095096381c621b1 100644 (file)
@@ -50,6 +50,7 @@ FEValuesBase<dim>::FEValuesBase (const unsigned int n_q_points,
 template <int dim>
 double FEValuesBase<dim>::shape_value (const unsigned int i,
                                       const unsigned int j) const {
+  Assert (update_flags & update_values, ExcAccessToUninitializedField());
   Assert (selected_dataset<shape_values.size(),
          ExcIndexRange (selected_dataset, 0, shape_values.size()));
   Assert (i<shape_values[selected_dataset].m(),
index c348740fb504b08d7220ddb28631f15016b80a44..c15ffc76e0d1c4f1772474df41d3bb9131daa78a 100644 (file)
@@ -593,7 +593,8 @@ void DataOut_Old<dim>::write_gnuplot (ostream &out, unsigned int accuracy) const
   QTrapez<1>     q_trapez;
   QIterated<dim> points (q_trapez, accuracy);
   
-  FEValues<dim> fe(dofs->get_fe(), points, UpdateFlags(update_q_points));
+  FEValues<dim> fe(dofs->get_fe(), points,
+                  UpdateFlags(update_values | update_q_points));
   vector< vector <Vector<double> > >
     values (dof_data.size(),
            vector< Vector<double> >(points.n_quadrature_points,
index 45e38031ffbe6ce061af41182b135260a49825ba..70b23947f302b48821a934186dd1f0b912693e4e 100644 (file)
@@ -193,7 +193,7 @@ void DataOutStack<dim>::build_patches (const unsigned int n_subdivisions)
   QIterated<dim> patch_points (q_trapez, n_subdivisions);
   FEValues<dim>  fe_patch_values (dof_handler->get_fe(),
                                  patch_points,
-                                 update_default);
+                                 update_values);
   const unsigned int n_q_points = patch_points.n_quadrature_points;
   vector<double>          patch_values (n_q_points);
   vector<Vector<double> > patch_values_system (n_q_points,
index d57cf1c2ae1a7aed8fb427c64674bb76d14b69ea..40026511fd3f498d1fbd7e22d1c21b5f0a6914df 100644 (file)
@@ -25,7 +25,7 @@ void MatrixCreator<dim>::create_mass_matrix (const DoFHandler<dim>    &dof,
                                             SparseMatrix<double>     &matrix,
                                             const Function<dim> * const a) {
   Vector<double> dummy;    // no entries, should give an error if accessed
-  UpdateFlags update_flags = update_JxW_values;
+  UpdateFlags update_flags = UpdateFlags(update_values | update_JxW_values);
   if (a != 0)
     update_flags = UpdateFlags (update_flags | update_q_points);
   const Assembler<dim>::AssemblerData data (dof,
@@ -55,7 +55,8 @@ void MatrixCreator<dim>::create_mass_matrix (const DoFHandler<dim>    &dof,
                                             const Function<dim>      &rhs,
                                             Vector<double>           &rhs_vector,
                                             const Function<dim> * const a) {
-  UpdateFlags update_flags = UpdateFlags(update_q_points |
+  UpdateFlags update_flags = UpdateFlags(update_values |
+                                        update_q_points |
                                         update_JxW_values);
   const Assembler<dim>::AssemblerData data (dof,
                                            true, true,
@@ -150,7 +151,9 @@ void MatrixCreator<dim>::create_boundary_mass_matrix (const DoFHandler<dim>    &
   Vector<double>     cell_vector(dofs_per_cell);
   
   
-  UpdateFlags update_flags = UpdateFlags (update_JxW_values | update_q_points);
+  UpdateFlags update_flags = UpdateFlags (update_values     |
+                                         update_JxW_values |
+                                         update_q_points);
   FEFaceValues<dim> fe_values (fe, q, update_flags);
 
                                   // two variables for the coefficient,
index 85d464b889bf8c896417a92d6a52dc8f441b84d7..b98221083d5a4eaad80611511ddc2b0ec4c865cb 100644 (file)
@@ -439,7 +439,8 @@ void VectorTools::create_right_hand_side (const DoFHandler<dim>    &dof,
   Assert (dof.get_fe().n_components() == rhs.n_components,
          ExcComponentMismatch());
   
-  UpdateFlags update_flags = UpdateFlags(update_q_points |
+  UpdateFlags update_flags = UpdateFlags(update_values   |
+                                        update_q_points |
                                         update_JxW_values);
   SparseMatrix<double> dummy;
   const Assembler<dim>::AssemblerData data (dof,
@@ -735,8 +736,12 @@ VectorTools::integrate_difference (const DoFHandler<dim>    &dof,
   
   UpdateFlags update_flags = UpdateFlags (update_q_points  |
                                          update_JxW_values);
+  if (norm != H1_seminorm)
+    update_flags != update_values;
+  
   if ((norm==H1_seminorm) || (norm==H1_norm))
     update_flags = UpdateFlags (update_flags | update_gradients);
+  
   FEValues<dim> fe_values(fe, q, update_flags);
 
   vector< Vector<double> >        function_values (n_q_points,
index 82c97e25c5f0d29350fa09a7731dec6475284343..d95986bfb18dc491eb1fa018de367edd5f6aa24c 100644 (file)
@@ -55,9 +55,13 @@ quadrature points.
 <code>
 // Initialize the trial functions on the cell faces.
 FEValues&lt;2&gt; fe_values(fe, quadrature,
-                   UpdateFlags(update_gradients | update_JxW_values));
+                   UpdateFlags(update_values    | 
+                               update_gradients |
+                               update_JxW_values));
 FEFaceValues&lt;2&gt; fe_face_values (fe, face_quadrature,
-                              UpdateFlags(update_JxW_values | update_q_points));
+                              UpdateFlags(update_values     | 
+                                          update_JxW_values |
+                                          update_q_points));
 </code>
 </pre>
 
index 25178f6044f4bb578b0132a0ed25f9c70c96e96f..0e0403cabfacb9d70d3a0576656708e859582801 100644 (file)
@@ -336,8 +336,10 @@ void LaplaceProblem::assemble_system ()
                                   // transformations from the unit
                                   // cell to the real cells. The
                                   // values of the shape functions
-                                  // are always computed, so we don't
-                                  // have to list them. The
+                                  // computed by specifying
+                                  // update_values; the gradients are
+                                  // done alike, using
+                                  // update_gradients. The
                                   // determinants of the Jacobians
                                   // and the weights are always used
                                   // together, so only the products
@@ -346,7 +348,8 @@ void LaplaceProblem::assemble_system ()
                                   // we also need them, we have to
                                   // list them as well:
   FEValues<2> fe_values (fe, quadrature_formula, 
-                        UpdateFlags(update_gradients |
+                        UpdateFlags(update_values    |
+                                    update_gradients |
                                     update_JxW_values));
 
                                   // For use further down below, we
index 3b09adeaede28c0dc740b7be14abc0d891415d51..d972b01fbdd6168f9c5044221d5768af777f1cec 100644 (file)
@@ -335,8 +335,8 @@ int PoissonProblem<dim>::run (const unsigned int level) {
   n_dofs.push_back (dof->n_dofs());
 
   cout << "    Assembling matrices..." << endl;
-  UpdateFlags update_flags = UpdateFlags(update_q_points  | update_gradients |
-                                        update_JxW_values);
+  UpdateFlags update_flags = UpdateFlags(update_values | update_q_points  |
+                                        update_gradients | update_JxW_values);
   
   ProblemBase<dim>::FunctionMap dirichlet_bc;
   dirichlet_bc[0] = boundary_values;
index 2aa1b4e5dac9403e9b901f82a8ca4a6dadbfb1b5..bde0cea6a562cf6e2cfb51b3f915d147d9908b72 100644 (file)
@@ -484,8 +484,8 @@ void PoissonProblem<dim>::run (ParameterHandler &prm) {
       n_dofs.push_back (dof->n_dofs());
 
       cout << "    Assembling matrices..." << endl;
-      UpdateFlags update_flags = UpdateFlags(update_q_points  | update_gradients |
-                                            update_JxW_values);
+      UpdateFlags update_flags = UpdateFlags(update_values | update_q_points  |
+                                            update_gradients | update_JxW_values);
   
       ProblemBase<dim>::FunctionMap dirichlet_bc;
       dirichlet_bc[0] = solution_function;
index 2341d34c145b8364f18777a952b42139fab02101..bdc538b84a5f06c0f14df3d70e02724b7653d558 100644 (file)
@@ -503,8 +503,8 @@ int PoissonProblem<dim>::run (const unsigned int level) {
   n_dofs.push_back (dof->DoFHandler<dim>::n_dofs());
 
   cout << "    Assembling matrices..." << endl;
-  UpdateFlags update_flags = UpdateFlags(update_q_points  | update_gradients |
-                                        update_JxW_values);
+  UpdateFlags update_flags = UpdateFlags(update_values | update_q_points  |
+                                        update_gradients | update_JxW_values);
   
   map<unsigned char,const Function<dim>*> dirichlet_bc;
   dirichlet_bc[0] = boundary_values;
index ea02510cb5781db7c641bc71ac9d6518729d4599..30155302fa831eb2d86ea51a5a7b0a523199de0d 100644 (file)
@@ -199,8 +199,8 @@ void NonlinearProblem<dim>::run () {
          cout << "    Nonlinear step " << nonlinear_step << endl;
          cout << "        Assembling matrices..." << endl;
          assemble (equation, quadrature, fe,
-                   UpdateFlags(update_gradients | update_JxW_values |
-                               update_q_points),
+                   UpdateFlags(update_values | update_gradients |
+                               update_JxW_values | update_q_points),
                    dirichlet_bc);
          
          cout << "        Solving..." << endl;
index f867e12661815429a2c0079a5e82073d0ff47f1b..309a056b64fdb9b71e022ff842ad9e28c367c123 100644 (file)
@@ -589,8 +589,8 @@ void PoissonProblem<dim>::run (ParameterHandler &prm) {
   ProblemBase<dim>::FunctionMap dirichlet_bc;
   dirichlet_bc[0] = boundary_values;
   assemble (equation, quadrature,
-           UpdateFlags(update_gradients | update_JxW_values |
-                       update_q_points),
+           UpdateFlags(update_values | update_gradients |
+                       update_JxW_values | update_q_points),
            dirichlet_bc);
 
   cout << "    Solving..." << endl;
index 272686fcd3be4aee164a03714424e59a7b614c28..ef53aef2c382043a517d9fa9aa171ff846c9b01a 100644 (file)
@@ -2122,11 +2122,12 @@ void EndEnergy<dim>::compute_vectors (const PartOfDomain pod,
   primal_cell = primal_dof->begin_active();
 
   FEValues<dim> fe_values (*fe, *quadrature,
-                          UpdateFlags(update_gradients      |
+                          UpdateFlags(update_values         |
+                                      update_gradients      |
                                       update_JxW_values     |
                                       update_q_points));
   FEValues<dim> fe_values_primal (*primal_fe, *quadrature,
-                                 update_gradients);
+                                 UpdateFlags(update_values | update_gradients));
   
   FullMatrix<double>  cell_matrix (dofs_per_cell, dofs_per_cell);
 
@@ -2266,7 +2267,8 @@ void SeismicSignal<dim>::compute_functionals (Vector<double> &j1,
   vector<int> cell_dof_indices (dofs_per_cell);
 
   FEFaceValues<dim> fe_face_values (*fe, *quadrature_face,
-                                   UpdateFlags(update_JxW_values     |
+                                   UpdateFlags(update_values         |
+                                               update_JxW_values     |
                                                update_q_points));
   
   for (; cell!=endc; ++cell)
@@ -2397,7 +2399,7 @@ void SplitSignal<dim>::compute_functionals (Vector<double> &j1,
   endc = dof->end();
 
   vector<int> dof_indices (fe->dofs_per_cell);
-  FEFaceValues<dim> fe_face_values (*fe, *quadrature_face, update_JxW_values);
+  FEFaceValues<dim> fe_face_values (*fe, *quadrature_face, UpdateFlags(update_values | update_JxW_values));
   
   for (; cell!=endc; ++cell)
     for (unsigned int face_no=0; face_no<GeometryInfo<dim>::faces_per_cell;
@@ -2465,7 +2467,7 @@ void SplitLine<1>::compute_endtime_vectors (Vector<double> &final_u_bar,
   DoFHandler<dim>::active_cell_iterator cell = dof->begin_active (),
                                        endc = dof->end ();
 
-  FEValues<dim> fe_values (*fe, *quadrature, update_JxW_values);
+  FEValues<dim> fe_values (*fe, *quadrature, UpdateFlags(update_values | update_JxW_values));
   vector<int> cell_dof_indices (dofs_per_cell);
 
   for (; cell!=endc; ++cell)
@@ -2517,7 +2519,7 @@ void OneBranch1d<dim>::compute_functionals (Vector<double> &j1,
   endc = dof->end();
 
   vector<int> dof_indices (fe->dofs_per_cell);
-  FEValues<dim> fe_values (*fe, *quadrature, update_JxW_values);
+  FEValues<dim> fe_values (*fe, *quadrature, UpdateFlags(update_values | update_JxW_values));
   
   for (; cell!=endc; ++cell)
     if ((cell->center()(0) > -0.6) &&
@@ -2566,7 +2568,7 @@ void SecondCrossing<dim>::compute_functionals (Vector<double> &j1,
   endc = dof->end();
 
   vector<int> dof_indices (fe->dofs_per_cell);
-  FEValues<dim> fe_values (*fe, *quadrature, update_JxW_values);
+  FEValues<dim> fe_values (*fe, *quadrature, UpdateFlags(update_values | update_JxW_values));
   
   for (; cell!=endc; ++cell)
     if ((cell->center()(0) > -0.03) &&
@@ -2755,7 +2757,8 @@ double EvaluateEnergyContent<dim>::compute_energy (const PartOfDomain pod) const
   endc = dof->end ();
 
   FEValues<dim> fe_values (*fe, *quadrature,
-                          UpdateFlags(update_gradients      |
+                          UpdateFlags(update_values         |
+                                      update_gradients      |
                                       update_JxW_values     |
                                       update_q_points));
   FullMatrix<double>  cell_matrix (fe->dofs_per_cell, fe->dofs_per_cell);
@@ -2942,7 +2945,9 @@ double EvaluateSeismicSignal<dim>::evaluate () {
                                        endc = dof->end();
   double u_integrated=0;
   FEFaceValues<dim> face_values (*fe, *quadrature_face,
-                                UpdateFlags(update_JxW_values|update_q_points));
+                                UpdateFlags(update_values         |
+                                            update_JxW_values     |
+                                            update_q_points));
   vector<double>    face_u (fe->dofs_per_face);
   
   for (; cell!=endc; ++cell)
@@ -3038,7 +3043,7 @@ double EvaluateSplitSignal<dim>::evaluate () {
   DoFHandler<dim>::active_cell_iterator cell = dof->begin_active(),
                                        endc = dof->end();
   double u_integrated=0;
-  FEFaceValues<dim> face_values (*fe, *quadrature_face, update_JxW_values);
+  FEFaceValues<dim> face_values (*fe, *quadrature_face, UpdateFlags(update_values | update_JxW_values));
   vector<double>    face_u (fe->dofs_per_face);
   
   for (; cell!=endc; ++cell)
@@ -3132,7 +3137,7 @@ double EvaluateOneBranch1d<1>::evaluate () {
   DoFHandler<1>::active_cell_iterator cell = dof->begin_active(),
                                      endc = dof->end();
   double u_integrated=0;
-  FEValues<1>  fe_values (*fe, *quadrature, update_JxW_values);
+  FEValues<1>  fe_values (*fe, *quadrature, UpdateFlags(update_values | update_JxW_values));
   vector<double> cell_u (fe->dofs_per_cell);
   
   for (; cell!=endc; ++cell)
@@ -3209,7 +3214,8 @@ double EvaluateSecondCrossing1d<1>::evaluate () {
   DoFHandler<1>::active_cell_iterator cell = dof->begin_active(),
                                      endc = dof->end();
   double u_integrated=0;
-  FEValues<1>  fe_values (*fe, *quadrature, UpdateFlags(update_JxW_values | update_q_points));
+  FEValues<1>  fe_values (*fe, *quadrature,
+                         UpdateFlags(update_values | update_JxW_values | update_q_points));
   vector<double> cell_u (fe->dofs_per_cell);
   
   for (; cell!=endc; ++cell)
@@ -5518,7 +5524,8 @@ void TimeStep_Wave<dim>::create_matrices ()
   
   
   FEValues<dim>  fe_values (fe, quadrature,
-                           UpdateFlags(update_gradients  |
+                           UpdateFlags(update_values |
+                                       update_gradients  |
                                        update_JxW_values |
                                        (!density_constant || !stiffness_constant ?
                                         update_q_points :
@@ -6070,7 +6077,8 @@ void TimeStep_Dual<dim>::build_rhs (Vector<double> &right_hand_side1,
                                   // is expensive to create it for
                                   // every cell
   FEValues<dim> fe_values (fe, quadrature,
-                          UpdateFlags(update_gradients |
+                          UpdateFlags(update_values |
+                                      update_gradients |
                                       update_JxW_values |
                                       update_q_points));
 
@@ -6745,7 +6753,8 @@ void TimeStep_ErrorEstimation<dim>::estimate_error_dual () {
     {
       FEValues<dim> fe_values (dual_problem.fe,
                               dual_problem.quadrature,
-                              UpdateFlags(update_gradients |
+                              UpdateFlags(update_values |
+                                          update_gradients |
                                           update_second_derivatives |
                                           update_JxW_values |
                                           update_q_points));
@@ -8391,7 +8400,8 @@ void TimeStep_Primal<dim>::build_rhs (Vector<double> &right_hand_side1,
                                   // is expensive to create it for
                                   // every cell
   FEValues<dim> fe_values (fe, quadrature,
-                          UpdateFlags(update_gradients |
+                          UpdateFlags(update_values |
+                                      update_gradients |
                                       update_JxW_values |
                                       update_q_points));
 
index 1ddf9d59dcfac4ee8d422aadec5e53e1d791b51a..a441df0fff81b7be44aa58ee4b4c4ff6ccff746b 100644 (file)
@@ -25,7 +25,7 @@ plot_shape_functions(FiniteElement<dim>& finel, const char* name)
 
   QTrapez<1> q_trapez;
   QIterated<dim> q(q_trapez, div);
-  FEValues<dim> fe(finel, q, UpdateFlags(update_default));
+  FEValues<dim> fe(finel, q, UpdateFlags(update_values));
 
   sprintf(fname, "%s.dat", name);
   ofstream gnuplot(fname);
index 8e0dd377be8217d73c0f1b68dcba733450513d03..d48c8809d3313cc66a0edf0e2e84474fd6bdc5c3 100644 (file)
@@ -28,7 +28,7 @@ plot_transformation(FiniteElement<dim>& finel,
   QTrapez<1> q_trapez;
   QIterated<dim> q(q_trapez, div);
   FEValues<dim> fe(finel, q,
-                  UpdateFlags(update_q_points | update_JxW_values));
+                  UpdateFlags(update_values | update_q_points | update_JxW_values));
 
   fe.reinit(c);
   

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.