1469 {
1471
1472 const double vol = getMeasure();
1473 auto t_h = getFTensor0FromVec(*
hPtr);
1474
1475 auto t_row_base = row_data.getFTensor0N();
1476 auto t_row_diff_base = row_data.getFTensor1DiffN<
SPACE_DIM>();
1477 auto t_w = getFTensor0IntegrationWeight();
1478 auto t_coords = getFTensor1CoordsAtGaussPts();
1479
1480 for (int gg = 0; gg != nbIntegrationPts; ++gg) {
1481
1482 const double r = t_coords(0);
1484
1485 const double f_dh =
get_f_dh(t_h) * alpha;
1486 const double beta =
eta2 * alpha;
1487
1488 int rr = 0;
1489 for (; rr != nbRows; ++rr) {
1490
1491 auto t_col_base = col_data.getFTensor0N(gg, 0);
1492 auto t_col_diff_base = col_data.getFTensor1DiffN<
SPACE_DIM>(gg, 0);
1493
1494 for (int cc = 0; cc != nbCols; ++cc) {
1495
1496 if constexpr (
I ==
false)
1497 locMat(rr, cc) -= (t_row_base * t_col_base) * f_dh;
1498 locMat(rr, cc) -= (t_row_diff_base(
i) * beta) * t_col_diff_base(
i);
1499
1500 ++t_col_base;
1501 ++t_col_diff_base;
1502 }
1503
1504 ++t_row_base;
1505 ++t_row_diff_base;
1506 }
1507
1508 for (; rr < nbRowBaseFunctions; ++rr) {
1509 ++t_row_base;
1510 ++t_row_diff_base;
1511 }
1512
1513 ++t_h;
1514 ++t_w;
1515 ++t_coords;
1516 }
1517
1519 }
#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()
auto cylindrical
[cylindrical]
auto get_f_dh
Derivative of double-well potential.
FTensor::Index< 'i', SPACE_DIM > i
constexpr IntegrationType I