9#ifndef EXECUTABLE_DIMENSION
10#define EXECUTABLE_DIMENSION 3
37 : AssemblyType::PETSC;
39 IntegrationType::GAUSS;
52 GAUSS>::OpGradSymTensorGrad<1, SPACE_DIM, SPACE_DIM, 0>;
66 GAUSS>::OpGradTensorGrad<1, SPACE_DIM, SPACE_DIM, 1>;
118 std::max(
static_cast<double>(std::numeric_limits<float>::min_exponent10),
128 constexpr double eps = 1e-12;
129 return std::max(r(tau),
eps * r(0));
195 auto get_ents_by_dim = [&](
const auto dim) {
208 auto get_base = [&]() {
209 auto domain_ents = get_ents_by_dim(
SPACE_DIM);
210 if (domain_ents.empty())
228 const auto base = get_base();
238 auto ents = get_ents_by_dim(0);
239 ents.merge(get_ents_by_dim(1));
250 auto project_ho_geometry = [&]() {
254 CHKERR project_ho_geometry();
264 auto get_command_line_parameters = [&]() {
294 MOFEM_LOG(
"EXAMPLE", Sev::inform) <<
"Hardening " <<
H;
295 MOFEM_LOG(
"EXAMPLE", Sev::inform) <<
"Viscous hardening " <<
visH;
296 MOFEM_LOG(
"EXAMPLE", Sev::inform) <<
"Saturation yield stress " <<
Qinf;
297 MOFEM_LOG(
"EXAMPLE", Sev::inform) <<
"Saturation exponent " <<
b_iso;
305 PetscBool is_scale = PETSC_TRUE;
322 MOFEM_LOG(
"EXAMPLE", Sev::inform) <<
"Scaled Hardening " <<
H;
323 MOFEM_LOG(
"EXAMPLE", Sev::inform) <<
"Scaled Viscous hardening " <<
visH;
325 <<
"Scaled Saturation yield stress " <<
Qinf;
331 auto set_matrial_stiffness = [&]() {
347 auto t_D = getFTensor4DdgFromMat<SPACE_DIM, SPACE_DIM, 0>(
349 auto t_D_axiator = getFTensor4DdgFromMat<SPACE_DIM, SPACE_DIM, 0>(
351 auto t_D_deviator = getFTensor4DdgFromMat<SPACE_DIM, SPACE_DIM, 0>(
354 constexpr double third = boost::math::constants::third<double>();
355 t_D_axiator(
i,
j,
k,
l) =
A *
358 t_D_deviator(
i,
j,
k,
l) =
360 t_D(
i,
j,
k,
l) = t_D_axiator(
i,
j,
k,
l) + t_D_deviator(
i,
j,
k,
l);
365 auto make_d_mat = []() {
378 CHKERR get_command_line_parameters();
379 CHKERR set_matrial_stiffness();
404 CHKERR bc_mng->removeBlockDOFsOnEntities(
simple->getProblemName(),
"REMOVE_X",
406 CHKERR bc_mng->removeBlockDOFsOnEntities(
simple->getProblemName(),
"REMOVE_Y",
408 CHKERR bc_mng->removeBlockDOFsOnEntities(
simple->getProblemName(),
"REMOVE_Z",
410 CHKERR bc_mng->removeBlockDOFsOnEntities(
simple->getProblemName(),
411 "REMOVE_ALL",
"U", 0, 3);
414 simple->getProblemName(),
"U");
416 auto &bc_map = bc_mng->getBcMapByBlockName();
417 boundaryMarker = bc_mng->getMergedBlocksMarker(vector<string>{
"FIX_"});
419 CHKERR bc_mng->pushMarkDOFsOnEntities(
simple->getProblemName(),
"REACTION",
422 for (
auto bc : bc_map)
423 MOFEM_LOG(
"EXAMPLE", Sev::verbose) <<
"Marker " << bc.first;
428 std::string reaction_block_set;
429 for (
auto bc : bc_map) {
430 if (bc_mng->checkBlock(bc,
"REACTION")) {
431 reaction_block_set = bc.first;
436 if (
auto bc = bc_mng->popMarkDOFsOnEntities(reaction_block_set)) {
443 ProblemsManager::MarkOP::AND, nodes,
447 MOFEM_LOG(
"EXAMPLE", Sev::warning) <<
"REACTION blockset does not exist";
451 MOFEM_LOG(
"EXAMPLE", Sev::warning) <<
"REACTION blockset does not exist";
465 auto add_domain_base_ops = [&](
auto &pipeline) {
485 auto add_domain_stress_ops = [&](
auto &pipeline,
auto m_D_ptr) {
492 "Wrong pointer for grad");
523 auto add_domain_ops_lhs_mechanical = [&](
auto &pipeline,
auto m_D_ptr) {
535 pipeline.push_back(
new OpKCauchy(
"U",
"U", m_D_ptr));
544 auto add_domain_ops_rhs_mechanical = [&](
auto &pipeline) {
549 pipeline,
mField,
"U", {boost::make_shared<PlasticityTimeScale>()},
550 "BODY_FORCE", Sev::inform);
565 auto add_domain_ops_lhs_constrain = [&](
auto &pipeline,
auto m_D_ptr) {
594 auto add_domain_ops_rhs_constrain = [&](
auto &pipeline,
auto m_D_ptr) {
607 auto add_boundary_ops_lhs_mechanical = [&](
auto &pipeline) {
615 auto add_boundary_ops_rhs_mechanical = [&](
auto &pipeline) {
619 pipeline, {
NOSPACE},
"GEOMETRY");
623 pipeline,
mField,
"U", {boost::make_shared<PlasticityTimeScale>()},
624 "FORCE", Sev::inform);
628 auto u_mat_ptr = boost::make_shared<MatrixDouble>();
634 mField, pipeline,
simple->getProblemName(),
"U", u_mat_ptr,
635 {boost::make_shared<TimeScale>()});
641 CHKERR add_domain_base_ops(pip->getOpDomainLhsPipeline());
642 CHKERR add_domain_stress_ops(pip->getOpDomainLhsPipeline(),
644 CHKERR add_domain_ops_lhs_mechanical(pip->getOpDomainLhsPipeline(),
646 CHKERR add_domain_ops_lhs_constrain(pip->getOpDomainLhsPipeline(),
649 add_boundary_ops_lhs_mechanical(pip->getOpBoundaryLhsPipeline());
651 CHKERR add_domain_base_ops(pip->getOpDomainRhsPipeline());
652 CHKERR add_domain_stress_ops(pip->getOpDomainRhsPipeline(),
654 CHKERR add_domain_ops_rhs_mechanical(pip->getOpDomainRhsPipeline());
655 CHKERR add_domain_ops_rhs_constrain(pip->getOpDomainRhsPipeline(),
660 add_boundary_ops_rhs_mechanical(pip->getOpBoundaryRhsPipeline());
662 auto integration_rule_bc = [](int, int,
int ao) {
return 2 * ao; };
664 auto vol_rule = [](int, int,
int ao) {
return 2 * ao +
geom_order - 1; };
666 CHKERR pip->setDomainRhsIntegrationRule(vol_rule);
667 CHKERR pip->setDomainLhsIntegrationRule(vol_rule);
669 CHKERR pip->setBoundaryLhsIntegrationRule(integration_rule_bc);
670 CHKERR pip->setBoundaryRhsIntegrationRule(integration_rule_bc);
672 auto create_reaction_pipeline = [&](
auto &pipeline) {
690 "Wrong pointer for grad");
761 auto set_section_monitor = [&](
auto solver) {
764 CHKERR TSGetSNES(solver, &snes);
765 CHKERR SNESMonitorSet(snes,
768 (
void *)(snes_ctx_ptr.get()),
nullptr);
772 auto create_post_process_element = [&]() {
773 auto pp_fe = boost::make_shared<PostProcEle>(
mField);
777 pp_fe->getOpPtrVector(), {H1},
"GEOMETRY");
779 auto x_ptr = boost::make_shared<MatrixDouble>();
780 pp_fe->getOpPtrVector().push_back(
782 auto u_ptr = boost::make_shared<MatrixDouble>();
783 pp_fe->getOpPtrVector().push_back(
786 pp_fe->getOpPtrVector().push_back(
791 pp_fe->getOpPtrVector().push_back(
800 pp_fe->getOpPtrVector().push_back(
802 pp_fe->getOpPtrVector().push_back(
804 pp_fe->getOpPtrVector().push_back(
806 pp_fe->getOpPtrVector().push_back(
809 pp_fe->getOpPtrVector().push_back(
812 pp_fe->getOpPtrVector().push_back(
816 pp_fe->getPostProcMesh(), pp_fe->getMapGaussPts(),
820 {{
"U", u_ptr}, {
"GEOMETRY", x_ptr}},
832 pp_fe->getOpPtrVector().push_back(
838 pp_fe->getOpPtrVector().push_back(
842 pp_fe->getPostProcMesh(), pp_fe->getMapGaussPts(),
846 {{
"U", u_ptr}, {
"GEOMETRY", x_ptr}},
858 pp_fe->getOpPtrVector().push_back(
861 pp_fe->getOpPtrVector().push_back(
865 pp_fe->getPostProcMesh(), pp_fe->getMapGaussPts(),
867 {{
"PLASTIC_SURFACE", commonPlasticDataPtr->getPlasticSurfacePtr()},
868 {
"PLASTIC_MULTIPLIER", commonPlasticDataPtr->getPlasticTauPtr()}},
874 {{
"PLASTIC_STRAIN", commonPlasticDataPtr->getPlasticStrainPtr()},
875 {
"PLASTIC_FLOW", commonPlasticDataPtr->getPlasticFlowPtr()}}
884 auto scatter_create = [&](
auto D,
auto coeff) {
886 CHKERR is_manager->isCreateProblemFieldAndRank(
simple->getProblemName(),
887 ROW,
"U", coeff, coeff, is);
889 CHKERR ISGetLocalSize(is, &loc_size);
891 CHKERR VecCreateMPI(mField.get_comm(), loc_size, PETSC_DETERMINE, &
v);
893 CHKERR VecScatterCreate(
D, is,
v, PETSC_NULL, &scatter);
898 auto set_time_monitor = [&](
auto dm,
auto solver) {
900 boost::shared_ptr<Monitor> monitor_ptr(
901 new Monitor(dm, create_post_process_element(), reactionFe, uXScatter,
902 uYScatter, uZScatter));
903 boost::shared_ptr<ForcesAndSourcesCore> null;
905 monitor_ptr, null, null);
909 auto set_fieldsplit_preconditioner = [&](
auto solver,
910 boost::shared_ptr<SetUpSchur>
915 CHKERR TSGetSNES(solver, &snes);
917 CHKERR SNESGetKSP(snes, &ksp);
919 CHKERR KSPGetPC(ksp, &pc);
920 PetscBool is_pcfs = PETSC_FALSE;
921 PetscObjectTypeCompare((PetscObject)pc, PCFIELDSPLIT, &is_pcfs);
924 if (is_pcfs == PETSC_TRUE) {
926 auto bc_mng = mField.getInterface<
BcManager>();
927 auto name_prb =
simple->getProblemName();
940 for (
auto f : {
"U",
"EP",
"TAU"}) {
946 CHKERR bc_mng->removeBlockDOFsOnEntities(
"SUB_BC",
"FIX_X",
"U", 0, 0);
947 CHKERR bc_mng->removeBlockDOFsOnEntities(
"SUB_BC",
"FIX_Y",
"U", 1, 1);
948 CHKERR bc_mng->removeBlockDOFsOnEntities(
"SUB_BC",
"FIX_Z",
"U", 2, 2);
949 CHKERR bc_mng->removeBlockDOFsOnEntities(
"SUB_BC",
"FIX_ALL",
"U", 0,
953 if (
auto sub_data = prb_ptr->getSubData()) {
954 is_sub = sub_data->getSmartRowIs();
955 ao_sub = sub_data->getSmartRowMap();
957 CHKERR ISGetSize(is_sub, &is_sub_size);
959 <<
"Field split second block size " << is_sub_size;
978 for (
auto f : {
"U"}) {
985 if (
auto sub_data = prb_ptr->getSubData()) {
986 is_sub = sub_data->getSmartRowIs();
987 ao_sub = sub_data->getSmartRowMap();
990 CHKERR ISGetSize(is_sub, &is_sub_size);
992 <<
"Field split second block size " << is_sub_size;
1004 is_all_bc = bc_mng->getBlockIS(name_prb,
"FIX_X",
"U", 0, 0);
1005 is_all_bc = bc_mng->getBlockIS(name_prb,
"FIX_Y",
"U", 1, 1, is_all_bc);
1006 is_all_bc = bc_mng->getBlockIS(name_prb,
"FIX_Z",
"U", 2, 2, is_all_bc);
1008 bc_mng->getBlockIS(name_prb,
"FIX_ALL",
"U", 0, 2, is_all_bc);
1010 CHKERR ISGetSize(is_all_bc, &is_all_bc_size);
1012 <<
"Field split first block size " << is_all_bc_size;
1021 CHKERR create_all_bc_is(is_all_bc);
1022 CHKERR create_sub_bc_dm(
simple->getDM(), dm_bc_sub, is_bc_sub, ao_bc_sub);
1028 CHKERR PCFieldSplitSetIS(pc, PETSC_NULL,
1030 CHKERR PCFieldSplitSetIS(pc, PETSC_NULL, is_bc_sub);
1032 if constexpr (
A == AssemblyType::SCHUR) {
1041 CHKERR ISExpand(is_epp, is_tau, &is_union_raw);
1047 CHKERR create_sub_u_dm(dm_bc_sub, dm_u_sub, is_u_sub, ao_u_sub);
1051 auto is_up = is_u_sub;
1052 CHKERR AOPetscToApplicationIS(ao_bc_sub, is_up);
1058 CHKERR PCFieldSplitGetSubKSP(pc, &
n, &ksps);
1059 CHKERR schur_ptr->setUp(ksps[1]);
1066 auto dm =
simple->getDM();
1068 uXScatter = scatter_create(
D, 0);
1069 uYScatter = scatter_create(
D, 1);
1071 uZScatter = scatter_create(
D, 2);
1073 auto solver = pip->createTSIM();
1075 auto active_pre_lhs = [&]() {
1077 std::fill(commonPlasticDataPtr->activityData.begin(),
1078 commonPlasticDataPtr->activityData.end(), 0);
1082 auto active_post_lhs = [&]() {
1084 auto get_iter = [&]() {
1089 "Can not get iter");
1093 auto iter = get_iter();
1096 std::array<int, 5> activity_data;
1097 std::fill(activity_data.begin(), activity_data.end(), 0);
1098 MPI_Allreduce(commonPlasticDataPtr->activityData.data(),
1099 activity_data.data(), activity_data.size(), MPI_INT,
1100 MPI_SUM, mField.get_comm());
1102 int &active_points = activity_data[0];
1103 int &avtive_full_elems = activity_data[1];
1104 int &avtive_elems = activity_data[2];
1105 int &nb_points = activity_data[3];
1106 int &nb_elements = activity_data[4];
1110 double proc_nb_points =
1111 100 *
static_cast<double>(active_points) / nb_points;
1112 double proc_nb_active =
1113 100 *
static_cast<double>(avtive_elems) / nb_elements;
1114 double proc_nb_full_active = 100;
1116 proc_nb_full_active =
1117 100 *
static_cast<double>(avtive_full_elems) / avtive_elems;
1120 "EXAMPLE", Sev::inform,
1121 "Iter %d nb pts %d nb avtive pts %d (%3.3f\%) nb active elements %d "
1122 "(%3.3f\%) nb full active elems %d (%3.3f\%)",
1123 iter, nb_points, active_points, proc_nb_points, avtive_elems,
1124 proc_nb_active, avtive_full_elems, proc_nb_full_active, iter);
1131 CHKERR TSSetSolution(solver,
D);
1132 CHKERR set_section_monitor(solver);
1133 CHKERR set_time_monitor(dm, solver);
1134 CHKERR TSSetSolution(solver,
D);
1135 CHKERR TSSetFromOptions(solver);
1137 boost::shared_ptr<SetUpSchur> schur_ptr;
1138 CHKERR set_fieldsplit_preconditioner(solver, schur_ptr);
1140 mField.getInterface<
PipelineManager>()->getDomainLhsFE()->preProcessHook =
1144 CHKERR schur_ptr->preProc();
1148 mField.getInterface<
PipelineManager>()->getDomainLhsFE()->postProcessHook =
1153 CHKERR active_post_lhs();
1157 mField.getInterface<
PipelineManager>()->getBoundaryLhsFE()->postProcessHook =
1161 CHKERR schur_ptr->postProc();
1168 BOOST_LOG_SCOPED_THREAD_ATTR(
"Timeline", attrs::timer());
1169 MOFEM_LOG(
"TIMER", Sev::verbose) <<
"TSSetUp";
1171 MOFEM_LOG(
"TIMER", Sev::verbose) <<
"TSSetUp <= done";
1172 MOFEM_LOG(
"TIMER", Sev::verbose) <<
"TSSolve";
1173 CHKERR TSSolve(solver, NULL);
1174 MOFEM_LOG(
"TIMER", Sev::verbose) <<
"TSSolve <= done";
1176 CHKERR VecGhostUpdateBegin(
D, INSERT_VALUES, SCATTER_FORWARD);
1177 CHKERR VecGhostUpdateEnd(
D, INSERT_VALUES, SCATTER_FORWARD);
1189 const char param_file[] =
"param_file.petsc";
1193 auto core_log = logging::core::get();
1205 DMType dm_name =
"DMMOFEM";
1210 moab::Core mb_instance;
1211 moab::Interface &moab = mb_instance;
1244 "Is expected that schur matrix is not allocated. This is "
1245 "possible only is PC is set up twice");
1271 CHKERR KSPSetFromOptions(solver);
1272 CHKERR KSPGetPC(solver, &pc);
1273 PetscBool is_pcfs = PETSC_FALSE;
1274 PetscObjectTypeCompare((PetscObject)pc, PCFIELDSPLIT, &is_pcfs);
1279 "Is expected that schur matrix is not allocated. This is "
1280 "possible only is PC is set up twice");
1288 pip->getOpBoundaryLhsPipeline().push_back(
1291 pip->getOpDomainLhsPipeline().push_back(
1327 CHKERR PCFieldSplitSetSchurPre(pc, PC_FIELDSPLIT_SCHUR_PRE_USER,
S);
1336 MOFEM_LOG(
"TIMER", Sev::verbose) <<
"Lhs Assemble Begin";
1342 MOFEM_LOG(
"TIMER", Sev::verbose) <<
"Lhs Assemble End";
1344 CHKERR MatAssemblyBegin(
S, MAT_FINAL_ASSEMBLY);
1345 CHKERR MatAssemblyEnd(
S, MAT_FINAL_ASSEMBLY);
1350boost::shared_ptr<SetUpSchur>
1354 return boost::shared_ptr<SetUpSchur>(
#define MOFEM_LOG_C(channel, severity, format,...)
void simple(double P1[], double P2[], double P3[], double c[], const int N)
ElementsAndOps< SPACE_DIM >::DomainEle DomainEle
ElementsAndOps< SPACE_DIM >::BoundaryEle BoundaryEle
Kronecker Delta class symmetric.
#define CATCH_ERRORS
Catch errors.
#define MAX_DOFS_ON_ENTITY
Maximal number of DOFs on entity.
@ AINSWORTH_LEGENDRE_BASE
Ainsworth Cole (Legendre) approx. base .
#define CHK_THROW_MESSAGE(err, msg)
Check and throw MoFEM exception.
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return()
@ L2
field with C-1 continuity
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
@ MOFEM_DATA_INCONSISTENCY
static const char *const ApproximationBaseNames[]
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
#define CHKERR
Inline error check.
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
constexpr double shear_modulus_G
constexpr double bulk_modulus_K
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::BiLinearForm< GAUSS >::OpMass< 1, SPACE_DIM > OpMass
FTensor::Index< 'n', SPACE_DIM > n
auto smartCreateDMMatrix(DM dm)
Get smart matrix from DM.
PetscErrorCode DMMoFEMCreateSubDM(DM subdm, DM dm, const char problem_name[])
Must be called by user to set Sub DM MoFEM data structures.
PetscErrorCode DMMoFEMAddElement(DM dm, std::string fe_name)
add element to dm
PetscErrorCode DMMoFEMSetSquareProblem(DM dm, PetscBool square_problem)
set squared problem
PetscErrorCode DMoFEMMeshToLocalVector(DM dm, Vec l, InsertMode mode, ScatterMode scatter_mode)
set local (or ghosted) vector values on mesh for partition only
PetscErrorCode DMMoFEMAddSubFieldRow(DM dm, const char field_name[])
PetscErrorCode DMRegister_MoFEM(const char sname[])
Register MoFEM problem.
PetscErrorCode DMMoFEMAddSubFieldCol(DM dm, const char field_name[])
auto smartCreateDMVector(DM dm)
Get smart vector from DM.
boost::ptr_deque< UserDataOperator > & getOpBoundaryLhsPipeline()
Get the Op Boundary Lhs Pipeline object.
static LoggerType & setLog(const std::string channel)
Set ans resset chanel logger.
#define MOFEM_LOG(channel, severity)
Log.
#define MOFEM_LOG_TAG(channel, tag)
Tag channel.
#define MOFEM_LOG_CHANNEL(channel)
Set and reset channel.
virtual MoFEMErrorCode loop_dofs(const Problem *problem_ptr, const std::string &field_name, RowColData rc, DofMethod &method, int lower_rank, int upper_rank, int verb=DEFAULT_VERBOSITY)=0
Make a loop over dofs.
const double v
phase velocity of light in medium (cm/ns)
FTensor::Index< 'k', 3 > k
FormsIntegrators< DomainEleOp >::Assembly< USER_ASSEMBLE >::LinearForm< GAUSS >::OpBaseTimesVector< 1, 3, 1 > OpInertiaForce
FormsIntegrators< DomainEleOp >::Assembly< USER_ASSEMBLE >::LinearForm< GAUSS >::OpSource< 1, 3 > OpBodyForce
const FTensor::Tensor2< T, Dim, Dim > Vec
PetscErrorCode MoFEMErrorCode
MoFEM/PETSc error code.
implementation of Data Operators for Forces and Sources
auto type_from_handle(const EntityHandle h)
get type from entity handle
PetscErrorCode DMMoFEMTSSetMonitor(DM dm, TS ts, const std::string fe_name, boost::shared_ptr< MoFEM::FEMethod > method, boost::shared_ptr< MoFEM::BasicMethod > pre_only, boost::shared_ptr< MoFEM::BasicMethod > post_only)
Set Monitor To TS solver.
PetscErrorCode PetscOptionsGetInt(PetscOptions *, const char pre[], const char name[], PetscInt *ivalue, PetscBool *set)
MoFEMErrorCode MoFEMSNESMonitorFields(SNES snes, PetscInt its, PetscReal fgnorm, SnesCtx *snes_ctx)
Sens monitor printing residual field by field.
auto createSmartDM(MPI_Comm comm, const std::string dm_type_name)
Creates smart DM object.
PetscErrorCode PetscOptionsGetBool(PetscOptions *, const char pre[], const char name[], PetscBool *bval, PetscBool *set)
PetscErrorCode PetscOptionsGetScalar(PetscOptions *, const char pre[], const char name[], PetscScalar *dval, PetscBool *set)
auto createAOMappingIS(IS isapp, IS ispetsc)
Creates an application mapping using two index sets.
OpCalculateScalarFieldValuesFromPetscVecImpl< PetscData::CTX_SET_X_T > OpCalculateScalarFieldValuesDot
auto getProblemPtr(DM dm)
get problem pointer from DM
auto smartGetDMSnesCtx(DM dm)
Get SNES context data structure used by DM.
OpPostProcMapInMoab< SPACE_DIM, SPACE_DIM > OpPPMap
static char help[]
[Solve]
double hardening_dtau2(double tau)
constexpr size_t activ_history_sise
#define EXECUTABLE_DIMENSION
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::LinearForm< G >::OpGradTimesTensor< 1, SPACE_DIM, SPACE_DIM > OpInternalForcePiola
FormsIntegrators< DomainEleOp >::Assembly< A >::BiLinearForm< GAUSS >::OpGradSymTensorGrad< 1, SPACE_DIM, SPACE_DIM, 0 > OpKCauchy
[Only used with Hooke equation (linear material model)]
FormsIntegrators< BoundaryEleOp >::Assembly< PETSC >::BiLinearForm< G >::OpMass< 1, SPACE_DIM > OpBoundaryMass
[Only used with Hencky/nonlinear material]
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::LinearForm< G >::OpGradTimesSymTensor< 1, SPACE_DIM, SPACE_DIM > OpInternalForceCauchy
FormsIntegrators< BoundaryEleOp >::Assembly< PETSC >::LinearForm< G >::OpBaseTimesVector< 1, SPACE_DIM, 0 > OpBoundaryVec
double hardening(double tau)
PetscBool is_large_strains
int geom_order
Order if fixed.
FormsIntegrators< DomainEleOp >::Assembly< A >::BiLinearForm< GAUSS >::OpGradTensorGrad< 1, SPACE_DIM, SPACE_DIM, 1 > OpKPiola
[Only used for dynamics]
double hardening_dtau(double tau)
constexpr IntegrationType G
double hardening_exp(double tau)
FormsIntegrators< BoundaryEleOp >::Assembly< PETSC >::LinearForm< G >::OpBaseTimesVector< 1, SPACE_DIM, 1 > OpBoundaryInternal
OpBaseImpl< PETSC, EdgeEleOp > OpBase
FTensor::Index< 'l', 3 > l
FTensor::Index< 'j', 3 > j
FTensor::Index< 'i', 3 > i
double getScale(const double time)
Get scaling at a given time.
MoFEMErrorCode tsSolve()
[Push operators to pipeline]
FieldApproximationBase base
std::tuple< SmartPetscObj< Vec >, SmartPetscObj< VecScatter > > uYScatter
MoFEMErrorCode createCommonData()
[Set up problem]
Example(MoFEM::Interface &m_field)
MoFEMErrorCode OPs()
[Boundary condition]
MoFEMErrorCode runProblem()
[Run problem]
MoFEM::Interface & mField
std::tuple< SmartPetscObj< Vec >, SmartPetscObj< VecScatter > > uZScatter
boost::shared_ptr< std::vector< unsigned char > > boundaryMarker
MoFEMErrorCode setupProblem()
[Run problem]
MoFEMErrorCode bC()
[Create common data]
boost::shared_ptr< std::vector< unsigned char > > reactionMarker
boost::shared_ptr< DomainEle > reactionFe
boost::shared_ptr< PlasticOps::CommonData > commonPlasticDataPtr
std::tuple< SmartPetscObj< Vec >, SmartPetscObj< VecScatter > > uXScatter
boost::shared_ptr< HenckyOps::CommonData > commonHenckyDataPtr
Add operators pushing bases from local to physical configuration.
Simple interface for fast problem set-up.
virtual moab::Interface & get_moab()=0
static MoFEMErrorCode Initialize(int *argc, char ***args, const char file[], const char help[])
Initializes the MoFEM database PETSc, MOAB and MPI.
static MoFEMErrorCode Finalize()
Checks for options to be called at the conclusion of the program.
Deprecated interface functions.
Definition of the displacement bc data structure.
Data on single entity (This is passed as argument to DataOperator::doWork)
Essential boundary conditions.
default operator for TRI element
Section manager is used to create indexes and sections.
static boost::shared_ptr< SinkType > createSink(boost::shared_ptr< std::ostream > stream_ptr, std::string comm_filter)
Create a sink object.
static boost::shared_ptr< std::ostream > getStrmWorld()
Get the strm world object.
Get value at integration points for scalar field.
Calculate symmetric tensor field rates ant integratio pts.
Calculate symmetric tensor field values at integration pts.
Get field gradients at integration pts for scalar filed rank 0, i.e. vector field.
Get values at integration pts for tensor filed rank 1, i.e. vector field.
Enforce essential constrains on lhs.
Enforce essential constrains on rhs.
Post post-proc data at points from hash maps.
Scale base functions by inverses of measure of element.
Clear Schur complement internal data.
Assemble Schur complement.
Set indices on entities on finite element.
PipelineManager interface.
MoFEM::VolumeElementForcesAndSourcesCore VolEle
MoFEM::FaceElementForcesAndSourcesCore FaceEle
MoFEM::EdgeElementForcesAndSourcesCore EdgeEle
Problem manager is used to build and partition problems.
Projection of edge entities with one mid-node on hierarchical basis.
Simple interface for fast problem set-up.
intrusive_ptr for managing petsc objects
Force scale operator for reading two columns.
double getScale(const double time)
Get scaling at a given time.
TimeScale(std::string file_name="", bool error_if_file_not_given=false)
TimeScale constructor.
MoFEMErrorCode getInterface(IFACE *&iface) const
Get interface refernce to pointer of interface.
Volume finite element base.
[Push operators to pipeline]
virtual MoFEMErrorCode setUp(KSP solver)=0
virtual MoFEMErrorCode postProc()=0
virtual MoFEMErrorCode preProc()=0
static boost::shared_ptr< SetUpSchur > createSetUpSchur(MoFEM::Interface &m_field, SmartPetscObj< DM >, SmartPetscObj< IS >, SmartPetscObj< AO >)
SmartPetscObj< PC > smartPC
SmartPetscObj< DM > subDM
MoFEMErrorCode setUp(KSP solver)
SetUpSchurImpl(MoFEM::Interface &m_field, SmartPetscObj< DM > sub_dm, SmartPetscObj< IS > sub_is, SmartPetscObj< AO > sub_ao)
SmartPetscObj< AO > subAO
virtual ~SetUpSchurImpl()
MoFEMErrorCode postProc()
MoFEMErrorCode setPC(PC pc)
SmartPetscObj< IS > subIS
MoFEMErrorCode setOperator()
MoFEM::Interface & mField