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

Go to the source code of this file.

Classes

struct  Poisson2DHomogeneous
 

Typedefs

using PostProcFaceEle = PostProcBrokenMeshInMoab< DomainEle >
 

Functions

int main (int argc, char *argv[])
 [Run program] More...
 

Variables

constexpr auto field_name = "U"
 
constexpr int SPACE_DIM
 
static char help [] = "...\n\n"
 

Typedef Documentation

◆ PostProcFaceEle

Definition at line 23 of file poisson_2d_homogeneous.cpp.

Function Documentation

◆ main()

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

[Run program]

[Main]

Examples
poisson_2d_homogeneous.cpp.

Definition at line 374 of file poisson_2d_homogeneous.cpp.

374  {
375 
376  // Initialisation of MoFEM/PETSc and MOAB data structures
377  const char param_file[] = "param_file.petsc";
378  MoFEM::Core::Initialize(&argc, &argv, param_file, help);
379 
380  // Error handling
381  try {
382  // Register MoFEM discrete manager in PETSc
383  DMType dm_name = "DMMOFEM";
384  CHKERR DMRegister_MoFEM(dm_name);
385 
386  // Create MOAB instance
387  moab::Core mb_instance; // mesh database
388  moab::Interface &moab = mb_instance; // mesh database interface
389 
390  // Create MoFEM instance
391  MoFEM::Core core(moab); // finite element database
392  MoFEM::Interface &m_field = core; // finite element interface
393 
394  // Run the main analysis
395  Poisson2DHomogeneous poisson_problem(m_field);
396  CHKERR poisson_problem.runProgram();
397  }
398  CATCH_ERRORS;
399 
400  // Finish work: cleaning memory, getting statistics, etc.
402 
403  return 0;
404 }

Variable Documentation

◆ field_name

constexpr auto field_name = "U"
constexpr

◆ help

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

Definition at line 25 of file poisson_2d_homogeneous.cpp.

◆ SPACE_DIM

constexpr int SPACE_DIM
constexpr
Initial value:
Examples
poisson_2d_homogeneous.cpp.

Definition at line 15 of file poisson_2d_homogeneous.cpp.

EXECUTABLE_DIMENSION
#define EXECUTABLE_DIMENSION
Definition: plastic.cpp:13
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
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
MoFEM::DMRegister_MoFEM
PetscErrorCode DMRegister_MoFEM(const char sname[])
Register MoFEM problem.
Definition: DMMoFEM.cpp:43
Poisson2DHomogeneous
Definition: poisson_2d_homogeneous.cpp:27
help
static char help[]
Definition: poisson_2d_homogeneous.cpp:25
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