]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Step-37: small update to the documentation 11179/head
authorPeter Munch <peterrmuench@gmail.com>
Fri, 13 Nov 2020 08:14:53 +0000 (09:14 +0100)
committerPeter Munch <peterrmuench@gmail.com>
Fri, 13 Nov 2020 08:14:53 +0000 (09:14 +0100)
examples/step-37/doc/intro.dox

index e302529e4d28ae7c155f79d78c96570d49f276ce..e60666c0d516d375c07d7ca70d8b281335353b6f 100644 (file)
@@ -114,10 +114,7 @@ Matrixfree<dim>::vmult (Vector<double>       &dst,
 
   std::vector<unsigned int> local_dof_indices (dofs_per_cell);
 
-  typename DoFHandler<dim>::active_cell_iterator
-    cell = dof_handler.begin_active(),
-    endc = dof_handler.end();
-  for (; cell!=endc; ++cell)
+  for (const auto & cell : dof_handler.active_cell_iterators())
     {
       cell_matrix = 0;
       fe_values.reinit (cell);
@@ -257,7 +254,6 @@ v = \sum_{\mathrm{cell}=1}^{\mathrm{n\_cells}} P_\mathrm{cell,{loc-glob}}^T
 v_\mathrm{cell}.
 @f}
 @code
-...
   FEValues<dim> fe_values_reference (fe, quadrature_formula,
                                      update_gradients);
   Triangulation<dim> reference_cell;
@@ -268,7 +264,7 @@ v_\mathrm{cell}.
                            update_inverse_jacobians | update_JxW_values |
                            update_quadrature_points);
 
-  for (; cell!=endc; ++cell)
+  for (const auto & cell : dof_handler.active_cell_iterators())
     {
       fe_values.reinit (cell);
       coefficient.value_list(fe_values.get_quadrature_points(),

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.