451 {
453
455
456 const double vol = getMeasure();
457 auto t_w = getFTensor0IntegrationWeight();
458 auto t_coords = getFTensor1CoordsAtGaussPts();
459 auto t_base = data.getFTensor1N<3>();
460 auto t_diff_base = data.getFTensor1DiffN<
SPACE_DIM>();
461
462#ifndef NDEBUG
463 if (data.getDiffN().size1() != data.getN().size1())
465 if (data.getDiffN().size2() != data.getN().size2() *
SPACE_DIM) {
467 << "Side " << rowSide << " " << CN::EntityTypeName(rowType);
468 MOFEM_LOG(
"SELF", Sev::error) << data.getN();
469 MOFEM_LOG(
"SELF", Sev::error) << data.getDiffN();
471 }
472#endif
473
474 auto t_old_sol = getFTensor1FromMat<SPACE_DIM>(*
oldSolPtr);
475 auto t_new_sol = getFTensor1FromMat<SPACE_DIM>(*
newSolPtr);
476
477 for (int gg = 0; gg != nbIntegrationPts; ++gg) {
478
479 const double alpha =
480 t_w * vol *
scalarFunction(t_coords(0), t_coords(1), t_coords(2));
481
482 int bb = 0;
483 for (; bb != nbRows; ++bb) {
484 locF[bb] += (t_base(
i) * alpha) *
487 ++t_base;
488 ++t_diff_base;
489 }
490
491 for (; bb < nbRowBaseFunctions; ++bb) {
492 ++t_base;
493 ++t_diff_base;
494 }
495
496 ++t_old_sol;
497 ++t_new_sol;
498
499 ++t_coords;
500 ++t_w;
501 }
502
504 }
#define FTENSOR_INDEX(DIM, I)
constexpr int SPACE_DIM
[Define dimension]
#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.
FTensor::Index< 'i', SPACE_DIM > i