v0.10.0
Classes | Typedefs | Functions | Variables
lesson7_plastic.cpp File Reference
#include <MoFEM.hpp>
#include <ElasticOps.hpp>
#include <PlasticOps.hpp>

Go to the source code of this file.

Classes

struct  Example
 [Example] More...
 

Typedefs

using EntData = DataForcesAndSourcesCore::EntData
 
using DomainEle = FaceElementForcesAndSourcesCoreBase
 
using DomainEleOp = DomainEle::UserDataOperator
 
using BoundaryEle = EdgeElementForcesAndSourcesCoreBase
 
using BoundaryEleOp = BoundaryEle::UserDataOperator
 

Functions

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

Variables

constexpr double young_modulus = 1e1
 
constexpr double poisson_ratio = 0.25
 
constexpr double sigmaY = 1
 
constexpr double H = 1e-2
 
constexpr double cn = H
 
constexpr int order = 2
 
static char help [] = "...\n\n"
 [Check] More...
 

Typedef Documentation

◆ BoundaryEle

Definition at line 30 of file lesson7_plastic.cpp.

◆ BoundaryEleOp

Definition at line 31 of file lesson7_plastic.cpp.

◆ DomainEle

Definition at line 28 of file lesson7_plastic.cpp.

◆ DomainEleOp

Definition at line 29 of file lesson7_plastic.cpp.

◆ EntData

Examples
lesson7_plastic.cpp.

Definition at line 27 of file lesson7_plastic.cpp.

Function Documentation

◆ main()

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

Definition at line 395 of file lesson7_plastic.cpp.

395  {
396 
397  MoFEM::Core::Initialize(&argc, &argv, (char *)0, help);
398 
399  try {
400 
401  //! [Register MoFEM discrete manager in PETSc]
402  DMType dm_name = "DMMOFEM";
403  CHKERR DMRegister_MoFEM(dm_name);
404  //! [Register MoFEM discrete manager in PETSc
405 
406  //! [Create MoAB]
407  moab::Core mb_instance; ///< mesh database
408  moab::Interface &moab = mb_instance; ///< mesh database interface
409  //! [Create MoAB]
410 
411  //! [Create MoFEM]
412  MoFEM::Core core(moab); ///< finite element database
413  MoFEM::Interface &m_field = core; ///< finite element database insterface
414  //! [Create MoFEM]
415 
416  //! [Load mesh]
417  Simple *simple = m_field.getInterface<Simple>();
418  CHKERR simple->getOptions();
419  CHKERR simple->loadFile("");
420  //! [Load mesh]
421 
422  //! [Example]
423  Example ex(m_field);
424  CHKERR ex.runProblem();
425  //! [Example]
426  }
427  CATCH_ERRORS;
428 
430 }
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[]
[Check]
#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

◆ cn

constexpr double cn = H
Examples
lesson7_plastic.cpp.

Definition at line 37 of file lesson7_plastic.cpp.

◆ H

constexpr double H = 1e-2
Examples
lesson7_plastic.cpp.

Definition at line 36 of file lesson7_plastic.cpp.

◆ help

char help[] = "...\n\n"
static

[Check]

Examples
lesson7_plastic.cpp.

Definition at line 393 of file lesson7_plastic.cpp.

◆ order

constexpr int order = 2

◆ poisson_ratio

constexpr double poisson_ratio = 0.25

◆ sigmaY

constexpr double sigmaY = 1
Examples
lesson7_plastic.cpp.

Definition at line 35 of file lesson7_plastic.cpp.

◆ young_modulus

constexpr double young_modulus = 1e1
Examples
lesson7_plastic.cpp, and Remodeling.cpp.

Definition at line 33 of file lesson7_plastic.cpp.