1189 {
1192
1193#ifndef NDEBUG
1196 "Broken side data pointer is null");
1197#endif
1198
1199
1200 const int nb_dofs = data.
getIndices().size();
1201 if (!nb_dofs)
1203
1204 const int nb_integration_pts = getGaussPts().size2();
1205 const int nb_base_functions = data.
getN().size2();
1206
1207 if (data.
getDiffN().size1() != nb_integration_pts)
1209 "Differential of base functions should have the same number of "
1210 "integration points as the data");
1211 if (data.
getDiffN().size2() != nb_base_functions * 2)
1213 "Differential of base functions should have the same number of "
1214 "base functions as the data");
1215
1216 double time = getFEMethod()->ts_t;
1219
1221
1224
1227 if (bc.faces.find(fe_ent) == bc.faces.end())
1228 continue;
1229
1233 } else {
1235 << "No scaling method found for " << bc.blockName;
1236 }
1237
1239 bc.vals[2]);
1241
1243 auto t_w = getFTensor0IntegrationWeight();
1244 auto t_tangent1 = getFTensor1Tangent1AtGaussPts();
1245 auto t_tangent2 = getFTensor1Tangent2AtGaussPts();
1246 auto t_var_flux =
1247 getFTensor2FromMat<SPACE_DIM, SPACE_DIM>(bd.getVarFlux());
1249
1250 for (int gg = 0; gg != nb_integration_pts; ++gg) {
1251 const double a = 0.5 * bd.getSense() * t_w;
1252
1256
1257 locJ +=
a * t_bc_disp(
i) * (t_var_flux(
i,
j) * t_normal(
j));
1258
1259 auto t_nf = getFTensor1FromArray<SPACE_DIM, SPACE_DIM>(
nF);
1260 int bb = 0;
1261 for (; bb != nb_dofs /
SPACE_DIM; ++bb) {
1262
1263
1264
1265
1266 ++t_nf;
1267 ++t_diff_base;
1268 }
1269 for (; bb != nb_base_functions; ++bb)
1270 ++t_diff_base;
1271
1272 ++t_w;
1273 ++t_tangent1;
1274 ++t_tangent2;
1275 ++t_var_flux;
1276 }
1277 }
1278
1279 }
1280
1281
1283}
#define FTENSOR_INDEXES(DIM,...)
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return()
#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
FTensor::Index< 'j', 3 > j
FTensor::Index< 'k', 3 > k
constexpr std::enable_if<(Dim0<=2 &&Dim1<=2), Tensor2_Expr< Levi_Civita< T >, T, Dim0, Dim1, i, j > >::type levi_civita(const Index< i, Dim0 > &, const Index< j, Dim1 > &)
levi_civita functions to make for easy adhoc use
constexpr IntegrationType I
static PetscBool physicalTimeFlg
static double currentPhysicalTime
MatrixDouble & getDiffN(const FieldApproximationBase base)
get derivatives of base functions
auto getFTensor1DiffN(const FieldApproximationBase base)
Get derivatives of base functions.
MatrixDouble & getN(const FieldApproximationBase base)
get base functions this return matrix (nb. of rows is equal to nb. of Gauss pts, nb....
const VectorInt & getIndices() const
Get global indices of degrees of freedom on entity.
VectorDouble nF
local right hand side vector