Assert (dynamic_cast<const InternalData *> (&fe_internal) != 0, ExcInternalError());
const InternalData &fe_data = static_cast<const InternalData &> (fe_internal);
- for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ // transform gradients and higher derivatives. there is nothing to do
+ // for values since we already emplaced them into output_data when
+ // we were in get_data()
+ if (fe_data.update_each & update_gradients && cell_similarity != CellSimilarity::translation)
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ mapping.transform (fe_data.shape_gradients[k],
+ mapping_covariant,
+ mapping_internal,
+ output_data.shape_gradients[k]);
+
+ if (fe_data.update_each & update_hessians && cell_similarity != CellSimilarity::translation)
{
- // transform gradients and higher derivatives. there is nothing to do
- // for values since we already emplaced them into output_data when
- // we were in get_data()
- if (fe_data.update_each & update_gradients && cell_similarity != CellSimilarity::translation)
- mapping.transform (fe_data.shape_gradients[k],
- mapping_covariant,
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ mapping.transform (fe_data.shape_hessians[k],
+ mapping_covariant_gradient,
mapping_internal,
- output_data.shape_gradients[k]);
-
- if (fe_data.update_each & update_hessians && cell_similarity != CellSimilarity::translation)
- {
- mapping.transform (fe_data.shape_hessians[k],
- mapping_covariant_gradient,
- mapping_internal,
- output_data.shape_hessians[k]);
-
- for (unsigned int i=0; i<quadrature.size(); ++i)
- for (unsigned int j=0; j<2; ++j)
- output_data.shape_hessians[k][i] -=
- mapping_data.jacobian_pushed_forward_grads[i][j]
- * output_data.shape_gradients[k][i][j];
- }
-
- if (fe_data.update_each & update_3rd_derivatives && cell_similarity != CellSimilarity::translation)
- {
- mapping.transform (fe_data.shape_3rd_derivatives[k],
- mapping_covariant_hessian,
- mapping_internal,
- output_data.shape_3rd_derivatives[k]);
-
- correct_third_derivatives(output_data, mapping_data, quadrature.size(), k);
- }
+ output_data.shape_hessians[k]);
+
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ for (unsigned int i=0; i<quadrature.size(); ++i)
+ for (unsigned int j=0; j<2; ++j)
+ output_data.shape_hessians[k][i] -=
+ mapping_data.jacobian_pushed_forward_grads[i][j]
+ * output_data.shape_gradients[k][i][j];
+ }
+
+ if (fe_data.update_each & update_3rd_derivatives && cell_similarity != CellSimilarity::translation)
+ {
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ mapping.transform (fe_data.shape_3rd_derivatives[k],
+ mapping_covariant_hessian,
+ mapping_internal,
+ output_data.shape_3rd_derivatives[k]);
+
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ correct_third_derivatives(output_data, mapping_data, quadrature.size(), k);
}
}
Assert (dynamic_cast<const InternalData *> (&fe_internal) != 0, ExcInternalError());
const InternalData &fe_data = static_cast<const InternalData &> (fe_internal);
- for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ // transform gradients and higher derivatives. there is nothing to do
+ // for values since we already emplaced them into output_data when
+ // we were in get_data()
+ if (fe_data.update_each & update_gradients && cell_similarity != CellSimilarity::translation)
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ mapping.transform (fe_data.shape_gradients[k],
+ mapping_covariant,
+ mapping_internal,
+ output_data.shape_gradients[k]);
+
+ if (fe_data.update_each & update_hessians && cell_similarity != CellSimilarity::translation)
{
- // transform gradients and higher derivatives. there is nothing to do
- // for values since we already emplaced them into output_data when
- // we were in get_data()
- if (fe_data.update_each & update_gradients && cell_similarity != CellSimilarity::translation)
- mapping.transform (fe_data.shape_gradients[k],
- mapping_covariant,
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ mapping.transform (fe_data.shape_hessians[k],
+ mapping_covariant_gradient,
mapping_internal,
- output_data.shape_gradients[k]);
-
- if (fe_data.update_each & update_hessians && cell_similarity != CellSimilarity::translation)
- {
- mapping.transform (fe_data.shape_hessians[k],
- mapping_covariant_gradient,
- mapping_internal,
- output_data.shape_hessians[k]);
-
- for (unsigned int i=0; i<quadrature.size(); ++i)
- for (unsigned int j=0; j<3; ++j)
- output_data.shape_hessians[k][i] -=
- mapping_data.jacobian_pushed_forward_grads[i][j]
- * output_data.shape_gradients[k][i][j];
- }
-
- if (fe_data.update_each & update_3rd_derivatives && cell_similarity != CellSimilarity::translation)
- {
- mapping.transform (fe_data.shape_3rd_derivatives[k],
- mapping_covariant_hessian,
- mapping_internal,
- output_data.shape_3rd_derivatives[k]);
-
- correct_third_derivatives(output_data, mapping_data, quadrature.size(), k);
- }
+ output_data.shape_hessians[k]);
+
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ for (unsigned int i=0; i<quadrature.size(); ++i)
+ for (unsigned int j=0; j<3; ++j)
+ output_data.shape_hessians[k][i] -=
+ mapping_data.jacobian_pushed_forward_grads[i][j]
+ * output_data.shape_gradients[k][i][j];
+ }
+
+ if (fe_data.update_each & update_3rd_derivatives && cell_similarity != CellSimilarity::translation)
+ {
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ mapping.transform (fe_data.shape_3rd_derivatives[k],
+ mapping_covariant_hessian,
+ mapping_internal,
+ output_data.shape_3rd_derivatives[k]);
+
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ correct_third_derivatives(output_data, mapping_data, quadrature.size(), k);
}
}
Assert (dynamic_cast<const InternalData *> (&fe_internal) != 0, ExcInternalError());
const InternalData &fe_data = static_cast<const InternalData &> (fe_internal);
- for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ // transform gradients and higher derivatives. there is nothing to do
+ // for values since we already emplaced them into output_data when
+ // we were in get_data()
+ if (fe_data.update_each & update_gradients && cell_similarity != CellSimilarity::translation)
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ mapping.transform (fe_data.shape_gradients[k],
+ mapping_covariant,
+ mapping_internal,
+ output_data.shape_gradients[k]);
+
+ if (fe_data.update_each & update_hessians && cell_similarity != CellSimilarity::translation)
{
- // transform gradients and higher derivatives. there is nothing to do
- // for values since we already emplaced them into output_data when
- // we were in get_data()
- if (fe_data.update_each & update_gradients && cell_similarity != CellSimilarity::translation)
- mapping.transform (fe_data.shape_gradients[k],
- mapping_covariant,
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ mapping.transform (fe_data.shape_hessians[k],
+ mapping_covariant_gradient,
mapping_internal,
- output_data.shape_gradients[k]);
-
- if (fe_data.update_each & update_hessians && cell_similarity != CellSimilarity::translation)
- {
- mapping.transform (fe_data.shape_hessians[k],
- mapping_covariant_gradient,
- mapping_internal,
- output_data.shape_hessians[k]);
-
- for (unsigned int i=0; i<quadrature.size(); ++i)
- for (unsigned int j=0; j<2; ++j)
- output_data.shape_hessians[k][i] -=
- mapping_data.jacobian_pushed_forward_grads[i][j]
- * output_data.shape_gradients[k][i][j];
- }
-
- if (fe_data.update_each & update_3rd_derivatives && cell_similarity != CellSimilarity::translation)
- {
- mapping.transform (fe_data.shape_3rd_derivatives[k],
- mapping_covariant_hessian,
- mapping_internal,
- output_data.shape_3rd_derivatives[k]);
-
- correct_third_derivatives(output_data, mapping_data, quadrature.size(), k);
- }
+ output_data.shape_hessians[k]);
+
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ for (unsigned int i=0; i<quadrature.size(); ++i)
+ for (unsigned int j=0; j<2; ++j)
+ output_data.shape_hessians[k][i] -=
+ mapping_data.jacobian_pushed_forward_grads[i][j]
+ * output_data.shape_gradients[k][i][j];
+ }
+
+ if (fe_data.update_each & update_3rd_derivatives && cell_similarity != CellSimilarity::translation)
+ {
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ mapping.transform (fe_data.shape_3rd_derivatives[k],
+ mapping_covariant_hessian,
+ mapping_internal,
+ output_data.shape_3rd_derivatives[k]);
+
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ correct_third_derivatives(output_data, mapping_data, quadrature.size(), k);
}
}
Assert (dynamic_cast<const InternalData *> (&fe_internal) != 0, ExcInternalError());
const InternalData &fe_data = static_cast<const InternalData &> (fe_internal);
- for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ // transform gradients and higher derivatives. there is nothing to do
+ // for values since we already emplaced them into output_data when
+ // we were in get_data()
+ if (fe_data.update_each & update_gradients && cell_similarity != CellSimilarity::translation)
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ mapping.transform (fe_data.shape_gradients[k],
+ mapping_covariant,
+ mapping_internal,
+ output_data.shape_gradients[k]);
+
+ if (fe_data.update_each & update_hessians && cell_similarity != CellSimilarity::translation)
{
- // transform gradients and higher derivatives. there is nothing to do
- // for values since we already emplaced them into output_data when
- // we were in get_data()
- if (fe_data.update_each & update_gradients && cell_similarity != CellSimilarity::translation)
- mapping.transform (fe_data.shape_gradients[k],
- mapping_covariant,
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ mapping.transform (fe_data.shape_hessians[k],
+ mapping_covariant_gradient,
mapping_internal,
- output_data.shape_gradients[k]);
-
- if (fe_data.update_each & update_hessians && cell_similarity != CellSimilarity::translation)
- {
- mapping.transform (fe_data.shape_hessians[k],
- mapping_covariant_gradient,
- mapping_internal,
- output_data.shape_hessians[k]);
-
- for (unsigned int i=0; i<quadrature.size(); ++i)
- for (unsigned int j=0; j<3; ++j)
- output_data.shape_hessians[k][i] -=
- mapping_data.jacobian_pushed_forward_grads[i][j]
- * output_data.shape_gradients[k][i][j];
- }
-
- if (fe_data.update_each & update_3rd_derivatives && cell_similarity != CellSimilarity::translation)
- {
- mapping.transform (fe_data.shape_3rd_derivatives[k],
- mapping_covariant_hessian,
- mapping_internal,
- output_data.shape_3rd_derivatives[k]);
-
- correct_third_derivatives(output_data, mapping_data, quadrature.size(), k);
- }
+ output_data.shape_hessians[k]);
+
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ for (unsigned int i=0; i<quadrature.size(); ++i)
+ for (unsigned int j=0; j<3; ++j)
+ output_data.shape_hessians[k][i] -=
+ mapping_data.jacobian_pushed_forward_grads[i][j]
+ * output_data.shape_gradients[k][i][j];
+ }
+
+ if (fe_data.update_each & update_3rd_derivatives && cell_similarity != CellSimilarity::translation)
+ {
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ mapping.transform (fe_data.shape_3rd_derivatives[k],
+ mapping_covariant_hessian,
+ mapping_internal,
+ output_data.shape_3rd_derivatives[k]);
+
+ for (unsigned int k=0; k<this->dofs_per_cell; ++k)
+ correct_third_derivatives(output_data, mapping_data, quadrature.size(), k);
}
}