From b48a92c1996d6a09a00d1b82c33deab550fa246c Mon Sep 17 00:00:00 2001 From: Wolfgang Bangerth Date: Sun, 17 May 2009 13:20:52 +0000 Subject: [PATCH] Augment documentation. git-svn-id: https://svn.dealii.org/trunk@18862 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/deal.II/include/numerics/vectors.h | 58 ++++++++++++++-------- 1 file changed, 37 insertions(+), 21 deletions(-) diff --git a/deal.II/deal.II/include/numerics/vectors.h b/deal.II/deal.II/include/numerics/vectors.h index f8a8208606..21e5af0e84 100644 --- a/deal.II/deal.II/include/numerics/vectors.h +++ b/deal.II/deal.II/include/numerics/vectors.h @@ -1703,9 +1703,12 @@ class VectorTools * freedom values as given by the input * vector; they are not weighted by the * area of cells, i.e. the mean is - * computed as sum_i v_i, rather - * than as int_Omega v(x) = int_Omega - * sum_i v_i phi_i(x). + * computed as $\sum_i v_i$, rather than + * as $\int_\Omega v(x) = \int_\Omega + * \sum_i v_i \phi_i(x)$. The latter can + * be obtained from the + * VectorTools::compute_mean_function, + * however. * * Apart from the vector @p v to operate * on, this function takes a bit @@ -1729,24 +1732,37 @@ class VectorTools * This function integrates the * chosen component over the * whole domain and returns the - * result. - * - * Subtracting this mean value - * from the node vector does not - * generally yield the desired - * result of a finite element - * function with mean value - * zero. In fact, it only works - * for Lagrangian - * elements. Therefore, it is - * necessary to compute the mean - * value and subtract it in the - * evaluation routine. + * result, i.e. it computes + * $\int_\Omega [u_h(x)]_c \; dx$ + * where $c$ is the vector component + * and $u_h$ is the function + * representation of the nodal + * vector given as fourth + * argument. The integral is evaluated + * numerically using the quadrature + * formula given as third argument. * - * So far, this is needed only in - * the error evaluation for - * Stokes with complete Dirichlet - * boundaries for the velocities. + * This function is used in the + * "Possibilities for extensions" part of + * the results section of @ref step_3 + * "step-3". + * + * @note The function is most often used + * when solving a problem whose solution + * is only defined up to a constant, for + * example a pure Neumann problem or the + * pressure in a Stokes or Navier-Stokes + * problem. In both cases, subtracting + * the mean value as computed by the + * current function, from the nodal + * vector does not generally yield the + * desired result of a finite element + * function with mean value zero. In + * fact, it only works for Lagrangian + * elements. For all other elements, you + * will need to compute the mean value + * and subtract it right inside the + * evaluation routine. */ template static double compute_mean_value (const Mapping &mapping, @@ -1756,7 +1772,7 @@ class VectorTools const unsigned int component); /** - * Calls the compute_mean_value() + * Calls the other compute_mean_value() * function, see above, with * mapping=MappingQ1@(). */ -- 2.39.5