749 {
751
752 const double vol = getMeasure();
753 auto t_w = getFTensor0IntegrationWeight();
754 auto t_coords = getFTensor1CoordsAtGaussPts();
755 auto t_row_base = row_data.getFTensor0N();
756 auto t_row_diff_base = row_data.getFTensor1DiffN<
SPACE_DIM>();
757
758#ifndef NDEBUG
759 if (row_data.getDiffN().size1() != row_data.getN().size1())
761 if (row_data.getDiffN().size2() != row_data.getN().size2() *
SPACE_DIM) {
763 << "Side " << rowSide << " " << CN::EntityTypeName(rowType);
764 MOFEM_LOG(
"SELF", Sev::error) << row_data.getN();
765 MOFEM_LOG(
"SELF", Sev::error) << row_data.getDiffN();
767 }
768
769 if (col_data.getDiffN().size1() != col_data.getN().size1())
771 if (col_data.getDiffN().size2() != col_data.getN().size2() *
SPACE_DIM) {
773 << "Side " << rowSide << " " << CN::EntityTypeName(rowType);
774 MOFEM_LOG(
"SELF", Sev::error) << col_data.getN();
775 MOFEM_LOG(
"SELF", Sev::error) << col_data.getDiffN();
777 }
778#endif
779
780 auto t_T = getFTensor0FromVec(*
TPtr);
781
782
783 for (int gg = 0; gg != nbIntegrationPts; gg++) {
784
785 const double alpha = t_w * vol;
786
787 int rr = 0;
788 for (; rr != nbRows; ++rr) {
789
790 auto t_col_base = col_data.getFTensor0N(gg, 0);
791 auto t_col_diff_base = col_data.getFTensor1DiffN<
SPACE_DIM>(gg, 0);
792
793 for (int cc = 0; cc != nbCols; ++cc) {
794
795 locMat(rr, cc) += (t_row_base * t_col_base * alpha);
796
797 ++t_col_base;
798 ++t_col_diff_base;
799 }
800
801 ++t_row_base;
802 ++t_row_diff_base;
803 }
804
805 for (; rr < nbRowBaseFunctions; ++rr) {
806 ++t_row_base;
807 ++t_row_diff_base;
808 }
809
810 ++t_T;
811
812 ++t_w;
813 ++t_coords;
814 }
815
817 }
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
@ MOFEM_DATA_INCONSISTENCY
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
#define MOFEM_LOG(channel, severity)
Log.