From: kanschat Date: Mon, 29 Nov 2010 17:17:26 +0000 (+0000) Subject: move grad_div to Divergence X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8e18c79493a26032fd0219c1067b623909b3a67a;p=dealii-svn.git move grad_div to Divergence git-svn-id: https://svn.dealii.org/trunk@22880 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/include/deal.II/integrators/divergence.h b/deal.II/include/deal.II/integrators/divergence.h index 23ab7dbaf9..57145b923c 100644 --- a/deal.II/include/deal.II/integrators/divergence.h +++ b/deal.II/include/deal.II/integrators/divergence.h @@ -243,6 +243,43 @@ namespace LocalIntegrators } } +/** + * The weak form of the grad-div operator penalizing volume changes + * @f[ + * \int_Z \nabla\!\cdot\!u \nabla\!\cdot\!v \,dx + * @f] + */ + template + void grad_div_matrix ( + FullMatrix& M, + const FEValuesBase& fe, + double factor = 1.) + { + const unsigned int n_dofs = fe.dofs_per_cell; + + AssertDimension(fe.get_fe().n_components(), dim); + AssertDimension(M.m(), n_dofs); + AssertDimension(M.n(), n_dofs); + + for (unsigned k=0;k - void grad_div_matrix ( - FullMatrix& M, - const FEValuesBase& fe, - double factor = 1.) - { - const unsigned int n_dofs = fe.dofs_per_cell; - - AssertDimension(fe.get_fe().n_components(), dim); - AssertDimension(M.m(), n_dofs); - AssertDimension(M.n(), n_dofs); - - for (unsigned k=0;k