633 {
635 const int nb_integration_pts = getGaussPts().size2();
636 const double area = getMeasure();
637 auto t_w = getFTensor0IntegrationWeight();
639
640 double values_integ = 0;
641
642 for (int gg = 0; gg != nb_integration_pts; ++gg) {
643 const double alpha = t_w * area;
644
645 values_integ += alpha * t_val;
646
647 ++t_w;
648 ++t_val;
649 }
650
652 std::array<double, 1> values;
653 values[0] = values_integ;
655 ADD_VALUES);
657}
#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()
#define CHKERR
Inline error check.
static auto getFTensor0FromVec(ublas::vector< T, A > &data)
Get tensor rank 0 (scalar) form data vector.
MoFEMErrorCode VecSetValues(Vec V, const EntitiesFieldData::EntData &data, const double *ptr, InsertMode iora)
Assemble PETSc vector.