263 if (
entsPtr->find(BoundaryEleOp::getFEEntityHandle()) ==
entsPtr->end())
266 const double area = getMeasure();
268 const auto row_size = data.getIndices().size();
272 auto integrate = [&](
auto col_indicies,
auto &col_diff_base_functions) {
275 const auto col_size = col_indicies.size();
277 locMat.resize(row_size, col_size,
false);
279 int nb_gp = getGaussPts().size2();
280 int nb_rows = data.getIndices().size();
282 auto t_w = getFTensor0IntegrationWeight();
283 auto t_coords = getFTensor1CoordsAtGaussPts();
284 auto t_grad_h = getFTensor1FromMat<SPACE_DIM>(*
gradHPtr);
285 auto t_row_base = data.getFTensor0N();
286 int nb_row_base_functions = data.getN().size2();
290 for (
int gg = 0; gg != nb_gp; ++gg) {
292 const double r = t_coords(0);
294 const double h_grad_norm = sqrt(t_grad_h(
i) * t_grad_h(
i) +
eps);
295 const double one_over_h_grad_norm = 1. / h_grad_norm;
296 const double beta = s * alpha *
eta2 * one_over_h_grad_norm *
300 for (; rr != nb_rows; ++rr) {
301 const double delta = beta * t_row_base;
303 auto ptr = &col_diff_base_functions(gg, 0);
304 auto t_col_diff_base = getFTensor1FromPtr<SPACE_DIM>(ptr);
306 for (
int cc = 0; cc != col_size; ++cc) {
307 locMat(rr, cc) += t_col_diff_base(
i) * (
delta * t_grad_h(
i));
313 for (; rr < nb_row_base_functions; ++rr) {
327 auto &col_ind = (*colIndicesPtr)[
c];
328 if (col_ind.size()) {
329 auto &diff_base = (*colDiffBaseFunctionsPtr)[
c];
331 CHKERR integrate(col_ind, diff_base);
334 &*data.getIndices().begin(), col_ind.size(),
335 &*col_ind.begin(), &
locMat(0, 0), ADD_VALUES);