9#ifndef EXECUTABLE_DIMENSION
10#define EXECUTABLE_DIMENSION 3
55 GAUSS>::OpMixDivTimesScalar<SPACE_DIM>;
69 GAUSS>::OpBaseTimesVector<3, SPACE_DIM, 1>;
76 GAUSS>::OpMixDivTimesU<3, 1, SPACE_DIM>;
84 GAUSS>::OpBaseTimesScalar<1>;
116 GAUSS>::OpEssentialRhs<HeatFluxCubitBcData, 3, SPACE_DIM>;
119 GAUSS>::OpEssentialLhs<HeatFluxCubitBcData, 3, SPACE_DIM>;
143auto save_range = [](moab::Interface &moab,
const std::string name,
147 CHKERR moab.add_entities(*out_meshset, r);
148 CHKERR moab.write_file(name.c_str(),
"VTK",
"", out_meshset->get_ptr(), 1);
176 :
public boost::enable_shared_from_this<BlockedParameters> {
183 return boost::shared_ptr<MatrixDouble>(shared_from_this(), &
mD);
187 return boost::shared_ptr<double>(shared_from_this(), &
coeffExpansion);
195 return boost::shared_ptr<double>(shared_from_this(), &
heatCapacity);
200 boost::ptr_deque<ForcesAndSourcesCore::UserDataOperator> &pipeline,
201 std::string block_elastic_name, std::string block_thermal_name,
202 boost::shared_ptr<BlockedParameters> blockedParamsPtr,
Sev sev);
206 boost::ptr_deque<ForcesAndSourcesCore::UserDataOperator> &pipeline,
207 std::string block_elastic_name, std::string block_thermal_name,
208 boost::shared_ptr<BlockedParameters> blockedParamsPtr,
Sev sev) {
212 OpMatElasticBlocks(boost::shared_ptr<MatrixDouble>
m,
double bulk_modulus_K,
215 std::vector<const CubitMeshSets *> meshset_vec_ptr)
220 "Can not get data from block");
227 for (
auto &b : blockData) {
229 if (b.blockEnts.find(getFEEntityHandle()) != b.blockEnts.end()) {
230 CHKERR getMatDPtr(matDPtr, b.bulkModulusK, b.shearModulusG);
235 CHKERR getMatDPtr(matDPtr, bulkModulusKDefault, shearModulusGDefault);
240 boost::shared_ptr<MatrixDouble> matDPtr;
244 double shearModulusG;
248 double bulkModulusKDefault;
249 double shearModulusGDefault;
250 std::vector<BlockData> blockData;
254 std::vector<const CubitMeshSets *> meshset_vec_ptr,
258 for (
auto m : meshset_vec_ptr) {
260 std::vector<double> block_data;
261 CHKERR m->getAttributes(block_data);
262 if (block_data.size() < 2) {
264 "Expected that block has two attributes");
266 auto get_block_ents = [&]() {
269 m_field.
get_moab().get_entities_by_handle(
m->meshset, ents,
true);
289 MoFEMErrorCode getMatDPtr(boost::shared_ptr<MatrixDouble> mat_D_ptr,
293 auto set_material_stiffness = [&]() {
303 auto t_D = getFTensor4DdgFromMat<SPACE_DIM, SPACE_DIM, 0>(*mat_D_ptr);
312 set_material_stiffness();
317 double default_bulk_modulus_K =
319 double default_shear_modulus_G =
322 pipeline.push_back(
new OpMatElasticBlocks(
323 blockedParamsPtr->getDPtr(), default_bulk_modulus_K,
324 default_bulk_modulus_K,
mField, sev,
329 (boost::format(
"%s(.*)") % block_elastic_name).str()
336 OpMatThermalBlocks(boost::shared_ptr<double> expansion_ptr,
337 boost::shared_ptr<double> conductivity_ptr,
338 boost::shared_ptr<double> capacity_ptr,
340 std::vector<const CubitMeshSets *> meshset_vec_ptr)
342 expansionPtr(expansion_ptr), conductivityPtr(conductivity_ptr),
343 capacityPtr(capacity_ptr) {
345 "Can not get data from block");
352 for (
auto &b : blockData) {
354 if (b.blockEnts.find(getFEEntityHandle()) != b.blockEnts.end()) {
355 *expansionPtr = b.expansion;
356 *conductivityPtr = b.conductivity;
357 *capacityPtr = b.capacity;
377 std::vector<BlockData> blockData;
381 std::vector<const CubitMeshSets *> meshset_vec_ptr,
385 for (
auto m : meshset_vec_ptr) {
387 std::vector<double> block_data;
388 CHKERR m->getAttributes(block_data);
389 if (block_data.size() < 3) {
391 "Expected that block has two attributes");
393 auto get_block_ents = [&]() {
396 m_field.
get_moab().get_entities_by_handle(
m->meshset, ents,
true);
401 <<
m->getName() <<
": expansion = " << block_data[0]
402 <<
" conductivity = " << block_data[1] <<
" capacity "
406 {block_data[0], block_data[1], block_data[2], get_block_ents()});
412 boost::shared_ptr<double> expansionPtr;
413 boost::shared_ptr<double> conductivityPtr;
414 boost::shared_ptr<double> capacityPtr;
417 pipeline.push_back(
new OpMatThermalBlocks(
418 blockedParamsPtr->getCoeffExpansionPtr(),
419 blockedParamsPtr->getHeatConductivityPtr(),
420 blockedParamsPtr->getHeatCapacityPtr(),
mField, sev,
425 (boost::format(
"%s(.*)") % block_thermal_name).str()
489 auto no_rule = [](int, int, int) {
return -1; };
492 field_eval_fe_ptr->getRuleHook = no_rule;
494 field_eval_fe_ptr->getOpPtrVector().push_back(
496 field_eval_fe_ptr->getOpPtrVector().push_back(
498 field_eval_fe_ptr->getOpPtrVector().push_back(
511 auto get_command_line_parameters = [&]() {
539 <<
"Reference_temperature " <<
ref_temp;
544 CHKERR get_command_line_parameters();
561 simple->getProblemName(),
"U");
563 simple->getProblemName(),
"FLUX",
false);
565 auto get_skin = [&]() {
570 CHKERR skin.find_skin(0, body_ents,
false, skin_ents);
574 auto filter_flux_blocks = [&](
auto skin) {
575 auto remove_cubit_blocks = [&](
auto c) {
585 skin = subtract(skin, ents);
590 auto remove_named_blocks = [&](
auto n) {
595 (boost::format(
"%s(.*)") %
n).str()
603 skin = subtract(skin, ents);
609 "remove_cubit_blocks");
611 "remove_cubit_blocks");
613 "remove_named_blocks");
619 auto filter_true_skin = [&](
auto skin) {
621 ParallelComm *pcomm =
623 CHKERR pcomm->filter_pstatus(skin, PSTATUS_SHARED | PSTATUS_MULTISHARED,
624 PSTATUS_NOT, -1, &boundary_ents);
625 return boundary_ents;
628 auto remove_flux_ents = filter_true_skin(filter_flux_blocks(get_skin()));
633 MOFEM_LOG(
"SYNC", Sev::noisy) << remove_flux_ents << endl;
646 simple->getProblemName(),
"FLUX", remove_flux_ents);
663 auto boundary_marker =
664 bc_mng->getMergedBlocksMarker(vector<string>{
"HEATFLUX"});
674 auto block_params = boost::make_shared<BlockedParameters>();
675 auto mDPtr = block_params->getDPtr();
676 auto coeff_expansion_ptr = block_params->getCoeffExpansionPtr();
677 auto heat_conductivity_ptr = block_params->getHeatConductivityPtr();
678 auto heat_capacity_ptr = block_params->getHeatCapacityPtr();
680 auto time_scale = boost::make_shared<TimeScale>();
682 auto add_domain_rhs_ops = [&](
auto &pipeline) {
688 auto mat_grad_ptr = boost::make_shared<MatrixDouble>();
689 auto mat_strain_ptr = boost::make_shared<MatrixDouble>();
690 auto mat_stress_ptr = boost::make_shared<MatrixDouble>();
692 auto vec_temp_ptr = boost::make_shared<VectorDouble>();
693 auto vec_temp_dot_ptr = boost::make_shared<VectorDouble>();
694 auto mat_flux_ptr = boost::make_shared<MatrixDouble>();
695 auto vec_temp_div_ptr = boost::make_shared<VectorDouble>();
701 "FLUX", vec_temp_div_ptr));
709 pipeline.push_back(
new OpStressThermal(
"U", mat_strain_ptr, vec_temp_ptr,
710 mDPtr, coeff_expansion_ptr,
713 pipeline.push_back(
new OpSetBc(
"FLUX",
true, boundary_marker));
717 [](
double,
double,
double)
constexpr {
return 1; }));
719 auto resistance = [heat_conductivity_ptr](
const double,
const double,
721 return (1. / (*heat_conductivity_ptr));
724 auto capacity = [heat_capacity_ptr](
const double,
const double,
726 return -(*heat_capacity_ptr);
731 pipeline.push_back(
new OpHdivFlux(
"FLUX", mat_flux_ptr, resistance));
732 pipeline.push_back(
new OpHDivTemp(
"FLUX", vec_temp_ptr, unity));
733 pipeline.push_back(
new OpBaseDivFlux(
"T", vec_temp_div_ptr, unity));
734 pipeline.push_back(
new OpBaseDotT(
"T", vec_temp_dot_ptr, capacity));
736 pipeline.push_back(
new OpUnSetBc(
"FLUX"));
739 pipeline,
mField,
"T", {time_scale},
"HEAT_SOURCE", Sev::inform);
741 pipeline,
mField,
"U", {time_scale},
"BODY_FORCE", Sev::inform);
743 pipeline,
mField,
"T", vec_temp_ptr,
"SETTEMP", Sev::inform);
748 auto add_domain_lhs_ops = [&](
auto &pipeline) {
754 pipeline.push_back(
new OpSetBc(
"FLUX",
true, boundary_marker));
756 pipeline.push_back(
new OpKCauchy(
"U",
"U", mDPtr));
758 "U",
"T", mDPtr, coeff_expansion_ptr));
760 auto resistance = [heat_conductivity_ptr](
const double,
const double,
762 return (1. / (*heat_conductivity_ptr));
764 auto capacity = [heat_capacity_ptr](
const double,
const double,
766 return -(*heat_capacity_ptr);
768 pipeline.push_back(
new OpHdivHdiv(
"FLUX",
"FLUX", resistance));
769 pipeline.push_back(
new OpHdivT(
770 "FLUX",
"T", []()
constexpr {
return -1; },
true));
772 auto op_capacity =
new OpCapacity(
"T",
"T", capacity);
773 op_capacity->feScalingFun = [](
const FEMethod *fe_ptr) {
776 pipeline.push_back(op_capacity);
778 pipeline.push_back(
new OpUnSetBc(
"FLUX"));
780 auto vec_temp_ptr = boost::make_shared<VectorDouble>();
783 pipeline,
mField,
"T", vec_temp_ptr,
"SETTEMP", Sev::verbose);
788 auto add_boundary_rhs_ops = [&](
auto &pipeline) {
793 pipeline.push_back(
new OpSetBc(
"FLUX",
true, boundary_marker));
796 pipeline_mng->getOpBoundaryRhsPipeline(),
mField,
"U", {time_scale},
"FORCE",
800 pipeline_mng->getOpBoundaryRhsPipeline(),
mField,
"FLUX", {time_scale},
801 "TEMPERATURE", Sev::inform);
803 pipeline.push_back(
new OpUnSetBc(
"FLUX"));
805 auto mat_flux_ptr = boost::make_shared<MatrixDouble>();
810 mField, pipeline,
simple->getProblemName(),
"FLUX", mat_flux_ptr,
816 auto add_boundary_lhs_ops = [&](
auto &pipeline) {
828 auto get_bc_hook_rhs = [&]() {
830 mField, pipeline_mng->getDomainRhsFE(), {time_scale});
833 auto get_bc_hook_lhs = [&]() {
835 mField, pipeline_mng->getDomainLhsFE(), {time_scale});
839 pipeline_mng->getDomainRhsFE()->preProcessHook = get_bc_hook_rhs();
840 pipeline_mng->getDomainLhsFE()->preProcessHook = get_bc_hook_lhs();
842 CHKERR add_domain_rhs_ops(pipeline_mng->getOpDomainRhsPipeline());
843 CHKERR add_domain_lhs_ops(pipeline_mng->getOpDomainLhsPipeline());
844 CHKERR add_boundary_rhs_ops(pipeline_mng->getOpBoundaryRhsPipeline());
845 CHKERR add_boundary_lhs_ops(pipeline_mng->getOpBoundaryLhsPipeline());
859 auto dm =
simple->getDM();
860 auto solver = pipeline_mng->createTSIM();
863 auto set_section_monitor = [&](
auto solver) {
866 CHKERR TSGetSNES(solver, &snes);
867 CHKERR SNESMonitorSet(snes,
870 (
void *)(snes_ctx_ptr.get()),
nullptr);
874 auto create_post_process_element = [&]() {
875 auto post_proc_fe = boost::make_shared<PostProcEle>(
mField);
877 auto block_params = boost::make_shared<BlockedParameters>();
878 auto mDPtr = block_params->getDPtr();
879 auto coeff_expansion_ptr = block_params->getCoeffExpansionPtr();
882 "MAT_THERMAL", block_params, Sev::verbose);
885 post_proc_fe->getOpPtrVector(), {H1, HDIV});
887 auto mat_grad_ptr = boost::make_shared<MatrixDouble>();
888 auto mat_strain_ptr = boost::make_shared<MatrixDouble>();
889 auto mat_stress_ptr = boost::make_shared<MatrixDouble>();
891 auto vec_temp_ptr = boost::make_shared<VectorDouble>();
892 auto mat_flux_ptr = boost::make_shared<MatrixDouble>();
894 post_proc_fe->getOpPtrVector().push_back(
896 post_proc_fe->getOpPtrVector().push_back(
899 auto u_ptr = boost::make_shared<MatrixDouble>();
900 post_proc_fe->getOpPtrVector().push_back(
902 post_proc_fe->getOpPtrVector().push_back(
905 post_proc_fe->getOpPtrVector().push_back(
907 post_proc_fe->getOpPtrVector().push_back(
909 coeff_expansion_ptr, mat_stress_ptr));
913 post_proc_fe->getOpPtrVector().push_back(
917 post_proc_fe->getPostProcMesh(), post_proc_fe->getMapGaussPts(),
919 {{
"T", vec_temp_ptr}},
921 {{
"U", u_ptr}, {
"FLUX", mat_flux_ptr}},
925 {{
"STRAIN", mat_strain_ptr}, {
"STRESS", mat_stress_ptr}}
934 auto monitor_ptr = boost::make_shared<FEMethod>();
935 auto post_proc_fe = create_post_process_element();
937 auto set_time_monitor = [&](
auto dm,
auto solver) {
939 monitor_ptr->preProcessHook = [&]() {
944 monitor_ptr->getCacheWeakPtr());
945 CHKERR post_proc_fe->writeFile(
946 "out_" + boost::lexical_cast<std::string>(monitor_ptr->ts_step) +
952 ->evalFEAtThePoint3D(
953 fieldEvalCoords.data(), 1e-12,
simple->getProblemName(),
954 simple->getDomainFEName(), fieldEvalData,
955 mField.get_comm_rank(), mField.get_comm_rank(),
nullptr,
959 ->evalFEAtThePoint2D(
960 fieldEvalCoords.data(), 1e-12,
simple->getProblemName(),
961 simple->getDomainFEName(), fieldEvalData,
962 mField.get_comm_rank(), mField.get_comm_rank(),
nullptr,
966 if (scalarFieldPtr->size()) {
968 MOFEM_LOG(
"ThermoElasticSync", Sev::inform)
969 <<
"Eval point T: " << t_temp;
971 if (vectorFieldPtr->size1()) {
973 auto t_disp = getFTensor1FromMat<SPACE_DIM>(*vectorFieldPtr);
974 MOFEM_LOG(
"ThermoElasticSync", Sev::inform)
975 <<
"Eval point U magnitude: " << sqrt(t_disp(
i) * t_disp(
i));
977 if (tensorFieldPtr->size1()) {
980 getFTensor2FromMat<SPACE_DIM, SPACE_DIM>(*tensorFieldPtr);
981 MOFEM_LOG(
"ThermoElasticSync", Sev::inform)
982 <<
"Eval point U_GRAD trace: " << t_disp_grad(
i,
i);
990 auto null = boost::shared_ptr<FEMethod>();
996 auto set_fieldsplit_preconditioner = [&](
auto solver) {
1000 CHKERR TSGetSNES(solver, &snes);
1002 CHKERR SNESGetKSP(snes, &ksp);
1004 CHKERR KSPGetPC(ksp, &pc);
1005 PetscBool is_pcfs = PETSC_FALSE;
1006 PetscObjectTypeCompare((PetscObject)pc, PCFIELDSPLIT, &is_pcfs);
1009 if (is_pcfs == PETSC_TRUE) {
1010 auto bc_mng = mField.getInterface<
BcManager>();
1012 auto name_prb =
simple->getProblemName();
1015 CHKERR is_mng->isCreateProblemFieldAndRank(name_prb,
ROW,
"U", 0,
1018 CHKERR is_mng->isCreateProblemFieldAndRank(name_prb,
ROW,
"FLUX", 0, 0,
1021 CHKERR is_mng->isCreateProblemFieldAndRank(name_prb,
ROW,
"T", 0, 0,
1024 CHKERR ISExpand(is_T, is_flux, &is_tmp);
1027 auto is_all_bc = bc_mng->getBlockIS(name_prb,
"HEATFLUX",
"FLUX", 0, 0);
1029 CHKERR ISGetSize(is_all_bc, &is_all_bc_size);
1031 <<
"Field split block size " << is_all_bc_size;
1032 if (is_all_bc_size) {
1034 CHKERR ISDifference(is_TFlux, is_all_bc, &is_tmp2);
1036 CHKERR PCFieldSplitSetIS(pc, PETSC_NULL,
1042 CHKERR PCFieldSplitSetIS(pc, PETSC_NULL, is_TFlux);
1043 CHKERR PCFieldSplitSetIS(pc, PETSC_NULL, is_u);
1050 CHKERR TSSetSolution(solver,
D);
1051 CHKERR TSSetFromOptions(solver);
1053 CHKERR set_section_monitor(solver);
1054 CHKERR set_fieldsplit_preconditioner(solver);
1055 CHKERR set_time_monitor(dm, solver);
1058 CHKERR TSSolve(solver, NULL);
1069 const char param_file[] =
"param_file.petsc";
1073 auto core_log = logging::core::get();
1087 DMType dm_name =
"DMMOFEM";
1092 moab::Core mb_instance;
1093 moab::Interface &moab = mb_instance;
#define MOFEM_LOG_SEVERITY_SYNC(comm, severity)
Synchronise "SYNC" on curtain severity level.
#define MOFEM_LOG_SYNCHRONISE(comm)
Synchronise "SYNC" channel.
#define MOFEM_TAG_AND_LOG(channel, severity, tag)
Tag and log in channel.
void simple(double P1[], double P2[], double P3[], double c[], const int N)
DomainEle::UserDataOperator DomainEleOp
Finire element operator type.
ElementsAndOps< SPACE_DIM >::DomainEle DomainEle
ElementsAndOps< SPACE_DIM >::BoundaryEle BoundaryEle
Kronecker Delta class symmetric.
#define CATCH_ERRORS
Catch errors.
FieldApproximationBase
approximation base
@ 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
@ HCURL
field with continuous tangents
@ HDIV
field with continuous normal traction
#define MYPCOMM_INDEX
default communicator number PCOMM
#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 CHKERR
Inline error check.
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::BiLinearForm< GAUSS >::OpMass< 1, SPACE_DIM > OpMass
FTensor::Index< 'n', SPACE_DIM > n
FTensor::Index< 'm', SPACE_DIM > m
PetscErrorCode DMRegister_MoFEM(const char sname[])
Register MoFEM problem.
PetscErrorCode DMoFEMLoopFiniteElements(DM dm, const char fe_name[], MoFEM::FEMethod *method, CacheTupleWeakPtr cache_ptr=CacheTupleSharedPtr())
Executes FEMethod for finite elements in DM.
auto createDMVector(DM dm)
Get smart vector from DM.
static LoggerType & setLog(const std::string channel)
Set ans resset chanel logger.
#define MOFEM_LOG(channel, severity)
Log.
SeverityLevel
Severity levels.
#define MOFEM_LOG_TAG(channel, tag)
Tag channel.
#define MOFEM_LOG_CHANNEL(channel)
Set and reset channel.
MoFEMErrorCode getCubitMeshsetPtr(const int ms_id, const CubitBCType cubit_bc_type, const CubitMeshSets **cubit_meshset_ptr) const
get cubit meshset
FTensor::Index< 'i', SPACE_DIM > i
const double c
speed of light (cm/ns)
FTensor::Index< 'l', 3 > l
FTensor::Index< 'j', 3 > j
FTensor::Index< 'k', 3 > k
FormsIntegrators< DomainEleOp >::Assembly< USER_ASSEMBLE >::LinearForm< GAUSS >::OpSource< 1, 3 > OpBodyForce
PetscErrorCode MoFEMErrorCode
MoFEM/PETSc error code.
implementation of Data Operators for Forces and Sources
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.
PetscErrorCode PetscOptionsGetScalar(PetscOptions *, const char pre[], const char name[], PetscScalar *dval, PetscBool *set)
PetscErrorCode PetscOptionsGetRealArray(PetscOptions *, const char pre[], const char name[], PetscReal dval[], PetscInt *nmax, PetscBool *set)
static auto getFTensor0FromVec(ublas::vector< T, A > &data)
Get tensor rank 0 (scalar) form data vector.
OpCalculateScalarFieldValuesFromPetscVecImpl< PetscData::CTX_SET_X_T > OpCalculateScalarFieldValuesDot
auto get_temp_meshset_ptr(moab::Interface &moab)
Create smart pointer to temporary meshset.
auto getDMSnesCtx(DM dm)
Get SNES context data structure used by DM.
OpPostProcMapInMoab< SPACE_DIM, SPACE_DIM > OpPPMap
double young_modulus
Young modulus.
static constexpr int approx_order
OpBaseImpl< PETSC, EdgeEleOp > OpBase
Add operators pushing bases from local to physical configuration.
Simple interface for fast problem set-up.
virtual moab::Interface & get_moab()=0
virtual MPI_Comm & get_comm() const =0
virtual int get_comm_rank() const =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.
Class (Function) to enforce essential constrains.
structure for User Loop Methods on finite elements
default operator for TRI element
Field evaluator interface.
@ OPSPACE
operator do Work is execute on space data
Definition of the heat flux bc data structure.
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.
static boost::shared_ptr< std::ostream > getStrmSync()
Get the strm sync object.
Interface for managing meshsets containing materials and boundary conditions.
Get vector field for H-div approximation.
Calculate divergence of vector field.
Get value at integration points for scalar field.
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.
Set indices on entities on finite element.
PipelineManager interface.
Problem manager is used to build and partition problems.
Simple interface for fast problem set-up.
intrusive_ptr for managing petsc objects
MoFEMErrorCode getInterface(IFACE *&iface) const
Get interface refernce to pointer of interface.
auto getHeatCapacityPtr()
auto getCoeffExpansionPtr()
auto getHeatConductivityPtr()
boost::shared_ptr< FieldEvaluatorInterface::SetPtsData > fieldEvalData
MoFEMErrorCode runProblem()
[Run problem]
std::array< double, SPACE_DIM > fieldEvalCoords
MoFEM::Interface & mField
MoFEMErrorCode createCommonData()
[Set up problem]
boost::shared_ptr< MatrixDouble > vectorFieldPtr
ThermoElasticProblem(MoFEM::Interface &m_field)
MoFEMErrorCode addMatBlockOps(boost::ptr_deque< ForcesAndSourcesCore::UserDataOperator > &pipeline, std::string block_elastic_name, std::string block_thermal_name, boost::shared_ptr< BlockedParameters > blockedParamsPtr, Sev sev)
boost::shared_ptr< VectorDouble > scalarFieldPtr
MoFEMErrorCode setupProblem()
add fields
MoFEMErrorCode bC()
[Create common data]
MoFEMErrorCode OPs()
[Boundary condition]
MoFEMErrorCode tsSolve()
[Push operators to pipeline]
boost::shared_ptr< MatrixDouble > tensorFieldPtr
static char help[]
[Solve]
#define EXECUTABLE_DIMENSION
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::LinearForm< GAUSS >::OpBaseTimesScalar< 1 > OpBaseDotT
Integrate Rhs base of temperature time heat capacity times heat rate (T)
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::BiLinearForm< GAUSS >::OpMixDivTimesScalar< SPACE_DIM > OpHdivT
Integrate Lhs div of base of flux time base of temperature (FLUX x T) and transpose of it,...
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::LinearForm< GAUSS >::OpBaseTimesVector< 3, SPACE_DIM, 1 > OpHdivFlux
Integrating Rhs flux base (1/k) flux (FLUX)
double default_heat_capacity
double default_young_modulus
[Essential boundary conditions (Least square approach)]
double default_coeff_expansion
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::BiLinearForm< GAUSS >::OpMass< 1, 1 > OpCapacity
Integrate Lhs base of temperature times (heat capacity) times base of temperature (T x T)
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::BiLinearForm< GAUSS >::OpMass< 3, SPACE_DIM > OpHdivHdiv
[Linear elastic problem]
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::LinearForm< GAUSS >::OpGradTimesSymTensor< 1, SPACE_DIM, SPACE_DIM > OpInternalForceCauchy
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::BiLinearForm< GAUSS >::OpGradSymTensorGrad< 1, SPACE_DIM, SPACE_DIM, 0 > OpKCauchy
[Linear elastic problem]
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::LinearForm< GAUSS >::OpMixDivTimesU< 3, 1, SPACE_DIM > OpHDivTemp
Integrate Rhs div flux base times temperature (T)
double default_heat_conductivity
OpBaseDotT OpBaseDivFlux
Integrate Rhs base of temperature times divergence of flux (T)
double default_poisson_ratio