v0.14.0
Classes | Typedefs | Functions | Variables
integration.cpp File Reference
#include <MoFEM.hpp>

Go to the source code of this file.

Classes

struct  Example
 [Example] More...
 
struct  Example::CommonData
 [Example] More...
 
struct  Example::OpZero
 [Common data] More...
 
struct  Example::OpFirst
 
struct  Example::OpSecond
 [Operator] More...
 

Typedefs

using Element = MoFEM::VolumeElementForcesAndSourcesCore
 
using OpElement = Element::UserDataOperator
 
using EntData = EntitiesFieldData::EntData
 

Functions

int main (int argc, char *argv[])
 [Test example] More...
 

Variables

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

Typedef Documentation

◆ Element

Definition at line 18 of file integration.cpp.

◆ EntData

Definition at line 20 of file integration.cpp.

◆ OpElement

Definition at line 19 of file integration.cpp.

Function Documentation

◆ main()

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

[Test example]

[main]

[Register MoFEM discrete manager in PETSc]

[Register MoFEM discrete manager in PETSc]

[Create MoAB]

< mesh database

< mesh database interface

[Create MoAB]

[Create MoFEM]

< finite element database

< finite element database interface

[Create MoFEM]

Definition at line 296 of file integration.cpp.

296  {
297 
298  // Initialisation of MoFEM/PETSc and MOAB data structures
299  const char param_file[] = "param_file.petsc";
300  MoFEM::Core::Initialize(&argc, &argv, param_file, help);
301 
302  // Error handling
303  try {
304 
305  //! [Register MoFEM discrete manager in PETSc]
306  DMType dm_name = "DMMOFEM";
307  CHKERR DMRegister_MoFEM(dm_name);
308  //! [Register MoFEM discrete manager in PETSc]
309 
310  //! [Create MoAB]
311  moab::Core mb_instance; ///< mesh database
312  moab::Interface &moab = mb_instance; ///< mesh database interface
313  //! [Create MoAB]
314 
315  //! [Create MoFEM]
316  MoFEM::Core core(moab); ///< finite element database
317  MoFEM::Interface &m_field = core; ///< finite element database interface
318  //! [Create MoFEM]
319 
320  Example ex(m_field);
321  CHKERR ex.runProblem();
322  }
323  CATCH_ERRORS;
324 
326 }

Variable Documentation

◆ help

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

Definition at line 16 of file integration.cpp.

MoFEM::CoreTmp< 0 >
Core (interface) class.
Definition: Core.hpp:82
MoFEM::CoreTmp< 0 >::Finalize
static MoFEMErrorCode Finalize()
Checks for options to be called at the conclusion of the program.
Definition: Core.cpp:112
help
static char help[]
Definition: integration.cpp:16
MoFEM::DeprecatedCoreInterface
Deprecated interface functions.
Definition: DeprecatedCoreInterface.hpp:16
MoFEM::Interface
DeprecatedCoreInterface Interface
Definition: Interface.hpp:2010
CHKERR
#define CHKERR
Inline error check.
Definition: definitions.h:548
Example
[Example]
Definition: plastic.cpp:177
MoFEM::DMRegister_MoFEM
PetscErrorCode DMRegister_MoFEM(const char sname[])
Register MoFEM problem.
Definition: DMMoFEM.cpp:43
MoFEM::CoreTmp< 0 >::Initialize
static MoFEMErrorCode Initialize(int *argc, char ***args, const char file[], const char help[])
Initializes the MoFEM database PETSc, MOAB and MPI.
Definition: Core.cpp:72
CATCH_ERRORS
#define CATCH_ERRORS
Catch errors.
Definition: definitions.h:385
MoFEM::Core
CoreTmp< 0 > Core
Definition: Core.hpp:1148