2016 {
2018
2019 EntityHandle fe_ent = OP::getFEEntityHandle();
2020
2022
2023 if (bc.faces.find(fe_ent) != bc.faces.end()) {
2025
2026 int nb_integration_pts = OP::getGaussPts().size2();
2027 auto t_w = OP::getFTensor0IntegrationWeight();
2028 int nb_base_functions = row_data.
getN().size2();
2030
2033
2034 auto get_t_vec = [&](const int rr) {
2035 std::array<double *, SPACE_DIM> ptrs;
2037 ptrs[
i] = &OP::locMat(rr +
i,
i);
2040 };
2041
2042 auto area = getMeasure();
2043 auto t_coords = OP::getFTensor1CoordsAtGaussPts();
2044 for (int gg = 0; gg != nb_integration_pts; ++gg) {
2045 auto tau_scale =
2046 area * t_w * OP::betaCoeff(t_coords(0), t_coords(1), t_coords(2));
2047 int rr = 0;
2048 for (; rr != nb_dofs /
SPACE_DIM; ++rr) {
2051 for (
int cc = 0; cc != nb_dofs /
SPACE_DIM; ++cc) {
2052 for (
int ii = 0; ii !=
SPACE_DIM; ++ii) {
2053 t_mat(ii) += tau_scale * (t_row_base_fun * t_col_base_fun);
2054 }
2055 ++t_col_base_fun;
2056 ++t_mat;
2057 }
2058 ++t_row_base_fun;
2059 }
2060 for (; rr != nb_base_functions; ++rr)
2061 ++t_row_base_fun;
2062
2063 ++t_w;
2064 ++t_coords;
2065 }
2066 }
2067 }
2068
2070}
#define FTENSOR_INDEX(DIM, I)
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
FTensor::Index< 'i', SPACE_DIM > i
FTensor::Index< 'j', 3 > j
FTensor::Tensor0< FTensor::PackPtr< double *, 1 > > getFTensor0N(const FieldApproximationBase base)
Get base function as Tensor0.
MatrixDouble & getN(const FieldApproximationBase base)
get base functions this return matrix (nb. of rows is equal to nb. of Gauss pts, nb....
const VectorInt & getIndices() const
Get global indices of degrees of freedom on entity.