v0.10.0
Classes | Typedefs | Functions | Variables
lesson8_contact.cpp File Reference
#include <MoFEM.hpp>
#include <ContactOps.hpp>
#include <OpPostProcElastic.hpp>

Go to the source code of this file.

Classes

struct  ElementsAndOps< DIM >
 
struct  ElementsAndOps< 2 >
 
struct  ElementsAndOps< 3 >
 
struct  Example
 [Example] More...
 

Typedefs

using EntData = DataForcesAndSourcesCore::EntData
 
using DomainEle = ElementsAndOps< SPACE_DIM >::DomainEle
 
using DomainEleOp = ElementsAndOps< SPACE_DIM >::DomainEleOp
 
using BoundaryEle = ElementsAndOps< SPACE_DIM >::BoundaryEle
 
using BoundaryEleOp = ElementsAndOps< SPACE_DIM >::BoundaryEleOp
 
using PostProcEle = ElementsAndOps< SPACE_DIM >::PostProcEle
 
using OpK = FormsIntegrators< DomainEleOp >::Assembly< PETSC >::BiLinearForm< GAUSS >::OpGradSymTensorGrad< 1, SPACE_DIM, SPACE_DIM, 0 >
 
using OpInternalForce = FormsIntegrators< DomainEleOp >::Assembly< PETSC >::LinearForm< GAUSS >::OpGradTimesSymTensor< 1, SPACE_DIM, SPACE_DIM >
 
using OpBodyForce = FormsIntegrators< DomainEleOp >::Assembly< PETSC >::LinearForm< GAUSS >::OpSource< 1, SPACE_DIM >
 

Functions

int main (int argc, char *argv[])
 

Variables

constexpr int SPACE_DIM = 2
 
constexpr EntityType boundary_ent = SPACE_DIM == 3 ? MBTRI : MBEDGE
 
constexpr int order = 2
 
constexpr double young_modulus = 10
 
constexpr double poisson_ratio = 0.25
 
constexpr double cn = 0.1
 
constexpr double spring_stiffness = 0
 
static char help [] = "...\n\n"
 

Typedef Documentation

◆ BoundaryEle

Definition at line 51 of file lesson8_contact.cpp.

◆ BoundaryEleOp

Definition at line 52 of file lesson8_contact.cpp.

◆ DomainEle

Definition at line 49 of file lesson8_contact.cpp.

◆ DomainEleOp

Definition at line 50 of file lesson8_contact.cpp.

◆ EntData

Examples
lesson8_contact.cpp.

Definition at line 48 of file lesson8_contact.cpp.

◆ OpBodyForce

using OpBodyForce = FormsIntegrators<DomainEleOp>::Assembly<PETSC>::LinearForm< GAUSS>::OpSource<1, SPACE_DIM>
Examples
lesson8_contact.cpp.

Definition at line 60 of file lesson8_contact.cpp.

◆ OpInternalForce

using OpInternalForce = FormsIntegrators<DomainEleOp>::Assembly< PETSC>::LinearForm<GAUSS>::OpGradTimesSymTensor<1, SPACE_DIM, SPACE_DIM>
Examples
lesson8_contact.cpp.

Definition at line 58 of file lesson8_contact.cpp.

◆ OpK

using OpK = FormsIntegrators<DomainEleOp>::Assembly<PETSC>::BiLinearForm< GAUSS>::OpGradSymTensorGrad<1, SPACE_DIM, SPACE_DIM, 0>

◆ PostProcEle

Definition at line 53 of file lesson8_contact.cpp.

Function Documentation

◆ main()

int main ( int  argc,
char *  argv[] 
)
Examples
lesson8_contact.cpp.

Definition at line 496 of file lesson8_contact.cpp.

496  {
497 
498  MoFEM::Core::Initialize(&argc, &argv, (char *)0, help);
499 
500  try {
501 
502  //! [Register MoFEM discrete manager in PETSc]
503  DMType dm_name = "DMMOFEM";
504  CHKERR DMRegister_MoFEM(dm_name);
505  //! [Register MoFEM discrete manager in PETSc
506 
507  //! [Create MoAB]
508  moab::Core mb_instance; ///< mesh database
509  moab::Interface &moab = mb_instance; ///< mesh database interface
510  //! [Create MoAB]
511 
512  //! [Create MoFEM]
513  MoFEM::Core core(moab); ///< finite element database
514  MoFEM::Interface &m_field = core; ///< finite element database insterface
515  //! [Create MoFEM]
516 
517  //! [Load mesh]
518  Simple *simple = m_field.getInterface<Simple>();
519  CHKERR simple->getOptions();
520  CHKERR simple->loadFile("");
521  //! [Load mesh]
522 
523  //! [Example]
524  Example ex(m_field);
525  CHKERR ex.runProblem();
526  //! [Example]
527  }
528  CATCH_ERRORS;
529 
531 }
Deprecated interface functions.
CoreTmp< 0 > Core
Definition: Core.hpp:1129
[Example]
static MoFEMErrorCode Initialize(int *argc, char ***args, const char file[], const char help[])
Initializes the MoFEM database PETSc, MOAB and MPI.
Definition: Core.cpp:60
Simple interface for fast problem set-up.
Definition: Simple.hpp:36
MoFEMErrorCode getInterface(const MOFEMuuid &uuid, IFACE *&iface) const
Get interface by uuid and return reference to pointer of interface.
void simple(double P1[], double P2[], double P3[], double c[], const int N)
Definition: acoustic.cpp:69
PetscErrorCode DMRegister_MoFEM(const char sname[])
Register MoFEM problem.
Definition: DMMMoFEM.cpp:48
static char help[]
#define CHKERR
Inline error check.
Definition: definitions.h:604
DeprecatedCoreInterface Interface
Definition: Interface.hpp:1943
Core (interface) class.
Definition: Core.hpp:77
#define CATCH_ERRORS
Catch errors.
Definition: definitions.h:441
static MoFEMErrorCode Finalize()
Checks for options to be called at the conclusion of the program.
Definition: Core.cpp:100

Variable Documentation

◆ boundary_ent

constexpr EntityType boundary_ent = SPACE_DIM == 3 ? MBTRI : MBEDGE
Examples
lesson8_contact.cpp.

Definition at line 46 of file lesson8_contact.cpp.

◆ cn

constexpr double cn = 0.1
Examples
lesson8_contact.cpp.

Definition at line 65 of file lesson8_contact.cpp.

◆ help

char help[] = "...\n\n"
static
Examples
lesson8_contact.cpp.

Definition at line 494 of file lesson8_contact.cpp.

◆ order

constexpr int order = 2
Examples
lesson8_contact.cpp.

Definition at line 62 of file lesson8_contact.cpp.

◆ poisson_ratio

constexpr double poisson_ratio = 0.25
Examples
lesson8_contact.cpp.

Definition at line 64 of file lesson8_contact.cpp.

◆ SPACE_DIM

constexpr int SPACE_DIM = 2
Examples
lesson8_contact.cpp.

Definition at line 45 of file lesson8_contact.cpp.

◆ spring_stiffness

constexpr double spring_stiffness = 0
Examples
lesson8_contact.cpp.

Definition at line 66 of file lesson8_contact.cpp.

◆ young_modulus

constexpr double young_modulus = 10
Examples
lesson8_contact.cpp.

Definition at line 63 of file lesson8_contact.cpp.