From: Timo Heister Date: Thu, 24 Oct 2019 20:13:01 +0000 (+0200) Subject: address comments X-Git-Tag: v9.2.0-rc1~943^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=00d907ce938d5e5827670f34b3e61f5194aa6dc5;p=dealii.git address comments --- diff --git a/include/deal.II/fe/fe_interface_values.h b/include/deal.II/fe/fe_interface_values.h index 50100a27c8..30dbeb9359 100644 --- a/include/deal.II/fe/fe_interface_values.h +++ b/include/deal.II/fe/fe_interface_values.h @@ -322,7 +322,7 @@ public: const unsigned int component = 0) const; /** - * Return the average of the hessian $\{\nabla^2 u \} = \frac{1}{2}\nabla^2 + * Return the average of the Hessian $\{\nabla^2 u \} = \frac{1}{2}\nabla^2 * u_{\text{cell0}} + \frac{1}{2} \nabla^2 u_{\text{cell1}}$ on the interface * for the shape function @p interface_dof_index at the quadrature point @p * q_point of component @p component. @@ -679,14 +679,14 @@ FEInterfaceValues::shape_value( const unsigned int q_point, const unsigned int component) const { - const auto dofpair = dofmap[interface_dof_index]; + const auto dof_pair = dofmap[interface_dof_index]; - if (here_or_there && dofpair[0] != numbers::invalid_unsigned_int) - return get_fe_face_values(0).shape_value_component(dofpair[0], + if (here_or_there && dof_pair[0] != numbers::invalid_unsigned_int) + return get_fe_face_values(0).shape_value_component(dof_pair[0], q_point, component); - if (!here_or_there && dofpair[1] != numbers::invalid_unsigned_int) - return get_fe_face_values(1).shape_value_component(dofpair[1], + if (!here_or_there && dof_pair[1] != numbers::invalid_unsigned_int) + return get_fe_face_values(1).shape_value_component(dof_pair[1], q_point, component); @@ -701,16 +701,16 @@ FEInterfaceValues::jump(const unsigned int interface_dof_index, const unsigned int q_point, const unsigned int component) const { - const auto dofpair = dofmap[interface_dof_index]; + const auto dof_pair = dofmap[interface_dof_index]; double value = 0.0; - if (dofpair[0] != numbers::invalid_unsigned_int) - value += get_fe_face_values(0).shape_value_component(dofpair[0], + if (dof_pair[0] != numbers::invalid_unsigned_int) + value += get_fe_face_values(0).shape_value_component(dof_pair[0], q_point, component); - if (dofpair[1] != numbers::invalid_unsigned_int) - value -= get_fe_face_values(1).shape_value_component(dofpair[1], + if (dof_pair[1] != numbers::invalid_unsigned_int) + value -= get_fe_face_values(1).shape_value_component(dof_pair[1], q_point, component); return value; @@ -725,21 +725,21 @@ FEInterfaceValues::average( const unsigned int q_point, const unsigned int component) const { - const auto dofpair = dofmap[interface_dof_index]; + const auto dof_pair = dofmap[interface_dof_index]; if (at_boundary()) - return 1.0 * get_fe_face_values(0).shape_value_component(dofpair[0], + return 1.0 * get_fe_face_values(0).shape_value_component(dof_pair[0], q_point, component); double value = 0.0; - if (dofpair[0] != numbers::invalid_unsigned_int) - value += 0.5 * get_fe_face_values(0).shape_value_component(dofpair[0], + if (dof_pair[0] != numbers::invalid_unsigned_int) + value += 0.5 * get_fe_face_values(0).shape_value_component(dof_pair[0], q_point, component); - if (dofpair[1] != numbers::invalid_unsigned_int) - value += 0.5 * get_fe_face_values(1).shape_value_component(dofpair[1], + if (dof_pair[1] != numbers::invalid_unsigned_int) + value += 0.5 * get_fe_face_values(1).shape_value_component(dof_pair[1], q_point, component); @@ -755,21 +755,21 @@ FEInterfaceValues::average_gradient( const unsigned int q_point, const unsigned int component) const { - const auto dofpair = dofmap[interface_dof_index]; + const auto dof_pair = dofmap[interface_dof_index]; if (at_boundary()) - return get_fe_face_values(0).shape_grad_component(dofpair[0], + return get_fe_face_values(0).shape_grad_component(dof_pair[0], q_point, component); Tensor<1, dim> value; - if (dofpair[0] != numbers::invalid_unsigned_int) - value += 0.5 * get_fe_face_values(0).shape_grad_component(dofpair[0], + if (dof_pair[0] != numbers::invalid_unsigned_int) + value += 0.5 * get_fe_face_values(0).shape_grad_component(dof_pair[0], q_point, component); - if (dofpair[1] != numbers::invalid_unsigned_int) - value += 0.5 * get_fe_face_values(1).shape_grad_component(dofpair[1], + if (dof_pair[1] != numbers::invalid_unsigned_int) + value += 0.5 * get_fe_face_values(1).shape_grad_component(dof_pair[1], q_point, component); @@ -785,27 +785,29 @@ FEInterfaceValues::average_hessian( const unsigned int q_point, const unsigned int component) const { - const auto dofpair = dofmap[interface_dof_index]; + const auto dof_pair = dofmap[interface_dof_index]; if (at_boundary()) - return get_fe_face_values(0).shape_hessian_component(dofpair[0], + return get_fe_face_values(0).shape_hessian_component(dof_pair[0], q_point, component); Tensor<2, dim> value; - if (dofpair[0] != numbers::invalid_unsigned_int) - value += 0.5 * get_fe_face_values(0).shape_hessian_component(dofpair[0], + if (dof_pair[0] != numbers::invalid_unsigned_int) + value += 0.5 * get_fe_face_values(0).shape_hessian_component(dof_pair[0], q_point, component); - if (dofpair[1] != numbers::invalid_unsigned_int) - value += 0.5 * get_fe_face_values(1).shape_hessian_component(dofpair[1], + if (dof_pair[1] != numbers::invalid_unsigned_int) + value += 0.5 * get_fe_face_values(1).shape_hessian_component(dof_pair[1], q_point, component); return value; } + + template Tensor<1, dim> FEInterfaceValues::jump_gradient( @@ -813,21 +815,21 @@ FEInterfaceValues::jump_gradient( const unsigned int q_point, const unsigned int component) const { - const auto dofpair = dofmap[interface_dof_index]; + const auto dof_pair = dofmap[interface_dof_index]; if (at_boundary()) - return get_fe_face_values(0).shape_grad_component(dofpair[0], + return get_fe_face_values(0).shape_grad_component(dof_pair[0], q_point, component); Tensor<1, dim> value; - if (dofpair[0] != numbers::invalid_unsigned_int) - value += 1.0 * get_fe_face_values(0).shape_grad_component(dofpair[0], + if (dof_pair[0] != numbers::invalid_unsigned_int) + value += 1.0 * get_fe_face_values(0).shape_grad_component(dof_pair[0], q_point, component); - if (dofpair[1] != numbers::invalid_unsigned_int) - value += -1.0 * get_fe_face_values(1).shape_grad_component(dofpair[1], + if (dof_pair[1] != numbers::invalid_unsigned_int) + value += -1.0 * get_fe_face_values(1).shape_grad_component(dof_pair[1], q_point, component);